|
|
@@ -643,9 +643,9 @@ func CentralKitchenForSchoolDataStatisticsExport(req md.CentralKitchenForSchoolD |
|
|
|
if req.EnterpriseId != 0 { |
|
|
|
sess.And("central_kitchen_for_school_package_ord_for_reserve.enterprise_id =?", req.EnterpriseId) |
|
|
|
} |
|
|
|
//if req.StartDate != "" { |
|
|
|
// sess.And("central_kitchen_for_school_package_ord_for_reserve.meal_time_start >= ?", req.StartDate) |
|
|
|
//} |
|
|
|
if req.StartDate != "" { |
|
|
|
sess.And("central_kitchen_for_school_package_ord_for_reserve.meal_time_start >= ? or central_kitchen_for_school_package_ord_for_reserve.meal_time_end <= ?", req.StartDate, req.EndDate) |
|
|
|
} |
|
|
|
//if req.EndDate != "" { |
|
|
|
// sess.And("central_kitchen_for_school_package_ord_for_reserve.meal_time_start <= ?", req.EndDate) |
|
|
|
//} |
|
|
@@ -684,7 +684,7 @@ func CentralKitchenForSchoolDataStatisticsExport(req md.CentralKitchenForSchoolD |
|
|
|
|
|
|
|
count, err2 := centralKitchenForSchoolUserWithDayDb.CountCentralKitchenForSchoolUserWithDayByOrdNo( |
|
|
|
v.CentralKitchenForSchoolPackageOrdForReserve.OutTradeNo, enum.CentralKitchenForSchoolUserWithDayStateForCancel, |
|
|
|
req.StartDate, req.EndDate) |
|
|
|
req.StartDate, req.EndDate, req.MealKindList) |
|
|
|
if err2 != nil { |
|
|
|
logx.Error(err) |
|
|
|
println("<<<<SelfSupportForSchoolDataStatisticsExport3>>>>>Error:::", err.Error()) |
|
|
@@ -811,9 +811,9 @@ func CentralKitchenForSchoolDataStatisticsExport(req md.CentralKitchenForSchoolD |
|
|
|
if req.EnterpriseId != 0 { |
|
|
|
sess.And("central_kitchen_for_school_package_ord_for_reserve.enterprise_id =?", req.EnterpriseId) |
|
|
|
} |
|
|
|
//if req.StartDate != "" { |
|
|
|
// sess.And("central_kitchen_for_school_package_ord_for_reserve.meal_time_start >= ?", req.StartDate) |
|
|
|
//} |
|
|
|
if req.StartDate != "" { |
|
|
|
sess.And("central_kitchen_for_school_package_ord_for_reserve.meal_time_start >= ? or central_kitchen_for_school_package_ord_for_reserve.meal_time_end <= ?", req.StartDate, req.EndDate) |
|
|
|
} |
|
|
|
//if req.EndDate != "" { |
|
|
|
// sess.And("central_kitchen_for_school_package_ord_for_reserve.meal_time_start <= ?", req.EndDate) |
|
|
|
//} |
|
|
@@ -856,7 +856,7 @@ func CentralKitchenForSchoolDataStatisticsExport(req md.CentralKitchenForSchoolD |
|
|
|
|
|
|
|
count, err2 := centralKitchenForSchoolUserWithDayDb.CountCentralKitchenForSchoolUserWithDayByOrdNo( |
|
|
|
v.CentralKitchenForSchoolPackageOrdForReserve.OutTradeNo, enum.CentralKitchenForSchoolUserWithDayStateForCancel, |
|
|
|
req.StartDate, req.EndDate) |
|
|
|
req.StartDate, req.EndDate, req.MealKindList) |
|
|
|
if err2 != nil { |
|
|
|
logx.Error(err) |
|
|
|
println("<<<<SelfSupportForSchoolDataStatisticsExport3>>>>>Error:::", err.Error()) |
|
|
@@ -1431,11 +1431,11 @@ func CentralKitchenForSchoolDataStatisticsExport(req md.CentralKitchenForSchoolD |
|
|
|
sess.And("central_kitchen_for_school_package_ord_for_reserve.enterprise_id =?", req.EnterpriseId) |
|
|
|
} |
|
|
|
if req.StartDate != "" { |
|
|
|
sess.And("central_kitchen_for_school_package_ord_for_reserve.meal_time_start >= ?", req.StartDate) |
|
|
|
} |
|
|
|
if req.EndDate != "" { |
|
|
|
sess.And("central_kitchen_for_school_package_ord_for_reserve.meal_time_start <= ?", req.EndDate) |
|
|
|
sess.And("central_kitchen_for_school_package_ord_for_reserve.meal_time_start >= ? or central_kitchen_for_school_package_ord_for_reserve.meal_time_end <= ?", req.StartDate, req.EndDate) |
|
|
|
} |
|
|
|
//if req.EndDate != "" { |
|
|
|
// sess.And("central_kitchen_for_school_package_ord_for_reserve.meal_time_start <= ?", req.EndDate) |
|
|
|
//} |
|
|
|
if len(req.MealKindList) > 0 { |
|
|
|
sess.In("central_kitchen_for_school_package_ord_for_reserve.kind", req.MealKindList) |
|
|
|
} |
|
|
@@ -1459,7 +1459,7 @@ func CentralKitchenForSchoolDataStatisticsExport(req md.CentralKitchenForSchoolD |
|
|
|
} |
|
|
|
count, err2 := centralKitchenForSchoolUserWithDayDb.CountCentralKitchenForSchoolUserWithDayByOrdNo( |
|
|
|
v.CentralKitchenForSchoolPackageOrdForReserve.OutTradeNo, enum.CentralKitchenForSchoolUserWithDayStateForCancel, |
|
|
|
req.StartDate, req.EndDate) |
|
|
|
req.StartDate, req.EndDate, req.MealKindList) |
|
|
|
if err2 != nil { |
|
|
|
logx.Error(err) |
|
|
|
println("<<<<SelfSupportForSchoolDataStatisticsExport3>>>>>Error:::", err.Error()) |
|
|
|