diff --git a/ruoyi-admin/src/main/java/com/ruoyi/system/controller/SysMakeOrderController.java b/ruoyi-admin/src/main/java/com/ruoyi/system/controller/SysMakeOrderController.java index 147e2f46..2a1aabbb 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/system/controller/SysMakeOrderController.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/system/controller/SysMakeOrderController.java @@ -9,10 +9,12 @@ import com.ruoyi.common.core.domain.entity.SysUser; import com.ruoyi.common.core.page.TableDataInfo; import com.ruoyi.common.enums.BusinessType; import com.ruoyi.common.utils.ShiroUtils; +import com.ruoyi.common.utils.StringUtils; import com.ruoyi.common.utils.poi.ExcelUtil; import com.ruoyi.erp.service.IErpMaterialService; import com.ruoyi.system.domain.SysMakeOrder; import com.ruoyi.system.domain.SysMakeorderDept; +import com.ruoyi.system.domain.SysSalesOrder; import com.ruoyi.system.domain.SysSalesOrderChild; import com.ruoyi.system.dto.SysEquipMaterialDto; import com.ruoyi.system.dto.SysMakeorderDeptDto; @@ -52,6 +54,9 @@ public class SysMakeOrderController extends BaseController @Autowired private ISysSalesOrderChildService salesOrderChildService; + @Autowired + private ISysSalesOrderService salesOrderService; + @GetMapping("/test") public AjaxResult test(){ sysMakeOrderService.generateMakeOrderBySalesOrderCode("XS20240411007"); @@ -108,6 +113,10 @@ public class SysMakeOrderController extends BaseController { mmap.put("currentUser", ShiroUtils.getSysUser()); SysMakeOrder sysMakeOrder = sysMakeOrderService.selectSysMakeOrderById(id); + SysSalesOrder sysSalesOrder = salesOrderService.selectSysSalesOrderBySalesOrderCode(sysMakeOrder.getSaleNo()); + if(StringUtils.isNotNull(sysSalesOrder)){ + sysMakeOrder.setOrderType(sysSalesOrder.getSalesOrderType()); + } mmap.put("sysMakeOrder", sysMakeOrder); return prefix + "/addPick"; } @@ -120,6 +129,10 @@ public class SysMakeOrderController extends BaseController { mmap.put("currentUser", ShiroUtils.getSysUser()); SysMakeOrder sysMakeOrder = sysMakeOrderService.selectSysMakeOrderById(id); + SysSalesOrder sysSalesOrder = salesOrderService.selectSysSalesOrderBySalesOrderCode(sysMakeOrder.getSaleNo()); + if(StringUtils.isNotNull(sysSalesOrder)){ + sysMakeOrder.setOrderType(sysSalesOrder.getSalesOrderType()); + } mmap.put("sysMakeOrder", sysMakeOrder); return prefix + "/addProcessInbound"; } diff --git a/ruoyi-admin/src/main/java/com/ruoyi/system/domain/SysMakeOrder.java b/ruoyi-admin/src/main/java/com/ruoyi/system/domain/SysMakeOrder.java index 8ef85dd1..5055782f 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/system/domain/SysMakeOrder.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/system/domain/SysMakeOrder.java @@ -42,6 +42,8 @@ public class SysMakeOrder extends BaseEntity @Excel(name = "关联销售订单号") private String saleNo; + @Excel(name = "订单类型") + private String orderType; /** 业务员 */ @Excel(name = "业务员") private String Salesman; @@ -158,7 +160,16 @@ public class SysMakeOrder extends BaseEntity this.Salesman = Salesman; } - public String getSalesman() + + public String getOrderType() { + return orderType; + } + + public void setOrderType(String orderType) { + this.orderType = orderType; + } + + public String getSalesman() { return Salesman; } diff --git a/ruoyi-admin/src/main/resources/templates/erp/inboundOrder/add.html b/ruoyi-admin/src/main/resources/templates/erp/inboundOrder/add.html index a36608c4..23f8dbe5 100644 --- a/ruoyi-admin/src/main/resources/templates/erp/inboundOrder/add.html +++ b/ruoyi-admin/src/main/resources/templates/erp/inboundOrder/add.html @@ -6,18 +6,6 @@
-
- -
- -
-
-
- -
- -
-
@@ -30,39 +18,338 @@
-
- +
+
- +
-
- -
- -
-
-
- +
+
-
- -
- -
-
+
+
+