From edc227277159601c5cb86829f1c5ce14cf7903a4 Mon Sep 17 00:00:00 2001
From: chenlu <1320612696@qq.com>
Date: 星期二, 24 九月 2024 10:12:55 +0800
Subject: [PATCH] Merge branch 'master' of http://10.153.19.25:10101/r/ERP_override
---
north-glass-erp/src/main/java/com/example/erp/service/sd/CustomerService.java | 13 +++++++++++++
1 files changed, 13 insertions(+), 0 deletions(-)
diff --git a/north-glass-erp/src/main/java/com/example/erp/service/sd/CustomerService.java b/north-glass-erp/src/main/java/com/example/erp/service/sd/CustomerService.java
index 6d9c114..6863176 100644
--- a/north-glass-erp/src/main/java/com/example/erp/service/sd/CustomerService.java
+++ b/north-glass-erp/src/main/java/com/example/erp/service/sd/CustomerService.java
@@ -7,9 +7,11 @@
import com.example.erp.dto.sd.DeliveryDetailDTO;
import com.example.erp.dto.sd.DeliveryDetailProductDTO;
import com.example.erp.entity.sd.*;
+import com.example.erp.entity.userInfo.Log;
import com.example.erp.entity.userInfo.SysError;
import com.example.erp.mapper.mm.FinishedGoodsInventoryMapper;
import com.example.erp.mapper.sd.*;
+import com.example.erp.service.userInfo.LogService;
import com.example.erp.service.userInfo.SysErrorService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
@@ -28,6 +30,8 @@
CustomerMapper customerMapper;
@Autowired
SysErrorService sysErrorService;
+ @Autowired
+ LogService logService;
public Map<String, Object> getSelectCustomer(Integer pageNum, Integer pageSize, Customer customer) {
@@ -42,6 +46,8 @@
public Boolean insertCustomer(Map<String,Object> object) {
boolean saveState = true;
+ Log log = new Log();
+ log.setContent(object.toString());
//璁剧疆鍥炴粴鐐�
Object savePoint = TransactionAspectSupport.currentTransactionStatus().createSavepoint();
try {
@@ -49,9 +55,12 @@
if(customer!=null){
if (customer.getId()!=null && customer.getId()!=0){
customerMapper.updateCustomer(customer);
+ log.setFunction("insertCustomer淇敼");
}else{
customerMapper.insertCustomer(customer);
+ log.setFunction("insertCustomer鏂板");
}
+ logService.saveLog(log);
}
@@ -79,6 +88,10 @@
if (customer.getId()!=null){
customerMapper.deleteCustomer(customer);
}
+ Log log = new Log();
+ log.setContent(object.toString());
+ log.setFunction("deleteCustomer鍒犻櫎");
+ logService.saveLog(log);
}
--
Gitblit v1.8.0