瀏覽代碼

update

tmp
DengBiao 8 月之前
父節點
當前提交
b61b1f5111
共有 2 個文件被更改,包括 25 次插入3 次删除
  1. +1
    -1
      app/admin/hdl/hdl_demo.go
  2. +24
    -2
      app/admin/svc/enterprise_manage/svc_central_kitchen_for_school.go

+ 1
- 1
app/admin/hdl/hdl_demo.go 查看文件

@@ -83,7 +83,7 @@ func DemoV1(c *gin.Context) {
for _, v := range m {
if recordsId[v.RecordsId] {
repeatIds = append(repeatIds, v.Id)
centralKitchenForSchoolUserRefundDayDb.CentralKitchenForSchoolUserRefundDayDelete(v.Id)
//centralKitchenForSchoolUserRefundDayDb.CentralKitchenForSchoolUserRefundDayDelete(v.Id)
}
recordsId[v.RecordsId] = true
}


+ 24
- 2
app/admin/svc/enterprise_manage/svc_central_kitchen_for_school.go 查看文件

@@ -664,7 +664,17 @@ func CentralKitchenForSchoolOrdList(req md.CentralKitchenForSchoolOrdListReq) (r
sess.And("user_identity.name like ?", "%"+req.Name+"%")
}
if req.Phone != "" {
sess.And("user.phone like ?", "%"+req.Phone+"%")
userDb := db.UserDb{}
userDb.Set()
user, err1 := userDb.GetUserByPhone(req.Phone)
if err1 != nil {
return nil, 0, err1
}
if user != nil {
sess.And("central_kitchen_for_school_package_ord.uid = ?", user.Id)
} else {
sess.And("user.phone like ?", "%"+req.Phone+"%")
}
}

if req.EnterPriseKind != 0 {
@@ -1000,7 +1010,19 @@ func CentralKitchenForSchoolReserveList(req md.CentralKitchenForSchoolReserveLis
sess.And("user_identity.name like ?", "%"+req.Name+"%")
}
if req.Phone != "" {
sess.And("user.phone like ?", "%"+req.Phone+"%")
if req.Phone != "" {
userDb := db.UserDb{}
userDb.Set()
user, err1 := userDb.GetUserByPhone(req.Phone)
if err1 != nil {
return nil, 0, err1
}
if user != nil {
sess.And("central_kitchen_for_school_package_ord.uid = ?", user.Id)
} else {
sess.And("user.phone like ?", "%"+req.Phone+"%")
}
}
}

if len(classWithUserIdentityIdsOne) > 0 {


Loading…
取消
儲存