|
@@ -13,7 +13,7 @@ import (
|
13
|
13
|
)
|
14
|
14
|
|
15
|
15
|
// GetPatientList 返回患者的列表
|
16
|
|
-func GetPatientList(orgID int64, keywords string, page, limit, schedulType, bindingState, lapseto, source, startTime, endTime, contagion, reimbursementWay, isscheduling, isprescription int64, isStartTime, isEndTime bool, patientSoureType int64) (patients []*models.Patients, total int64, err error) {
|
|
16
|
+func GetPatientList(orgID int64, keywords string, page, limit, schedulType, bindingState, lapseto, source, startTime, endTime, contagion, reimbursementWay, isscheduling, isprescription int64, isStartTime, isEndTime bool, patientSoureType int64, nurse int64) (patients []*models.Patients, total int64, err error) {
|
17
|
17
|
|
18
|
18
|
db := readDb.Table("xt_patients as p").Where("p.status=1")
|
19
|
19
|
if orgID > 0 {
|
|
@@ -69,6 +69,9 @@ func GetPatientList(orgID int64, keywords string, page, limit, schedulType, bind
|
69
|
69
|
if patientSoureType > 0 {
|
70
|
70
|
db = db.Where("p.patient_source =?", patientSoureType)
|
71
|
71
|
}
|
|
72
|
+ if nurse > 0 {
|
|
73
|
+ db = db.Where("p.head_nurse_id = ?", nurse)
|
|
74
|
+ }
|
72
|
75
|
|
73
|
76
|
offset := (page - 1) * limit
|
74
|
77
|
if lapseto == 2 || lapseto == 3 {
|