优化商品成本价的计算逻辑,解决计算查询的bug

This commit is contained in:
jishenghua
2025-06-30 22:08:56 +08:00
parent 30007c1c3d
commit 3b7b13eaee
2 changed files with 3 additions and 2 deletions

View File

@@ -1062,7 +1062,8 @@ public class DepotItemService {
@Transactional(value = "transactionManager", rollbackFor = Exception.class)
public void updateCurrentUnitPrice(DepotItem depotItem) throws Exception {
Boolean forceFlag = systemConfigService.getForceApprovalFlag();
Boolean inOutManageFlag = systemConfigService.getInOutManageFlag();
//此处给出入库管理的传值默认为false不然会导致查询不到销售相关的单据
Boolean inOutManageFlag = false;
//查询多单位信息
Unit unitInfo = materialService.findUnit(depotItem.getMaterialId());
List<DepotItemVo4DetailByTypeAndMId> itemList = findDetailByDepotIdsAndMaterialIdList(null, forceFlag, inOutManageFlag, depotItem.getSku(),