diff --git a/business/jxstore/cms/cms.go b/business/jxstore/cms/cms.go index 08222f58b..af72e45b4 100644 --- a/business/jxstore/cms/cms.go +++ b/business/jxstore/cms/cms.go @@ -622,14 +622,10 @@ func GetSToURidingDistance2(sLng, sLat, uLng, uLat float64, orderId string) (way if err != nil { return nil, err } - if len(waybills) == 0 { - return wayBill, err + if len(waybills) == model.NO { + return nil, fmt.Errorf("请先创建运单,或者转自配送") } for _, v := range waybills { - if len(waybills) == 1 && v.Status == model.OrderStatusCanceled { - return nil, nil - } - // 获取骑行路线图 if v.OriginalData == "" { originalData, distance, durationTime, err := GetCyclingLine(sLng, sLat, uLng, uLat)