From 9169334afe5385ad41286a99cfd68a6a8fe89e22 Mon Sep 17 00:00:00 2001
From: liuxiaolong <736321739@qq.com>
Date: 星期三, 04 十二月 2019 15:05:04 +0800
Subject: [PATCH] update protomsg and fix GetPollConfig

---
 controllers/pollConfig.go |   10 ++++++++--
 1 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/controllers/pollConfig.go b/controllers/pollConfig.go
index 70194c4..ffc3258 100644
--- a/controllers/pollConfig.go
+++ b/controllers/pollConfig.go
@@ -78,9 +78,15 @@
 // @Router /data/api-v/pollConfig/getPollConfig [get]
 func (controller PollConfigController) GetPollConfig(c *gin.Context) {
 	var api dbapi.SysSetApi
-	b, data := api.GetPollConfig()
+	b, d := api.GetPollConfig()
 	if b {
-		util.ResponseFormat(c, code.Success, data)
+		util.ResponseFormat(c, code.Success, map[string]interface{}{
+			"server_id": d.ServerId,
+			"poll_period": d.PollPeriod,
+			"delay": d.Delay,
+			"enable": d.Enable,
+			"pollChannelCount": d.PollChannelCount,
+		})
 	} else {
 		util.ResponseFormat(c, code.ComError, "鏌ヨ澶辫触")
 	}

--
Gitblit v1.8.0