1
This commit is contained in:
@@ -384,11 +384,11 @@ func makeRiderInfo(fakeWayBill *model.Waybill, riderInfo *utils.RiderInfo) {
|
|||||||
|
|
||||||
// UpdateFakeWayBillToTiktok 轮询更新假订单到抖音(抖音/美团/饿百)
|
// UpdateFakeWayBillToTiktok 轮询更新假订单到抖音(抖音/美团/饿百)
|
||||||
func UpdateFakeWayBillToTiktok() {
|
func UpdateFakeWayBillToTiktok() {
|
||||||
scheduleTimer, _ := rand.Int(rand.Reader, big.NewInt(1000))
|
//scheduleTimer, _ := rand.Int(rand.Reader, big.NewInt(1000))
|
||||||
randTimeSchedule := scheduleTimer.Int64()
|
//randTimeSchedule := scheduleTimer.Int64()
|
||||||
if randTimeSchedule > 200 {
|
//if randTimeSchedule > 500 {
|
||||||
return
|
// return
|
||||||
}
|
//}
|
||||||
|
|
||||||
fakeWayBill, err := dao.GetWayBillFakeOrder()
|
fakeWayBill, err := dao.GetWayBillFakeOrder()
|
||||||
if err != nil {
|
if err != nil {
|
||||||
@@ -445,7 +445,7 @@ func UpdateFakeWayBillToTiktok() {
|
|||||||
}
|
}
|
||||||
// 推送完成时加多加十分钟,相当于是配送中状态多存货十分钟
|
// 推送完成时加多加十分钟,相当于是配送中状态多存货十分钟
|
||||||
if fakeWayBill[i].Status == model.WaybillStatusDelivered {
|
if fakeWayBill[i].Status == model.WaybillStatusDelivered {
|
||||||
randTime += 600
|
randTime += 300
|
||||||
}
|
}
|
||||||
fakeWayBill[i].StatusTime = time.Now().Add(time.Duration(randTime) * time.Second).Local()
|
fakeWayBill[i].StatusTime = time.Now().Add(time.Duration(randTime) * time.Second).Local()
|
||||||
fakeWayBill[i].WaybillFinishedAt = time.Now()
|
fakeWayBill[i].WaybillFinishedAt = time.Now()
|
||||||
|
|||||||
Reference in New Issue
Block a user