From 0632b21db7576e4a223eb4f6ca09b650616222f2 Mon Sep 17 00:00:00 2001
From: Tomas <tomasysh@gmail.com>
Date: 星期三, 17 一月 2024 09:54:09 +0800
Subject: [PATCH] Fixed: 移除 lodash, @type/lodash 導致的 side-effect

---
 pamapi/src/main/java/com/pollex/pam/web/rest/SatisfactionResource.java |   24 +++++++++++-------------
 1 files changed, 11 insertions(+), 13 deletions(-)

diff --git a/pamapi/src/main/java/com/pollex/pam/web/rest/SatisfactionResource.java b/pamapi/src/main/java/com/pollex/pam/web/rest/SatisfactionResource.java
index b4dbfdc..d1af1d5 100644
--- a/pamapi/src/main/java/com/pollex/pam/web/rest/SatisfactionResource.java
+++ b/pamapi/src/main/java/com/pollex/pam/web/rest/SatisfactionResource.java
@@ -2,8 +2,9 @@
 
 import java.util.List;
 
-import com.pollex.pam.enums.SatisfactionTypeEnum;
-import com.pollex.pam.service.dto.SatisfactionSystemScoreDTO;
+import com.pollex.pam.business.aop.logging.audit.AuditLoggingInject;
+import com.pollex.pam.business.aop.logging.audit.AuditLoggingType;
+import com.pollex.pam.business.enums.SatisfactionTypeEnum;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
@@ -14,11 +15,11 @@
 import org.springframework.web.bind.annotation.RequestMapping;
 import org.springframework.web.bind.annotation.RestController;
 
-import com.pollex.pam.domain.Satisfaction;
-import com.pollex.pam.security.SecurityUtils;
-import com.pollex.pam.service.SatisfactionService;
-import com.pollex.pam.service.dto.SatisfactionCustomerScoreDTO;
-import com.pollex.pam.service.dto.SatisfactionDTO;
+import com.pollex.pam.business.domain.Satisfaction;
+import com.pollex.pam.business.security.SecurityUtils;
+import com.pollex.pam.business.service.SatisfactionService;
+import com.pollex.pam.business.service.dto.SatisfactionCustomerScoreDTO;
+import com.pollex.pam.business.service.dto.SatisfactionDTO;
 
 @RestController
 @RequestMapping("/api/satisfaction")
@@ -30,12 +31,14 @@
 	@Autowired
 	SatisfactionService satisfactionService;
 
+    @AuditLoggingInject(type = AuditLoggingType.CUSTOMER_FILL_SATISFACTION)
 	@PostMapping("/score")
 	public Satisfaction scorefaction(@RequestBody SatisfactionCustomerScoreDTO scoreDTO) {
 		return satisfactionService.scorefaction(scoreDTO);
 	}
 
-	@PostMapping("/score/all")
+    @AuditLoggingInject(type = AuditLoggingType.CUSTOMER_FILL_SATISFACTION)
+    @PostMapping("/score/all")
 	public List<Satisfaction> scoreAllfaction(@RequestBody List<SatisfactionCustomerScoreDTO> scoreDTO) {
 		return satisfactionService.scoreAllfaction(scoreDTO);
 	}
@@ -50,9 +53,4 @@
 		log.error("Not has agent code and customer id");
 		throw new IllegalArgumentException("Not has agent code and customer id");
 	}
-
-    @PostMapping("/system/score")
-    public Satisfaction createSystemSatisfaction(@RequestBody SatisfactionSystemScoreDTO scoreDTO) {
-        return satisfactionService.fillSystemSatisfaction(scoreDTO);
-    }
 }

--
Gitblit v1.8.0