Compare commits
No commits in common. "master" and "v1.1.72" have entirely different histories.
@ -260,32 +260,6 @@ func CreateGetGameCompanyResp() *GetGameCompanyResp {
|
|||||||
|
|
||||||
// ==== 获取游戏客户端版本配置
|
// ==== 获取游戏客户端版本配置
|
||||||
|
|
||||||
type GameVersion struct {
|
|
||||||
ID int `json:"id"`
|
|
||||||
GameID int `json:"game_id"`
|
|
||||||
GameVersion string `json:"version"`
|
|
||||||
GameURL string `json:"url"`
|
|
||||||
PayCallbackURL string `json:"pay_callback_url"`
|
|
||||||
DomainURL string `json:"domain_url"`
|
|
||||||
Status int `json:"status"`
|
|
||||||
H5Version int `json:"h5_version"`
|
|
||||||
H5Status int `json:"h5_status"`
|
|
||||||
IsH5Logout int `json:"is_h5_logout"`
|
|
||||||
HideWindow int `json:"hidewindow"`
|
|
||||||
PayInfo PayInfo `json:"pay_display_info"`
|
|
||||||
IsYsdk int `json:"is_ysdk"`
|
|
||||||
CheckVerified int `json:"check_verified"`
|
|
||||||
Company string `json:"company"`
|
|
||||||
CompanyKf string `json:"company_kf"`
|
|
||||||
CompanyProto string `json:"company_proto"`
|
|
||||||
CompanySms string `json:"company_sms"`
|
|
||||||
KfStatus int `json:"kf_status"`
|
|
||||||
PopupTime int `json:"popup_time"`
|
|
||||||
ExtData map[string]any `json:"ext_data"`
|
|
||||||
VersionStatus int `json:"version_status"`
|
|
||||||
VersionTime int `json:"version_time"`
|
|
||||||
}
|
|
||||||
|
|
||||||
type GetGameVersionReq struct {
|
type GetGameVersionReq struct {
|
||||||
*requests.RpcRequest
|
*requests.RpcRequest
|
||||||
GameId int `position:"Body" field:"game_id"`
|
GameId int `position:"Body" field:"game_id"`
|
||||||
@ -296,7 +270,7 @@ type GetGameVersionResp struct {
|
|||||||
*responses.BaseResponse
|
*responses.BaseResponse
|
||||||
Code int `json:"code"`
|
Code int `json:"code"`
|
||||||
Msg string `json:"msg"`
|
Msg string `json:"msg"`
|
||||||
Data GameVersion `json:"data"`
|
Data GameVersionInfo `json:"data"`
|
||||||
}
|
}
|
||||||
|
|
||||||
func CreateGetGameVersionReq(gameId int, gameVersion string) *GetGameVersionReq {
|
func CreateGetGameVersionReq(gameId int, gameVersion string) *GetGameVersionReq {
|
||||||
|
@ -33,14 +33,3 @@ func (c *Client) OpenGame(req *OpenGameReq) (resp *OpenGameResp, err error) {
|
|||||||
|
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
// NewPayRedisData 设置支付redis相关数据
|
|
||||||
func (c *Client) NewPayRedisData(req *NewPayRedisDataReq) (resp *NewPayRedisDataResp, err error) {
|
|
||||||
resp = CreateNewPayRedisDataResp()
|
|
||||||
err = c.DoAction(req, resp)
|
|
||||||
if err != nil {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
@ -19,18 +19,3 @@ func TestOpenGame(t *testing.T) {
|
|||||||
|
|
||||||
fmt.Println(resp.Code, resp.Msg)
|
fmt.Println(resp.Code, resp.Msg)
|
||||||
}
|
}
|
||||||
|
|
||||||
func TestNewPayRedisData(t *testing.T) {
|
|
||||||
client, err := NewClient()
|
|
||||||
if err != nil {
|
|
||||||
panic(err)
|
|
||||||
}
|
|
||||||
req := CreateNewPayRedisDataReq()
|
|
||||||
|
|
||||||
resp, err := client.NewPayRedisData(req)
|
|
||||||
if err != nil {
|
|
||||||
panic(err)
|
|
||||||
}
|
|
||||||
|
|
||||||
fmt.Println(resp.Code, resp.Msg)
|
|
||||||
}
|
|
||||||
|
@ -15,14 +15,6 @@ type OpenGameResp struct {
|
|||||||
*responses.BaseResponse
|
*responses.BaseResponse
|
||||||
}
|
}
|
||||||
|
|
||||||
type NewPayRedisDataReq struct {
|
|
||||||
*requests.RpcRequest
|
|
||||||
}
|
|
||||||
|
|
||||||
type NewPayRedisDataResp struct {
|
|
||||||
*responses.BaseResponse
|
|
||||||
}
|
|
||||||
|
|
||||||
// GetHttpContentBytes 因为http://script.gaore.com/open_game.php?game_id=这个接口返回的不是json,反序列化会报错,所以返回一个固定的json
|
// GetHttpContentBytes 因为http://script.gaore.com/open_game.php?game_id=这个接口返回的不是json,反序列化会报错,所以返回一个固定的json
|
||||||
func (baseResponse *OpenGameResp) GetHttpContentBytes() []byte {
|
func (baseResponse *OpenGameResp) GetHttpContentBytes() []byte {
|
||||||
b, _ := json.Marshal(map[string]interface{}{"code": 200, "msg": "success"})
|
b, _ := json.Marshal(map[string]interface{}{"code": 200, "msg": "success"})
|
||||||
@ -48,21 +40,3 @@ func CreateOpenGameResp() *OpenGameResp {
|
|||||||
BaseResponse: &responses.BaseResponse{},
|
BaseResponse: &responses.BaseResponse{},
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// CreateNewPayRedisDataReq 设置支付redis相关数据
|
|
||||||
func CreateNewPayRedisDataReq() *NewPayRedisDataReq {
|
|
||||||
req := &NewPayRedisDataReq{
|
|
||||||
&requests.RpcRequest{},
|
|
||||||
}
|
|
||||||
|
|
||||||
req.InitWithApiInfo(HOST, VERSION, "pay/new_pay_redis_data.php")
|
|
||||||
req.Method = requests.GET
|
|
||||||
|
|
||||||
return req
|
|
||||||
}
|
|
||||||
|
|
||||||
func CreateNewPayRedisDataResp() *NewPayRedisDataResp {
|
|
||||||
return &NewPayRedisDataResp{
|
|
||||||
BaseResponse: &responses.BaseResponse{},
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
@ -3,7 +3,6 @@ package stat
|
|||||||
import (
|
import (
|
||||||
"golib.gaore.com/GaoreGo/gaore-common-sdk-go/sdk"
|
"golib.gaore.com/GaoreGo/gaore-common-sdk-go/sdk"
|
||||||
"golib.gaore.com/GaoreGo/gaore-common-sdk-go/sdk/requests"
|
"golib.gaore.com/GaoreGo/gaore-common-sdk-go/sdk/requests"
|
||||||
"time"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
@ -54,10 +53,6 @@ func (c *Client) GetAgentList(req *GetAgentListReq) (resp *GetAgentListResp, err
|
|||||||
// GetUserRoleRegPage 获取用户角色注册分页列表
|
// GetUserRoleRegPage 获取用户角色注册分页列表
|
||||||
func (c *Client) GetUserRoleRegPage(req *UserRoleRegReq) (resp *UserRoleRegResp, err error) {
|
func (c *Client) GetUserRoleRegPage(req *UserRoleRegReq) (resp *UserRoleRegResp, err error) {
|
||||||
resp = CreateUserRoleRegPageResp()
|
resp = CreateUserRoleRegPageResp()
|
||||||
// 设置超时时间
|
|
||||||
req.SetConnectTimeout(10 * time.Second)
|
|
||||||
// 设置读取超时时间
|
|
||||||
req.SetReadTimeout(20 * time.Second)
|
|
||||||
err = c.DoAction(req, resp)
|
err = c.DoAction(req, resp)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return
|
return
|
||||||
|
@ -88,8 +88,8 @@ func TestClient_GetUserRoleRegPage(t *testing.T) {
|
|||||||
req := CreateUserRoleRegPageReq(UserRoleRegParam{
|
req := CreateUserRoleRegPageReq(UserRoleRegParam{
|
||||||
Page: 1,
|
Page: 1,
|
||||||
PageSize: 10,
|
PageSize: 10,
|
||||||
RoleId: "",
|
RoleId: "-1",
|
||||||
RoleName: "温文波箐魔灵",
|
RoleName: "",
|
||||||
})
|
})
|
||||||
|
|
||||||
resp, err := client.GetUserRoleRegPage(req)
|
resp, err := client.GetUserRoleRegPage(req)
|
||||||
|
Loading…
Reference in New Issue
Block a user