|
@@ -787,7 +787,7 @@ func CentralKitchenForSchoolDataStatisticsExport(req md.CentralKitchenForSchoolD |
|
|
} |
|
|
} |
|
|
var m []*db.CentralKitchenForSchoolPackageOrdWithUserIdentity |
|
|
var m []*db.CentralKitchenForSchoolPackageOrdWithUserIdentity |
|
|
_, err := sess. |
|
|
_, err := sess. |
|
|
Join("LEFT", "user_identity", "central_kitchen_for_school_package_ord.user_identity_id = user_identity.id"). |
|
|
|
|
|
|
|
|
Join("LEFT", "user_identity", "central_kitchen_for_school_package_ord_for_reserve.user_identity_id = user_identity.id"). |
|
|
Join("LEFT", "enterprise", "enterprise.id = user_identity.enterprise_id"). |
|
|
Join("LEFT", "enterprise", "enterprise.id = user_identity.enterprise_id"). |
|
|
Join("LEFT", "user", "user.id = user_identity.uid"). |
|
|
Join("LEFT", "user", "user.id = user_identity.uid"). |
|
|
Join("LEFT", "class_with_user", "class_with_user.user_identity_id = user_identity.id"). |
|
|
Join("LEFT", "class_with_user", "class_with_user.user_identity_id = user_identity.id"). |
|
@@ -1026,7 +1026,7 @@ func CentralKitchenForSchoolDataStatisticsExport(req md.CentralKitchenForSchoolD |
|
|
} |
|
|
} |
|
|
_, err := sess. |
|
|
_, err := sess. |
|
|
Join("LEFT", "central_kitchen_for_school_package_ord", "central_kitchen_for_school_package_ord_for_reserve.out_trade_no = central_kitchen_for_school_package_ord.out_trade_no"). |
|
|
Join("LEFT", "central_kitchen_for_school_package_ord", "central_kitchen_for_school_package_ord_for_reserve.out_trade_no = central_kitchen_for_school_package_ord.out_trade_no"). |
|
|
Join("LEFT", "user_identity", "central_kitchen_for_school_package_ord.user_identity_id = user_identity.id"). |
|
|
|
|
|
|
|
|
Join("LEFT", "user_identity", "central_kitchen_for_school_package_ord_for_reserve.user_identity_id = user_identity.id"). |
|
|
Join("LEFT", "enterprise", "enterprise.id = user_identity.enterprise_id"). |
|
|
Join("LEFT", "enterprise", "enterprise.id = user_identity.enterprise_id"). |
|
|
Join("LEFT", "user", "user.id = user_identity.uid"). |
|
|
Join("LEFT", "user", "user.id = user_identity.uid"). |
|
|
Join("LEFT", "class_with_user", "class_with_user.user_identity_id = user_identity.id"). |
|
|
Join("LEFT", "class_with_user", "class_with_user.user_identity_id = user_identity.id"). |
|
@@ -1237,7 +1237,7 @@ func CentralKitchenForSchoolDataStatisticsExport(req md.CentralKitchenForSchoolD |
|
|
} |
|
|
} |
|
|
_, err := sess. |
|
|
_, err := sess. |
|
|
Join("LEFT", "central_kitchen_for_school_package_ord", "central_kitchen_for_school_package_ord_for_reserve.out_trade_no = central_kitchen_for_school_package_ord.out_trade_no"). |
|
|
Join("LEFT", "central_kitchen_for_school_package_ord", "central_kitchen_for_school_package_ord_for_reserve.out_trade_no = central_kitchen_for_school_package_ord.out_trade_no"). |
|
|
Join("LEFT", "user_identity", "central_kitchen_for_school_package_ord.user_identity_id = user_identity.id"). |
|
|
|
|
|
|
|
|
Join("LEFT", "user_identity", "central_kitchen_for_school_package_ord_for_reserve.user_identity_id = user_identity.id"). |
|
|
Join("LEFT", "enterprise", "enterprise.id = user_identity.enterprise_id"). |
|
|
Join("LEFT", "enterprise", "enterprise.id = user_identity.enterprise_id"). |
|
|
Join("LEFT", "user", "user.id = user_identity.uid"). |
|
|
Join("LEFT", "user", "user.id = user_identity.uid"). |
|
|
Join("LEFT", "class_with_user", "class_with_user.user_identity_id = user_identity.id"). |
|
|
Join("LEFT", "class_with_user", "class_with_user.user_identity_id = user_identity.id"). |
|
@@ -1274,8 +1274,8 @@ func CentralKitchenForSchoolDataStatisticsExport(req md.CentralKitchenForSchoolD |
|
|
enum.CentralKitchenForSchoolUserWithDayStateForCancel, enum.CentralKitchenForSchoolUserWithDayStateForCanceling, |
|
|
enum.CentralKitchenForSchoolUserWithDayStateForCancel, enum.CentralKitchenForSchoolUserWithDayStateForCanceling, |
|
|
req.StartDate, req.EndDate, []int{v.CentralKitchenForSchoolPackageOrdForReserve.Kind}) |
|
|
req.StartDate, req.EndDate, []int{v.CentralKitchenForSchoolPackageOrdForReserve.Kind}) |
|
|
if err2 != nil { |
|
|
if err2 != nil { |
|
|
logx.Error(err) |
|
|
|
|
|
println("<<<<SelfSupportForSchoolDataStatisticsExport3>>>>>Error:::", err.Error()) |
|
|
|
|
|
|
|
|
logx.Error(err2) |
|
|
|
|
|
println("<<<<SelfSupportForSchoolDataStatistics Export3>>>>>Error:::", err2.Error()) |
|
|
return |
|
|
return |
|
|
} |
|
|
} |
|
|
if count == 0 { |
|
|
if count == 0 { |
|
@@ -1689,7 +1689,7 @@ func CentralKitchenForSchoolDataStatisticsExport(req md.CentralKitchenForSchoolD |
|
|
} |
|
|
} |
|
|
var m []*db.CentralKitchenForSchoolPackageOrdWithUserIdentity |
|
|
var m []*db.CentralKitchenForSchoolPackageOrdWithUserIdentity |
|
|
_, err := sess. |
|
|
_, err := sess. |
|
|
Join("LEFT", "user_identity", "central_kitchen_for_school_package_ord.user_identity_id = user_identity.id"). |
|
|
|
|
|
|
|
|
Join("LEFT", "user_identity", "central_kitchen_for_school_package_ord_for_reserve.user_identity_id = user_identity.id"). |
|
|
Join("LEFT", "enterprise", "enterprise.id = user_identity.enterprise_id"). |
|
|
Join("LEFT", "enterprise", "enterprise.id = user_identity.enterprise_id"). |
|
|
Join("LEFT", "user", "user.id = user_identity.uid"). |
|
|
Join("LEFT", "user", "user.id = user_identity.uid"). |
|
|
Join("LEFT", "class_with_user", "class_with_user.user_identity_id = user_identity.id"). |
|
|
Join("LEFT", "class_with_user", "class_with_user.user_identity_id = user_identity.id"). |
|
@@ -1896,7 +1896,7 @@ func CentralKitchenForSchoolDataStatisticsExport(req md.CentralKitchenForSchoolD |
|
|
} |
|
|
} |
|
|
_, err := sess. |
|
|
_, err := sess. |
|
|
Join("LEFT", "central_kitchen_for_school_package_ord", "central_kitchen_for_school_package_ord_for_reserve.out_trade_no = central_kitchen_for_school_package_ord.out_trade_no"). |
|
|
Join("LEFT", "central_kitchen_for_school_package_ord", "central_kitchen_for_school_package_ord_for_reserve.out_trade_no = central_kitchen_for_school_package_ord.out_trade_no"). |
|
|
Join("LEFT", "user_identity", "central_kitchen_for_school_package_ord.user_identity_id = user_identity.id"). |
|
|
|
|
|
|
|
|
Join("LEFT", "user_identity", "central_kitchen_for_school_package_ord_for_reserve.user_identity_id = user_identity.id"). |
|
|
Join("LEFT", "enterprise", "enterprise.id = user_identity.enterprise_id"). |
|
|
Join("LEFT", "enterprise", "enterprise.id = user_identity.enterprise_id"). |
|
|
FindAndCount(&m) |
|
|
FindAndCount(&m) |
|
|
if err != nil { |
|
|
if err != nil { |
|
@@ -2145,7 +2145,7 @@ func CentralKitchenForSchoolDataStatisticsContrast(req md.CentralKitchenForSchoo |
|
|
|
|
|
|
|
|
_, err := sess. |
|
|
_, err := sess. |
|
|
Join("LEFT", "central_kitchen_for_school_package_ord", "central_kitchen_for_school_package_ord_for_reserve.out_trade_no = central_kitchen_for_school_package_ord.out_trade_no"). |
|
|
Join("LEFT", "central_kitchen_for_school_package_ord", "central_kitchen_for_school_package_ord_for_reserve.out_trade_no = central_kitchen_for_school_package_ord.out_trade_no"). |
|
|
Join("LEFT", "user_identity", "central_kitchen_for_school_package_ord.user_identity_id = user_identity.id"). |
|
|
|
|
|
|
|
|
Join("LEFT", "user_identity", "central_kitchen_for_school_package_ord_for_reserve.user_identity_id = user_identity.id"). |
|
|
Join("LEFT", "enterprise", "enterprise.id = user_identity.enterprise_id"). |
|
|
Join("LEFT", "enterprise", "enterprise.id = user_identity.enterprise_id"). |
|
|
Join("LEFT", "user", "user.id = user_identity.uid"). |
|
|
Join("LEFT", "user", "user.id = user_identity.uid"). |
|
|
Join("LEFT", "class_with_user", "class_with_user.user_identity_id = user_identity.id"). |
|
|
Join("LEFT", "class_with_user", "class_with_user.user_identity_id = user_identity.id"). |
|
@@ -2176,7 +2176,7 @@ func CentralKitchenForSchoolDataStatisticsContrast(req md.CentralKitchenForSchoo |
|
|
} |
|
|
} |
|
|
_, err1 := sess1. |
|
|
_, err1 := sess1. |
|
|
Join("LEFT", "central_kitchen_for_school_package_ord", "central_kitchen_for_school_package_ord_for_reserve.out_trade_no = central_kitchen_for_school_package_ord.out_trade_no"). |
|
|
Join("LEFT", "central_kitchen_for_school_package_ord", "central_kitchen_for_school_package_ord_for_reserve.out_trade_no = central_kitchen_for_school_package_ord.out_trade_no"). |
|
|
Join("LEFT", "user_identity", "central_kitchen_for_school_package_ord.user_identity_id = user_identity.id"). |
|
|
|
|
|
|
|
|
Join("LEFT", "user_identity", "central_kitchen_for_school_package_ord_for_reserve.user_identity_id = user_identity.id"). |
|
|
Join("LEFT", "enterprise", "enterprise.id = user_identity.enterprise_id"). |
|
|
Join("LEFT", "enterprise", "enterprise.id = user_identity.enterprise_id"). |
|
|
Join("LEFT", "user", "user.id = user_identity.uid"). |
|
|
Join("LEFT", "user", "user.id = user_identity.uid"). |
|
|
Join("LEFT", "class_with_user", "class_with_user.user_identity_id = user_identity.id"). |
|
|
Join("LEFT", "class_with_user", "class_with_user.user_identity_id = user_identity.id"). |
|
|