【cs服务】
1、用户补充资料
This commit is contained in:
parent
c0ced849fc
commit
32ba08b231
@ -104,3 +104,9 @@ func (client *Client) OrderSubmit(req *OrderSubmitRequest) (resp *OrderSubmitRes
|
|||||||
err = client.DoAction(req, resp)
|
err = client.DoAction(req, resp)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (client *Client) OrderFurtherPart(req *OrderFurtherPartRequest) (resp *OrderFurtherPartResponse, err error) {
|
||||||
|
resp = CreateOrderFurtherPartResponse()
|
||||||
|
err = client.DoAction(req, resp)
|
||||||
|
return
|
||||||
|
}
|
||||||
|
@ -185,6 +185,7 @@ 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 {
|
||||||
@ -204,6 +205,7 @@ 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 {
|
||||||
@ -224,6 +226,7 @@ func TestOrderAppraise(t *testing.T) {
|
|||||||
fmt.Printf(fmt.Sprintf("%v", res))
|
fmt.Printf(fmt.Sprintf("%v", res))
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 工单重启
|
||||||
func TestOrderRestart(t *testing.T) {
|
func TestOrderRestart(t *testing.T) {
|
||||||
client, newErr := NewClient()
|
client, newErr := NewClient()
|
||||||
if newErr != nil {
|
if newErr != nil {
|
||||||
@ -244,6 +247,8 @@ func TestOrderRestart(t *testing.T) {
|
|||||||
}
|
}
|
||||||
fmt.Printf(fmt.Sprintf("%v", res))
|
fmt.Printf(fmt.Sprintf("%v", res))
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 提交工单
|
||||||
func TestOrderSubmit(t *testing.T) {
|
func TestOrderSubmit(t *testing.T) {
|
||||||
client, newErr := NewClient()
|
client, newErr := NewClient()
|
||||||
if newErr != nil {
|
if newErr != nil {
|
||||||
@ -290,3 +295,30 @@ func TestOrderSubmit(t *testing.T) {
|
|||||||
}
|
}
|
||||||
fmt.Printf(fmt.Sprintf("%v", res))
|
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))
|
||||||
|
}
|
||||||
|
@ -280,3 +280,35 @@ func CreateOrderSubmitResponse() (resp *OrderSubmitResponse) {
|
|||||||
BaseResponse: &responses.BaseResponse{},
|
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