Browse Source

[feat]新增采购订单子表数据筛选供应商编号,采购计划单号。

dev
zhangsiqi 4 months ago
parent
commit
868fd3d71c
  1. 12
      ruoyi-admin/src/main/java/com/ruoyi/purchase/controller/PurchaseOrderController.java

12
ruoyi-admin/src/main/java/com/ruoyi/purchase/controller/PurchaseOrderController.java

@ -185,6 +185,18 @@ public class PurchaseOrderController extends BaseController
public String edit(@PathVariable("purchaseOrderId") Long purchaseOrderId, ModelMap mmap)
{
PurchaseOrder purchaseOrder = purchaseOrderService.selectPurchaseOrderById(purchaseOrderId);
//获取子表信息
List<PurchaseOrderChild> purchaseOrderChildList = purchaseOrderChildService.selectPurchaseOrderChildByOrderCode(purchaseOrder.getPurchaseOrderCode());
//Set<String>子表供应商的信息 供应商编号-供应商名称
//Set<String>子表采购计划单信息
Set<String> supplierCodes = new HashSet<>();
Set<String> purchasePlanCodes = new HashSet<>();
for(PurchaseOrderChild purchaseOrderChild : purchaseOrderChildList){
supplierCodes.add(purchaseOrderChild.getSupplierCode());
purchasePlanCodes.add(purchaseOrderChild.getPurchasePlanCode());
}
mmap.put("supplierCodes", supplierCodes);
mmap.put("purchasePlanCodes", purchasePlanCodes);
mmap.put("purchaseOrder", purchaseOrder);
return prefix + "/edit";
}

Loading…
Cancel
Save