Commit ca6f5ada0b96eaf43519aa6a0b868819d21d71dd
1 parent
e62e5159
Exists in
ver2.3.0
提交
Showing
2 changed files
with
3 additions
and
1 deletions
Show diff stats
src/HttpServer/logic/datadef.go
| @@ -105,6 +105,7 @@ type DrawguangoldData struct { | @@ -105,6 +105,7 @@ type DrawguangoldData struct { | ||
| 105 | Guangold int `json:"guangold"` | 105 | Guangold int `json:"guangold"` |
| 106 | Wallgold int `json:"wallgold"` | 106 | Wallgold int `json:"wallgold"` |
| 107 | Totalfetchcnt int `json:"totalfetchcnt"` | 107 | Totalfetchcnt int `json:"totalfetchcnt"` |
| 108 | + Getgoldnum int `json:"getgoldnum"` | ||
| 108 | } | 109 | } |
| 109 | 110 | ||
| 110 | type DrawguangoldResp struct { | 111 | type DrawguangoldResp struct { |
src/HttpServer/logic/logic.go
| @@ -1017,7 +1017,7 @@ func HandlerDrawguangold(w http.ResponseWriter, data string, uuid int) { | @@ -1017,7 +1017,7 @@ func HandlerDrawguangold(w http.ResponseWriter, data string, uuid int) { | ||
| 1017 | } | 1017 | } |
| 1018 | 1018 | ||
| 1019 | //todo 此处需要调佣SDK接口通知金币变化 | 1019 | //todo 此处需要调佣SDK接口通知金币变化 |
| 1020 | - goldnum, _, err := AddCoinToSdk(uuid, rdata.Goldnum, rdata.Gameid, rdata.Channel, 105) | 1020 | + goldnum, realgold, err := AddCoinToSdk(uuid, rdata.Goldnum, rdata.Gameid, rdata.Channel, 105) |
| 1021 | if err != nil { | 1021 | if err != nil { |
| 1022 | logger.Error("Drawgold failed err=%v", err) | 1022 | logger.Error("Drawgold failed err=%v", err) |
| 1023 | resp.Message = "从存钱罐提取金币失败了" | 1023 | resp.Message = "从存钱罐提取金币失败了" |
| @@ -1034,6 +1034,7 @@ func HandlerDrawguangold(w http.ResponseWriter, data string, uuid int) { | @@ -1034,6 +1034,7 @@ func HandlerDrawguangold(w http.ResponseWriter, data string, uuid int) { | ||
| 1034 | resp.Data.Guangold = uinfo.GuanGold | 1034 | resp.Data.Guangold = uinfo.GuanGold |
| 1035 | resp.Data.Wallgold = uinfo.RealGold | 1035 | resp.Data.Wallgold = uinfo.RealGold |
| 1036 | resp.Data.Totalfetchcnt = uinfo.Achieve.SumGetGuan | 1036 | resp.Data.Totalfetchcnt = uinfo.Achieve.SumGetGuan |
| 1037 | + resp.Data.Getgoldnum = realgold | ||
| 1037 | 1038 | ||
| 1038 | SaveUserInfo(uinfo, uniqueuuid) | 1039 | SaveUserInfo(uinfo, uniqueuuid) |
| 1039 | 1040 |