|
@@ -7,7 +7,6 @@ import com.ym.mec.auth.api.client.SysUserFeignService;
|
|
|
import com.ym.mec.auth.api.entity.SysUser;
|
|
|
import com.ym.mec.biz.dal.dao.*;
|
|
|
import com.ym.mec.biz.dal.dto.BasicUserDto;
|
|
|
-import com.ym.mec.biz.dal.dto.GoodsBatchNoDto;
|
|
|
import com.ym.mec.biz.dal.dto.GoodsSellDto;
|
|
|
import com.ym.mec.biz.dal.dto.RepairGoodsDto;
|
|
|
import com.ym.mec.biz.dal.entity.*;
|
|
@@ -262,7 +261,7 @@ public class StudentRepairServiceImpl extends BaseServiceImpl<Integer, StudentRe
|
|
|
List<GoodsSellDto> goodsSellDtos = JSONObject.parseArray(studentGoodsSell.getGoodsJson(),GoodsSellDto.class);
|
|
|
List<Integer> goodsIds = goodsSellDtos.stream().map(e -> e.getGoodsId()).collect(Collectors.toList());
|
|
|
|
|
|
- Map<Integer, BigDecimal> map = getMap("goods", "id_", "market_price_", goodsIds, Integer.class, BigDecimal.class);
|
|
|
+ Map<Integer, BigDecimal> map = getMap("goods", "id_", "discount_price_", goodsIds, Integer.class, BigDecimal.class);
|
|
|
for (GoodsSellDto goodsSellDto : goodsSellDtos) {
|
|
|
goodsSellDto.setGoodsPrice(map.get(goodsSellDto.getGoodsId()));
|
|
|
goodsSellDto.setTotalGoodsPrice(map.get(goodsSellDto.getGoodsId()).multiply(new BigDecimal(goodsSellDto.getGoodsNum())));
|
|
@@ -805,6 +804,9 @@ public class StudentRepairServiceImpl extends BaseServiceImpl<Integer, StudentRe
|
|
|
parentGoodsAddTotalPriceMap.put(sellOrder.getParentGoodsId(),parentTotalGoodsPrice.subtract(totalGoodsPrice));
|
|
|
}else if(parentTotalGoodsPrice.compareTo(totalGoodsPrice) == -1){//小于
|
|
|
parentGoodsCutTotalPriceMap.put(sellOrder.getParentGoodsId(),totalGoodsPrice.subtract(parentTotalGoodsPrice));
|
|
|
+ }else {
|
|
|
+ parentGoodsCutTotalPriceMap.put(sellOrder.getParentGoodsId(),BigDecimal.ZERO);
|
|
|
+ parentGoodsAddTotalPriceMap.put(sellOrder.getParentGoodsId(),BigDecimal.ZERO);
|
|
|
}
|
|
|
}
|
|
|
//分配组合商品的中单个商品的价格
|