|
@@ -72,7 +72,6 @@ func HisManagerApiRegistRouters() {
|
72
|
72
|
beego.Router("/api/incomestatistics/get", &HisApiController{}, "get:GetIncomeStatisticsData")
|
73
|
73
|
|
74
|
74
|
beego.Router("/api/postprojectinformation", &HisApiController{}, "post:PostProjectInformation")
|
75
|
|
- //beego.Router("/api/editprojectinformation", &HisApiController{}, "post:EditProjectInformation")
|
76
|
75
|
beego.Router("/api/hisprescriptiontemplate/create", &HisApiController{}, "post:CreateHisPrescriptionTemplate")
|
77
|
76
|
beego.Router("/api/privateexpenses/get", &HisApiController{}, "get:GetPrivateExpensesInfo")
|
78
|
77
|
beego.Router("/api/changemedtype/post", &HisApiController{}, "post:ChangeMedType")
|
|
@@ -101,14 +100,10 @@ func HisManagerApiRegistRouters() {
|
101
|
100
|
beego.Router("/api/batch/settleaccount", &HisApiController{}, "get:GetBatchSettleAccounts")
|
102
|
101
|
|
103
|
102
|
beego.Router("/api/monthhispatient", &HisApiController{}, "get:GetMonthHisPatient")
|
104
|
|
-
|
105
|
103
|
beego.Router("/api/changeorderdesc", &HisApiController{}, "get:ChangeOrderDesc")
|
106
|
|
-
|
107
|
104
|
beego.Router("/api/getfapiaonumber", &HisApiController{}, "get:GetFaPiaoNumber")
|
108
|
|
-
|
109
|
105
|
beego.Router("/api/associationprescription", &HisApiController{}, "get:AssociationHisPrescription")
|
110
|
106
|
beego.Router("/api/checkhispatient", &HisApiController{}, "get:CheckHisPatient")
|
111
|
|
-
|
112
|
107
|
beego.Router("/api/hisorder/listtwo", &HisApiController{}, "get:GetHisOrderListTwo")
|
113
|
108
|
|
114
|
109
|
}
|
|
@@ -10284,6 +10279,46 @@ func (this *HisApiController) GetLastOrNextHisPrescription() {
|
10284
|
10279
|
record_time := theAdviceRecordTime.Unix()
|
10285
|
10280
|
adminUserInfo := this.GetAdminUserInfo()
|
10286
|
10281
|
prescriptions, err := service.GetHisPrescriptionByType(change_type, record_time, adminUserInfo.CurrentOrgId, patient_id, p_type)
|
|
10282
|
+
|
|
10283
|
+ if adminUserInfo.CurrentOrgId == 10265 {
|
|
10284
|
+ _, config := service.FindHisStockPriceRecordByOrgId(adminUserInfo.CurrentOrgId)
|
|
10285
|
+ if config.ID > 0 && config.IsOpen == 1 {
|
|
10286
|
+ for _, subitems := range prescriptions {
|
|
10287
|
+ for _, item := range subitems.VMHisPrescription {
|
|
10288
|
+ for _, subItem := range item.HisDoctorAdviceInfo {
|
|
10289
|
+ drug, _ := service.GetDrugByGoodId(subItem.DrugId)
|
|
10290
|
+ info, _ := service.GetWarehoseInfoByDrugId(subItem.DrugId, adminUserInfo.CurrentOrgId)
|
|
10291
|
+ if info.RetailPrice > 0 {
|
|
10292
|
+ if subItem.PrescribingNumberUnit == drug.MaxUnit && drug.MaxUnit != drug.MinUnit {
|
|
10293
|
+ subItem.Drug.RetailPrice = drug.RetailPrice
|
|
10294
|
+ }
|
|
10295
|
+ if subItem.PrescribingNumberUnit == drug.MinUnit {
|
|
10296
|
+ subItem.Drug.MinPrice = info.RetailPrice
|
|
10297
|
+ subItem.Drug.RetailPrice = info.RetailPrice
|
|
10298
|
+ }
|
|
10299
|
+
|
|
10300
|
+ }
|
|
10301
|
+ }
|
|
10302
|
+ }
|
|
10303
|
+ }
|
|
10304
|
+ }
|
|
10305
|
+
|
|
10306
|
+ if config.ID > 0 && config.IsOpen == 1 {
|
|
10307
|
+ for _, subitems := range prescriptions {
|
|
10308
|
+ for _, item := range subitems.VMHisPrescription {
|
|
10309
|
+ for _, subItem := range item.HisPrescriptionProject {
|
|
10310
|
+ if subItem.Type == 3 {
|
|
10311
|
+ info, _ := service.GetGoodWarehoseInfoByGoodId(subItem.ProjectId, adminUserInfo.CurrentOrgId)
|
|
10312
|
+ if info.Price > 0 {
|
|
10313
|
+ subItem.GoodInfo.PackingPrice = info.Price
|
|
10314
|
+ }
|
|
10315
|
+ }
|
|
10316
|
+ }
|
|
10317
|
+ }
|
|
10318
|
+ }
|
|
10319
|
+ }
|
|
10320
|
+ }
|
|
10321
|
+
|
10287
|
10322
|
if err == nil {
|
10288
|
10323
|
if len(prescriptions) == 0 {
|
10289
|
10324
|
this.ServeFailJSONWithSGJErrorCode(enums.ErrorCodeDoctorAdviceEmpty)
|
|
@@ -10340,7 +10375,6 @@ func (this *HisApiController) GetCallHisPrescription() {
|
10340
|
10375
|
}
|
10341
|
10376
|
}
|
10342
|
10377
|
}
|
10343
|
|
-
|
10344
|
10378
|
if config.ID > 0 && config.IsOpen == 1 {
|
10345
|
10379
|
for _, subitems := range prescriptions {
|
10346
|
10380
|
for _, item := range subitems.VMHisPrescription {
|