Commit ed87073c9f6283cb27a8f72dbc356fcf6c59adba

Authored by 陆恒
1 parent 0b7af79c

提交

Showing 1 changed file with 10 additions and 10 deletions   Show diff stats
src/HttpServer/logic/logic.go
@@ -124,14 +124,6 @@ func HandlerGetcash(w http.ResponseWriter, data string, uuid int) { @@ -124,14 +124,6 @@ func HandlerGetcash(w http.ResponseWriter, data string, uuid int) {
124 break 124 break
125 } 125 }
126 126
127 - _, err = GetCashFromSDK(uuid, drawnum, rdata.Gameid, rdata.Channel, rdata.Openid, rdata.Nickname, rdata.Headurl, rdata.Ver)  
128 - if err != nil {  
129 - logger.Error("GetCashFromSDK failed err=%v", err)  
130 - resp.Message = "从后台提现失败了"  
131 - resp.Code = ERROR_GETCASH_FAILED  
132 - break  
133 - }  
134 -  
135 index, info := uinfo.GetWithDrawData(rdata.Money) 127 index, info := uinfo.GetWithDrawData(rdata.Money)
136 if index == -1 || info == nil { 128 if index == -1 || info == nil {
137 logger.Error("AddWithDrawList failed err=%v", err) 129 logger.Error("AddWithDrawList failed err=%v", err)
@@ -170,6 +162,14 @@ func HandlerGetcash(w http.ResponseWriter, data string, uuid int) { @@ -170,6 +162,14 @@ func HandlerGetcash(w http.ResponseWriter, data string, uuid int) {
170 } 162 }
171 } 163 }
172 164
  165 + gold, err := GetCashFromSDK(uuid, drawnum, rdata.Gameid, rdata.Channel, rdata.Openid, rdata.Nickname, rdata.Headurl, rdata.Ver)
  166 + if err != nil {
  167 + logger.Error("GetCashFromSDK failed err=%v", err)
  168 + resp.Message = "从后台提现失败了"
  169 + resp.Code = ERROR_GETCASH_FAILED
  170 + break
  171 + }
  172 +
173 //需要保存一下提现记录 173 //需要保存一下提现记录
174 /*data := new(WithDrawRecord) 174 /*data := new(WithDrawRecord)
175 data.Withdrawmoney = rdata.Money 175 data.Withdrawmoney = rdata.Money
@@ -186,8 +186,8 @@ func HandlerGetcash(w http.ResponseWriter, data string, uuid int) { @@ -186,8 +186,8 @@ func HandlerGetcash(w http.ResponseWriter, data string, uuid int) {
186 uinfo.WithDraw.Cashdata[index].Isnew = 0 186 uinfo.WithDraw.Cashdata[index].Isnew = 0
187 } 187 }
188 188
189 - //uinfo.RealGold =  
190 - uinfo.RealGold -= drawnum * 100 189 + uinfo.RealGold = gold
  190 + //uinfo.RealGold -= drawnum * 100
191 191
192 resp.Data.Walletgold = uinfo.RealGold 192 resp.Data.Walletgold = uinfo.RealGold
193 SaveUserInfo(uinfo) 193 SaveUserInfo(uinfo)