Commit e78d5f76 by yinyong

处理调拨单数据sku为null问题

parent eec6eb31
......@@ -100,9 +100,11 @@ public class SyncCostFirstJob extends PointJob {
} catch (Exception e) {
throw new RuntimeException("BeanUtils.copyProperties失败, ChannelId是" + costFirstData.getChannelId());
}
int i = baseCostFirstMapper.updateByExampleSelective(dcBaseCostFirst, DcBaseCostFirstExample.newAndCreateCriteria().andBailunSkuEqualTo(dcBaseCostFirst.getBailunSku()).andChannelIdEqualTo(dcBaseCostFirst.getChannelId()).example());
if (i == 0) {
baseCostFirstMapper.insertSelective(dcBaseCostFirst);
if(StringUtils.isNotBlank(dcBaseCostFirst.getBailunSku())) {
int i = baseCostFirstMapper.updateByExampleSelective(dcBaseCostFirst, DcBaseCostFirstExample.newAndCreateCriteria().andBailunSkuEqualTo(dcBaseCostFirst.getBailunSku()).andChannelIdEqualTo(dcBaseCostFirst.getChannelId()).example());
if (i == 0) {
baseCostFirstMapper.insertSelective(dcBaseCostFirst);
}
}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment