筛选游戏列表进行排序

fix/release
mofangmin 1 year ago
parent 080a7fa6ba
commit 80d6d36874
  1. 8
      call/config.go

@ -716,11 +716,15 @@ func GetConfigGameList(num int, cond ...int) []*common.ConfigGameList {
continue
}
ret = append(ret, v)
}
sort.Slice(ret, func(i, j int) bool {
return ret[i].Sort > ret[j].Sort
})
if num > 0 && len(ret) >= num {
return ret[:num]
} else {
return ret
}
}
return ret
}
func GetConfigGameListByID(provider, gameID int) *common.ConfigGameList {

Loading…
Cancel
Save