Merge remote-tracking branch 'origin/main'

This commit is contained in:
Jack 2025-10-31 16:04:01 +08:00
commit 002baf3ffd

View File

@ -207,6 +207,7 @@ public class ProductMappingServiceImpl extends BaseServiceImpl<ProductMappingMap
*/
@Transactional
public void dealData(List<ShopProductBase> shopProductBaseList,Map shopProductSpecItemMap,Map ShopBaseProductSpecMap, Map<String,ProductMapping> productMappingMap,boolean isUpdate,String isPublish){
Date currentDate=new Date();
List<ShopProductItem> shopProductItems=findShopProductItemsList(shopProductBaseList);
Map<String,Integer> shopProductItemCategoryIdMap=new HashMap<>();
shopProductItemCategoryIdMap=shopProductItems.stream().collect(Collectors.toMap(ShopProductItem::getItem_number,ShopProductItem::getCategory_id,
@ -243,8 +244,10 @@ public class ProductMappingServiceImpl extends BaseServiceImpl<ProductMappingMap
// shopProductItems.get(i).setItem_enable(StateCode.PRODUCT_STATE_OFF_THE_SHELF);
}
if(StringUtils.isNotEmpty(shopProductBaseList.get(i).getProduct_image())){
shopProductBaseList.get(i).setProduct_sale_time(currentDate);
shopProductBaseList.get(i).setProduct_state_id(StateCode.PRODUCT_STATE_NORMAL);
shopProductIndex.setProduct_state_id(StateCode.PRODUCT_STATE_NORMAL);
shopProductIndex.setProduct_sale_time(currentDate.getTime());
shopProductItems.get(i).setItem_enable(StateCode.PRODUCT_STATE_NORMAL);
}