瀏覽代碼

提交代码

陈少旭 1 年之前
父節點
當前提交
5180bae95c
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      service/statistis_qc_service.go

+ 1 - 1
service/statistis_qc_service.go 查看文件

@@ -643,7 +643,7 @@ func GetPrescriptionByAnticoagulant(page int64, limit int64, orgid int64, antico
643 643
 
644 644
 func GetPrescriptionByDialyzer(page int64, limit int64, orgid int64, dialyzer string, start_time int64, end_time int64) (solution []*models.DialysisPrescription, total int64, err error) {
645 645
 
646
-	db := XTReadDB().Model(&models.DialysisPrescription{}).Where("status = 1")
646
+	db := XTReadDB().Model(&models.DialysisPrescription{}).Preload("QCPatients", "status = 1 and user_org_id = ?", orgid).Where("status = 1")
647 647
 	if len(dialyzer) > 0 {
648 648
 		db = db.Where("dialysis_dialyszers = ?", dialyzer)
649 649
 	}