修改饿了么转自送

This commit is contained in:
邹宗楠
2022-06-17 11:53:57 +08:00
parent 1633f07bc5
commit 20841b7096
2 changed files with 10 additions and 3 deletions

View File

@@ -1026,7 +1026,7 @@ func (s *DefScheduler) swtich2SelfDeliverWithRetry(savedOrderInfo *WatchOrderInf
order := savedOrderInfo.order
globals.SugarLogger.Debugf("swtich2SelfDeliverWithRetry orderID:%s", order.VendorOrderID)
if order.WaybillVendorID != order.VendorID { // && err != scheduler.ErrOrderStatusAlreadySatisfyCurOperationELM && err != scheduler.ErrOrderStatusAlreadySatisfyCurOperationMTWM
if err := s.Swtich2SelfDeliver(order, ""); err != nil && (err != scheduler.ErrOrderStatusAlreadySatisfyCurOperation && !strings.Contains(err.Error(), "1047")) { //1047美团混合送
if err := s.Swtich2SelfDeliver(order, ""); err != nil && (err != scheduler.ErrOrderStatusAlreadySatisfyCurOperation && !strings.Contains(err.Error(), "1047") && !strings.Contains(err.Error(), "301251")) { //301251饿了转自送 1047美团混合送
globals.SugarLogger.Infof("swtich2SelfDeliverWithRetry failed, bill:%v, err:%v", bill, err)
if retryCount > 0 {
utils.AfterFuncWithRecover(duration, func() {

View File

@@ -1,10 +1,11 @@
package elm
import (
"testing"
"errors"
"git.rosy.net.cn/baseapi/utils"
_ "git.rosy.net.cn/jx-callback/business/jxcallback/orderman"
"git.rosy.net.cn/jx-callback/globals/testinit"
"testing"
)
func init() {
@@ -21,3 +22,9 @@ func TestGetOrder(t *testing.T) {
t.Fatal(err.Error())
}
}
func TestQQQQ(t *testing.T) {
err := errors.New("无需切自配送 level:0, code:301251")
dd := utils.IsErrMatch(err, "301251", nil)
t.Log(dd)
}