金额改成int
This commit is contained in:
parent
9c93f863b5
commit
d67eb28722
@ -418,10 +418,12 @@ func TestGetRole(t *testing.T) {
|
||||
return
|
||||
}
|
||||
//game_id=9175&server_id=0&user_id=247058227&user_name=yg90938415&no_virtual=1
|
||||
//game_id=3706&no_virtual=1®_time=0&server_id=0&use_cache=0&user_id=253403109&user_name=nl16840512
|
||||
req := CreateGetRoleReq(&GetRoleReq{
|
||||
GameId: 7874,
|
||||
UserId: "221016372",
|
||||
UserName: "rz35990497",
|
||||
ServerId: 10358,
|
||||
GameId: 8049,
|
||||
UserId: "135837010",
|
||||
UserName: "qy13815523",
|
||||
NoVirtual: 1,
|
||||
})
|
||||
resp, err := client.GetRole(req)
|
||||
@ -429,5 +431,5 @@ func TestGetRole(t *testing.T) {
|
||||
t.Error(err)
|
||||
return
|
||||
}
|
||||
fmt.Printf("%+v", resp.Data.RoleListInfo[0])
|
||||
fmt.Printf("%+v", resp)
|
||||
}
|
||||
|
||||
@ -1,8 +1,6 @@
|
||||
package game
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
|
||||
"golib.gaore.com/GaoreGo/gaore-common-sdk-go/sdk/requests"
|
||||
"golib.gaore.com/GaoreGo/gaore-common-sdk-go/sdk/responses"
|
||||
)
|
||||
@ -70,7 +68,7 @@ type MakeOrderReq struct {
|
||||
RealSid string `position:"Body" field:"real_sid"`
|
||||
RoleId string `position:"Body" field:"role_id"`
|
||||
RoleName string `position:"Body" field:"role_name"`
|
||||
Money string `position:"Body" field:"money"`
|
||||
Money int `position:"Body" field:"money"`
|
||||
ServerName string `position:"Body" field:"server_name"`
|
||||
ProductName string `position:"Body" field:"product_name"`
|
||||
DwId int64 `position:"Body" field:"dw_id"`
|
||||
@ -94,7 +92,7 @@ type MakeOrderParam struct {
|
||||
RealSid string
|
||||
RoleId string
|
||||
RoleName string
|
||||
Money float64
|
||||
Money int
|
||||
ServerName string
|
||||
ProductName string
|
||||
DwId int64
|
||||
@ -109,7 +107,7 @@ func CreateMakeOrderReq(param MakeOrderParam) *MakeOrderReq {
|
||||
RealSid: param.RealSid,
|
||||
RoleId: param.RoleId,
|
||||
RoleName: param.RoleName,
|
||||
Money: fmt.Sprintf("%v", param.Money),
|
||||
Money: param.Money,
|
||||
ServerName: param.ServerName,
|
||||
ProductName: param.ProductName,
|
||||
DwId: param.DwId,
|
||||
|
||||
@ -198,7 +198,7 @@ func TestGetUserId(t *testing.T) {
|
||||
t.Error(err)
|
||||
return
|
||||
}
|
||||
req := CreateGetUserIdRequest("rz35990497")
|
||||
req := CreateGetUserIdRequest("qy13815523")
|
||||
resp, err := client.GetUserId(req)
|
||||
if err != nil {
|
||||
t.Error(err)
|
||||
|
||||
@ -48,7 +48,7 @@ func TestManualReplenish(t *testing.T) {
|
||||
}
|
||||
req := CreateManualReplenishRequest(ManualReplenishParam{
|
||||
GameId: 100,
|
||||
Money: 6,
|
||||
Money: 98,
|
||||
OrderId: "202112060000193551730",
|
||||
UserName: "testuser",
|
||||
PayChannel: 1,
|
||||
|
||||
@ -7,7 +7,7 @@ import (
|
||||
|
||||
type ManualReplenishParam struct {
|
||||
GameId int64
|
||||
Money float64
|
||||
Money int
|
||||
OrderId string
|
||||
UserName string
|
||||
PayChannel int64
|
||||
@ -17,7 +17,7 @@ type ManualReplenishParam struct {
|
||||
type ManualReplenishRequest struct {
|
||||
*requests.RpcRequest
|
||||
GameId int64 `position:"Body" field:"game_id"`
|
||||
Money float64 `position:"Body" field:"money"`
|
||||
Money int `position:"Body" field:"money"`
|
||||
OrderId string `position:"Body" field:"order_id"`
|
||||
UserName string `position:"Body" field:"user_name"`
|
||||
PayChannel int64 `position:"Body" field:"pay_channel"`
|
||||
|
||||
@ -3,8 +3,9 @@ package sms
|
||||
import (
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
"golib.gaore.com/GaoreGo/gaore-common-sdk-go/sdk/requests"
|
||||
"testing"
|
||||
|
||||
"golib.gaore.com/GaoreGo/gaore-common-sdk-go/sdk/requests"
|
||||
)
|
||||
|
||||
var (
|
||||
@ -108,16 +109,16 @@ func TestClient_SendSmsCode(t *testing.T) {
|
||||
}},
|
||||
})
|
||||
|
||||
req.Domain = requests.Host{
|
||||
Default: "127.0.0.1:8804",
|
||||
}
|
||||
//req.Domain = requests.Host{
|
||||
// Default: "127.0.0.1:8804",
|
||||
//}
|
||||
|
||||
sms, err := client.SendSms(req)
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
|
||||
fmt.Println(sms)
|
||||
fmt.Println(sms.Msg)
|
||||
}
|
||||
|
||||
func TestClient_SendSmsUrl(t *testing.T) {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user