Commit defeae42 authored by 332784038@qq.com's avatar 332784038@qq.com

Merge branch 'master-fix' into dev

# Conflicts:
#	yudao-module-product/yudao-module-product-core/src/main/java/cn/iocoder/yudao/module/product/service/product/impl/ProductPriceServiceImpl.java
parents 9019db04 8856a394
......@@ -3371,7 +3371,7 @@ public class ProductPriceServiceImpl extends AbstractService<ProductPriceMapper,
.collect(toList());
if (CollectionUtil.isNotEmpty(stepSpecialList)) {
Map<String, ProductPriceStepSpecialDO> stepSpecialMap = stepSpecialList.stream()
.collect(Collectors.toMap(ProductPriceStepSpecialDO::getSpecialDictType, v -> v));
.collect(Collectors.toMap(ProductPriceStepSpecialDO::getSpecialDictType, v -> v, (v1, v2) -> v2));
List<ProductPriceStepSpecialDO> dbStepSpecialList = stepSpecialGroupMap.get(dbStep.getId());
if (CollectionUtil.isEmpty(dbStepSpecialList)) continue;
for (ProductPriceStepSpecialDO dbStepSpecial : dbStepSpecialList) {
......@@ -3561,7 +3561,7 @@ public class ProductPriceServiceImpl extends AbstractService<ProductPriceMapper,
dbItem.setProductId(productDO.getId());
dbItem.setWarehouseLineId(lineId);
dbItem.setShippingChannelId(shippingChannelId);
dbItem.setId(null);
if (dbItem.getNeedBook() == null) {
dbItem.setNeedBook(0);
}
......@@ -3589,13 +3589,14 @@ public class ProductPriceServiceImpl extends AbstractService<ProductPriceMapper,
dbItem.setBlacklist(0);
dbItem.setStatus(0);
dbItem.setCreateTime(current);
dbItem.setId(null);
}
dbItem.setUpdateTime(current);
String transportType = lineTransportTypeMap.get(lineId);
initBasePrice(dbItem, transportType);
if (Objects.isNull(dbItem.getId())){
productPriceMapper.insert(dbItem);
productPriceMapper.insert(dbItem);
}else {
productPriceMapper.updateById(dbItem);
}
......
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