新增投诉骑手接口
This commit is contained in:
@@ -343,3 +343,15 @@ func (a *API) SimulateRearrange(deliveryId int64, mtPeiSongId string) (err error
|
||||
func (a *API) SimulateReportException(deliveryId int64, mtPeiSongId string) (err error) {
|
||||
return a.simulateOrderBehavior("reportException", deliveryId, mtPeiSongId)
|
||||
}
|
||||
|
||||
//评价骑手
|
||||
func (a *API) EvaluateRider(deliveryId int64, mtPeiSongId string, score int, commentContent string) (err error) {
|
||||
params := map[string]interface{}{
|
||||
"delivery_id": deliveryId,
|
||||
"mt_peisong_id": mtPeiSongId,
|
||||
"score": score,
|
||||
"comment_content": commentContent,
|
||||
}
|
||||
_, err = a.AccessAPI("order/evaluate", params)
|
||||
return err
|
||||
}
|
||||
|
||||
@@ -62,3 +62,10 @@ func TestCancelOrder(t *testing.T) {
|
||||
handleError(t, err)
|
||||
sugarLogger.Debug(result)
|
||||
}
|
||||
|
||||
func TestEvaluateRider(t *testing.T) {
|
||||
err := api.EvaluateRider(123456789, "1529387562097059", 1, "just a test")
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user