소스 검색

update

tmp
DengBiao 8 달 전
부모
커밋
798263bd6d
1개의 변경된 파일5개의 추가작업 그리고 5개의 파일을 삭제
  1. +5
    -5
      app/admin/svc/svc_data_statisstics.go

+ 5
- 5
app/admin/svc/svc_data_statisstics.go 파일 보기

@@ -848,10 +848,10 @@ func CentralKitchenForSchoolDataStatisticsExport(req md.CentralKitchenForSchoolD
sess.And("central_kitchen_for_school_package_ord.enterprise_id =?", req.EnterpriseId)
}
if req.StartDate != "" {
sess.And("central_kitchen_for_school_package_ord.create_at >= ?", req.StartDate)
sess.And("central_kitchen_for_school_package_ord.pay_at >= ?", req.StartDate)
}
if req.EndDate != "" {
sess.And("central_kitchen_for_school_package_ord.create_at <= ?", req.EndDate)
sess.And("central_kitchen_for_school_package_ord.pay_at <= ?", req.EndDate)
}
if req.EnterPriseKind != 0 {
sess.And("enterprise.kind = ?", req.EnterPriseKind)
@@ -1759,7 +1759,7 @@ func CentralKitchenForSchoolDataStatisticsExport(req md.CentralKitchenForSchoolD
for _, v := range m {
var income, refund string
//统计收入
sql1 := fmt.Sprintf("SELECT sum(total_price) as total FROM central_kitchen_for_school_package_ord where state = 1 and enterprise_id = %d and create_at >= '%s' and create_at < '%s'", v.Id, req.StartDate, req.EndDate)
sql1 := fmt.Sprintf("SELECT sum(total_price) as total FROM central_kitchen_for_school_package_ord where state = 1 and enterprise_id = %d and pay_at >= '%s' and pay_at < '%s'", v.Id, req.StartDate, req.EndDate)
mapArr1, err := db.QueryNativeString(db.Db, sql1)
if err != nil {
logx.Error(err)
@@ -1818,10 +1818,10 @@ func CentralKitchenForSchoolDataStatisticsExport(req md.CentralKitchenForSchoolD
sess.And("central_kitchen_for_school_package_ord.enterprise_id =?", req.EnterpriseId)
}
if req.StartDate != "" {
sess.And("central_kitchen_for_school_package_ord.create_at >= ?", req.StartDate)
sess.And("central_kitchen_for_school_package_ord.pay_at >= ?", req.StartDate)
}
if req.EndDate != "" {
sess.And("central_kitchen_for_school_package_ord.create_at <= ?", req.EndDate)
sess.And("central_kitchen_for_school_package_ord.pay_at <= ?", req.EndDate)
}
if req.EnterPriseKind != 0 {
sess.And("enterprise.kind = ?", req.EnterPriseKind)


불러오는 중...
취소
저장