diff --git a/src/HttpServer/logic/httpserver.go b/src/HttpServer/logic/httpserver.go index cca3b15..20e75af 100644 --- a/src/HttpServer/logic/httpserver.go +++ b/src/HttpServer/logic/httpserver.go @@ -212,9 +212,14 @@ func Addcoin(w http.ResponseWriter, r *http.Request) { Channel string `json:"channel"` } + type AddcoinData struct { + Walletgold int `json:"walletgold"` + } + type AddcoinResp struct { Code int `json:"code"` Message string `json:"message"` + Data AddcoinData `json:"data"` } Uuid := 0 @@ -266,6 +271,7 @@ func Addcoin(w http.ResponseWriter, r *http.Request) { var resp AddcoinResp resp.Code = 0 resp.Message = "success" + resp.Data.Walletgold = uinfo.RealGold respstr, _ := json.Marshal(&resp) fmt.Fprint(w, string(respstr)) } -- libgit2 0.21.0