From 4a44e1391d26f2fbe756be23161cc2f299a8a7eb Mon Sep 17 00:00:00 2001 From: chenhao <852066789@qq.com> Date: Thu, 3 Jul 2025 11:13:11 +0800 Subject: [PATCH] =?UTF-8?q?feat(customer):=20=E5=A2=9E=E5=8A=A0=E5=AE=A2?= =?UTF-8?q?=E6=88=B7=E6=89=80=E5=B1=9E=E8=A1=8C=E4=B8=9A=E5=AD=97=E6=AE=B5?= =?UTF-8?q?=E5=B9=B6=E4=BC=98=E5=8C=96=E7=9B=B8=E5=85=B3=E5=8A=9F=E8=83=BD?= =?UTF-8?q?-=20=E5=9C=A8=E5=AE=A2=E6=88=B7=E4=BF=A1=E6=81=AF=E4=B8=AD?= =?UTF-8?q?=E6=B7=BB=E5=8A=A0=20BG=E5=B1=9E=E6=80=A7=E5=AD=97=E6=AE=B5=20-?= =?UTF-8?q?=20=E6=A0=B9=E6=8D=AE=20BG=20=E5=B1=9E=E6=80=A7=E5=8A=A8?= =?UTF-8?q?=E6=80=81=E5=8A=A0=E8=BD=BD=E8=A1=8C=E4=B8=9A=E7=B1=BB=E5=9E=8B?= =?UTF-8?q?=20-=20=E6=9B=B4=E6=96=B0=E9=A1=B9=E7=9B=AE=E4=BF=A1=E6=81=AF?= =?UTF-8?q?=E5=92=8C=E8=AE=A2=E5=8D=95=E4=BF=A1=E6=81=AF=EF=BC=8C=E5=85=B3?= =?UTF-8?q?=E8=81=94=E5=AE=A2=E6=88=B7=E6=89=80=E5=B1=9E=E8=A1=8C=E4=B8=9A?= =?UTF-8?q?=20-=20=E4=BC=98=E5=8C=96=E5=AE=A2=E6=88=B7=E9=80=89=E6=8B=A9?= =?UTF-8?q?=E7=95=8C=E9=9D=A2=EF=BC=8C=E6=94=AF=E6=8C=81=E6=8C=89=20BG=20?= =?UTF-8?q?=E5=92=8C=E8=A1=8C=E4=B8=9A=E7=AD=9B=E9=80=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../resources/templates/project/info/add.html | 18 ++-- .../templates/project/info/edit.html | 20 ++-- .../project/info/selectCustomer.html | 78 +++++++++++--- .../templates/project/order/add.html | 4 +- .../templates/project/order/edit.html | 28 ++--- .../project/order/selectProject.html | 16 +-- .../templates/system/customer/add.html | 102 ++++++++++++++---- .../templates/system/customer/edit.html | 96 +++++++++++++---- .../templates/system/customer/info.html | 14 ++- .../com/ruoyi/sip/domain/CustomerInfo.java | 4 +- .../impl/ProjectOrderInfoServiceImpl.java | 14 +-- .../mapper/manage/CustomerInfoMapper.xml | 7 +- .../mapper/sip/ProjectInfoMapper.xml | 9 +- .../mapper/sip/ProjectOrderInfoMapper.xml | 3 +- 14 files changed, 302 insertions(+), 111 deletions(-) diff --git a/ruoyi-admin/src/main/resources/templates/project/info/add.html b/ruoyi-admin/src/main/resources/templates/project/info/add.html index 1069ef82..f6e0cd7a 100644 --- a/ruoyi-admin/src/main/resources/templates/project/info/add.html +++ b/ruoyi-admin/src/main/resources/templates/project/info/add.html @@ -95,6 +95,9 @@ label { margin-bottom: 0 !important; } + [name="bgProperty"], #industryTypeBox select { + pointer-events: none; + }
@@ -112,19 +115,19 @@ - BG* + BG - 行业* + 行业 @@ -446,6 +449,9 @@ $('[name="customerName"]').val(rows[0].customerName); $('[name="customerUserName"]').val(rows[0].contactPerson); $('[name="customerPhone"]').val(rows[0].contactPhone); + $('[name="bgProperty"]').val(rows[0].bgProperty); + changeBg() + $('[name="industryType"]').val(rows[0].industryType); $.modal.close(index); } @@ -575,7 +581,7 @@ str += ` ` }) $('#industryTypeBox').html(` - ${str} @@ -587,7 +593,7 @@ str += ` ` }) $('#industryTypeBox').html(` - ${str} diff --git a/ruoyi-admin/src/main/resources/templates/project/info/edit.html b/ruoyi-admin/src/main/resources/templates/project/info/edit.html index 54786665..4f7302e7 100644 --- a/ruoyi-admin/src/main/resources/templates/project/info/edit.html +++ b/ruoyi-admin/src/main/resources/templates/project/info/edit.html @@ -103,6 +103,9 @@ .white-bg{ padding: 0px 50px; } + [name="bgProperty"], #industryTypeBox select { + pointer-events: none; + }
@@ -126,20 +129,20 @@ class="form-control"> - BG* + BG - 行业* + 行业 - @@ -510,6 +513,9 @@ $('[name="customerName"]').val(rows[0].customerName); $('[name="customerUserName"]').val(rows[0].contactPerson); $('[name="customerPhone"]').val(rows[0].contactPhone); + $('[name="bgProperty"]').val(rows[0].bgProperty); + changeBg() + $('[name="industryType"]').val(rows[0].industryType); $.modal.close(index); } @@ -651,7 +657,7 @@ str += ` ` }) $('#industryTypeBox').html(` - ${str} @@ -663,7 +669,7 @@ str += ` ` }) $('#industryTypeBox').html(` - ${str} diff --git a/ruoyi-admin/src/main/resources/templates/project/info/selectCustomer.html b/ruoyi-admin/src/main/resources/templates/project/info/selectCustomer.html index e8c95239..b58896e0 100644 --- a/ruoyi-admin/src/main/resources/templates/project/info/selectCustomer.html +++ b/ruoyi-admin/src/main/resources/templates/project/info/selectCustomer.html @@ -33,14 +33,24 @@
  • - - +
  • +
  • + +
    + +
    + +
  • +
  •  搜索 @@ -62,7 +72,7 @@
  • - diff --git a/ruoyi-admin/src/main/resources/templates/project/order/add.html b/ruoyi-admin/src/main/resources/templates/project/order/add.html index ccd5bcd2..671944d6 100644 --- a/ruoyi-admin/src/main/resources/templates/project/order/add.html +++ b/ruoyi-admin/src/main/resources/templates/project/order/add.html @@ -532,8 +532,8 @@ function searchProject() { var url = prefix + "/selectProject"; var options = { - title: '选择客户', - width: "680", + title: '选择项目', + width: "800", url: url, height: '600', callBack: doSubmitProject diff --git a/ruoyi-admin/src/main/resources/templates/project/order/edit.html b/ruoyi-admin/src/main/resources/templates/project/order/edit.html index 3c34d82e..27d109eb 100644 --- a/ruoyi-admin/src/main/resources/templates/project/order/edit.html +++ b/ruoyi-admin/src/main/resources/templates/project/order/edit.html @@ -73,9 +73,9 @@ position: relative; } - /*[name="bgProperty"], #industryTypeBox select {*/ - /* pointer-events: none;*/ - /*}*/ + [name="bgProperty"], #industryTypeBox select { + pointer-events: none; + } #projectNameBox { margin-left: 20px; @@ -136,20 +136,20 @@ required> - BG* + BG - - 行业* + 行业 - @@ -520,8 +520,8 @@ function searchProject() { var url = prefix + "/selectProject"; var options = { - title: '选择客户', - width: "680", + title: '选择项目', + width: "800", url: url, height: '600', callBack: doSubmitProject @@ -701,7 +701,7 @@ str += ` ` }) $('#industryTypeBox').html(` - ${str} @@ -713,7 +713,7 @@ str += ` ` }) $('#industryTypeBox').html(` - ${str} diff --git a/ruoyi-admin/src/main/resources/templates/project/order/selectProject.html b/ruoyi-admin/src/main/resources/templates/project/order/selectProject.html index 105627ce..5c50589c 100644 --- a/ruoyi-admin/src/main/resources/templates/project/order/selectProject.html +++ b/ruoyi-admin/src/main/resources/templates/project/order/selectProject.html @@ -50,9 +50,7 @@ \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/system/customer/info.html b/ruoyi-admin/src/main/resources/templates/system/customer/info.html index 69b76ca4..8cba5749 100644 --- a/ruoyi-admin/src/main/resources/templates/system/customer/info.html +++ b/ruoyi-admin/src/main/resources/templates/system/customer/info.html @@ -133,11 +133,23 @@ field: 'contactEmail', title: '联系邮件' }, + { + field: 'bgProperty', + title: '所属行业', + formatter: (value, row) => { + return $.table.selectDictLabel([[${@dict.getType('bg_type')}]], value); + } + }, { field: 'industryType', title: '所属行业', formatter: (value, row) => { - return [[${@dict.getType('industry_code')}]].find((ele) => ele.dictValue == value)?.dictLabel + if (row.bgProperty === 'YYS') { + return $.table.selectDictLabel([[${@dict.getType('bg_yys')}]], value); + } else { + return $.table.selectDictLabel([[${@dict.getType('bg_hysy')}]], value); + + } } }, { diff --git a/ruoyi-sip/src/main/java/com/ruoyi/sip/domain/CustomerInfo.java b/ruoyi-sip/src/main/java/com/ruoyi/sip/domain/CustomerInfo.java index 3a9e4c2c..c8afb4a6 100644 --- a/ruoyi-sip/src/main/java/com/ruoyi/sip/domain/CustomerInfo.java +++ b/ruoyi-sip/src/main/java/com/ruoyi/sip/domain/CustomerInfo.java @@ -62,7 +62,9 @@ public class CustomerInfo extends BaseEntity /** 联系邮件 */ @Excel(name = "联系邮件") private String contactEmail; - + /** 所属行业 */ + @Excel(name = "BG") + private String bgProperty; /** 所属行业 */ @Excel(name = "所属行业") private String industryType; diff --git a/ruoyi-sip/src/main/java/com/ruoyi/sip/service/impl/ProjectOrderInfoServiceImpl.java b/ruoyi-sip/src/main/java/com/ruoyi/sip/service/impl/ProjectOrderInfoServiceImpl.java index 2bc68ec6..5aa43485 100644 --- a/ruoyi-sip/src/main/java/com/ruoyi/sip/service/impl/ProjectOrderInfoServiceImpl.java +++ b/ruoyi-sip/src/main/java/com/ruoyi/sip/service/impl/ProjectOrderInfoServiceImpl.java @@ -216,13 +216,13 @@ public class ProjectOrderInfoServiceImpl implements IProjectOrderInfoService { // projectOrderInfo.setOrderCode(orderNumber); // } //更新BG属性 - ProjectInfo projectInfo = new ProjectInfo(); - projectInfo.setId(projectOrderInfo.getProjectId()); - projectInfo.setBgProperty(projectOrderInfo.getBgProperty()); - projectInfo.setIndustryType(projectOrderInfo.getIndustryType()); - projectInfo.setUpdateBy(ShiroUtils.getUserId().toString()); - projectInfo.setUpdateTime(DateUtils.getNowDate()); - projectInfoMapper.updateProjectInfo(projectInfo); +// ProjectInfo projectInfo = new ProjectInfo(); +// projectInfo.setId(projectOrderInfo.getProjectId()); +// projectInfo.setBgProperty(projectOrderInfo.getBgProperty()); +// projectInfo.setIndustryType(projectOrderInfo.getIndustryType()); +// projectInfo.setUpdateBy(ShiroUtils.getUserId().toString()); +// projectInfo.setUpdateTime(DateUtils.getNowDate()); +// projectInfoMapper.updateProjectInfo(projectInfo); //不更新订单编号 projectOrderInfo.setOrderCode(null); diff --git a/ruoyi-sip/src/main/resources/mapper/manage/CustomerInfoMapper.xml b/ruoyi-sip/src/main/resources/mapper/manage/CustomerInfoMapper.xml index e625ada5..cc51c103 100644 --- a/ruoyi-sip/src/main/resources/mapper/manage/CustomerInfoMapper.xml +++ b/ruoyi-sip/src/main/resources/mapper/manage/CustomerInfoMapper.xml @@ -16,6 +16,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" + @@ -25,7 +26,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" select id, customer_code, customer_name, customer_postcode, province, city, address, contact_person, - contact_phone, contact_email, industry_type, remark, create_at, update_at, delete_at, status from customer_info + contact_phone, contact_email, industry_type, remark, create_at, update_at, delete_at, status, bg_property from customer_info