1688授权回调相关修改

20230922-ljl-fixBug
cxxxxxxx详 1 year ago
parent 0cf41447f8
commit ad47ae4d92

@ -13,6 +13,8 @@ import com.ms.api.service.ShopService;
import com.ms.api.service.ShopTo1688DsMemberService;
import com.ms.api.tool.CommonTool;
import com.ms.dal.entity.Shop;
import com.ms.dal.entity.Shop1688DsAuth;
import com.ms.dal.entity.ShopTo1688DsMember;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
@ -34,12 +36,16 @@ public class MemberAuthCallback extends SPIBaseService implements ExtensionServi
// ----参数校验----
MemberAuthCallBackRequestDTO fields = req.getData();
// Shop shop = shop1688DsAuthService.selectByPrimaryKey();
// if (Objects.isNull(shop)) {
// shop = new Shop();
// shop.setShopId(shopId);
// shopService.insert(shop);
// }
Shop1688DsAuth shop1688DsAuth = new Shop1688DsAuth();
shop1688DsAuth.setAuthCode(fields.getAuthCode());
shop1688DsAuth.setShopId(shopId);
shop1688DsAuthService.insert(shop1688DsAuth);
ShopTo1688DsMember shopTo1688DsMember= new ShopTo1688DsMember();
shopTo1688DsMember.setCnaliMemberId(fields.getCnaliMemberId());
shopTo1688DsMember.setShopId(shopId);
// shopTo1688DsMember.setGmtExpire(fields.getGmtMemberExpireTime());
shopTo1688DsMemberService.insert(shopTo1688DsMember);
log.info("receive callback: " + JSON.toJSONString(fields));

Loading…
Cancel
Save