rsf-admin/src/page/orders/config/orderItemColumns.jsx
@@ -53,9 +53,9 @@ <TruncatedTextField source="maktx" label="table.field.asnOrderItem.maktx" key="maktx" maxLength={20} />, //物料名称 <TextField source="batch" label="table.field.asnOrderItem.splrBatch" key="batch" />, //批次 <TextField source="spec" label="table.field.asnOrderItem.spec" key="spec" />, //规格 <TextField source="stockUnit" label="table.field.asnOrderItem.unit" key="stockUnit" />, //单位 <NumberField source="anfme" label="table.field.asnOrderItem.anfme" key="anfme" />, //应收数量 <NumberField source="qty" label="table.field.asnOrderItem.qty" key="qty" />, //实收数量 <TextField source="stockUnit" label="table.field.asnOrderItem.unit" key="stockUnit" />, //单位 <TextField source="targetWarehouseId" label="table.field.asnOrderItem.targetWarehouseId" key="targetWarehouseId" />, //建议目标仓 ]; rsf-admin/src/page/waitPakin/WaitPakinItemList.jsx
@@ -169,9 +169,9 @@ <TextField source="matnrCode" label="table.field.waitPakinItem.matnrCode" />, <TextField source="maktx" label="table.field.waitPakinItem.maktx" />, <TextField source="batch" label="table.field.waitPakinItem.batch" />, <TextField source="unit" label="table.field.waitPakinItem.unit" />, <NumberField source="anfme" label="table.field.waitPakinItem.anfme" />, // <NumberField source="qty" label="table.field.waitPakinItem.qty" />, <TextField source="unit" label="table.field.waitPakinItem.unit" />, <TextField source="platOrderCode" label="table.field.asnOrderItem.platOrderCode" />, <TextField source="projectCode" label="table.field.asnOrderItem.projectCode" />, <NumberField source="workQty" label="table.field.waitPakinItem.workQty" />, rsf-server/src/main/java/com/vincent/rsf/server/api/controller/erp/params/InventoryQueryConditionParam.java
@@ -61,6 +61,12 @@ private String matGroup; /** * 库区 */ @ApiModelProperty(value = "库区") private String wareHouseAreaId; /** * 从Map构造InventoryQueryConditionParam对象 * 用于接收其他方法返回的Map参数并自动转换 * @@ -93,6 +99,9 @@ if (map.containsKey("matGroup")) { param.setMatGroup((String) map.get("matGroup")); } if (map.containsKey("wareHouseAreaId")) { param.setMatGroup((String) map.get("wareHouseAreaId")); } return param; } @@ -124,6 +133,9 @@ if (matGroup != null) { map.put("matGroup", matGroup); } if (wareHouseAreaId != null) { map.put("wareHouseAreaId", wareHouseAreaId); } return map; } } rsf-server/src/main/java/com/vincent/rsf/server/api/controller/pda/InBoundController.java
@@ -2,19 +2,21 @@ import com.vincent.rsf.framework.common.Cools; import com.vincent.rsf.framework.common.R; import com.vincent.rsf.server.api.controller.erp.params.InventoryQueryConditionParam; import com.vincent.rsf.server.api.entity.params.PdaGeneralParam; import com.vincent.rsf.server.api.service.InBoundService; import com.vincent.rsf.server.api.service.ReceiveMsgService; import com.vincent.rsf.server.common.annotation.OperationLog; import com.vincent.rsf.server.system.controller.BaseController; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.security.access.prepost.PreAuthorize; import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.RequestBody; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RestController; import java.util.Map; import javax.annotation.Resource; @Api(tags = "PDA入库操作接口") @RequestMapping("/pda") @@ -23,6 +25,8 @@ @Autowired private InBoundService inBoundService; @Resource private ReceiveMsgService receiveMsgService; @PostMapping("/in/emptyContainer/warehousing") @ApiOperation("空容器入库") @@ -48,4 +52,22 @@ return inBoundService.checkNonOrder(param, getLoginUserId()); } /** * 库存查询明细 * * @param condition 查询条件 * @return 库存明细列表 */ @PostMapping("/inventory/details") @ApiOperation(value = "库存查询明细", hidden = true) @OperationLog("库存查询明细") public R queryInventoryDetails(@RequestBody InventoryQueryConditionParam condition) { // 参数验证 if (condition == null) { return R.error("查询条件不能为空"); } return receiveMsgService.erpQueryInventoryDetails(condition); } } rsf-server/src/main/java/com/vincent/rsf/server/api/service/impl/ReceiveMsgServiceImpl.java
@@ -1124,6 +1124,32 @@ } } // 仓库编码过滤 if (StringUtils.isNotBlank(condition.getWareHouseAreaId())) { String wareHouseAreaId = condition.getWareHouseAreaId(); LambdaQueryWrapper<WarehouseAreas> whWrapper = new LambdaQueryWrapper<>(); whWrapper.eq(WarehouseAreas::getCode, wareHouseAreaId); // 调用WarehouseService查询仓库信息(复用Service层方法) List<WarehouseAreas> warehouses = warehouseAreasService.list(whWrapper); if (!warehouses.isEmpty()) { Long targetWarehouseId = warehouses.get(0).getId(); // 过滤库位,只保留目标仓库的库位 locMap = locMap.entrySet().stream() .filter(entry -> Objects.equals(entry.getValue().getAreaId(), targetWarehouseId)) .collect(Collectors.toMap(Map.Entry::getKey, Map.Entry::getValue)); // 过滤locItems,只保留目标仓库的 Set<Long> validLocIds = locMap.keySet(); locItems = locItems.stream() .filter(item -> item.getLocId() != null && validLocIds.contains(item.getLocId())) .collect(Collectors.toList()); List<Long> warehouseAreaIds = Collections.singletonList(targetWarehouseId); } else { return R.ok().add(new ArrayList<>()); } } // 调用WarehouseService查询仓库信息(复用Service层方法) Map<Long, Warehouse> warehouseMap = new HashMap<>(); if (!warehouseIds.isEmpty()) {