商品同步 关联Id

This commit is contained in:
2025-04-12 17:30:03 +08:00
parent 03f40c4ae7
commit 154a1a0930

View File

@@ -620,7 +620,7 @@ public class ShopSyncServiceImpl implements ShopSyncService {
List<Map<String, Object>> mainMapList = new ArrayList<>();
Map<Long, String> dataMap = new HashMap<>();
Product newEntity = BeanUtil.copyProperties(mainEntity, Product.class);
newEntity.setSyncId(mainEntity.getSyncId());
newEntity.setSyncId(mainEntity.getId());
newEntity.setShopId(shopId);
newEntity.setCategoryId(newEntity.getCategoryId() != null ? categoryMap.get(shopId) : null);
newEntity.setSpecId(newEntity.getSpecId() != null ? specMap.get(shopId) : null);