You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
40 lines
1.1 KiB
40 lines
1.1 KiB
|
2 months ago
|
package guser
|
||
|
|
|
||
|
|
//func LostUserDetail(c *gin.Context) {
|
||
|
|
// a := app.NewApp(c)
|
||
|
|
// defer func() {
|
||
|
|
// a.Response()
|
||
|
|
// }()
|
||
|
|
// req := new(values.LostUserDetailReq)
|
||
|
|
// if !a.S(req) {
|
||
|
|
// return
|
||
|
|
// }
|
||
|
|
// resp := values.LostUserDetailResp{}
|
||
|
|
//
|
||
|
|
// for i := 0; i < len(common.RoomGameIDs); i++ {
|
||
|
|
// resp.List = append(resp.List, getLostUserDetail(req.Uid, common.RoomGameIDs[i]))
|
||
|
|
// }
|
||
|
|
//
|
||
|
|
// for i := 0; i < len(common.MillionGameIDs); i++ {
|
||
|
|
// resp.List = append(resp.List, getLostUserDetail(req.Uid, common.MillionGameIDs[i].(int)))
|
||
|
|
// }
|
||
|
|
//
|
||
|
|
// a.Data = resp
|
||
|
|
//}
|
||
|
|
//
|
||
|
|
//func getLostUserDetail(uid int, gameId int) values.LostUserDetail {
|
||
|
|
// var lostUserDetail values.LostUserDetail
|
||
|
|
//
|
||
|
|
// lostUserDetail.GameId = gameId
|
||
|
|
//
|
||
|
|
// isWin := true
|
||
|
|
// winCount := models.GetWinGameCountByBalance(nil, nil, &uid, nil, &gameId, nil, &isWin)
|
||
|
|
// lostUserDetail.GameCount = models.GetGameCountByBalance(nil, nil, &uid, nil, &gameId, nil)
|
||
|
|
//
|
||
|
|
// lostUserDetail.WinPer = utils.GetPer(winCount, lostUserDetail.GameCount)
|
||
|
|
//
|
||
|
|
// lostUserDetail.BreakPer = utils.GetPer(models.GetPlayerBreakCount(nil, nil, &uid, &gameId, nil, nil), lostUserDetail.GameCount)
|
||
|
|
//
|
||
|
|
// return lostUserDetail
|
||
|
|
//}
|