1
This commit is contained in:
@@ -121,7 +121,7 @@ func AutoSettingFakeDelivery() {
|
||||
if randTime < 0 {
|
||||
randTime = 1
|
||||
}
|
||||
if randTime > int64(len(riderListInfo[riderKey])) {
|
||||
if randTime >= int64(len(riderListInfo[riderKey])) {
|
||||
randTime = int64(len(riderListInfo[riderKey])) - 1
|
||||
}
|
||||
|
||||
@@ -133,6 +133,9 @@ func AutoSettingFakeDelivery() {
|
||||
return
|
||||
}
|
||||
//自动发单
|
||||
if len(riderListInfo[riderKey]) == 0 {
|
||||
globals.SugarLogger.Errorf("riderListInfo[riderKey][randTime] :%s,%s,%d", riderListInfo[riderKey][randTime], riderKey, randTime)
|
||||
}
|
||||
for riderName, riderPhone := range riderListInfo[riderKey][randTime] {
|
||||
globals.SugarLogger.Debugf("SelfDeliveringAndUpdateStatus : %s", v.VendorOrderID)
|
||||
if err := defsch.FixedScheduler.SelfDeliveringAndUpdateStatus(jxcontext.AdminCtx, v.VendorOrderID, v.VendorID, jxcontext.AdminCtx.GetUserName(), riderName, riderPhone); err != nil {
|
||||
|
||||
@@ -339,6 +339,9 @@ func (c *BaseScheduler) CheckStoreBalanceWithTip(ctx *jxcontext.Context, order *
|
||||
if tipFee > int64(storeAcct.AccountBalance) {
|
||||
return model.ErrCodeAccountBalanceNotEnough, fmt.Errorf("门店账户余额不足,不能加小费!")
|
||||
}
|
||||
if tipFee >= 1000 {
|
||||
return model.ErrCodeAccountBalanceNotEnough, fmt.Errorf("小费单子加价金额大于十元")
|
||||
}
|
||||
}
|
||||
return errCode, err
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user