From 1acb4040ddacb2ba95141eeaed7fb3e1487f631d Mon Sep 17 00:00:00 2001 From: liuxiaoxu <1793812695@qq.com> Date: Fri, 23 Aug 2024 19:39:47 +0800 Subject: [PATCH] =?UTF-8?q?[fix]=20=E9=94=80=E5=94=AE=E7=AE=A1=E7=90=86=20?= =?UTF-8?q?=E4=BF=AE=E6=94=B9=E9=94=80=E5=94=AE=E5=8F=91=E8=B5=B7=E5=87=BA?= =?UTF-8?q?=E8=B4=A7=E5=89=8D=E7=AB=AF=E5=88=97=E8=A1=A8=E9=A1=B5=E9=9D=A2?= =?UTF-8?q?=EF=BC=9A=E6=96=B0=E5=A2=9E=E6=94=B6=E8=B4=A7=E8=81=94=E7=B3=BB?= =?UTF-8?q?=E4=BA=BA=E4=B8=BA=E4=B8=8B=E6=8B=89=E9=80=89=E6=8B=A9=EF=BC=8C?= =?UTF-8?q?=E6=94=B6=E8=B4=A7=E7=94=B5=E8=AF=9D=E5=92=8C=E6=94=B6=E8=B4=A7?= =?UTF-8?q?=E5=9C=B0=E5=9D=80=E4=B8=BA=E8=87=AA=E5=8A=A8=E8=B5=8B=E5=80=BC?= =?UTF-8?q?=EF=BC=9B=E6=96=B0=E5=A2=9E=E6=94=B6=E8=B4=A7=E8=81=94=E7=B3=BB?= =?UTF-8?q?=E4=BA=BA=E4=B8=8B=E6=8B=89=E9=80=89=E6=8B=A9=E5=89=8D=E7=AB=AF?= =?UTF-8?q?js=E6=96=B9=E6=B3=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../SysSalesShippingInformController.java | 6 +- .../system/salesOrder/salesDeliverGoods.html | 75 ++++++++++++++++++- 2 files changed, 74 insertions(+), 7 deletions(-) diff --git a/ruoyi-admin/src/main/java/com/ruoyi/system/controller/SysSalesShippingInformController.java b/ruoyi-admin/src/main/java/com/ruoyi/system/controller/SysSalesShippingInformController.java index 70f31264..3396cbc3 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/system/controller/SysSalesShippingInformController.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/system/controller/SysSalesShippingInformController.java @@ -90,7 +90,7 @@ public class SysSalesShippingInformController extends BaseController * 导出出货单1模板 * */ @RequiresPermissions("system:salesShippingInform:exportShippingOrderOne") - @Log(title = "采购订单", businessType = BusinessType.EXPORT) + @Log(title = "销售出货单", businessType = BusinessType.EXPORT) @GetMapping("/exportShippingOrderOne/{outOrderCode}") public void exportShippingOrderOne(@PathVariable("outOrderCode") String outOrderCode,HttpServletResponse response) { @@ -103,7 +103,7 @@ public class SysSalesShippingInformController extends BaseController * 导出出货单2模板 * */ @RequiresPermissions("system:salesShippingInform:exportShippingOrderTwo") - @Log(title = "采购订单", businessType = BusinessType.EXPORT) + @Log(title = "销售出货单", businessType = BusinessType.EXPORT) @GetMapping("/exportShippingOrderTwo/{outOrderCode}") public void exportShippingOrderTwo(@PathVariable("outOrderCode") String outOrderCode,HttpServletResponse response) { @@ -116,7 +116,7 @@ public class SysSalesShippingInformController extends BaseController * 导出出货单通知单模板 * */ @RequiresPermissions("system:salesShippingInform:exportShippingInformOrder") - @Log(title = "采购订单", businessType = BusinessType.EXPORT) + @Log(title = "销售出货单", businessType = BusinessType.EXPORT) @GetMapping("/exportShippingInformOrder/{outOrderCode}") public void exportShippingInformOrder(@PathVariable("outOrderCode") String outOrderCode,HttpServletResponse response) { diff --git a/ruoyi-admin/src/main/resources/templates/system/salesOrder/salesDeliverGoods.html b/ruoyi-admin/src/main/resources/templates/system/salesOrder/salesDeliverGoods.html index 073fe82e..79ccbff1 100644 --- a/ruoyi-admin/src/main/resources/templates/system/salesOrder/salesDeliverGoods.html +++ b/ruoyi-admin/src/main/resources/templates/system/salesOrder/salesDeliverGoods.html @@ -50,19 +50,22 @@
- +
- + +
- +
- +
@@ -138,6 +141,70 @@ $.operate.saveJson(prefix + "/salesDeliverGoods", jsonData); } + + + loadCustomerDelivery(); + //获取已经选择客户Id相关的生产单号 + function loadCustomerDelivery() { + const url = ctx + 'system/customer/shippingList'; + const data = { + enterpriseCode: sysSalesOrder.enterpriseCode, + }; + + // 使用 $.ajax 发送请求 + $.ajax({ + type: 'POST', + url: url, + dataType: 'json', + data: data, + success: function(response) { + console.log("response:", response); + + if (response.code === 0 && Array.isArray(response.rows) && response.rows.length > 0) { + const selectElement = $('#customerDelivery'); + selectElement.empty(); + + // 存储每个客户名称对应的信息 + const customerDataMap = {}; + + // 遍历返回的数据,添加为下拉框的选项并存储数据 + $.each(response.rows, function(index, item) { + const customerName = item.customerName; + customerDataMap[customerName] = item; // 存储数据 + + // 添加选项到下拉框 + selectElement.append($('