From 86fc29740373b896d63276d38aa23c20da040ae8 Mon Sep 17 00:00:00 2001
From: Administrator <15274802129@163.com>
Date: Thu, 13 Aug 2026 17:15:58 +0800
Subject: [PATCH] refactor(station-dashboard): 将自动轮询改为手动刷新机制

---
 src/main/java/com/xcong/excoin/modules/gateApi/GateConfigController.java |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/src/main/java/com/xcong/excoin/modules/gateApi/GateConfigController.java b/src/main/java/com/xcong/excoin/modules/gateApi/GateConfigController.java
index 40ab8e0..8d17b05 100644
--- a/src/main/java/com/xcong/excoin/modules/gateApi/GateConfigController.java
+++ b/src/main/java/com/xcong/excoin/modules/gateApi/GateConfigController.java
@@ -4,6 +4,7 @@
 import io.swagger.annotations.Api;
 import io.swagger.annotations.ApiOperation;
 import lombok.extern.slf4j.Slf4j;
+import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.http.MediaType;
 import org.springframework.web.bind.annotation.*;
@@ -13,6 +14,7 @@
  * Gate 配置控制面板 REST 接口。
  */
 @Slf4j
+@ConditionalOnProperty(name = "app.gate.enabled", havingValue = "true", matchIfMissing = true)
 @RestController
 @RequestMapping("/api/gate")
 @Api(tags = "Gate配置管理")
@@ -102,9 +104,9 @@
     public Result getStatus() {
         GateGridTradeService service = clientManager.getGridTradeService();
         if (service == null) {
-            return Result.ok("STOPPED");
+            return Result.ok("success", "STOPPED");
         }
-        return Result.ok(service.isStrategyActive() ? "ACTIVE" : "STOPPED");
+        return Result.ok("success", service.isStrategyActive() ? "ACTIVE" : "STOPPED");
     }
 
     /**

--
Gitblit v1.9.1