XMLWAN 5 gadus atpakaļ
vecāks
revīzija
9abbffb9a3

+ 7 - 7
controllers/mobile_api_controllers/dialysis_api_controller.go Parādīt failu

@@ -6258,11 +6258,11 @@ func (this *DialysisAPIController) GetBloodDialysisPatient() {
6258 6258
 	patient, err := service.GetBloodDialysisPatient(7957)
6259 6259
 	fmt.Print(patient)
6260 6260
 	fmt.Print("报错------------------", err)
6261
-	//if err != nil {
6262
-	//  this.ServeFailJsonSend(enums.ErrorCodeDataException, "添加设备失败")
6263
-	//  return
6264
-	//}
6265
-	//this.ServeSuccessJSON(map[string]interface{}{
6266
-	//  "patient": patient,
6267
-	//})
6261
+	if err != nil {
6262
+		this.ServeFailJsonSend(enums.ErrorCodeDataException, "添加设备失败")
6263
+		return
6264
+	}
6265
+	this.ServeSuccessJSON(map[string]interface{}{
6266
+		"patient": patient,
6267
+	})
6268 6268
 }

+ 0 - 33
controllers/patientManage_api_controller.go Parādīt failu

@@ -1,33 +0,0 @@
1
-package controllers
2
-
3
-import (
4
-	"XT_New/controllers/mobile_api_controllers"
5
-	"XT_New/enums"
6
-	"XT_New/service"
7
-	"fmt"
8
-	"github.com/astaxie/beego"
9
-)
10
-
11
-type PatientAPIController struct {
12
-	//controllers.BaseAPIController
13
-	mobile_api_controllers.MobileBaseAPIAuthController
14
-}
15
-
16
-func PatientRouters() {
17
-	beego.Router("/api/patient/getbloodDialysisPatient", &PatientAPIController{}, "Get:GetBloodDialysisPatient")
18
-}
19
-
20
-func (this *PatientAPIController) GetBloodDialysisPatient() {
21
-	//adminUser := this.GetAdminUserInfo()
22
-	//orgId := adminUser.CurrentOrgId
23
-	//fmt.Print("orgId")
24
-	patient, err := service.GetBloodDialysisPatient(7957)
25
-	fmt.Print("报错------------------", err)
26
-	if err != nil {
27
-		this.ServeFailJsonSend(enums.ErrorCodeDataException, "添加设备失败")
28
-		return
29
-	}
30
-	this.ServeSuccessJSON(map[string]interface{}{
31
-		"patient": patient,
32
-	})
33
-}

+ 2 - 2
main.go Parādīt failu

@@ -1,8 +1,8 @@
1 1
 package main
2 2
 
3 3
 import (
4
-	_ "XT/routers"
5
-	"XT/service"
4
+	_ "XT_New/routers"
5
+	"XT_New/service"
6 6
 
7 7
 	"github.com/astaxie/beego"
8 8
 )