Browse Source

体积小

XMLWAN 3 years ago
parent
commit
7a998a72ea
2 changed files with 5 additions and 1 deletions
  1. 4 0
      models/xcx_user_models.go
  2. 1 1
      service/xcx_mobile_api_service.go

+ 4 - 0
models/xcx_user_models.go View File

@@ -200,3 +200,7 @@ type XcXDialysisOrder struct {
200 200
 	DifficultPunctureNurse int64  `gorm:"column:difficult_puncture_nurse" json:"difficult_puncture_nurse" form:"difficult_puncture_nurse"`
201 201
 	NewFistulaNurse        string `gorm:"column:new_fistula_nurse" json:"new_fistula_nurse" form:"new_fistula_nurse"`
202 202
 }
203
+
204
+func (XcXDialysisOrder) TableName() string {
205
+	return "xt_dialysis_order"
206
+}

+ 1 - 1
service/xcx_mobile_api_service.go View File

@@ -234,7 +234,7 @@ func GetNextPatientSchedule(patient_id int64, dialysis_date int64) (models.Blood
234 234
 	if dialysis_date > 0 {
235 235
 		db = db.Where("x.schedule_date >?", dialysis_date)
236 236
 	}
237
-	err := db.Select("x.patient_id,x.schedule_date,x.mode_id,z.name,n.number").Joins("left join xt_device_zone as z on z.id = x.partition_id").Joins("left join xt_device_number as n on n.id = x.bed_id").Order("x.schedule_date asc").Limit(1).Scan(&schedule).Error
237
+	err := db.Select("x.patient_id,x.schedule_type,x.schedule_date,x.mode_id,z.name,n.number").Joins("left join xt_device_zone as z on z.id = x.partition_id").Joins("left join xt_device_number as n on n.id = x.bed_id").Order("x.schedule_date asc").Limit(1).Scan(&schedule).Error
238 238
 	return schedule, err
239 239
 }
240 240