投诉骑手

This commit is contained in:
苏尹岚
2019-12-25 18:37:00 +08:00
parent 8b86f84966
commit 3983e9d5a9
3 changed files with 14 additions and 9 deletions

View File

@@ -249,14 +249,14 @@ func GetComplaintReasons() (complaintReasonList []*dadaapi.ComplaintReason) {
return complaintReasonList
}
func ComplaintRider(ctx *jxcontext.Context, orderID string, vendorID, complaintID int) (err error) {
func ComplaintRider(ctx *jxcontext.Context, vendorOrderID string, vendorID, waybillVendorID, complaintID int) (err error) {
db := dao.GetDB()
p := partner.GetDeliveryPlatformFromVendorID(vendorID).Handler
wayBillList, err := dao.GetWayBillByOrderID(db, model.OrderStatusFinished, vendorID, orderID)
wayBillList, err := dao.GetWayBillByOrderID(db, model.OrderStatusFinished, vendorID, waybillVendorID, vendorOrderID)
if err == nil && len(wayBillList) > 0 {
err = p.ComplaintRider(wayBillList[0], complaintID, complaintReasonsMap[complaintID])
} else {
return fmt.Errorf("未查询到到相关订单,订单状态要求必须是完成!订单号:[%v] ,厂商:[%v]", orderID, vendorID)
return fmt.Errorf("未查询到到相关订单,订单状态要求必须是完成!订单号:[%v] ,厂商:[%v]", orderID, waybillVendorID)
}
return err
}