Compare commits
No commits in common. "32ba08b231db757389559431a4fdc68ddf94d0dd" and "bc565ac059d317aa8f665bbf43426c6dcef9edd9" have entirely different histories.
32ba08b231
...
bc565ac059
@ -94,19 +94,3 @@ func (client *Client) OrderAppraise(req *OrderAppraiseRequest) (resp *OrderAppra
|
|||||||
err = client.DoAction(req, resp)
|
err = client.DoAction(req, resp)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
func (client *Client) OrderRestart(req *OrderRestartRequest) (resp *OrderRestartResponse, err error) {
|
|
||||||
resp = CreateOrderRestartResponse()
|
|
||||||
err = client.DoAction(req, resp)
|
|
||||||
return
|
|
||||||
}
|
|
||||||
func (client *Client) OrderSubmit(req *OrderSubmitRequest) (resp *OrderSubmitResponse, err error) {
|
|
||||||
resp = CreateOrderSubmitResponse()
|
|
||||||
err = client.DoAction(req, resp)
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
func (client *Client) OrderFurtherPart(req *OrderFurtherPartRequest) (resp *OrderFurtherPartResponse, err error) {
|
|
||||||
resp = CreateOrderFurtherPartResponse()
|
|
||||||
err = client.DoAction(req, resp)
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
@ -185,7 +185,6 @@ func TestOrderUrgent(t *testing.T) {
|
|||||||
fmt.Printf(fmt.Sprintf("%v", res))
|
fmt.Printf(fmt.Sprintf("%v", res))
|
||||||
}
|
}
|
||||||
|
|
||||||
// 用户更新工单处理标识
|
|
||||||
func TestOrderUpdateHandle(t *testing.T) {
|
func TestOrderUpdateHandle(t *testing.T) {
|
||||||
client, newErr := NewClient()
|
client, newErr := NewClient()
|
||||||
if newErr != nil {
|
if newErr != nil {
|
||||||
@ -205,7 +204,6 @@ func TestOrderUpdateHandle(t *testing.T) {
|
|||||||
fmt.Printf(fmt.Sprintf("%v", res))
|
fmt.Printf(fmt.Sprintf("%v", res))
|
||||||
}
|
}
|
||||||
|
|
||||||
// 用户评价工单
|
|
||||||
func TestOrderAppraise(t *testing.T) {
|
func TestOrderAppraise(t *testing.T) {
|
||||||
client, newErr := NewClient()
|
client, newErr := NewClient()
|
||||||
if newErr != nil {
|
if newErr != nil {
|
||||||
@ -225,100 +223,3 @@ func TestOrderAppraise(t *testing.T) {
|
|||||||
}
|
}
|
||||||
fmt.Printf(fmt.Sprintf("%v", res))
|
fmt.Printf(fmt.Sprintf("%v", res))
|
||||||
}
|
}
|
||||||
|
|
||||||
// 工单重启
|
|
||||||
func TestOrderRestart(t *testing.T) {
|
|
||||||
client, newErr := NewClient()
|
|
||||||
if newErr != nil {
|
|
||||||
panic(newErr)
|
|
||||||
}
|
|
||||||
req := CreateOrderRestartRequest(OrderRestartParam{
|
|
||||||
OrderNum: "20250530173554491048",
|
|
||||||
RemarkContent: "模拟用户重启",
|
|
||||||
RemarkPic: []string{},
|
|
||||||
})
|
|
||||||
res, err := client.OrderRestart(req)
|
|
||||||
if err != nil {
|
|
||||||
t.Error(err)
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if res.Code != 0 {
|
|
||||||
t.Error("工单重启失败")
|
|
||||||
}
|
|
||||||
fmt.Printf(fmt.Sprintf("%v", res))
|
|
||||||
}
|
|
||||||
|
|
||||||
// 提交工单
|
|
||||||
func TestOrderSubmit(t *testing.T) {
|
|
||||||
client, newErr := NewClient()
|
|
||||||
if newErr != nil {
|
|
||||||
panic(newErr)
|
|
||||||
}
|
|
||||||
req := CreateOrderSubmitRequest(OrderSubmitParam{
|
|
||||||
GameId: 7991,
|
|
||||||
UserName: "ws45265737",
|
|
||||||
Uid: 65598086,
|
|
||||||
RoleId: "10676785",
|
|
||||||
RoleName: "流水行者",
|
|
||||||
ServerName: "血阳琉璃",
|
|
||||||
OrderTemplateCode: "btu7RoDj",
|
|
||||||
Detail: "我的问题是,组队这个玩法的初衷是希望实现大家能和身边认识的朋友一起下洞的目标。但是现在看来,很多玩家都选择了在游戏中随机匹配队友,而我们发现,组队机制暴露的绝大部分玩家体验问题都是在随机匹配中出现的。<br/>比如恶意踢人,又比如匹配到的玩家等级比较低,不符合自己本次下洞的目标,再或者是组队进入洞窟却发现队友已经快要收尾结束探险了。",
|
|
||||||
Phone: "13725263463",
|
|
||||||
ApplyIp: "183.63.75.58",
|
|
||||||
OrderParts: []OrderSubmitPart{
|
|
||||||
{
|
|
||||||
PartKey: "email",
|
|
||||||
PartName: "联系邮箱",
|
|
||||||
PartValue: "kingson2011@126.com",
|
|
||||||
PicValue: nil,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
PartKey: "pay_pic",
|
|
||||||
PartName: "充值凭证",
|
|
||||||
PartValue: "",
|
|
||||||
PicValue: []string{
|
|
||||||
"uploads/d1a/d1aba28357b89e7ebfc77e5c43fc81b7.jpeg",
|
|
||||||
"uploads/c37/c3726c5cf7175ed048f6c68416dbf30b.jpeg",
|
|
||||||
"uploads/ca2/ca285ae8feae8c60d51b53079fa9b2a9.jpeg",
|
|
||||||
},
|
|
||||||
},
|
|
||||||
},
|
|
||||||
SmsCode: "7204",
|
|
||||||
})
|
|
||||||
res, err := client.OrderSubmit(req)
|
|
||||||
if err != nil {
|
|
||||||
t.Error(err)
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if res.Code != 0 {
|
|
||||||
t.Error("工单提交失败")
|
|
||||||
}
|
|
||||||
fmt.Printf(fmt.Sprintf("%v", res))
|
|
||||||
}
|
|
||||||
|
|
||||||
// 用户工单补充资料
|
|
||||||
func TestOrderFurtherPart(t *testing.T) {
|
|
||||||
client, newErr := NewClient()
|
|
||||||
if newErr != nil {
|
|
||||||
panic(newErr)
|
|
||||||
}
|
|
||||||
req := CreateOrderFurtherPartRequest(OrderFurtherPartParam{
|
|
||||||
OrderNum: "20250611160840208567",
|
|
||||||
OrderParts: []OrderSubmitPart{
|
|
||||||
{
|
|
||||||
PartKey: "game_name",
|
|
||||||
PartName: "游戏名称",
|
|
||||||
PartValue: "镇魂街:最终章",
|
|
||||||
},
|
|
||||||
},
|
|
||||||
})
|
|
||||||
res, err := client.OrderFurtherPart(req)
|
|
||||||
if err != nil {
|
|
||||||
t.Error(err)
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if res.Code != 0 {
|
|
||||||
t.Error("用户工单补充资料失败")
|
|
||||||
}
|
|
||||||
fmt.Printf(fmt.Sprintf("%v", res))
|
|
||||||
}
|
|
||||||
|
@ -171,144 +171,3 @@ func CreateOrderAppraiseResponse() (resp *OrderAppraiseResponse) {
|
|||||||
BaseResponse: &responses.BaseResponse{},
|
BaseResponse: &responses.BaseResponse{},
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// OrderRestartParam 用户重启工单
|
|
||||||
type OrderRestartParam struct {
|
|
||||||
OrderNum string `json:"order_num"`
|
|
||||||
RemarkContent string `json:"remark_content"`
|
|
||||||
RemarkPic []string `json:"remark_pic"`
|
|
||||||
}
|
|
||||||
type OrderRestartRequest struct {
|
|
||||||
*requests.JsonRequest
|
|
||||||
OrderNum string `position:"Json" field:"order_num"`
|
|
||||||
RemarkContent string `position:"Json" field:"remark_content"`
|
|
||||||
RemarkPic []string `position:"Json" field:"remark_pic"`
|
|
||||||
}
|
|
||||||
type OrderRestartResponse struct {
|
|
||||||
*responses.BaseResponse
|
|
||||||
Code int `json:"code"`
|
|
||||||
Msg string `json:"msg"`
|
|
||||||
}
|
|
||||||
|
|
||||||
func CreateOrderRestartRequest(param OrderRestartParam) (req *OrderRestartRequest) {
|
|
||||||
req = &OrderRestartRequest{
|
|
||||||
JsonRequest: &requests.JsonRequest{},
|
|
||||||
OrderNum: param.OrderNum,
|
|
||||||
RemarkContent: param.RemarkContent,
|
|
||||||
RemarkPic: param.RemarkPic,
|
|
||||||
}
|
|
||||||
req.InitWithApiInfo(HOST, VERSION, "/v1/work_order/order_restart")
|
|
||||||
req.Method = requests.POST
|
|
||||||
return
|
|
||||||
}
|
|
||||||
func CreateOrderRestartResponse() (resp *OrderRestartResponse) {
|
|
||||||
return &OrderRestartResponse{
|
|
||||||
BaseResponse: &responses.BaseResponse{},
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// OrderSubmitParam 工单提交
|
|
||||||
type OrderSubmitParam struct {
|
|
||||||
GameId int64 `json:"game_id"`
|
|
||||||
UserName string `json:"user_name"`
|
|
||||||
Uid int64 `json:"uid"`
|
|
||||||
RoleId string `json:"role_id"`
|
|
||||||
RoleName string `json:"role_name"`
|
|
||||||
ServerName string `json:"server_name"`
|
|
||||||
OrderTemplateCode string `json:"order_template_code"`
|
|
||||||
Detail string `json:"detail"`
|
|
||||||
Phone string `json:"phone"`
|
|
||||||
ApplyIp string `json:"apply_ip"`
|
|
||||||
OrderParts []OrderSubmitPart `json:"order_parts"`
|
|
||||||
SmsCode string `json:"sms_code"`
|
|
||||||
}
|
|
||||||
|
|
||||||
type OrderSubmitPart struct {
|
|
||||||
PartId int64 `json:"part_id"`
|
|
||||||
PartKey string `json:"part_key"`
|
|
||||||
PartName string `json:"part_name"`
|
|
||||||
PartValue string `json:"part_value"`
|
|
||||||
PartType int64 `json:"part_type"`
|
|
||||||
PicValue []string `json:"pic_value"`
|
|
||||||
}
|
|
||||||
type OrderSubmitRequest struct {
|
|
||||||
*requests.JsonRequest
|
|
||||||
GameId int64 `position:"Json" field:"game_id"`
|
|
||||||
UserName string `position:"Json" field:"user_name"`
|
|
||||||
Uid int64 `position:"Json" field:"uid"`
|
|
||||||
RoleId string `position:"Json" field:"role_id"`
|
|
||||||
RoleName string `position:"Json" field:"role_name"`
|
|
||||||
ServerName string `position:"Json" field:"server_name"`
|
|
||||||
OrderTemplateCode string `position:"Json" field:"order_template_code"`
|
|
||||||
Detail string `position:"Json" field:"detail"`
|
|
||||||
Phone string `position:"Json" field:"phone"`
|
|
||||||
ApplyIp string `position:"Json" field:"apply_ip"`
|
|
||||||
OrderParts []OrderSubmitPart `position:"Json" field:"order_parts"`
|
|
||||||
SmsCode string `position:"Json" field:"sms_code"`
|
|
||||||
}
|
|
||||||
type OrderSubmitResponse struct {
|
|
||||||
*responses.BaseResponse
|
|
||||||
Code int `json:"code"`
|
|
||||||
Msg string `json:"msg"`
|
|
||||||
Data struct {
|
|
||||||
OrderNum string `json:"order_num"`
|
|
||||||
} `json:"data"`
|
|
||||||
}
|
|
||||||
|
|
||||||
func CreateOrderSubmitRequest(param OrderSubmitParam) (req *OrderSubmitRequest) {
|
|
||||||
req = &OrderSubmitRequest{
|
|
||||||
JsonRequest: &requests.JsonRequest{},
|
|
||||||
GameId: param.GameId,
|
|
||||||
UserName: param.UserName,
|
|
||||||
Uid: param.Uid,
|
|
||||||
RoleId: param.RoleId,
|
|
||||||
RoleName: param.RoleName,
|
|
||||||
ServerName: param.ServerName,
|
|
||||||
OrderTemplateCode: param.OrderTemplateCode,
|
|
||||||
Detail: param.Detail,
|
|
||||||
Phone: param.Phone,
|
|
||||||
ApplyIp: param.ApplyIp,
|
|
||||||
OrderParts: param.OrderParts,
|
|
||||||
SmsCode: param.SmsCode,
|
|
||||||
}
|
|
||||||
req.InitWithApiInfo(HOST, VERSION, "/v1/work_order/order_submit")
|
|
||||||
req.Method = requests.POST
|
|
||||||
return
|
|
||||||
}
|
|
||||||
func CreateOrderSubmitResponse() (resp *OrderSubmitResponse) {
|
|
||||||
return &OrderSubmitResponse{
|
|
||||||
BaseResponse: &responses.BaseResponse{},
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// OrderFurtherPartParam 工单补充资料
|
|
||||||
type OrderFurtherPartParam struct {
|
|
||||||
OrderNum string `json:"order_num"`
|
|
||||||
OrderParts []OrderSubmitPart `json:"order_parts"`
|
|
||||||
}
|
|
||||||
type OrderFurtherPartRequest struct {
|
|
||||||
*requests.JsonRequest
|
|
||||||
OrderNum string `position:"Json" field:"order_num"`
|
|
||||||
OrderParts []OrderSubmitPart `position:"Json" field:"order_parts"`
|
|
||||||
}
|
|
||||||
type OrderFurtherPartResponse struct {
|
|
||||||
*responses.BaseResponse
|
|
||||||
Code int `json:"code"`
|
|
||||||
Msg string `json:"msg"`
|
|
||||||
}
|
|
||||||
|
|
||||||
func CreateOrderFurtherPartRequest(param OrderFurtherPartParam) (req *OrderFurtherPartRequest) {
|
|
||||||
req = &OrderFurtherPartRequest{
|
|
||||||
JsonRequest: &requests.JsonRequest{},
|
|
||||||
OrderNum: param.OrderNum,
|
|
||||||
OrderParts: param.OrderParts,
|
|
||||||
}
|
|
||||||
req.InitWithApiInfo(HOST, VERSION, "/v1/work_order/order_further_data")
|
|
||||||
req.Method = requests.POST
|
|
||||||
return
|
|
||||||
}
|
|
||||||
func CreateOrderFurtherPartResponse() (resp *OrderFurtherPartResponse) {
|
|
||||||
return &OrderFurtherPartResponse{
|
|
||||||
BaseResponse: &responses.BaseResponse{},
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
Loading…
Reference in New Issue
Block a user