From 481d8165f26fc7e37f0e87f6444ac0340bb563a3 Mon Sep 17 00:00:00 2001
From: xiaoyi <908147524@qq.com>
Date: 星期二, 03 十一月 2026 18:53:22 +0800
Subject: [PATCH] fix: 移植长辉已验证的四类接口 500/体验问题(不含物料颜色字段)

---
 yudao-module-crm/src/main/java/cn/iocoder/yudao/module/crm/controller/admin/refund/CrmRefundController.java |   40 ++++++++++++++++++----------------------
 1 files changed, 18 insertions(+), 22 deletions(-)

diff --git a/yudao-module-crm/src/main/java/cn/iocoder/yudao/module/crm/controller/admin/refund/CrmRefundController.java b/yudao-module-crm/src/main/java/cn/iocoder/yudao/module/crm/controller/admin/refund/CrmRefundController.java
index 256bcda..6648550 100644
--- a/yudao-module-crm/src/main/java/cn/iocoder/yudao/module/crm/controller/admin/refund/CrmRefundController.java
+++ b/yudao-module-crm/src/main/java/cn/iocoder/yudao/module/crm/controller/admin/refund/CrmRefundController.java
@@ -21,12 +21,11 @@
 
 import java.io.IOException;
 import java.util.List;
-import java.util.Map;
+import java.util.Set;
 
 import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT;
 import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
 import static cn.iocoder.yudao.framework.common.pojo.PageParam.PAGE_SIZE_NONE;
-import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId;
 
 @Tag(name = "绠$悊鍚庡彴 - CRM 閫�璐瑰崟")
 @RestController
@@ -52,28 +51,27 @@
         return success(true);
     }
 
-    @PutMapping("/audit")
-    @Operation(summary = "瀹℃壒閫�璐瑰崟锛堥�氳繃/椹冲洖锛�")
-    @PreAuthorize("@ss.hasPermission('crm:refund:update')")
-    public CommonResult<Boolean> auditRefund(@Valid @RequestBody CrmRefundAuditReqVO auditReqVO) {
-        refundService.auditRefund(auditReqVO);
-        return success(true);
-    }
-
     @PutMapping("/submit")
-    @Operation(summary = "鎻愪氦閫�璐瑰崟瀹℃壒")
+    @Operation(summary = "鎻愪氦閫�璐瑰崟瀹℃壒锛堣崏绋�/瀹℃牳涓嶉�氳繃鈫掑鎵逛腑锛夛紝瀹℃壒浜虹敱瀹℃壒閰嶇疆缁熶竴鎸囧畾")
+    @Parameter(name = "id", description = "缂栧彿", required = true)
     @PreAuthorize("@ss.hasPermission('crm:refund:update')")
-    public CommonResult<Boolean> submitRefund(@RequestParam("id") Long id,
-                                              @RequestParam("processDefinitionKey") String processDefinitionKey) {
-        refundService.submitRefund(id, processDefinitionKey, getLoginUserId());
+    public CommonResult<Boolean> submitRefund(@RequestParam("id") Long id) {
+        refundService.submitRefund(id);
         return success(true);
     }
 
-    @GetMapping("/approve-process-list")
-    @Operation(summary = "鑾峰緱閫�璐瑰崟瀹℃壒娴佺▼瀹氫箟鍒楄〃")
-    @PreAuthorize("@ss.hasPermission('crm:refund:query')")
-    public CommonResult<List<Map<String, Object>>> getRefundApproveProcessDefinitionList() {
-        return success(refundService.getRefundApproveProcessDefinitionList());
+    @PutMapping("/audit")
+    @Operation(summary = "瀹℃牳閫�璐瑰崟锛堝鎵逛腑鈫掑鏍搁�氳繃/瀹℃牳涓嶉�氳繃锛夛紝浠呭鎵逛汉鏈汉鍙搷浣�")
+    @PreAuthorize("@ss.hasPermission('crm:refund:audit')")
+    public CommonResult<Boolean> auditRefund(@Valid @RequestBody CrmRefundAuditReqVO auditReqVO) {
+        refundService.auditRefund(auditReqVO.getId(), auditReqVO.getPass(), auditReqVO.getReviewRemark());
+        return success(true);
+    }
+
+    @GetMapping("/approver-ids")
+    @Operation(summary = "鑾峰緱閫�璐瑰崟鐨勫鎵逛汉缂栧彿闆嗗悎锛屼緵鍓嶇鍒ゆ柇鏄惁灞曠ず瀹℃牳鎸夐挳")
+    public CommonResult<Set<Long>> getApproverUserIds() {
+        return success(refundService.getRefundApproverUserIds());
     }
 
     @DeleteMapping("/delete")
@@ -88,14 +86,12 @@
     @GetMapping("/get")
     @Operation(summary = "鑾峰緱閫�璐瑰崟")
     @Parameter(name = "id", description = "缂栧彿", required = true)
-    @PreAuthorize("@ss.hasPermission('crm:refund:query')")
     public CommonResult<CrmRefundRespVO> getRefund(@RequestParam("id") Long id) {
         return success(refundService.getRefund(id));
     }
 
     @GetMapping("/page")
     @Operation(summary = "鑾峰緱閫�璐瑰崟鍒嗛〉")
-    @PreAuthorize("@ss.hasPermission('crm:refund:query')")
     public CommonResult<PageResult<CrmRefundRespVO>> getRefundPage(@Valid CrmRefundPageReqVO pageReqVO) {
         return success(refundService.getRefundPage(pageReqVO));
     }
@@ -111,4 +107,4 @@
         ExcelUtils.write(response, "閫�璐瑰崟.xls", "鏁版嵁", CrmRefundRespVO.class, list);
     }
 
-}
\ No newline at end of file
+}

--
Gitblit v1.9.3