dengbiao há 2 meses
ascendente
cometimento
78a2147aba
1 ficheiros alterados com 4 adições e 4 eliminações
  1. +4
    -4
      app/customer/svc/order/svc_central_kitchen_for_school_order.go

+ 4
- 4
app/customer/svc/order/svc_central_kitchen_for_school_order.go Ver ficheiro

@@ -97,16 +97,16 @@ func CentralKitchenForSchoolOrderRefund(req md.CentralKitchenForSchoolOrderRefun
//2、判断是否为可退餐时间段
now := time.Now()
today, _ := time.ParseInLocation("2006-01-02", time.Now().Format("2006-01-02"), time.Local)
tomorrowDay := today.AddDate(0, 0, 1)
//tomorrowDay := today.AddDate(0, 0, 1)

date, _ := time.ParseInLocation("2006-01-02", centralKitchenForSchoolUserWithDay.Date, time.Local)
if today.After(date) || today.Equal(date) {
if today.After(date) {
//2.2、判断是否小于今天
err = errors.New("当前订餐不在可退订时间范围内")
return
}
if tomorrowDay.Equal(date) {
//2.3、判断是否过了日可订餐时间
if today.Equal(date) {
//2.3、判断是否过了日可订餐时间
var centralKitchenForSchoolCancelMealTime time.Time
var cfg *model.SysCfg
if centralKitchenForSchoolUserWithDay.Kind == enum.CentralKitchenForSchoolUserWithDayKindForBreakfast {


Carregando…
Cancelar
Guardar