From 81aef1730430160f0ffe2c4b74249d30c300dd1e Mon Sep 17 00:00:00 2001 From: zhangsiqi <2825463979@qq.com> Date: Wed, 10 Jul 2024 20:31:40 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=EF=BC=9A=E4=BF=AE=E5=A4=8D?= =?UTF-8?q?=EF=BC=8C=E4=BF=AE=E5=A4=8D=E5=AE=A2=E6=88=B7=E6=8A=A5=E4=BB=B7?= =?UTF-8?q?=E4=B8=9A=E5=8A=A1=E7=BB=8F=E7=90=86=E5=AE=A1=E6=A0=B8=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2=EF=BC=8C=E6=8A=A5=E4=BB=B7=E8=AE=A1=E7=AE=97=E6=9C=89?= =?UTF-8?q?=E8=AF=AF=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../templates/system/customerQuote/add.html | 89 +++++---- .../system/customerQuote/detail.html | 27 +-- .../templates/system/customerQuote/edit.html | 22 +-- .../system/customerQuote/taskModifyApply.html | 172 ++++++++++-------- .../system/customerQuote/taskYwjlVerify.html | 100 +++++----- .../system/customerQuote/taskYwzgVerify.html | 65 ++++--- .../system/customerQuote/taskZozjVerify.html | 87 ++++----- 7 files changed, 276 insertions(+), 286 deletions(-) diff --git a/ruoyi-admin/src/main/resources/templates/system/customerQuote/add.html b/ruoyi-admin/src/main/resources/templates/system/customerQuote/add.html index 2a1da822..f722f360 100644 --- a/ruoyi-admin/src/main/resources/templates/system/customerQuote/add.html +++ b/ruoyi-admin/src/main/resources/templates/system/customerQuote/add.html @@ -145,6 +145,7 @@ var sysUnitClassDatas = [[${@dict.getType('sys_unit_class')}]]; var processMethodDatas = [[${@dict.getType('processMethod')}]]; var userName = [[${@permission.getPrincipalProperty('userName')}]]; + var loginName = [[${@permission.getPrincipalProperty('loginName')}]]; var prefix = ctx + "system/customerQuote"; var commonCurrency = $("#commonCurrency_add option:selected").val(); $("#form-customerQuote-add").validate({focusCleanup: true}); @@ -166,11 +167,9 @@ } } } - //获取客户信息 - - // 监听客户编号下拉框的变化 - $('#customerCode').on('change', function() { + // 监听客户编号下拉框的变化 + $('#customerCode').on('change', function() { var selectedCustomerCode = $(this).val(); // 获取选中的客户ID if (selectedCustomerCode) { // 发起Ajax请求获取客户名称 @@ -208,14 +207,12 @@ $('input[name="customerName"]').val(''); } }); - - $(document).ready(function() { // 初始化时默认加载客户编号列表 loadCustomerIds(); }); // 假设的加载客户编号列表函数 - function loadCustomerIds() { + function loadCustomerIds() { var url = ctx + 'system/customer/getCustomers'; $.ajax({ type: 'GET', // 请求类型 @@ -245,9 +242,6 @@ } }); } - - - //添加收款明细 function insertNoMaterialNoRow() { // 生成一个简单的唯一标识,这里使用时间戳作为示例 @@ -270,8 +264,6 @@ } - - $(function() { var options = { id:'bootstrap-sub-table-quoteChild', @@ -544,46 +536,51 @@ // 可以选择取消这次编辑操作,但Bootstrap Table默认不会提供直接的API来取消编辑后的保存,您可能需要手动恢复数据或采取其他策略。 } }); - // 初始化时也需要根据当前的货币类型设置一次 $("#commonCurrency_add").trigger('change'); + getBusinessMembers(); + getCustomerCode(); }); - //获取单号 - $.ajax({ - url: prefix + "/getId", - type: "post", - dateType: "json", - success: function (resp) { - if (resp.code === 0) { - $("input[name='supplierCode']").val(resp.data); - } else { - $.modal.msgError("失败啦"); + function getCustomerCode(){ + //获取单号 + $.ajax({ + url: prefix + "/getId", + type: "post", + dateType: "json", + success: function (resp) { + if (resp.code === 0) { + $("input[name='supplierCode']").val(resp.data); + } else { + $.modal.msgError("失败啦"); + } + }, + error: function () { + $.modal.msgError("后台出错啦!"); } - }, - error: function () { - $.modal.msgError("后台出错啦!"); - } - }); - /*业务员列表*/ - $.ajax({ - url: ctx + 'system/salesOrder/getBinessMembers', - type: 'get', - success: function (res) { - console.log(res) - if (res.rows.length > 0) { - var usertData = res.rows; - //alert(JSON.stringify(data)); - for (let i in usertData) { - // console.log(finishProductData[i].finishProductCode) - $("#form-customerQuote-add select[name='businessMembers']").append( - ""); + }); + } + function getBusinessMembers(){ + /*业务员列表*/ + $.ajax({ + url: ctx + 'system/salesOrder/getBinessMembers', + type: 'get', + success: function (res) { + console.log(res) + if (res.rows.length > 0) { + var usertData = res.rows; + //alert(JSON.stringify(data)); + for (let i in usertData) { + // console.log(finishProductData[i].finishProductCode) + $("#form-customerQuote-add select[name='businessMembers']").append( + ""); + } + $("#form-customerQuote-add select[name='businessMembers']").val(loginName).trigger("change"); + } else { + $.modal.msgError(res.msg); } - $("#form-customerQuote-add select[name='businessMembers']").val(userName).trigger("change"); - } else { - $.modal.msgError(res.msg); } - } - }); + }); + } function doSubmit(index, layero,uniqueId){ console.log(uniqueId); var iframeWin = window[layero.find('iframe')[0]['name']]; diff --git a/ruoyi-admin/src/main/resources/templates/system/customerQuote/detail.html b/ruoyi-admin/src/main/resources/templates/system/customerQuote/detail.html index 4a5e27d6..df0750e0 100644 --- a/ruoyi-admin/src/main/resources/templates/system/customerQuote/detail.html +++ b/ruoyi-admin/src/main/resources/templates/system/customerQuote/detail.html @@ -70,7 +70,10 @@