From 94ade6f6b27becf9d73bcd2cfa62f6d9490c7e36 Mon Sep 17 00:00:00 2001 From: xd <844539747@qq.com> Date: Tue, 26 Mar 2024 16:46:24 +0800 Subject: [PATCH] '123' --- .../customer/CustomerController.java | 2 + .../com/ruoyi/customer/domain/Customer.java | 98 +++++++++++-------- .../mapper/customer/CustomerMapper.xml | 22 ++++- .../src/views/customer/customer/index.vue | 8 ++ 4 files changed, 86 insertions(+), 44 deletions(-) diff --git a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/customer/CustomerController.java b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/customer/CustomerController.java index cc08f8b..6c74572 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/customer/CustomerController.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/customer/CustomerController.java @@ -96,6 +96,7 @@ public class CustomerController extends BaseController public AjaxResult add(@RequestBody Customer customer) { customer.setCusCode(IdUtils.createNo("KH_",3)); + customer.setCreateBy(getUsername()); return toAjax(customerService.insertCustomer(customer)); } @@ -107,6 +108,7 @@ public class CustomerController extends BaseController @PutMapping public AjaxResult edit(@RequestBody Customer customer) { + customer.setUpdateBy(getUsername()); return toAjax(customerService.updateCustomer(customer)); } diff --git a/ruoyi-system/src/main/java/com/ruoyi/customer/domain/Customer.java b/ruoyi-system/src/main/java/com/ruoyi/customer/domain/Customer.java index e4e42d6..91806d8 100644 --- a/ruoyi-system/src/main/java/com/ruoyi/customer/domain/Customer.java +++ b/ruoyi-system/src/main/java/com/ruoyi/customer/domain/Customer.java @@ -8,7 +8,7 @@ import com.ruoyi.common.core.domain.BaseEntity; /** * 客户管理对象 customer - * + * * @author ruoyi * @date 2024-03-25 */ @@ -84,199 +84,211 @@ public class Customer extends BaseEntity @Excel(name = "客户审批状态") private String cusApprovalStatus; + /** 创建人 */ + @Excel(name = "创建人") + private String createName; + /** 银行信息 */ private List bankList; - public void setCusId(Long cusId) + public void setCusId(Long cusId) { this.cusId = cusId; } - public Long getCusId() + public Long getCusId() { return cusId; } - public void setCusCode(String cusCode) + public void setCusCode(String cusCode) { this.cusCode = cusCode; } - public String getCusCode() + public String getCusCode() { return cusCode; } - public void setCusName(String cusName) + public void setCusName(String cusName) { this.cusName = cusName; } - public String getCusName() + public String getCusName() { return cusName; } - public void setCusSapCode(String cusSapCode) + public void setCusSapCode(String cusSapCode) { this.cusSapCode = cusSapCode; } - public String getCusSapCode() + public String getCusSapCode() { return cusSapCode; } - public void setCusStreet(String cusStreet) + public void setCusStreet(String cusStreet) { this.cusStreet = cusStreet; } - public String getCusStreet() + public String getCusStreet() { return cusStreet; } - public void setCusPaymentTerms(String cusPaymentTerms) + public void setCusPaymentTerms(String cusPaymentTerms) { this.cusPaymentTerms = cusPaymentTerms; } - public String getCusPaymentTerms() + public String getCusPaymentTerms() { return cusPaymentTerms; } - public void setCusPhoneNumber(String cusPhoneNumber) + public void setCusPhoneNumber(String cusPhoneNumber) { this.cusPhoneNumber = cusPhoneNumber; } - public String getCusPhoneNumber() + public String getCusPhoneNumber() { return cusPhoneNumber; } - public void setCusIndustryCode(String cusIndustryCode) + public void setCusIndustryCode(String cusIndustryCode) { this.cusIndustryCode = cusIndustryCode; } - public String getCusIndustryCode() + public String getCusIndustryCode() { return cusIndustryCode; } - public void setCusGroup(String cusGroup) + public void setCusGroup(String cusGroup) { this.cusGroup = cusGroup; } - public String getCusGroup() + public String getCusGroup() { return cusGroup; } - public void setCusVatNo(String cusVatNo) + public void setCusVatNo(String cusVatNo) { this.cusVatNo = cusVatNo; } - public String getCusVatNo() + public String getCusVatNo() { return cusVatNo; } - public void setCusType(String cusType) + public void setCusType(String cusType) { this.cusType = cusType; } - public String getCusType() + public String getCusType() { return cusType; } - public void setCusCountry(String cusCountry) + public void setCusCountry(String cusCountry) { this.cusCountry = cusCountry; } - public String getCusCountry() + public String getCusCountry() { return cusCountry; } - public void setCusLanguage(String cusLanguage) + public void setCusLanguage(String cusLanguage) { this.cusLanguage = cusLanguage; } - public String getCusLanguage() + public String getCusLanguage() { return cusLanguage; } - public void setCusLabel(String cusLabel) + public void setCusLabel(String cusLabel) { this.cusLabel = cusLabel; } - public String getCusLabel() + public String getCusLabel() { return cusLabel; } - public void setCusClassification(String cusClassification) + public void setCusClassification(String cusClassification) { this.cusClassification = cusClassification; } - public String getCusClassification() + public String getCusClassification() { return cusClassification; } - public void setCusReceivingEmail(String cusReceivingEmail) + public void setCusReceivingEmail(String cusReceivingEmail) { this.cusReceivingEmail = cusReceivingEmail; } - public String getCusReceivingEmail() + public String getCusReceivingEmail() { return cusReceivingEmail; } - public void setCusRecipient(String cusRecipient) + public void setCusRecipient(String cusRecipient) { this.cusRecipient = cusRecipient; } - public String getCusRecipient() + public String getCusRecipient() { return cusRecipient; } - public void setCusRecipientPhone(String cusRecipientPhone) + public void setCusRecipientPhone(String cusRecipientPhone) { this.cusRecipientPhone = cusRecipientPhone; } - public String getCusRecipientPhone() + public String getCusRecipientPhone() { return cusRecipientPhone; } - public void setCusRemark(String cusRemark) + public void setCusRemark(String cusRemark) { this.cusRemark = cusRemark; } - public String getCusRemark() + public String getCusRemark() { return cusRemark; } - public void setCusState(String cusState) + public void setCusState(String cusState) { this.cusState = cusState; } - public String getCusState() + public String getCusState() { return cusState; } - public void setCusApprovalStatus(String cusApprovalStatus) + public void setCusApprovalStatus(String cusApprovalStatus) { this.cusApprovalStatus = cusApprovalStatus; } - public String getCusApprovalStatus() + public String getCusApprovalStatus() { return cusApprovalStatus; } + public String getCreateName() { + return createName; + } + + public void setCreateName(String createName) { + this.createName = createName; + } + public List getBankList() { return bankList; diff --git a/ruoyi-system/src/main/resources/mapper/customer/CustomerMapper.xml b/ruoyi-system/src/main/resources/mapper/customer/CustomerMapper.xml index 6009218..e212a3b 100644 --- a/ruoyi-system/src/main/resources/mapper/customer/CustomerMapper.xml +++ b/ruoyi-system/src/main/resources/mapper/customer/CustomerMapper.xml @@ -26,6 +26,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" + + + + + @@ -39,8 +44,17 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" + + LEFT JOIN sys_user s on s.user_name=a.create_by + + - select cus_id, cus_code, cus_name, cus_sap_code, cus_street, cus_payment_terms, cus_phone_number, cus_industry_code, cus_group, cus_vat_no, cus_type, cus_country, cus_language, cus_label, cus_classification, cus_receiving_email, cus_recipient, cus_recipient_phone, cus_remark, cus_state, cus_approval_status from customer + select a.cus_id, a.cus_code, a.cus_name, a.cus_sap_code, a.cus_street, a.cus_payment_terms, a.cus_phone_number, + a.cus_industry_code, a.cus_group, a.cus_vat_no, a.cus_type, a.cus_country, a.cus_language, a.cus_label, + a.cus_classification, a.cus_receiving_email, a.cus_recipient, a.cus_recipient_phone, a.cus_remark, + a.cus_state, a.cus_approval_status,a.create_time,s.nick_name create_name + from customer a +