Browse Source

Merge branch '20201014_xt_api_new_branch' of http://git.shengws.com/csx/XT_New into 20201014_xt_api_new_branch

csx 4 years ago
parent
commit
3ee6ed3fe0

+ 20 - 0
.idea/misc.xml View File

@@ -3,4 +3,24 @@
3 3
   <component name="JavaScriptSettings">
4 4
     <option name="languageLevel" value="ES6" />
5 5
   </component>
6
+  <component name="SvnBranchConfigurationManager">
7
+    <option name="myConfigurationMap">
8
+      <map>
9
+        <entry key="$PROJECT_DIR$/../CDM">
10
+          <value>
11
+            <SvnBranchConfiguration>
12
+              <option name="trunkUrl" value="svn://112.74.16.180/Product/SGJ/SGJ1.0/Project/SGJ1.0/Application/MBGL" />
13
+            </SvnBranchConfiguration>
14
+          </value>
15
+        </entry>
16
+        <entry key="$PROJECT_DIR$/../SYB_Admin">
17
+          <value>
18
+            <SvnBranchConfiguration>
19
+              <option name="trunkUrl" value="svn://112.74.16.180/Product/SYB/SYB1.0/Application/SYB_Admin" />
20
+            </SvnBranchConfiguration>
21
+          </value>
22
+        </entry>
23
+      </map>
24
+    </option>
25
+  </component>
6 26
 </project>

+ 2 - 0
controllers/doctors_api_controller.go View File

@@ -54,6 +54,7 @@ func (c *DoctorsApiController) ScheduleAdvices() {
54 54
 
55 55
 	scheduals, err := service.MobileGetScheduleDoctorAdvices(orgID, date.Unix(), adviceType, patientType, adminUserInfo.AdminUser.Id)
56 56
 	hisAdvices, _ := service.GetHisDoctorAdvices(orgID, date.Unix())
57
+	config, _ := service.GetHisDoctorConfig(orgID)
57 58
 	adminUser, _ := service.GetAllAdminUsers(orgID, adminUserInfo.CurrentAppId)
58 59
 	if err != nil {
59 60
 		c.ErrorLog("获取排班信息失败:%v", err)
@@ -69,6 +70,7 @@ func (c *DoctorsApiController) ScheduleAdvices() {
69 70
 			"scheduals":  filtedScheduals,
70 71
 			"adminUser":  adminUser,
71 72
 			"hisAdvices": hisAdvices,
73
+			"config":     config,
72 74
 		})
73 75
 	}
74 76
 }

+ 2 - 0
controllers/mobile_api_controllers/doctor_advice_api_controller.go View File

@@ -42,6 +42,7 @@ func (this *DoctorAdviceAPIController) ScheduleAdvices() {
42 42
 	//获取his医嘱数据
43 43
 	fmt.Println("date.un222222", date.Unix())
44 44
 	hisAdvices, _ := service.GetHisDoctorAdvices(orgID, date.Unix())
45
+	config, _ := service.GetHisDoctorConfig(orgID)
45 46
 	adminUser, _ := service.GetAllAdminUsers(orgID, adminInfo.App.Id)
46 47
 	if err != nil {
47 48
 		this.ErrorLog("获取排班信息失败:%v", err)
@@ -57,6 +58,7 @@ func (this *DoctorAdviceAPIController) ScheduleAdvices() {
57 58
 			"scheduals":  filtedScheduals,
58 59
 			"adminUser":  adminUser,
59 60
 			"hisAdvices": hisAdvices,
61
+			"config":     config,
60 62
 		})
61 63
 	}
62 64
 }

+ 6 - 0
service/mobile_dialysis_service.go View File

@@ -1674,3 +1674,9 @@ type HisMScheduleDoctorAdviceVM struct {
1674 1674
 func (HisMScheduleDoctorAdviceVM) TableName() string {
1675 1675
 	return "xt_schedule"
1676 1676
 }
1677
+
1678
+func GetHisDoctorConfig(orgid int64) (models.XtHisConfig, error) {
1679
+	config := models.XtHisConfig{}
1680
+	err := XTReadDB().Model(&config).Where("user_org_id = ? and status =1", orgid).Find(&config).Error
1681
+	return config, err
1682
+}