|
@@ -161,13 +161,13 @@ public class ProductService {
|
|
|
|
|
|
for(PackageProductRelation rel : currentRelationList){
|
|
|
//skip pid not belong merchant
|
|
|
-
|
|
|
- if(null == merchantProductRepository.findByPidAndMerchantId(pid, merchantId)){
|
|
|
- log.info("Skip, Pid not Belong Merchant, pid={}, merchantId={}", pid, merchantId);
|
|
|
+ String pkgId = rel.getPkgId();
|
|
|
+ if(null == pkgId || null == merchantProductRepository.findByPidAndMerchantId(pkgId, merchantId)){
|
|
|
+ log.info("Skip, pkgId not Belong Merchant, pkgId={}, merchantId={}", pkgId, merchantId);
|
|
|
continue;
|
|
|
}
|
|
|
|
|
|
- pids.add(rel.getPkgId());
|
|
|
+ pids.add(pkgId);
|
|
|
}
|
|
|
|
|
|
if (pids.isEmpty()){
|