渠道 兼容

This commit is contained in:
2026-01-23 10:15:53 +08:00
parent 3dcc649224
commit b9e768bd47

View File

@@ -14,7 +14,6 @@ import com.czg.pay.PolyMerchantDTO;
import com.czg.service.order.mapper.ShopMerchantMapper;
import com.czg.service.order.service.ShopDirectMerchantService;
import com.czg.utils.AssertUtil;
import com.czg.utils.CzgStrUtils;
import com.mybatisflex.spring.service.impl.ServiceImpl;
import jakarta.annotation.Resource;
import jakarta.validation.constraints.NotBlank;
@@ -81,7 +80,9 @@ public class ShopMerchantServiceImpl extends ServiceImpl<ShopMerchantMapper, Sho
}
shopMerchant.setShopId(shopMerchantParam.getShopId());
if (isUp) {
shopMerchant.setChannel(CzgStrUtils.getStrOrNull(shopMerchantParam.getChannel()));
if (StrUtil.isNotBlank(shopMerchantParam.getChannel())) {
shopMerchant.setChannel(shopMerchantParam.getChannel());
}
shopMerchant.setRelatedId(shopMerchantParam.getRelatedId());
if (shopMerchant.getRelatedId() != null && !shopMerchantParam.getRelatedId().equals(shopMerchant.getRelatedId())) {
ShopDirectMerchant shopDirectMerchant = shopDirectMerchantService.getById(shopMerchant.getRelatedId());