This commit is contained in:
邹宗楠
2023-05-23 19:06:47 +08:00
parent bb57eacecc
commit dcc5c91f58
6 changed files with 18 additions and 34 deletions

View File

@@ -358,7 +358,6 @@ func (c *DeliveryHandler) CreateWaybill(order *model.GoodsOrder, maxDeliveryFee
}
// 重新发送订单
result, err = api.DadaAPI.ReaddOrder(billParams)
globals.SugarLogger.Debugf("重新发送订单多次发单======== := %s", utils.Format4Output(result, false))
if err != nil {
return nil, err
}
@@ -368,7 +367,6 @@ func (c *DeliveryHandler) CreateWaybill(order *model.GoodsOrder, maxDeliveryFee
if result, err = api.DadaAPI.QueryDeliverFee(billParams); err != nil {
return nil, err
}
globals.SugarLogger.Debugf("查询达达订单费用(第一次发单)======== := %s", utils.Format4Output(result, false))
// 阀值警报
if err = delivery.CallCreateWaybillPolicy(jxutils.StandardPrice2Int(result.Fee), maxDeliveryFee, order, model.VendorIDDada); err != nil {
return nil, err
@@ -377,7 +375,6 @@ func (c *DeliveryHandler) CreateWaybill(order *model.GoodsOrder, maxDeliveryFee
if err = api.DadaAPI.AddOrderAfterQuery(result.DeliveryNo); err != nil {
return nil, err
}
globals.SugarLogger.Debugf("重新发送订单======== := %s", utils.Format4Output(result, false))
}
if result == nil {
return nil, errors.New("达达配送,平台调用错误,无订单数据返回")