|
@@ -18,7 +18,7 @@ func GetBatchDrugHisPrescription(ids []string, record_time int64, user_org_id in
|
18
|
18
|
return
|
19
|
19
|
}
|
20
|
20
|
|
21
|
|
-func GetBatchProjectHisPrescription(ids []string, record_time int64, user_org_id int64) (patients models.PrintPatient, err error) {
|
|
21
|
+func GetBatchProjectHisPrescription(ids []string, record_time int64, user_org_id int64) (patients []*models.PrintPatient, err error) {
|
22
|
22
|
readDb.Model(&models.PrintPatient{}).Preload("HisPrintPatient", "status = 1 AND record_date = ?", record_time).
|
23
|
23
|
Preload("HisPrintPrescription", func(db *gorm.DB) *gorm.DB {
|
24
|
24
|
return db.Where("status = 1 AND user_org_id = ? AND record_date = ? AND type <> 1", user_org_id, record_time).
|
|
@@ -32,7 +32,7 @@ func GetBatchProjectHisPrescription(ids []string, record_time int64, user_org_id
|
32
|
32
|
|
33
|
33
|
}
|
34
|
34
|
|
35
|
|
-func GetBatchInspectionProjectHisPrescription(ids []string, record_time int64, user_org_id int64) (patients models.PrintPatient, err error) {
|
|
35
|
+func GetBatchInspectionProjectHisPrescription(ids []string, record_time int64, user_org_id int64) (patients []*models.PrintPatient, err error) {
|
36
|
36
|
readDb.Model(&models.PrintPatient{}).Preload("HisPrintPatient", "status = 1 AND record_date = ?", record_time).
|
37
|
37
|
Preload("HisPrintPrescription", func(db *gorm.DB) *gorm.DB {
|
38
|
38
|
return db.Where("status = 1 AND user_org_id = ? AND record_date = ? AND type <> 1", user_org_id, record_time).
|