From e38b54037fb3e2a7e2014c0f1931d026ac6f6972 Mon Sep 17 00:00:00 2001
From: wujianwei <wjw@11.com>
Date: 星期二, 07 四月 2026 17:59:50 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/yagwly_fa_master' into yagwly_fa_master
---
api/src/main/java/com/ruoyi/api/third/controller/AuditLogController.java | 78 +++++++++++++++++++++++++++++++++++++++
1 files changed, 78 insertions(+), 0 deletions(-)
diff --git a/api/src/main/java/com/ruoyi/api/third/controller/AuditLogController.java b/api/src/main/java/com/ruoyi/api/third/controller/AuditLogController.java
new file mode 100644
index 0000000..81d5e5c
--- /dev/null
+++ b/api/src/main/java/com/ruoyi/api/third/controller/AuditLogController.java
@@ -0,0 +1,78 @@
+package com.ruoyi.api.third.controller;
+
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.RequestBody;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+
+import com.ruoyi.common.core.domain.AjaxResult;
+import com.ruoyi.tms.domain.PayableAuditLog;
+import com.ruoyi.tms.domain.ReceivableAuditLog;
+import com.ruoyi.tms.service.IPayableAuditLogService;
+import com.ruoyi.tms.service.IReceivableAuditLogService;
+
+import lombok.extern.slf4j.Slf4j;
+
+/**
+ * 瀹℃牳鏃ュ織鎺ユ敹Controller
+ * 鐢ㄤ簬鎺ユ敹鍏朵粬绯荤粺鍙戦�佺殑搴斾粯璐﹀崟鍜屽簲鏀惰处鍗曠殑瀹℃牳鏃ュ織
+ *
+ * @author ruoyi
+ * @date 2026-04-07
+ */
+@RestController
+@RequestMapping("/api/third/audit")
+@Slf4j
+public class AuditLogController {
+
+ @Autowired
+ private IPayableAuditLogService payableAuditLogService;
+
+ @Autowired
+ private IReceivableAuditLogService receivableAuditLogService;
+
+ /**
+ * 鎺ユ敹搴斾粯璐﹀崟瀹℃牳鏃ュ織
+ *
+ * @param auditLog 搴斾粯璐﹀崟瀹℃牳鏃ュ織
+ * @return 缁撴灉
+ */
+ @PostMapping("/ap-bill")
+ public AjaxResult receiveApBillAuditLog(@RequestBody PayableAuditLog auditLog) {
+ try {
+ log.info("鎺ユ敹鍒板簲浠樿处鍗曞鏍告棩蹇�: {}", auditLog);
+ int result = payableAuditLogService.insertPayableAuditLog(auditLog);
+ if (result > 0) {
+ return AjaxResult.success("鎺ユ敹鎴愬姛");
+ } else {
+ return AjaxResult.error("鎺ユ敹澶辫触");
+ }
+ } catch (Exception e) {
+ log.error("鎺ユ敹搴斾粯璐﹀崟瀹℃牳鏃ュ織澶辫触", e);
+ return AjaxResult.error("鎺ユ敹澶辫触: " + e.getMessage());
+ }
+ }
+
+ /**
+ * 鎺ユ敹搴旀敹璐﹀崟瀹℃牳鏃ュ織
+ *
+ * @param auditLog 搴旀敹璐﹀崟瀹℃牳鏃ュ織
+ * @return 缁撴灉
+ */
+ @PostMapping("/ar-bill")
+ public AjaxResult receiveArBillAuditLog(@RequestBody ReceivableAuditLog auditLog) {
+ try {
+ log.info("鎺ユ敹鍒板簲鏀惰处鍗曞鏍告棩蹇�: {}", auditLog);
+ int result = receivableAuditLogService.insertReceivableAuditLog(auditLog);
+ if (result > 0) {
+ return AjaxResult.success("鎺ユ敹鎴愬姛");
+ } else {
+ return AjaxResult.error("鎺ユ敹澶辫触");
+ }
+ } catch (Exception e) {
+ log.error("鎺ユ敹搴旀敹璐﹀崟瀹℃牳鏃ュ織澶辫触", e);
+ return AjaxResult.error("鎺ユ敹澶辫触: " + e.getMessage());
+ }
+ }
+}
\ No newline at end of file
--
Gitblit v1.8.0