From b495fb319a41a858856281a318d03c5768c93759 Mon Sep 17 00:00:00 2001 From: wangjiuyun <1595161655@qq.com> Date: Thu, 5 Jun 2025 17:15:21 +0800 Subject: [PATCH] =?UTF-8?q?=E5=90=88=E5=90=8C=E6=A1=A3=E6=A1=88=E7=BC=96?= =?UTF-8?q?=E8=BE=91=E4=BB=A3=E7=90=86=E5=95=86=E5=90=8C=E6=AD=A5=E5=8A=9F?= =?UTF-8?q?=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../templates/manage/order/edit.html | 29 ++++++++- .../templates/project/order/order.html | 62 +------------------ 2 files changed, 30 insertions(+), 61 deletions(-) diff --git a/ruoyi-admin/src/main/resources/templates/manage/order/edit.html b/ruoyi-admin/src/main/resources/templates/manage/order/edit.html index 4c7f4c99..ea0c0bc4 100644 --- a/ruoyi-admin/src/main/resources/templates/manage/order/edit.html +++ b/ruoyi-admin/src/main/resources/templates/manage/order/edit.html @@ -86,6 +86,8 @@ + @@ -276,10 +278,21 @@ } $('[name="orderPartnerCode"]').val(rows[0].partnerCode); $('[name="orderPartnerName"]').val(rows[0].partnerName); - - + $('#customerSet').attr('partnerName', rows[0].partnerName); + $('#customerSet').attr('contactPerson', rows[0].contactPerson); + $('#customerSet').attr('contactPhone', rows[0].contactPhone); $.modal.close(index); } + function initCustomerSet(){ + $.operate.post( ctx + "system/partner/list",{isTable:0,partnerName:[[${orderInfo.orderPartnerName}]],pageSize:1,pageNum:0},function (res){ + if(res.rows.length){ + $('#customerSet').attr('partnerName', res.rows[0].partnerName); + $('#customerSet').attr('contactPerson', res.rows[0].contactPerson); + $('#customerSet').attr('contactPhone', res.rows[0].contactPhone); + } + + }) + } function importList() { $('#uploadInput').click() @@ -335,6 +348,7 @@ }) changeOrderType() + initCustomerSet() }); function downloadTem() { @@ -494,6 +508,17 @@ $('form').find('textarea').css('pointer-events', 'none') window.localStorage.removeItem('isOrderDetail') } + function setCustomer() { + if (!$('#customerSet').attr('partnerName')) { + $.modal.alertWarning("请先选择代理商"); + return + } + $('[name="customerCode"]').attr('readonly', false).attr('required', false).val('').parent().parent().find('label').removeClass('is-required') + $(' [name="customerEmail"]').val(''); + $(' [name="customerName"]').val($('#customerSet').attr('partnerName')); + $(' [name="customerContact"]').val($('#customerSet').attr('contactPerson')); + $(' [name="customerPhone"]').val($('#customerSet').attr('contactPhone')); + } diff --git a/ruoyi-admin/src/main/resources/templates/project/order/order.html b/ruoyi-admin/src/main/resources/templates/project/order/order.html index b33331ff..e19561eb 100644 --- a/ruoyi-admin/src/main/resources/templates/project/order/order.html +++ b/ruoyi-admin/src/main/resources/templates/project/order/order.html @@ -11,11 +11,11 @@