Browse Source

2024/6/17

28169 1 day ago
parent
commit
fb312e62dd
2 changed files with 8 additions and 8 deletions
  1. BIN
      XT_New.exe
  2. 8 8
      controllers/inspection_api_controller.go

BIN
XT_New.exe View File


+ 8 - 8
controllers/inspection_api_controller.go View File

1151
 
1151
 
1152
 	org_id := c.GetAdminUserInfo().CurrentOrgId
1152
 	org_id := c.GetAdminUserInfo().CurrentOrgId
1153
 
1153
 
1154
-	patient, _ := service.GetPatientDetailTwo(patient_id)
1155
-	inspection, _ := service.GetInspectionGroup(patient.BloodId, org_id)
1154
+	//patient, _ := service.GetPatientDetailTwo(patient_id)
1155
+	inspection, _ := service.GetInspectionGroup(patient_id, org_id)
1156
 
1156
 
1157
 	if len(inspection) > 0 {
1157
 	if len(inspection) > 0 {
1158
 		for _, item := range inspection {
1158
 		for _, item := range inspection {
1159
-			lastInspection, _ := service.GetLastInspectionProject(item.PatientId, org_id, item.ProjectId)
1159
+			lastInspection, _ := service.GetLastInspectionProject(patient_id, org_id, item.ProjectId)
1160
 			item.InspectDate = lastInspection.InspectDate
1160
 			item.InspectDate = lastInspection.InspectDate
1161
-			inspecList, _ := service.GetInspectionByProjectId(item.PatientId, org_id, item.ProjectId)
1161
+			inspecList, _ := service.GetInspectionByProjectId(patient_id, org_id, item.ProjectId)
1162
 			item.Count = int64(len(inspecList))
1162
 			item.Count = int64(len(inspecList))
1163
 		}
1163
 		}
1164
 	}
1164
 	}
1176
 
1176
 
1177
 	org_id := c.GetAdminUserInfo().CurrentOrgId
1177
 	org_id := c.GetAdminUserInfo().CurrentOrgId
1178
 
1178
 
1179
-	patient, _ := service.GetPatientDetailTwo(patient_id)
1179
+	//patient, _ := service.GetPatientDetailTwo(patient_id)
1180
 
1180
 
1181
 	referenceList, _ := service.GetInSpctionRerefce(project_id, org_id)
1181
 	referenceList, _ := service.GetInSpctionRerefce(project_id, org_id)
1182
 
1182
 
1183
-	inspection, _ := service.GetInspectionGroupByRecordDate(patient.BloodId, project_id, org_id)
1183
+	inspection, _ := service.GetInspectionGroupByRecordDate(patient_id, project_id, org_id)
1184
 
1184
 
1185
 	if len(inspection) > 0 {
1185
 	if len(inspection) > 0 {
1186
 		for _, item := range inspection {
1186
 		for _, item := range inspection {
1187
-			inspeclist, _ := service.GetInspectionByProject(patient.BloodId, project_id, org_id, item.InspectDate)
1187
+			inspeclist, _ := service.GetInspectionByProject(patient_id, project_id, org_id, item.InspectDate)
1188
 			for _, it := range inspeclist {
1188
 			for _, it := range inspeclist {
1189
 				item.Child = append(item.Child, it)
1189
 				item.Child = append(item.Child, it)
1190
 			}
1190
 			}
1191
 		}
1191
 		}
1192
 	}
1192
 	}
1193
 
1193
 
1194
-	patients, _ := service.GetPatientByIDOne(org_id, patient.BloodId)
1194
+	patients, _ := service.GetPatientByIDOne(org_id, patient_id)
1195
 
1195
 
1196
 	c.ServeSuccessJSON(map[string]interface{}{
1196
 	c.ServeSuccessJSON(map[string]interface{}{
1197
 		"inspection":    inspection,
1197
 		"inspection":    inspection,