Преглед на файлове

Merge branch '20201109_pc_vue_new_branch' of http://git.shengws.com/csx/Vue_New into 20201109_pc_vue_new_branch

XMLWAN преди 4 години
родител
ревизия
c5ee0366ff
променени са 100 файла, в които са добавени 16749 реда и са изтрити 4380 реда
  1. 2 2
      config/index.js
  2. 0 1
      config/prod.env.js
  3. 3 2
      src/api/advice.js
  4. 31 3
      src/api/config.js
  5. 1 0
      src/api/dialysis.js
  6. 40 0
      src/api/his/his.js
  7. 82 0
      src/api/his/his_config.js
  8. 9 9
      src/api/project/project.js
  9. 44 0
      src/api/schedule.js
  10. BIN
      src/assets/home/111.jpg
  11. BIN
      src/assets/home/222.jpg
  12. 2 0
      src/lang/zh.js
  13. 12 0
      src/router/modules/dialysis.js
  14. 18 0
      src/router/modules/outpatientDoctorStation.js
  15. 34 0
      src/store/modules/globalConfig.js
  16. 95 7
      src/xt_pages/data/basicConfig.vue
  17. 284 229
      src/xt_pages/data/components/addInspection.vue
  18. 307 257
      src/xt_pages/data/components/editInspection.vue
  19. 47 19
      src/xt_pages/data/druguseTemplate.vue
  20. 3 3
      src/xt_pages/data/prescription.vue
  21. 5 3
      src/xt_pages/data/printTemplate.vue
  22. 165 0
      src/xt_pages/data/printTemplate/schedulePrint.vue
  23. 1 0
      src/xt_pages/dialysis/PatientBox.vue
  24. 9 1
      src/xt_pages/dialysis/batch_print/batch_print_order.vue
  25. 49 14
      src/xt_pages/dialysis/batch_print/batch_print_order_six.vue
  26. 1516 0
      src/xt_pages/dialysis/batch_print/batch_print_order_thirtyNine.vue
  27. 12 0
      src/xt_pages/dialysis/bloodPresssWatch.vue
  28. 1 1
      src/xt_pages/dialysis/details/BasicInfor.vue
  29. 61 13
      src/xt_pages/dialysis/details/DialysisPrescription.vue
  30. 3 0
      src/xt_pages/dialysis/details/NavIgation.vue
  31. 3 2
      src/xt_pages/dialysis/details/assessmentAfter.vue
  32. 6 0
      src/xt_pages/dialysis/details/assessmentBefore.vue
  33. 7 3
      src/xt_pages/dialysis/details/dialog/AssessmentAfterDislysis.vue
  34. 2 2
      src/xt_pages/dialysis/details/dialog/DoctorAdviceDialog.vue
  35. 3 1
      src/xt_pages/dialysis/details/dialog/acceptsTreatmentDialog.vue
  36. 9 1
      src/xt_pages/dialysis/details/dialog/assessmentBeforeDislysisDialog.vue
  37. 10 1
      src/xt_pages/dialysis/details/dialog/computer_dialog.vue
  38. 206 45
      src/xt_pages/dialysis/details/dialog/dialysisPrescriptionDialog.vue
  39. 9 6
      src/xt_pages/dialysis/details/dialog/doubleCheckDialog.vue
  40. 14 2
      src/xt_pages/dialysis/details/dialog/finish_dialog.vue
  41. 19 3
      src/xt_pages/dialysis/details/dialog/monitor_dialog.vue
  42. 1 0
      src/xt_pages/dialysis/details/dialog/treatmentSummaryDialog.vue
  43. 4 4
      src/xt_pages/dialysis/details/dialysisMonitoring.vue
  44. 10 0
      src/xt_pages/dialysis/details/index.vue
  45. 3 2
      src/xt_pages/dialysis/dialysisDoctorAdvice.vue
  46. 24 0
      src/xt_pages/dialysis/dialysisPrintOrder.vue
  47. 10 10
      src/xt_pages/dialysis/schedualPatient.vue
  48. 2580 0
      src/xt_pages/dialysis/template/DialysisPrintOrderForty.vue
  49. 32 10
      src/xt_pages/dialysis/template/DialysisPrintOrderSix.vue
  50. 2 2
      src/xt_pages/dialysis/template/DialysisPrintOrderTen.vue
  51. 1 0
      src/xt_pages/dialysis/template/DialysisPrintOrderThirtyFour.vue
  52. 4 4
      src/xt_pages/dialysis/template/DialysisPrintOrderThirtyNine.vue
  53. 10 2
      src/xt_pages/dialysis/template/dialysisPrintOrderTwelve.vue
  54. 8 1
      src/xt_pages/dialysis/template/dialysisPrintOrderTwo.vue
  55. 14 9
      src/xt_pages/hospitalStation/allListPrint.vue
  56. 1 1
      src/xt_pages/hospitalStation/components/ChargePrescriptionTable.vue
  57. 52 33
      src/xt_pages/hospitalStation/components/callPrescription.vue
  58. 188 47
      src/xt_pages/hospitalStation/components/deskPrescription.vue
  59. 20 1
      src/xt_pages/hospitalStation/components/inquiriesDetail.vue
  60. 1 1
      src/xt_pages/hospitalStation/components/newPrescriptionTable.vue
  61. 43 24
      src/xt_pages/hospitalStation/components/nextOrLastPrescription.vue
  62. 13 12
      src/xt_pages/hospitalStation/components/prescriptionTable.vue
  63. 125 17
      src/xt_pages/hospitalStation/doctorDesk.vue
  64. 26 16
      src/xt_pages/hospitalStation/listPrint.vue
  65. 7 1
      src/xt_pages/hospitalStation/newStatementPrint.vue
  66. 54 13
      src/xt_pages/hospitalStation/outpatientChargesManagement.vue
  67. 7 2
      src/xt_pages/hospitalStation/summary.vue
  68. 294 284
      src/xt_pages/hospitalStation/summaryDetail.vue
  69. 7 2
      src/xt_pages/outpatientCharges/allListPrint.vue
  70. 1 1
      src/xt_pages/outpatientCharges/components/chargeMonthPrescriptionTable.vue
  71. 2 4
      src/xt_pages/outpatientCharges/components/prescriptionTable.vue
  72. 324 326
      src/xt_pages/outpatientCharges/components/registerDialog.vue
  73. 3 3
      src/xt_pages/outpatientCharges/costComparison.vue
  74. 185 57
      src/xt_pages/outpatientCharges/incomeStatistics.vue
  75. 1 1
      src/xt_pages/outpatientCharges/invoiceTemplate/printTwo.vue
  76. 10 5
      src/xt_pages/outpatientCharges/listPrint.vue
  77. 10 10
      src/xt_pages/outpatientCharges/listTemplate/printTwo.vue
  78. 16 33
      src/xt_pages/outpatientCharges/newStatementPrint.vue
  79. 1047 661
      src/xt_pages/outpatientCharges/outpatientChargesManagement.vue
  80. 140 133
      src/xt_pages/outpatientCharges/statementPrint.vue
  81. 12 9
      src/xt_pages/outpatientCharges/summary.vue
  82. 13 3
      src/xt_pages/outpatientCharges/summaryDetail.vue
  83. 26 4
      src/xt_pages/outpatientDoctorStation/components/callPrescription.vue
  84. 1302 1101
      src/xt_pages/outpatientDoctorStation/components/deskPrescription.vue
  85. 990 0
      src/xt_pages/outpatientDoctorStation/components/dialysisIndex.vue
  86. 15 3
      src/xt_pages/outpatientDoctorStation/components/inquiriesDetail.vue
  87. 1 1
      src/xt_pages/outpatientDoctorStation/components/newPrescriptionTable.vue
  88. 22 7
      src/xt_pages/outpatientDoctorStation/components/nextOrLastPrescription.vue
  89. 113 30
      src/xt_pages/outpatientDoctorStation/components/prescriptionTable.vue
  90. 468 0
      src/xt_pages/outpatientDoctorStation/components/prescriptionTemplateTable.vue
  91. 250 67
      src/xt_pages/outpatientDoctorStation/components/saveTemplate.vue
  92. 2287 767
      src/xt_pages/outpatientDoctorStation/doctorDesk.vue
  93. 7 7
      src/xt_pages/outpatientDoctorStation/pastInquiries.vue
  94. 488 0
      src/xt_pages/outpatientDoctorStation/prescriptionTemplate.vue
  95. 1997 0
      src/xt_pages/outpatientDoctorStation/prescriptionTemplatedetail.vue
  96. 8 3
      src/xt_pages/outpatientDoctorStation/print.vue
  97. 330 0
      src/xt_pages/outpatientDoctorStation/template/printFour.vue
  98. 14 14
      src/xt_pages/outpatientDoctorStation/template/printOne.vue
  99. 2 2
      src/xt_pages/outpatientDoctorStation/treatTemplate/printOne.vue
  100. 0 0
      src/xt_pages/outpatientRegistration/index.vue

+ 2 - 2
config/index.js Целия файл

@@ -29,8 +29,8 @@ module.exports = {
29 29
 
30 30
      // host: 'xt.test.sgjyun.com',
31 31
     //  host: 'xt.kuyicloud.com',
32
-    host: 'xt.test.sgjyun.com',
33
-    // host: 'localhost',
32
+    // host: 'xt.test.sgjyun.com',
33
+    host: 'localhost',
34 34
     port: 9528, // can be overwritten by process.env.PORT, if port is in use, a free one will be determined
35 35
     autoOpenBrowser: true,
36 36
     errorOverlay: true,

+ 0 - 1
config/prod.env.js Целия файл

@@ -9,4 +9,3 @@ module.exports = {
9 9
   MIRCO_MALL_HOST: '"http://mall.kuyicloud.com"',
10 10
   CDM_HOST: '"http://cdm.kuyicloud.com"',
11 11
 }
12
-

+ 3 - 2
src/api/advice.js Целия файл

@@ -212,13 +212,14 @@ export function DeleteAdviceTemplate(id, template_id, parent_id) {
212 212
   });
213 213
 }
214 214
 
215
-export function postAdviceTemplate(params, name, advice_type) {
215
+export function postAdviceTemplate(params, name,sort, advice_type) {
216 216
   return request({
217 217
     url:
218 218
       "/api/advicetemplate/create?template_name=" +
219 219
       name +
220 220
       "&advice_type=" +
221
-      advice_type,
221
+      advice_type
222
+      +"&sort="+sort,
222 223
     method: "post",
223 224
     data: params
224 225
   });

+ 31 - 3
src/api/config.js Целия файл

@@ -148,7 +148,7 @@ export function postMonitorIsOpen(params){
148 148
 
149 149
 
150 150
 export function getMonitorConfig(params){
151
-  
151
+
152 152
   return request({
153 153
     url:"/api/monitor/getmonitorconfig",
154 154
     method:"Get",
@@ -158,7 +158,7 @@ export function getMonitorConfig(params){
158 158
 
159 159
 
160 160
 export function addOrderConfig(params){
161
-  
161
+
162 162
   return request({
163 163
     url:"/api/order/addorderconfig",
164 164
     method:"Get",
@@ -168,7 +168,7 @@ export function addOrderConfig(params){
168 168
 }
169 169
 
170 170
 export function getOrderConfig(params){
171
-  
171
+
172 172
   return request({
173 173
     url:"/api/order/getorderconfig",
174 174
     method:"get",
@@ -176,3 +176,31 @@ export function getOrderConfig(params){
176 176
   })
177 177
 }
178 178
 
179
+export function changeFuncPrint(params){
180
+
181
+  return request({
182
+    url:"/api/order/changefuncprint",
183
+    method:"get",
184
+    params:params
185
+  })
186
+}
187
+
188
+export function getDataPrintList(params){
189
+
190
+  return request({
191
+    url:"/api/order/getdataprint",
192
+    method:"get",
193
+    params:params
194
+  })
195
+}
196
+
197
+
198
+
199
+export function postXtHisProjectIsOpen(params){
200
+
201
+  return request({
202
+    url:"/api/xtconfigproject/isopen",
203
+    method:"post",
204
+    params:params
205
+  })
206
+}

+ 1 - 0
src/api/dialysis.js Целия файл

@@ -157,6 +157,7 @@ export function postPrescription(params) {
157 157
 }
158 158
 
159 159
 export function postSoulution(params) {
160
+  console.log("params",params)
160 161
   return request({
161 162
     url: '/api/dialysis/soulution',
162 163
     method: 'Post',

+ 40 - 0
src/api/his/his.js Целия файл

@@ -429,7 +429,47 @@ export function getHisHospitalPrescriptionList (params) {
429 429
 
430 430
 
431 431
 
432
+export function getIncomeStatisticsDataList(params) {
433
+  return request({
434
+    url: "/api/incomestatistics/get",
435
+    method: "get",
436
+    params:params,
437
+  });
438
+}
439
+
440
+
441
+
442
+
443
+
444
+
445
+export function saveTeam(data, params) {
446
+  return request({
447
+    url: "/api/his/saveprojectteam",
448
+    method: "post",
449
+    data:data,
450
+    params:params,
451
+  });
452
+}
453
+
454
+
455
+
432 456
 
457
+export function editTeam(params,data) {
458
+  return request({
459
+    url: "/api/his/updateprojectteam",
460
+    method: "post",
461
+    data:data,
462
+    params:params,
463
+  });
464
+}
433 465
 
466
+export function createdTemplate(params,data) {
467
+  return request({
468
+    url: "/api/hisprescriptiontemplate/create",
469
+    method: "post",
470
+    data:data,
471
+    params:params,
472
+  });
473
+}
434 474
 
435 475
 

+ 82 - 0
src/api/his/his_config.js Целия файл

@@ -0,0 +1,82 @@
1
+import request from "@/utils/request";
2
+
3
+
4
+
5
+export function getPatientList(params) {
6
+  return request({
7
+    url: "/api/his/patient/list",
8
+    method: "get",
9
+    params:params
10
+  });
11
+}
12
+
13
+
14
+export function getPrescriptionTemplateList(params) {
15
+  return request({
16
+    url: "/api/his/prescriptiontemplate/list",
17
+    method: "get",
18
+    params:params
19
+  });
20
+}
21
+
22
+
23
+export function getPrescriptionTemplateInfo(params) {
24
+  return request({
25
+    url: "/api/his/prescriptiontemplate/info",
26
+    method: "get",
27
+    params:params
28
+  });
29
+}
30
+
31
+
32
+
33
+export function createdTemplate(params,data) {
34
+  return request({
35
+    url: "/api/his/prescriptiontemplate/create",
36
+    method: "post",
37
+    data:data,
38
+    params:params,
39
+  });
40
+}
41
+
42
+
43
+
44
+
45
+export function delHisPrescriptionTemplate(params) {
46
+  return request({
47
+    url: "/api/his/prescriptiontemplate/delete",
48
+    method: "post",
49
+    params:params,
50
+  });
51
+}
52
+
53
+
54
+
55
+export function delHisPrescriptionInfoTemplate(params) {
56
+  return request({
57
+    url: "/api/his/prescriptioninfotemplate/delete",
58
+    method: "post",
59
+    params:params,
60
+  });
61
+}
62
+
63
+
64
+
65
+
66
+export function delHisPrescriptionAdviceTemplate(params) {
67
+  return request({
68
+    url: "/api/his/advicetemplate/delete",
69
+    method: "post",
70
+    params:params,
71
+  });
72
+}
73
+
74
+
75
+
76
+export function delHisPrescriptionProjectTemplate(params) {
77
+  return request({
78
+    url: "/api/his/projecttemplate/delete",
79
+    method: "post",
80
+    params:params,
81
+  });
82
+}

+ 9 - 9
src/api/project/project.js Целия файл

@@ -1,5 +1,5 @@
1 1
 import request from "@/utils/request";
2
-import url from "postcss-url";
2
+
3 3
 
4 4
 export function saveProject(params){
5 5
 
@@ -47,14 +47,14 @@ export function deleteHisProject(id,params){
47 47
   })
48 48
 }
49 49
 
50
-export function saveProjectTeam(params){
51
-
52
-  return request({
53
-    url:"/api/his/saveprojectteam",
54
-    methods:"Get",
55
-    params:params
56
-  })
57
-}
50
+// export function saveProjectTeam(params,data){
51
+//   return request({
52
+//     url:"/api/his/saveprojectteam",
53
+//     methods:"DELETE",
54
+//     data:data,
55
+//     params:params,
56
+//   })
57
+// }
58 58
 
59 59
 export function getProjectTeamList(params){
60 60
 

+ 44 - 0
src/api/schedule.js Целия файл

@@ -8,6 +8,15 @@ export function getWeekPanels(t,patitionId) {
8 8
   })
9 9
 }
10 10
 
11
+
12
+export function getWeekPanelsOne(t,patitionId){
13
+  
14
+  return request({
15
+    url: '/api/schedule/weekpanelone?data=' + t+"&patitionid="+patitionId,
16
+    method: 'get'
17
+  })
18
+}
19
+
11 20
 export function getSchedules(params) {
12 21
   return request({
13 22
     url: '/api/schedule/schedules',
@@ -16,6 +25,14 @@ export function getSchedules(params) {
16 25
   })
17 26
 }
18 27
 
28
+export function getSchedulesOne(params){
29
+  return request({
30
+    url: '/api/schedule/schedulesone',
31
+    method: 'get',
32
+    params:params,
33
+  })
34
+}
35
+
19 36
 export function getSchedulePatients(params) {
20 37
   return request({
21 38
     url: '/api/schedule/patients',
@@ -194,4 +211,31 @@ export function getAllZoneList(params){
194 211
     method:"get",
195 212
     params:params
196 213
   })
214
+}
215
+
216
+export function getPatientSheduleCount(params){
217
+   
218
+  return request({
219
+    url:"/api/schedule/getpatientschedulecount",
220
+    method:"get",
221
+    params:params
222
+  })
223
+}
224
+
225
+export function postScheduleTemplate(params){
226
+   
227
+  return request({
228
+    url:"/api/schedule/postscheduletemplate",
229
+    method:"get",
230
+    params:params
231
+  })
232
+}
233
+
234
+export function getScheduleTemplate(params){
235
+  
236
+  return request({
237
+    url:"/api/schedule/getscheduletemplate",
238
+    method:"get",
239
+    params:params,
240
+  })
197 241
 }

BIN
src/assets/home/111.jpg Целия файл


BIN
src/assets/home/222.jpg Целия файл


+ 2 - 0
src/lang/zh.js Целия файл

@@ -247,6 +247,8 @@ export default {
247 247
     hospitalStation:"住院工作站",
248 248
     pastInquiries:"既往查询",
249 249
 
250
+    prescriptionTemplate:"处方模版",
251
+
250 252
   },
251 253
   navbar: {
252 254
     logOut: '退出登录',

+ 12 - 0
src/router/modules/dialysis.js Целия файл

@@ -399,6 +399,18 @@ export default {
399 399
         noCache: true
400 400
       }
401 401
     },
402
+    {
403
+      path: '/dialysis/print/batch/thirtyNine',
404
+      component: () =>
405
+        import('@/xt_pages/dialysis/batch_print/batch_print_order_thirtyNine'),
406
+      hidden: true,
407
+      is_menu: false,
408
+      name: 'batch_print_order_thirtyNine',
409
+      meta: {
410
+        title: '批量打印',
411
+        noCache: true
412
+      }
413
+    },
402 414
     {
403 415
       path: '/dialysis/print/batch/thirtyThree_one',
404 416
       component: () =>

+ 18 - 0
src/router/modules/outpatientDoctorStation.js Целия файл

@@ -24,6 +24,24 @@ export default {
24 24
         name: 'outpatientDoctorStationPastInquiries',
25 25
         meta: { title: 'outpatientDoctorStationPastInquiries', noCache: true }
26 26
     },
27
+    {
28
+      path: '/outpatientDoctorStation/prescriptionTemplate',
29
+      component: () => import('@/xt_pages/outpatientDoctorStation/prescriptionTemplate'),
30
+      name: 'prescriptionTemplate',
31
+      meta: { title: 'prescriptionTemplate', noCache: true }
32
+    },
33
+
34
+    {
35
+      path: '/outpatientDoctorStation/prescriptionTemplatedetail',
36
+      component: () => import('@/xt_pages/outpatientDoctorStation/prescriptionTemplatedetail'),
37
+      name: 'prescriptionTemplatedetail',
38
+      hidden: true,
39
+      is_menu: false,
40
+      meta: { title: 'prescriptionTemplatedetail', noCache: true }
41
+    },
42
+
43
+
44
+
27 45
     {
28 46
         path: '/outpatientDoctorStation/templateManagement',
29 47
         component: () => import('@/xt_pages/outpatientDoctorStation/templateManagement'),

+ 34 - 0
src/store/modules/globalConfig.js Целия файл

@@ -524,6 +524,36 @@ const global_config = {
524 524
         sodium: 1,
525 525
         calcium: 1,
526 526
         bicarbonate: 1
527
+      },
528
+      22: {
529
+        id: 22,
530
+        name: '血浆胆红素吸附+HDF',
531
+        dialysis_duration: 1,
532
+        replacement_way: 1,
533
+        hemodialysis_machine: 2,
534
+        blood_filter: 1,
535
+        perfusion_apparatus: 2,
536
+        blood_flow_volume: 1,
537
+        dialysate_flow: 1,
538
+        kalium: 1,
539
+        sodium: 1,
540
+        calcium: 1,
541
+        bicarbonate: 1
542
+      },
543
+      23: {
544
+        id: 23,
545
+        name: '血浆胆红素吸附',
546
+        dialysis_duration: 1,
547
+        replacement_way: 1,
548
+        hemodialysis_machine: 2,
549
+        blood_filter: 1,
550
+        perfusion_apparatus: 2,
551
+        blood_flow_volume: 1,
552
+        dialysate_flow: 1,
553
+        kalium: 1,
554
+        sodium: 1,
555
+        calcium: 1,
556
+        bicarbonate: 1
527 557
       }
528 558
     },
529 559
     anticoagulants_confit: { // 抗凝剂
@@ -1875,6 +1905,10 @@ const global_config = {
1875 1905
         id: 36,
1876 1906
         name: '轴'
1877 1907
       },
1908
+      {
1909
+        id: 37,
1910
+        name: '辆'
1911
+      },
1878 1912
     ],
1879 1913
     body_fluid: [{
1880 1914
       id: 1,

+ 95 - 7
src/xt_pages/data/basicConfig.vue Целия файл

@@ -15,7 +15,7 @@
15 15
             <p style="font-size:18px;font-weight:bold">门诊打印</p>
16 16
             <p style="font-size:14px;margin-top:5px;color:#333;">开启直接打印后,门诊病历、处方、治疗单、处置单、收费清单等打印时跳过打印预览,直接连接打印机打印。</p>
17 17
             <p style="margin-top:20px;">直接打印:
18
-                <el-switch v-model="value"></el-switch>
18
+                <el-switch v-model="is_open_print" @change="changeFuncPrint"></el-switch>
19 19
             </p>
20 20
         </div>
21 21
         <div class="configBox">
@@ -26,6 +26,15 @@
26 26
           </p>
27 27
         </div>
28 28
 
29
+        <div class="configBox">
30
+            <p style="font-size:18px;font-weight:bold">处方项目同步到临时医嘱</p>
31
+            <p style="font-size:14px;margin-top:5px;color:#333;">开启门诊处方的项目同步后,护士则在血透的临时医嘱中可以看到相关的耗材/检验检查数据</p>
32
+            <p style="margin-top:20px;">门诊处方项目同步到透析医嘱:
33
+                <el-switch v-model="is_open_xt_his_project" @change="changeFuncProject"></el-switch>
34
+            </p>
35
+        </div>
36
+
37
+
29 38
         <!-- <div class="configBox">
30 39
           <p style="font-size:18px;font-weight:bold">血压数据自动获取</p>
31 40
           <p style="font-size:14px;margin-top:5px;color:#333;">在联机的状态下,开启透析监测-血压数据自动获取功能后,则不需要手动输入,数据会自动上传到监测中</p>
@@ -71,14 +80,14 @@
71 80
                 <!--<el-switch v-model="value"></el-switch>-->
72 81
             <!--</p>-->
73 82
         <!--</div>-->
74
-        
83
+
75 84
     </div>
76 85
   </div>
77 86
 </template>
78 87
 
79 88
 <script>
80 89
 import BreadCrumb from "@/xt_pages/components/bread-crumb";
81
-import { getAllIsOpenInit,postXtHisIsOpen,postMonitorIsOpen} from '@/api/config'
90
+import { getAllIsOpenInit,postXtHisIsOpen,postMonitorIsOpen,changeFuncPrint,getDataPrintList,postXtHisProjectIsOpen} from '@/api/config'
82 91
 
83 92
 export default {
84 93
   name: "printTemplate",
@@ -94,6 +103,8 @@ export default {
94 103
       is_open_xt_his:false,
95 104
       is_open_monitor:false,
96 105
       is_open_order:false,
106
+      is_open_print:false,
107
+      is_open_xt_his_project: false,
97 108
     };
98 109
   },
99 110
   methods: {
@@ -103,10 +114,18 @@ export default {
103 114
           if (response.data.state === 1) {
104 115
             if(response.data.data.is_open_xt_his == 1) {
105 116
               this.is_open_xt_his = true
117
+
106 118
             }else{
107 119
               this.is_open_xt_his = false
108 120
             }
109 121
 
122
+            if(response.data.data.is_open_xt_his_project == 1) {
123
+              this.is_open_xt_his_project = true
124
+
125
+            }else{
126
+              this.is_open_xt_his_project = false
127
+            }
128
+
110 129
           } else {
111 130
             this.$message.error(response.data.msg)
112 131
           }
@@ -145,6 +164,38 @@ export default {
145 164
         )
146 165
       }
147 166
     },
167
+    changeFuncProject(val){
168
+      if(this.is_open_xt_his_project){
169
+        let params={
170
+          is_open:this.is_open_xt_his_project
171
+        }
172
+        postXtHisProjectIsOpen(params).then(
173
+          response => {
174
+            if (response.data.state === 1) {
175
+              this.is_open_xt_his_project = response.data.data.is_open
176
+
177
+            } else {
178
+              this.$message.error(response.data.msg)
179
+            }
180
+          }
181
+        )
182
+      }else{
183
+        let params={
184
+          is_open:this.is_open_xt_his_project
185
+        }
186
+        postXtHisProjectIsOpen(params).then(
187
+          response => {
188
+            if (response.data.state === 1) {
189
+              this.is_open_xt_his_project = response.data.data.is_open
190
+
191
+            } else {
192
+              this.$message.error(response.data.msg)
193
+            }
194
+          }
195
+        )
196
+      }
197
+    },
198
+
148 199
 
149 200
     changeFuncTwo(){
150 201
       console.log("3333333",this.is_open_monitor)
@@ -192,7 +243,7 @@ export default {
192 243
        }
193 244
       let params = {
194 245
          is_open:is_open,
195
-       } 
246
+       }
196 247
       addOrderConfig(params).then(response=>{
197 248
          if(response.data.state == 1){
198 249
            var config = response.data.data.config
@@ -213,14 +264,51 @@ export default {
213 264
            }
214 265
         }
215 266
       })
267
+    },
268
+
269
+    changeFuncPrint(val){
270
+      console.log("val22222",val)
271
+      var is_open  = 0
272
+      if(val == true){
273
+         is_open = 1
274
+      }
275
+      if(val == false){
276
+        is_open = 0
277
+      }
278
+      var params = {
279
+        is_open:is_open,
280
+      }
281
+
282
+      changeFuncPrint(params).then(response=>{
283
+         if(response.data.state == 1){
284
+           var dataPrint =  response.data.data.dataPrint
285
+           this.$message.success("保存成功")
286
+           this.getDataPrintList()
287
+         }
288
+      })
289
+    },
290
+
291
+    getDataPrintList(){
292
+      getDataPrintList().then(response=>{
293
+         if(response.data.state ==1){
294
+           var dataPrint = response.data.data.dataPrint
295
+           console.log("列表数据",dataPrint)
296
+           if(dataPrint.is_open == 1){
297
+              this.is_open_print = true
298
+           }
299
+           if(dataPrint.is_open == 0){
300
+              this.is_open_print = false
301
+           }
302
+         }
303
+      })
216 304
     }
217 305
 
218 306
   },
219 307
   created() {
220 308
     this.getInitIsOpenConfig()
221
-    this.getMonitorConfig()
222
-    this.getOrderConfig()
223
-
309
+    // this.getMonitorConfig()
310
+    // this.getOrderConfig()
311
+    this.getDataPrintList()
224 312
   }
225 313
 };
226 314
 </script>

+ 284 - 229
src/xt_pages/data/components/addInspection.vue Целия файл

@@ -1,12 +1,13 @@
1 1
 <template>
2 2
     <el-dialog
3
-        :title="formTitle"
4
-        width="900px"
5
-        :visible.sync="visible"
6
-        :before-close="_close"
3
+            :title="formTitle"
4
+            width="900px"
5
+            :visible.sync="visible"
6
+            :before-close="_close"
7 7
     >
8 8
         <div>
9
-            <el-form :model="form" :rules="rules" ref="form" label-width="100px" style="display: flex;flex-wrap: wrap;justify-content: space-between;">
9
+            <el-form :model="form" :rules="rules" ref="form" label-width="100px"
10
+                     style="display: flex;flex-wrap: wrap;justify-content: space-between;">
10 11
                 <el-form-item label="组套名称 : " prop="project_team" style="width:100%">
11 12
                     <el-input v-model="form.project_team" placeholder="" maxlength="30"></el-input>
12 13
                 </el-form-item>
@@ -19,61 +20,66 @@
19 20
                 <el-form-item label="五笔 : " prop="wubi" style="width:50%">
20 21
                     <el-input v-model="form.wubi" placeholder="" maxlength="30"></el-input>
21 22
                 </el-form-item>
22
-                
23
+
23 24
                 <el-form-item label="试管颜色 : " prop="tube_color" style="width:50%">
24 25
                     <el-select v-model="form.tube_color" style="width:160px;" placeholder="请选择">
25 26
                         <el-option
26
-                         v-for="(item,index) in getDictionaryDataConfig('system','tube_color')"
27
-                         :key="index"
28
-                         :label="item.name"
29
-                         :value="item.id">
27
+                                v-for="(item,index) in getDictionaryDataConfig('system','tube_color')"
28
+                                :key="index"
29
+                                :label="item.name"
30
+                                :value="item.id">
30 31
                         </el-option>
31
-                  </el-select>
32
+                    </el-select>
32 33
                 </el-form-item>
33 34
                 <el-form-item label="组套类型 : " prop="team_type" style="width:50%">
34 35
                     <el-select v-model="form.team_type" style="width:100%;" placeholder="请选择">
35 36
                         <el-option
36
-                        v-for="item in options"
37
-                        :key="item.value"
38
-                        :label="item.label"
39
-                        :value="item.value">
37
+                                v-for="item in options"
38
+                                :key="item.value"
39
+                                :label="item.label"
40
+                                :value="item.value">
40 41
                         </el-option>
41 42
                     </el-select>
42 43
                 </el-form-item>
43 44
                 <el-form-item label="备注 : " prop="name" style="width:100%;">
44 45
                     <el-input type="textarea" :rows="2" placeholder="请输入内容" v-model="form.remark"></el-input>
45 46
                 </el-form-item>
46
-  
47
-                 <el-form-item label="组套明细" style="width:50%;">
48
-                    <el-select v-model="form.project_detail" placeholder="请选择">
49
-                        <el-option
50
-                        v-for="item in projectList"
51
-                        :key="item.id"
52
-                        :label="item.project_name"
53
-                        :value="item.id">
54
-                        </el-option>
55
-                    </el-select>
56 47
 
57
-                    </el-form-item>
58
-                 <el-form-item label="数量" style="width:50%;"> 
59
-                      <div style="display:flex;"> 
60
-                         <el-input v-model="form.number" style="margin-right:10px;"></el-input>
61
-                         <el-button type="primary" @click="addProjectList">添加</el-button>
62
-                      </div>
63
-                  </el-form-item>
48
+                <el-form-item label="组套明细" style="width:50%;">
49
+                    <el-autocomplete
50
+                            class="inline-input"
51
+                            v-model="form.project_detail"
52
+                            :fetch-suggestions="querySearch"
53
+                            placeholder="请输入内容"
54
+                            @select="handleSelect"
55
+                    ></el-autocomplete>
56
+
57
+                </el-form-item>
58
+
59
+
60
+                <el-form-item label="数量" style="width:50%;">
61
+                    <div style="display:flex;">
62
+                        <el-input v-model="form.number" style="margin-right:10px;"></el-input>
63
+                        <el-button type="primary" @click="addProjectList">添加</el-button>
64
+                    </div>
65
+                </el-form-item>
64 66
             </el-form>
65 67
             <el-form>
66
-                <el-table :data="tableData" border  style="100%" :row-style="{ color: '#303133' }" :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}" highlight-current-row ref="tab">
68
+                <el-table :data="tableData" border style="100%" :row-style="{ color: '#303133' }"
69
+                          :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}"
70
+                          highlight-current-row ref="tab">
67 71
                     <el-table-column align="center" prop="name" label="分类" width="120">
68
-                        <template slot-scope="scope">{{getId(scope.row.statistical_classification)}}</template>
72
+                        <template slot-scope="scope">
73
+                            <div >{{scope.row.type == 2?getId(scope.row.statistical_classification):'耗材'}}</div>
74
+                        </template>
69 75
                     </el-table-column>
70 76
                     <el-table-column align="center" prop="name" label="组套明细" width="120">
71 77
                         <template slot-scope="scope">{{scope.row.project_name}}</template>
72 78
                     </el-table-column>
73
-                     <el-table-column align="center" prop="name" label="数量" width="120">
79
+                    <el-table-column align="center" prop="name" label="数量" width="120">
74 80
                         <template slot-scope="scope">{{scope.row.number}}</template>
75 81
                     </el-table-column>
76
-                     <el-table-column align="center" prop="name" label="单位" width="120">
82
+                    <el-table-column align="center" prop="name" label="单位" width="120">
77 83
                         <template slot-scope="scope">{{scope.row.unit}}</template>
78 84
                     </el-table-column>
79 85
                     <el-table-column align="center" prop="name" label="单价" width="120">
@@ -81,18 +87,18 @@
81 87
                     </el-table-column>
82 88
                     <el-table-column align="center" prop="name" label="操作">
83 89
                         <template slot-scope="scope">
84
-                          <el-tooltip
85
-                            class="item"
86
-                            effect="dark"
87
-                            content="删除"
88
-                            placement="top"
90
+                            <el-tooltip
91
+                                    class="item"
92
+                                    effect="dark"
93
+                                    content="删除"
94
+                                    placement="top"
89 95
                             >
90
-                            <el-button
91
-                                type="danger"
92
-                                icon="el-icon-delete"
93
-                                size="small"
94
-                                @click="DeleteProject(scope.row.id,scope.$index)"
95
-                            ></el-button>
96
+                                <el-button
97
+                                        type="danger"
98
+                                        icon="el-icon-delete"
99
+                                        size="small"
100
+                                        @click="DeleteProject(scope.row.id,scope.$index)"
101
+                                ></el-button>
96 102
                             </el-tooltip>
97 103
                         </template>
98 104
                     </el-table-column>
@@ -103,202 +109,251 @@
103 109
 
104 110
         <div slot="footer" class="dialog-footer">
105 111
             <el-button @click="hide">取 消</el-button>
106
-            <el-button type="primary"  @click="submitAction('form')">保 存</el-button>
112
+            <el-button type="primary" @click="submitAction('form')">保 存</el-button>
107 113
         </div>
108
-  </el-dialog>
114
+    </el-dialog>
109 115
 </template>
110 116
 
111 117
 <script>
112
-import { getDictionaryDataConfig,getDataConfig } from "@/utils/data";
113
-import { saveProjectTeam,getAllProjectList,addProjectList,DeleteProject,getProjectDetail } from "@/api/project/project"
114
-export default {
115
-    data(){
116
-        return{
117
-            visible:false,
118
-            formTitle:'',
119
-            activeName:'first',
120
-            form:{
121
-              project_team:'',
122
-              price:"",
123
-              pinyin:"",
124
-              wubi:"",
125
-              tube_color:"",
126
-              team_type:"",
127
-              remark:"",
128
-              project_detail:"",
129
-              number:""
130
-            },
131
-            options: [
132
-            {value: 1,label: '是'},
133
-            {value: 2,label: '否'}
134
-            ],
135
-            value: '',
136
-            radio:'1',
137
-            rules: {
138
-              project_team: [{ required: true, message: '请填写组套名称', trigger: 'blur'  }],
139
-            //   pinyin: [{ required: true, message: '请填写拼音' , trigger: 'blur' }],
140
-            //   wubi: [{ required: true, message: '请填写五笔' , trigger: 'blur' }],
141
-              price: [{ required: true, message: '请填写价格', trigger: 'change' }],
142
-              team_type: [{ required:true,message:'请填写组套类型',trigger:'change' }]
143
-           },
144
-           tableData:[],
145
-           projectList:[],
146
-           tabList:[],
147
-           itemList:[]
148
-        }
149
-    },
150
-    methods:{
151
-        getDataConfig(module, filed_name){
152
-            return getDataConfig(module, filed_name)
153
-        },
154
-            getDictionaryDataConfig(module, filed_name) {
155
-            return getDictionaryDataConfig(module, filed_name)
156
-        },
157
-        _close: function(done) {
158
-            done()
159
-        },
160
-        clear: function() {
161
-            this.form.id = 0;
162
-            this.form.name = "";
163
-            this.form.intro = "";
164
-        },
165
-        show(id) {
166
-            this.visible = true
167
-            this.formTitle = '新增' 
168
-         },
169
-        hide() {
170
-         this.visible = false
118
+  import { getDataConfig, getDictionaryDataConfig } from '@/utils/data'
119
+  import {
120
+    addProjectList,
121
+    DeleteProject,
122
+    getAllProjectList,
123
+    getProjectDetail,
124
+    saveProjectTeam
125
+  } from '@/api/project/project'
126
+
127
+  import {
128
+    saveTeam
129
+  } from '@/api/his/his'
130
+
131
+
132
+  export default {
133
+    data() {
134
+      return {
135
+        project_name:"",
136
+        visible: false,
137
+        formTitle: '',
138
+        activeName: 'first',
139
+        form: {
140
+          project_team: '',
141
+          price: '',
142
+          pinyin: '',
143
+          wubi: '',
144
+          tube_color: '',
145
+          team_type: '',
146
+          remark: '',
147
+          project_detail: '',
148
+          number: '1'
171 149
         },
172
-        submitAction(formName){
173
-           this.$refs[formName].validate((valid)=>{
174
-                var arr = []
175
-                var listId = []
176
-                for(let i=0;i<this.tableData.length;i++){
177
-                    arr.push(this.tableData[i].id)
178
-                    
179
-                }
180
-                console.log("arr",arr)
181
-                console.log("table",this.tableData)
182
-                var ids = arr.join(",")
183
-                var listIds = this.itemList.join(",")
184
-                var params = {
185
-                 project_team:this.form.project_team,
186
-                 price:this.form.price,
187
-                 pinyin:this.form.pinyin,
188
-                 wubi:this.form.wubi,
189
-                 tube_color:this.form.tube_color,
190
-                 team_type:this.form.team_type,
191
-                 remark:this.form.remark,
192
-                 ids:ids,
193
-                 item_id:listIds
194
-               }
195
-              
196
-              saveProjectTeam(params).then(response=>{
197
-                 if(response.data.state == 1){
198
-                   var projectTeam = response.data.data.projectTeam
199
-                   console.log("projectTeam",projectTeam)
200
-                   this.$message.success("保存成功")  
201
-                   this.visible = false
202
-                   this.form.project_team = "",
203
-                   this.form.price = "",
204
-                   this.form.pinyin = "",
205
-                   this.form.wubi = "",
206
-                   this.form.tube_color = "",
207
-                   this.form.team_type = "",
208
-                   this.form.remark = ""
209
-                   this.tableData = []
210
-                   this.form.number = ""
211
-                   this.$parent.getlist()
212
-                 }else{
213
-                    this.$message.error("项目组套名称已存在!")
214
-                 }
215
-              }) 
216
-           })
150
+        options: [
151
+          { value: 1, label: '是' },
152
+          { value: 2, label: '否' }
153
+        ],
154
+        value: '',
155
+        radio: '1',
156
+        rules: {
157
+          project_team: [{ required: true, message: '请填写组套名称', trigger: 'blur' }],
158
+          //   pinyin: [{ required: true, message: '请填写拼音' , trigger: 'blur' }],
159
+          //   wubi: [{ required: true, message: '请填写五笔' , trigger: 'blur' }],
160
+          price: [{ required: true, message: '请填写价格', trigger: 'change' }],
161
+          team_type: [{ required: true, message: '请填写组套类型', trigger: 'change' }]
217 162
         },
218
-        getlist(){
219
-          getAllProjectList().then(response=>{
220
-             if(response.data.state == 1){
221
-               var projectList = response.data.data.projectList
222
-               console.log('projectlist33333',projectList)
223
-              
224
-               this.projectList = projectList
225
-            //    var hisprojectlist = response.data.data.hisprojectlist
226
-            //    console.log("hisprojectlist",hisprojectlist)
227
-            //    this.tableData = hisprojectlist
228
-             }
229
-          })   
230
-        },
231
-       
232
-        getId(id){
233
-          var name = ""
234
-          var statistics_category =  getDictionaryDataConfig('system','statistics_category') 
235
-          console.log("2235",statistics_category)
236
-          for(let i=0;i<statistics_category.length;i++){
237
-             if(id == statistics_category[i].id){
238
-                 name = statistics_category[i].name
239
-             }
163
+        tableData: [],
164
+        projectList: [],
165
+        tabList: [],
166
+        itemList: []
167
+      }
168
+    },
169
+    methods: {
170
+      querySearch(queryString, cb) {
171
+        var restaurants = this.projectList;
172
+        var results = queryString ? restaurants.filter(this.createFilter(queryString)) : restaurants;
173
+        // 调用 callback 返回建议列表的数据
174
+        cb(results);
175
+
176
+      }, createFilter(queryString) {
177
+        return (restaurant) => {
178
+          return (restaurant.project_name.toLowerCase().indexOf(queryString.toLowerCase()) === 0);
179
+        };
180
+      },
181
+      handleSelect(val){
182
+        this.project_name = val.project_name
183
+        this.form.project_detail = val.id
184
+      },
185
+      getDataConfig(module, filed_name) {
186
+        return getDataConfig(module, filed_name)
187
+      },
188
+      getDictionaryDataConfig(module, filed_name) {
189
+        return getDictionaryDataConfig(module, filed_name)
190
+      },
191
+      _close: function(done) {
192
+        done()
193
+      },
194
+      clear: function() {
195
+        this.form.id = 0
196
+        this.form.name = ''
197
+        this.form.intro = ''
198
+      },
199
+      show(id) {
200
+        this.visible = true
201
+        this.formTitle = '新增'
202
+      },
203
+      hide() {
204
+        this.visible = false
205
+      },
206
+      submitAction(formName) {
207
+        this.$refs[formName].validate((valid) => {
208
+          var params = {
209
+            project_team: this.form.project_team,
210
+            price: this.form.price,
211
+            pinyin: this.form.pinyin,
212
+            wubi: this.form.wubi,
213
+            tube_color: this.form.tube_color,
214
+            team_type: this.form.team_type,
215
+            remark: this.form.remark,
240 216
           }
241
-          return name
242
-        },
243
-        chagneInspection(id){
244
-           getProjectDetail(id).then(response=>{
245
-              if(response.data.state == 1){
246
-               var projectdetail = response.data.data.projecDetail
247
-               console.log("projectdetail",projectdetail)
248
-               this.tableData.push(projectdetail)
249
-              }
250
-           })
251
-        },
252
-       addProjectList(){
253
-          
254
-          for(let i=0;i<this.projectList.length;i++){
255
-            if(this.form.project_detail == this.projectList[i].id){
256
-                this.projectList[i].number = this.form.number
257
-                this.tableData.push(this.projectList[i])
258
-            }
259
-         }
260
-         console.log("33333",this.tableData)
261
-      
262
-         
263
-            const params = {
264
-              id:this.form.project_detail,
265
-              number:parseInt(this.form.number)
266
-            }
267
-           console.log("params",params)
268
-          addProjectList(params).then(response=>{
269
-             if(response.data.state == 1){
270
-               var projectList = response.data.data.projectList
271
-               var item = response.data.data.item
272
-               console.log("item22222",item)
273
-               this.itemList.push(item.id)
274
-               this.$message.success("保存成功")
275
-               this.form.project_detail = ""
276
-               this.form.number = ""
277
-            //    this.getlist()
278
-             }
279
-          })
280
-        },
281
-        DeleteProject(id,index){
282
-           this.$confirm("确认删除此项目吗?", "删除", {
283
-            confirmButtonText: "确 定",
284
-            cancelButtonText: "取 消",
285
-            type: "warning"
286
-         }).then(() => {
287
-          DeleteProject(id).then(response => {
217
+          let data = {
218
+            "info":this.tableData
219
+          }
220
+          saveTeam(data,params).then(response => {
288 221
             if (response.data.state == 1) {
289
-               this.tableData.splice(index, 1);
222
+              var projectTeam = response.data.data.projectTeam
223
+              console.log('projectTeam', projectTeam)
224
+              this.$message.success('保存成功')
225
+              this.visible = false
226
+              this.form.project_team = '',
227
+                this.form.price = '',
228
+                this.form.pinyin = '',
229
+                this.form.wubi = '',
230
+                this.form.tube_color = '',
231
+                this.form.team_type = '',
232
+                this.form.remark = ''
233
+              this.tableData = []
234
+              this.form.number = ''
235
+              this.$parent.getlist()
290 236
             } else {
291
-             
237
+              this.$message.error('项目组套名称已存在!')
238
+            }
239
+          })
240
+        })
241
+      },
242
+      getlist() {
243
+        let params = {
244
+          keyword: ""
245
+
246
+        }
247
+        getAllProjectList(params).then(response => {
248
+          if (response.data.state == 1) {
249
+            var projectList = response.data.data.projectList
250
+            var goodInfos = response.data.data.good_info
251
+
252
+            for (let i = 0; i < projectList.length; i++) {
253
+              let obj = {
254
+                id: projectList[i].id,
255
+                statistical_classification: projectList[i].statistical_classification,
256
+                number: '1',
257
+                project_name: projectList[i].project_name,
258
+                unit: projectList[i].unit,
259
+                price: projectList[i].price,
260
+                type: 2
261
+              }
262
+              this.projectList.push(obj)
263
+
264
+            }
265
+
266
+            for (let i = 0; i < goodInfos.length; i++) {
267
+              let obj = {
268
+                id: goodInfos[i].id,
269
+                statistical_classification: goodInfos[i].statistical_classification,
270
+                number: '1',
271
+                project_name: goodInfos[i].good_name,
272
+                unit: goodInfos[i].good_unit,
273
+                price: goodInfos[i].retail_price,
274
+                type: 3
275
+              }
276
+              this.projectList.push(obj)
292 277
             }
293
-          });
278
+
279
+            console.log(this.projectList)
280
+
281
+            // this.projectList = projectList
282
+            //    var hisprojectlist = response.data.data.hisprojectlist
283
+            //    console.log("hisprojectlist",hisprojectlist)
284
+            //    this.tableData = hisprojectlist
285
+          }
294 286
         })
295
-        .catch(() => {});
287
+      },
288
+
289
+      getId(id) {
290
+        var name = ''
291
+        var statistics_category = getDictionaryDataConfig('system', 'statistics_category')
292
+        console.log('2235', statistics_category)
293
+        for (let i = 0; i < statistics_category.length; i++) {
294
+          if (id == statistics_category[i].id) {
295
+            name = statistics_category[i].name
296
+          }
296 297
         }
298
+        return name
299
+      },
300
+      chagneInspection(id) {
301
+        getProjectDetail(id).then(response => {
302
+          if (response.data.state == 1) {
303
+            var projectdetail = response.data.data.projecDetail
304
+            console.log('projectdetail', projectdetail)
305
+            this.tableData.push(projectdetail)
306
+          }
307
+        })
308
+      },
309
+      addProjectList() {
310
+        console.log(this.projectList)
311
+        for (let i = 0; i < this.projectList.length; i++) {
312
+          if (this.form.project_detail == this.projectList[i].id) {
313
+            this.projectList[i].number = this.form.number
314
+            this.projectList[i].number =  this.projectList[i].number.toString()
315
+            this.tableData.push(this.projectList[i])
316
+            this.form.project_detail = ""
317
+            this.form.number = ""
318
+          }
319
+        }
320
+        // console.log("33333",this.tableData)
321
+        //
322
+        //
323
+        //    const params = {
324
+        //      id:this.form.project_detail,
325
+        //      number:parseInt(this.form.number)
326
+        //    }
327
+        //   console.log("params",params)
328
+        //  addProjectList(params).then(response=>{
329
+        //     if(response.data.state == 1){
330
+        //       var projectList = response.data.data.projectList
331
+        //       var item = response.data.data.item
332
+        //       console.log("item22222",item)
333
+        //       this.itemList.push(item.id)
334
+        //       this.$message.success("保存成功")
335
+        //       this.form.project_detail = ""
336
+        //       this.form.number = ""
337
+        //    //    this.getlist()
338
+        //     }
339
+        //  })
340
+      },
341
+      DeleteProject(id, index) {
342
+        this.$confirm('确认删除此项目吗?', '删除', {
343
+          confirmButtonText: '确 定',
344
+          cancelButtonText: '取 消',
345
+          type: 'warning'
346
+        }).then(() => {
347
+            this.tableData.splice(index, 1)
348
+        })
349
+          .catch(() => {
350
+          })
351
+      }
297 352
     },
298
-    created(){
353
+    created() {
299 354
       //获取所以的项目
300 355
       this.getlist()
301
-   
356
+
302 357
     }
303
-}
358
+  }
304 359
 </script>

+ 307 - 257
src/xt_pages/data/components/editInspection.vue Целия файл

@@ -1,12 +1,13 @@
1 1
 <template>
2 2
     <el-dialog
3
-        :title="formTitle"
4
-        width="900px"
5
-        :visible.sync="visible"
6
-        :before-close="_close"
3
+            :title="formTitle"
4
+            width="900px"
5
+            :visible.sync="visible"
6
+            :before-close="_close"
7 7
     >
8 8
         <div>
9
-            <el-form :model="form" :rules="rules" ref="form" label-width="100px" style="display: flex;flex-wrap: wrap;justify-content: space-between;">
9
+            <el-form :model="form" :rules="rules" ref="form" label-width="100px"
10
+                     style="display: flex;flex-wrap: wrap;justify-content: space-between;">
10 11
                 <el-form-item label="组套名称 : " prop="project_team" style="width:100%">
11 12
                     <el-input v-model="form.project_team" placeholder="" maxlength="30"></el-input>
12 13
                 </el-form-item>
@@ -19,60 +20,64 @@
19 20
                 <el-form-item label="五笔 : " prop="wubi" style="width:50%">
20 21
                     <el-input v-model="form.wubi" placeholder="" maxlength="30"></el-input>
21 22
                 </el-form-item>
22
-                
23
+
23 24
                 <el-form-item label="试管颜色 : " prop="name" style="width:50%">
24
-                     <el-select v-model="form.tube_color" style="width:160px;" placeholder="请选择">
25
+                    <el-select v-model="form.tube_color" style="width:160px;" placeholder="请选择">
25 26
                         <el-option
26
-                         v-for="(item,index) in getDictionaryDataConfig('system','tube_color')"
27
-                         :key="index"
28
-                         :label="item.name"
29
-                         :value="item.id">
27
+                                v-for="(item,index) in getDictionaryDataConfig('system','tube_color')"
28
+                                :key="index"
29
+                                :label="item.name"
30
+                                :value="item.id">
30 31
                         </el-option>
31
-                  </el-select>
32
+                    </el-select>
32 33
                 </el-form-item>
33 34
                 <el-form-item label="组套类型 : " prop="team_type" style="width:50%">
34 35
                     <el-select v-model="form.team_type" style="width:100%;" placeholder="请选择">
35 36
                         <el-option
36
-                        v-for="item in options"
37
-                        :key="item.value"
38
-                        :label="item.label"
39
-                        :value="item.value">
37
+                                v-for="item in options"
38
+                                :key="item.value"
39
+                                :label="item.label"
40
+                                :value="item.value">
40 41
                         </el-option>
41 42
                     </el-select>
42 43
                 </el-form-item>
43 44
                 <el-form-item label="备注 : " prop="name" style="width:100%;">
44 45
                     <el-input type="textarea" :rows="2" placeholder="请输入内容" v-model="form.remark"></el-input>
45 46
                 </el-form-item>
46
-                 <el-form-item label="组套明细" style="width:50%;">
47
+                <el-form-item label="组套明细" style="width:50%;">
47 48
                     <el-select v-model="form.project_detail" placeholder="请选择">
48 49
                         <el-option
49
-                        v-for="item in projectList"
50
-                        :key="item.id"
51
-                        :label="item.project_name"
52
-                        :value="item.id">
50
+                                v-for="item,index in projectList"
51
+                                :key="index"
52
+                                :label="item.project_name"
53
+                                :value="item.id">
53 54
                         </el-option>
54 55
                     </el-select>
55 56
 
56
-                    </el-form-item>
57
-                 <el-form-item label="数量" style="width:50%;"> 
58
-                      <div style="display:flex;"> 
59
-                         <el-input v-model="form.number" style="margin-right:10px;"></el-input>
60
-                         <el-button type="primary" @click="addProjectList">添加</el-button>
61
-                      </div>
62
-                  </el-form-item>
57
+                </el-form-item>
58
+                <el-form-item label="数量" style="width:50%;">
59
+                    <div style="display:flex;">
60
+                        <el-input v-model="form.number" style="margin-right:10px;"></el-input>
61
+                        <el-button type="primary" @click="addProjectList">添加</el-button>
62
+                    </div>
63
+                </el-form-item>
63 64
             </el-form>
64 65
             <el-form>
65
-                <el-table :data="tableData" border  style="100%" :row-style="{ color: '#303133' }" :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}" highlight-current-row ref="tab">
66
+                <el-table :data="tableData" border style="100%" :row-style="{ color: '#303133' }"
67
+                          :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}"
68
+                          highlight-current-row ref="tab">
66 69
                     <el-table-column align="center" prop="name" label="分类" width="120">
67
-                        <template slot-scope="scope">{{getId(scope.row.statistical_classification)}}</template>
70
+                        <template slot-scope="scope">
71
+                            <div>{{scope.row.type == 2?getId(scope.row.statistical_classification):'耗材'}}</div>
72
+                        </template>
68 73
                     </el-table-column>
69 74
                     <el-table-column align="center" prop="name" label="组套明细" width="120">
70 75
                         <template slot-scope="scope">{{scope.row.project_name}}</template>
71 76
                     </el-table-column>
72
-                     <el-table-column align="center" prop="name" label="数量" width="120">
77
+                    <el-table-column align="center" prop="name" label="数量" width="120">
73 78
                         <template slot-scope="scope">{{scope.row.number}}</template>
74 79
                     </el-table-column>
75
-                     <el-table-column align="center" prop="name" label="单位" width="120">
80
+                    <el-table-column align="center" prop="name" label="单位" width="120">
76 81
                         <template slot-scope="scope">{{scope.row.unit}}</template>
77 82
                     </el-table-column>
78 83
                     <el-table-column align="center" prop="name" label="单价" width="120">
@@ -80,18 +85,18 @@
80 85
                     </el-table-column>
81 86
                     <el-table-column align="center" prop="name" label="操作">
82 87
                         <template slot-scope="scope">
83
-                          <el-tooltip
84
-                            class="item"
85
-                            effect="dark"
86
-                            content="删除"
87
-                            placement="top"
88
+                            <el-tooltip
89
+                                    class="item"
90
+                                    effect="dark"
91
+                                    content="删除"
92
+                                    placement="top"
88 93
                             >
89
-                            <el-button
90
-                                type="danger"
91
-                                icon="el-icon-delete"
92
-                                size="small"
93
-                                @click="DeleteProject(scope.row.id,scope.$index)"
94
-                            ></el-button>
94
+                                <el-button
95
+                                        type="danger"
96
+                                        icon="el-icon-delete"
97
+                                        size="small"
98
+                                        @click="DeleteProject(scope.row.m_id,scope.$index)"
99
+                                ></el-button>
95 100
                             </el-tooltip>
96 101
                         </template>
97 102
                     </el-table-column>
@@ -102,234 +107,279 @@
102 107
 
103 108
         <div slot="footer" class="dialog-footer">
104 109
             <el-button @click="hide">取 消</el-button>
105
-            <el-button type="primary"  @click="submitAction('form')">保 存</el-button>
110
+            <el-button type="primary" @click="submitAction('form')">保 存</el-button>
106 111
         </div>
107
-  </el-dialog>
112
+    </el-dialog>
108 113
 </template>
109 114
 
110 115
 <script>
111
-import { getProjectTeamDetail,updatedProjectTeam,getAllProjectList,addProjectList,DeleteProject } from "@/api/project/project"
112
-import { getDictionaryDataConfig,getDataConfig} from "@/utils/data";
113
-export default {
114
-    data(){
115
-        return{
116
-            visible:false,
117
-            formTitle:'',
118
-            activeName:'first',
119
-            form:{
120
-              id:"",
121
-              project_team:'',
122
-              price:"",
123
-              pinyin:"",
124
-              wubi:"",
125
-              tube_color:"",
126
-              team_type:"",
127
-              remark:"",
128
-              project_detail:"",
129
-              number:"",
130
-              item_id:"",
131
-            },
132
-            options: [{
133
-            value: 1,
134
-            label: '是'
135
-            }, {
136
-            value: 2,
137
-            label: '否'
138
-            },],
139
-            value: '',
140
-            radio:'1',
141
-            rules: {
142
-              project_team: [{ required: true, message: '请填写组套名称', trigger: 'blur'  }],
143
-            //   pinyin: [{ required: true, message: '请填写拼音' , trigger: 'blur' }],
144
-            //   wubi: [{ required: true, message: '请填写五笔' , trigger: 'blur' }],
145
-              price: [{ required: true, message: '请填写价格', trigger: 'change' }],
146
-              team_type: [{ required:true,message:'请填写组套类型',trigger:'change' }]
147
-           },
148
-           tableData:[],
149
-           item_id:[],
150
-           projectList:[]
151
-        }
152
-    },
153
-    methods:{
154
-         getDataConfig(module, filed_name){
155
-            return getDataConfig(module, filed_name)
156
-        },
157
-            getDictionaryDataConfig(module, filed_name) {
158
-            return getDictionaryDataConfig(module, filed_name)
159
-        },
160
-        _close: function(done) {
161
-            done()
162
-        },
163
-        clear: function() {
164
-            this.form.id = 0;
165
-            this.form.name = "";
166
-            this.form.intro = "";
167
-        },
168
-        show(id) {
169
-         this.visible = true
170
-         this.formTitle = '编辑'
171
-         this.getProjectTeamDetail(id) 
116
+  import {
117
+    editTeam
118
+  } from '@/api/his/his'
119
+  import {
120
+    addProjectList,
121
+    DeleteProject,
122
+    getAllProjectList,
123
+    getProjectTeamDetail,
124
+    updatedProjectTeam
125
+  } from '@/api/project/project'
126
+  import { getDataConfig, getDictionaryDataConfig } from '@/utils/data'
127
+
128
+  export default {
129
+    data() {
130
+      return {
131
+        visible: false,
132
+        formTitle: '',
133
+        activeName: 'first',
134
+        form: {
135
+          id: '',
136
+          project_team: '',
137
+          price: '',
138
+          pinyin: '',
139
+          wubi: '',
140
+          tube_color: '',
141
+          team_type: '',
142
+          remark: '',
143
+          project_detail: '',
144
+          number: '',
145
+          item_id: ''
172 146
         },
173
-        hide() {
174
-    
175
-            this.visible = false
147
+        options: [{
148
+          value: 1,
149
+          label: '是'
150
+        }, {
151
+          value: 2,
152
+          label: '否'
153
+        }],
154
+        value: '',
155
+        radio: '1',
156
+        rules: {
157
+          project_team: [{ required: true, message: '请填写组套名称', trigger: 'blur' }],
158
+          //   pinyin: [{ required: true, message: '请填写拼音' , trigger: 'blur' }],
159
+          //   wubi: [{ required: true, message: '请填写五笔' , trigger: 'blur' }],
160
+          price: [{ required: true, message: '请填写价格', trigger: 'change' }],
161
+          team_type: [{ required: true, message: '请填写组套类型', trigger: 'change' }]
176 162
         },
177
-        getProjectTeamDetail(id){
178
-           getProjectTeamDetail(id).then(response=>{
179
-              if(response.data.state == 1){
180
-                 var projectTeamDetail =  response.data.data.projectTeamDetail
181
-                 console.log("projectTeamDetail",projectTeamDetail)
182
-                 var str  = projectTeamDetail.project_id
183
-                 var arr = str.split(",")
184
-                 console.log("Arr33333",arr)
185
-                 var list = response.data.data.list
186
-                 console.log("list",list)
187
-                 var hisList = response.data.data.hisList
188
-                 console.log("histList",hisList)
189
-                 for(let i=0;i<list.length;i++){
190
-                   for(let j=0;j<hisList.length;j++){
191
-                       if(list[i].id == hisList[j].project_id){
192
-                           list[i].number = hisList[j].number
193
-                       }
194
-                   }
195
-                 }
196
-                
197
-                 var strArr = []
198
-                 for(let i=0;i<arr.length;i++){
199
-                   for(let j=0;j<list.length;j++){
200
-                      if((arr[i]== list[j].id)){
201
-                          strArr.push(list[j])
202
-                      }
203
-                   }
204
-                 }
205
-                 console.log("数据222222",strArr)
206
-                 this.tableData = strArr
207
-               
208
-               
209
-                 this.form.id = projectTeamDetail.id
210
-                 this.form.project_team = projectTeamDetail.project_team
211
-                 this.form.price = projectTeamDetail.price
212
-                 this.form.pinyin = projectTeamDetail.pinyin
213
-                 this.form.wubi  = projectTeamDetail.wubi
214
-                 this.form.tube_color = projectTeamDetail.tube_color
215
-                 if(projectTeamDetail.tube_color == 0){
216
-                    this.form.tube_color = ""
217
-                 }
218
-                 this.form.team_type = projectTeamDetail.team_type
219
-                 if(projectTeamDetail.team_type == 0){
220
-                    this.form.team_type = ""
221
-                 }     
222
-                 this.form.remark = projectTeamDetail.remark
223
-                 this.form.item_id = projectTeamDetail.item_id
224
-                //  console.log("project",projectTeamDetail)
163
+        tableData: [],
164
+        item_id: [],
165
+        projectList: []
166
+      }
167
+    },
168
+    methods: {
169
+      getDataConfig(module, filed_name) {
170
+        return getDataConfig(module, filed_name)
171
+      },
172
+      getDictionaryDataConfig(module, filed_name) {
173
+        return getDictionaryDataConfig(module, filed_name)
174
+      },
175
+      _close: function(done) {
176
+        done()
177
+      },
178
+      clear: function() {
179
+        this.form.id = 0
180
+        this.form.name = ''
181
+        this.form.intro = ''
182
+      },
183
+      show(id) {
184
+        this.visible = true
185
+        this.formTitle = '编辑'
186
+        this.getlist(id)
187
+        this.getProjectTeamDetail(id)
188
+
189
+      }, getlist(id) {
190
+
191
+        getAllProjectList().then(response => {
192
+          if (response.data.state == 1) {
193
+            console.log(id)
194
+            console.log('!~~~~')
195
+
196
+            var projectList = response.data.data.projectList
197
+            var goodInfos = response.data.data.good_info
198
+
199
+            for (let i = 0; i < projectList.length; i++) {
200
+              let obj = {
201
+                id: projectList[i].id,
202
+                statistical_classification: projectList[i].statistical_classification,
203
+                number: '1',
204
+                project_name: projectList[i].project_name,
205
+                unit: projectList[i].unit,
206
+                price: projectList[i].price,
207
+                type: 2,
208
+                m_id: 0
225 209
               }
226
-           }) 
227
-        },
228
-        submitAction(formName){
229
-           this.$refs[formName].validate((valid)=>{
230
-               var arr = []
231
-                for(let i=0;i<this.tableData.length;i++){
232
-                    arr.push(this.tableData[i].id)
233
-                }
234
-             
235
-               var ids = arr.join(",")
236
-               var item_id = this.form.item_id + "," + this.item_id.join(",") 
237
-               console.log("item_id",item_id)
238
-               
239
-               if(valid){
240
-                var params = {
241
-                    id:this.form.id,
242
-                    project_team:this.form.project_team,
243
-                    price:this.form.price,
244
-                    pinyin:this.form.pinyin,
245
-                    wubi:this.form.wubi,
246
-                    tube_color:this.form.tube_color,
247
-                    team_type:this.form.team_type,
248
-                    remark:this.form.remark,
249
-                    ids:ids,
250
-                    item_id:item_id
251
-                }
252
-                // console.log("params",params)
253
-                 updatedProjectTeam(params).then(response=>{
254
-                   if(response.data.state == 1){
255
-                     var projectTeam = response.data.data.projectTeam
256
-                     this.$message.success("保存成功")
257
-                     this.visible = false
258
-                     this.$parent.getlist()
259
-                   }
260
-                 })
210
+              this.projectList.push(obj)
211
+
212
+            }
213
+
214
+            for (let i = 0; i < goodInfos.length; i++) {
215
+              let obj = {
216
+                id: goodInfos[i].id,
217
+                statistical_classification: goodInfos[i].statistical_classification,
218
+                number: '1',
219
+                project_name: goodInfos[i].good_name,
220
+                unit: goodInfos[i].good_unit,
221
+                price: goodInfos[i].retail_price,
222
+                type: 3,
223
+                m_id: 0
224
+
261 225
               }
262
-           })  
263
-        
264
-        },
265
-       getlist(){
266
-          getAllProjectList().then(response=>{
267
-             if(response.data.state == 1){
268
-               var projectList = response.data.data.projectList
269
-               console.log('projectlist33333',projectList)
270
-               this.projectList = projectList
271
-               var hisprojectlist = response.data.data.hisprojectlist
272
-             console.log("hisprojectlist",hisprojectlist)
273
-            //    this.tableData = hisprojectlist
274
-             }
275
-          })   
276
-        },
277
-        getId(id){
278
-          console.log("id",id)
279
-          var name = ""
280
-          var statistics_category =  getDictionaryDataConfig('system','statistics_category') 
281
-          console.log("statics",statistics_category)
282
-          for(let i=0;i<statistics_category.length;i++){
283
-             if(id == statistics_category[i].id){
284
-                 name = statistics_category[i].name
285
-             }
226
+              this.projectList.push(obj)
227
+            }
228
+
286 229
           }
287
-          return name
288
-        },
289
-       addProjectList(){
290
-           
291
-           console.log("表格",this.tableData)
292
-            const params = {
293
-              id:this.form.project_detail,
294
-              number:parseInt(this.form.number)
230
+        })
231
+      },
232
+
233
+      hide() {
234
+        this.visible = false
235
+      },
236
+      getProjectTeamDetail(id) {
237
+        getProjectTeamDetail(id).then(response => {
238
+          if (response.data.state == 1) {
239
+            this.tableData = []
240
+            var projectTeamDetail = response.data.data.projectTeamDetail
241
+            var hisList = response.data.data.hisList
242
+
243
+            console.log(this.projectList)
244
+            console.log(hisList)
245
+
246
+            for (let i = 0; i < hisList.length; i++) {
247
+
248
+              let obj = {
249
+                m_id: hisList[i].id,
250
+                id: hisList[i].project_id,
251
+                number: hisList[i].number,
252
+                type: hisList[i].type
253
+              }
254
+              if (hisList[i].type == 2) {
255
+                obj['statistical_classification'] = hisList[i].project.statistical_classification
256
+                obj['project_name'] = hisList[i].project.project_name
257
+                obj['unit'] = hisList[i].project.unit
258
+                obj['price'] = hisList[i].project.price
259
+
260
+              } else {
261
+                obj['project_name'] = hisList[i].good_info.good_name
262
+                obj['unit'] = hisList[i].good_info.good_unit
263
+                obj['price'] = hisList[i].good_info.retail_price
264
+              }
265
+              this.tableData.push(obj)
295 266
             }
296
-           console.log("params",params)
297
-          addProjectList(params).then(response=>{
298
-             if(response.data.state == 1){
299
-               var projectList = response.data.data.projectList
300
-               projectList.number = parseInt(this.form.number)
301
-               this.tableData.push(projectList)
302
-               console.log("23333",this.tableData)
303
-               var item = response.data.data.item
304
-               this.item_id.push(item.id)
305
-               this.$message.success("保存成功")
306
-               this.form.project_detail = ""
307
-               this.form.number = ""
308
-               this.getlist()
309
-             }
310
-          })
311
-        },
312
-        DeleteProject(id,index){
267
+            this.form.id = projectTeamDetail.id
268
+            this.form.project_team = projectTeamDetail.project_team
269
+            this.form.price = projectTeamDetail.price
270
+            this.form.pinyin = projectTeamDetail.pinyin
271
+            this.form.wubi = projectTeamDetail.wubi
272
+            this.form.tube_color = projectTeamDetail.tube_color
273
+            if (projectTeamDetail.tube_color == 0) {
274
+              this.form.tube_color = ''
275
+            }
276
+            this.form.team_type = projectTeamDetail.team_type
277
+            if (projectTeamDetail.team_type == 0) {
278
+              this.form.team_type = ''
279
+            }
280
+            this.form.remark = projectTeamDetail.remark
281
+            // this.form.item_id = projectTeamDetail.item_id
282
+            //  console.log("project",projectTeamDetail)
283
+          }
284
+        })
285
+      },
286
+      submitAction(formName) {
287
+        this.$refs[formName].validate((valid) => {
288
+          var arr = []
289
+          for (let i = 0; i < this.tableData.length; i++) {
290
+            if (this.tableData[i].m_id == 0) {
291
+              arr.push(this.tableData[i])
292
+            }
293
+          }
313 294
 
314
-           this.$confirm("确认删除此项目吗?", "删除", {
315
-            confirmButtonText: "确 定",
316
-            cancelButtonText: "取 消",
317
-            type: "warning"
318
-         }).then(() => {
319
-          DeleteProject(id).then(response => {
320
-            if (response.data.state == 1) {
321
-               this.tableData.splice(index, 1);
322
-               
323
-            } else {
324
-             
295
+          if (valid) {
296
+            var params = {
297
+              id: this.form.id,
298
+              project_team: this.form.project_team,
299
+              price: this.form.price,
300
+              pinyin: this.form.pinyin,
301
+              wubi: this.form.wubi,
302
+              tube_color: this.form.tube_color,
303
+              team_type: this.form.team_type,
304
+              remark: this.form.remark
325 305
             }
326
-          });
306
+            let data = {
307
+              'info': arr
308
+            }            // console.log("params",params)
309
+            editTeam(params, data).then(response => {
310
+              if (response.data.state == 1) {
311
+                // var projectTeam = response.data.data.projectTeam
312
+                this.$message.success('保存成功')
313
+                this.visible = false
314
+                // this.$parent.getlist()
315
+              }
316
+            })
317
+          }
327 318
         })
328
-        .catch(() => {});
319
+
320
+      },
321
+      getId(id) {
322
+        console.log('id', id)
323
+        var name = ''
324
+        var statistics_category = getDictionaryDataConfig('system', 'statistics_category')
325
+        console.log('statics', statistics_category)
326
+        for (let i = 0; i < statistics_category.length; i++) {
327
+          if (id == statistics_category[i].id) {
328
+            name = statistics_category[i].name
329
+          }
330
+        }
331
+        return name
332
+      },
333
+      addProjectList() {
334
+        for (let i = 0; i < this.projectList.length; i++) {
335
+          if (this.form.project_detail == this.projectList[i].id) {
336
+            this.projectList[i].number = this.form.number
337
+            this.projectList[i].number = this.projectList[i].number.toString()
338
+            this.tableData.push(this.projectList[i])
339
+            this.form.project_detail = ''
340
+            this.form.number = ''
341
+          }
329 342
         }
343
+
344
+      },
345
+      DeleteProject(id, index) {
346
+
347
+        if (id == 0) {
348
+          this.$confirm('确认删除此项目吗?', '删除', {
349
+            confirmButtonText: '确 定',
350
+            cancelButtonText: '取 消',
351
+            type: 'warning'
352
+          }).then(() => {
353
+            this.tableData.splice(index, 1)
354
+
355
+          })
356
+            .catch(() => {
357
+            })
358
+
359
+        } else {
360
+          this.$confirm('确认删除此项目吗?', '删除', {
361
+            confirmButtonText: '确 定',
362
+            cancelButtonText: '取 消',
363
+            type: 'warning'
364
+          }).then(() => {
365
+            DeleteProject(id).then(response => {
366
+              if (response.data.state == 1) {
367
+                this.tableData.splice(index, 1)
368
+
369
+              } else {
370
+
371
+              }
372
+            })
373
+          })
374
+            .catch(() => {
375
+            })
376
+
377
+        }
378
+
379
+      }
330 380
     },
331
-    created(){
332
-       this.getlist()   
381
+    created() {
382
+      this.getlist()
333 383
     }
334
-}
384
+  }
335 385
 </script>

+ 47 - 19
src/xt_pages/data/druguseTemplate.vue Целия файл

@@ -129,7 +129,6 @@
129 129
                 prop="amount1"
130 130
                 align="center"
131 131
                 label="药品规格">
132
-                <!-- {{drugDesc(scope.row)}} -->
133 132
                 <template slot-scope="scope">
134 133
                   <span v-if="scope.row.advice_desc">{{scope.row.advice_desc}}{{scope.row.drug_spec_unit}}</span>
135 134
                 </template>
@@ -189,6 +188,13 @@
189 188
                 </template>
190 189
               </el-table-column>
191 190
 
191
+             <el-table-column prop="blood_flow_volume" align="center" label="排序">
192
+                <template slot-scope="scope">
193
+                  <span v-if="scope.row.sort == 0"></span>
194
+                  <span v-if="scope.row.sort!=0">{{scope.row.sort}}</span>
195
+                </template>
196
+              </el-table-column>
197
+
192 198
               <el-table-column
193 199
                 align="center"
194 200
                 label="操作"
@@ -228,7 +234,9 @@
228 234
                   <el-form-item label="模版名称" style="width: 300px" prop="name">
229 235
                     <el-input v-model="form.name"></el-input>
230 236
                   </el-form-item>
231
-
237
+                 <el-form-item label="排序" style="width: 300px" prop="name">
238
+                    <el-input v-model="form.sort" v-type="number"></el-input>
239
+                  </el-form-item>
232 240
                   <el-form-item label="模版类型" prop="advice_type">
233 241
                     <el-radio-group v-model="form.advice_type">
234 242
                       <el-radio :label="0">临时</el-radio>
@@ -711,11 +719,15 @@
711 719
             <!--增删改查都请求网络类型的dialog-->
712 720
             <el-dialog title="编辑医嘱模版" :visible.sync="templateTableTwoVisible" width="800px">
713 721
               <div>
714
-                <!--<el-form ref="form" :model="form" :rule="formRules" label-width="100px">-->
715
-                <!--<el-form-item label="模版名称" style="width: 300px" prop="name">-->
716
-                <!--<el-input v-model="form.name" ></el-input>-->
717
-                <!--</el-form-item>-->
718
-                <!--</el-form>-->
722
+                <el-form ref="form" :model="form" :rule="formRules" label-width="100px">
723
+                  <el-form-item label="模版名称" style="width: 300px" prop="name">
724
+                    <el-input v-model="form.name" ></el-input>
725
+                  </el-form-item>
726
+
727
+                   <el-form-item label="排序" style="width: 300px" prop="name">
728
+                    <el-input v-model="form.sort" ></el-input>
729
+                   </el-form-item>
730
+                </el-form>
719 731
 
720 732
 
721 733
                 <div class="txsj" style="text-align: center;margin-bottom: 30px">
@@ -1448,8 +1460,8 @@
1448 1460
         },
1449 1461
         form: {
1450 1462
           name: '',
1451
-          advice_type: 0
1452
-
1463
+          advice_type: 0,
1464
+          sort:"",
1453 1465
         },
1454 1466
         drugwayForm: {
1455 1467
           name: '',
@@ -1669,11 +1681,11 @@
1669 1681
         const params = {
1670 1682
           'data': this.adviceTableData
1671 1683
         }
1672
-
1684
+       
1673 1685
         let name = encodeURIComponent(this.form.name)
1674 1686
         console.log("params",params)
1675
-
1676
-        postAdviceTemplate(params, name, this.form.advice_type).then(response => {
1687
+        let sort = this.form.sort
1688
+        postAdviceTemplate(params, name,sort, this.form.advice_type).then(response => {
1677 1689
 
1678 1690
           if (response.data.state == 0) {
1679 1691
             this.$message.error(response.data.msg)
@@ -1691,6 +1703,7 @@
1691 1703
                 }
1692 1704
                 object['name'] = template.name
1693 1705
                 object['isNoSub'] = 2
1706
+                object['sort'] = template.sort
1694 1707
                 this.adviceTemplates.unshift(object)
1695 1708
               }
1696 1709
             }
@@ -2145,6 +2158,7 @@
2145 2158
                 object['name'] = response.data.data.advice_templates[i].name
2146 2159
                 object['isNoSub'] = 1
2147 2160
                 object['template_id'] = response.data.data.advice_templates[i].id
2161
+                object['sort'] = response.data.data.advice_templates[i].sort
2148 2162
                 this.adviceTemplates.push(object)
2149 2163
               }
2150 2164
 
@@ -2158,13 +2172,15 @@
2158 2172
                   }
2159 2173
                   object['isNoSub'] = 2
2160 2174
                   object['name'] = response.data.data.advice_templates[i].name
2175
+                  object['sort'] = response.data.data.advice_templates[i].sort
2161 2176
                   this.adviceTemplates.push(object)
2177
+
2178
+
2162 2179
                 }
2163 2180
               }
2164 2181
             }
2165
-
2166
-            console.log(this.adviceTemplates)
2167
-
2182
+             this.adviceTemplates.sort(this.sortData)
2183
+             console.log("列表",this.adviceTemplates)
2168 2184
             // 处理单元格合并的数据
2169 2185
             this.handleSpanTempArr()
2170 2186
           }
@@ -2462,7 +2478,8 @@
2462 2478
             return 'success-row'
2463 2479
           }
2464 2480
         }
2465
-      }, cellMouseEnter: function(row, column, cell, event) {
2481
+      }, 
2482
+      cellMouseEnter: function(row, column, cell, event) {
2466 2483
         if (column.label == '模版名称') {
2467 2484
           this.sameRowArr.forEach((arr, i) => {
2468 2485
             if (arr.indexOf(row.index) != -1) {
@@ -2678,25 +2695,33 @@
2678 2695
         this.sameRowArr = sameRowArr
2679 2696
       },
2680 2697
        handleUpdateAdviceTemplate(row, index) {
2698
+       
2681 2699
         this.current_template_id = row.template_id
2682 2700
         this.current_template_name = row.name
2683 2701
         this.form.name = row.name
2684 2702
         this.form.advice_type = row.advice_type
2703
+        if(row.sort == 0){
2704
+          row.sort = ""
2705
+        }else{
2706
+          this.form.sort = row.sort
2707
+        }
2685 2708
         this.templateTableTwoVisible = true
2686 2709
         this.adviceTableDataTwo = []
2710
+      
2687 2711
         for (let i = 0; i < this.adviceTemplates.length; i++) {
2688 2712
           if (this.adviceTemplates[i].template_id == row.template_id) {
2689 2713
             this.adviceTableDataTwo.push(this.adviceTemplates[i])
2690 2714
           }
2691 2715
         }
2716
+        this.getAdviceConfig()
2692 2717
       },
2693 2718
       modifyTemplateName() {
2694 2719
         const params = {
2695 2720
           template_name: this.form.name,
2696
-          template_id: this.current_template_id
2721
+          template_id: this.current_template_id,
2722
+          sort:this.form.sort,
2697 2723
         }
2698
-        console.log("params---",params)
2699
-
2724
+      
2700 2725
         updateTemplateName(params).then(response => {
2701 2726
           if (response.data.state == 0) {
2702 2727
             this.$message.error(response.data.msg)
@@ -2918,6 +2943,9 @@
2918 2943
         console.log('results',results)
2919 2944
         cb(results);
2920 2945
       },
2946
+     sortData(a, b) {
2947
+       return a.sort - b.sort
2948
+     }
2921 2949
     }
2922 2950
   }
2923 2951
 </script>

+ 3 - 3
src/xt_pages/data/prescription.vue Целия файл

@@ -229,7 +229,7 @@
229 229
                     </el-form-item>
230 230
                   </el-col>
231 231
 
232
-                  <el-col :span="8">
232
+                  <el-col :span="8" v-if="this.$store.getters.xt_user.template_info.org_id != 9987 && this.$store.getters.xt_user.template_info.org_id != 3877 && this.$store.getters.xt_user.template_info.org_id != 10090">
233 233
                     <el-form-item label="透析器/灌流器:">
234 234
                       <el-input
235 235
                         v-model="addPlan.dialyzer_perfusion_apparatus" @focus="showInnerDialog('5')"></el-input>
@@ -237,14 +237,14 @@
237 237
                   </el-col>
238 238
 
239 239
 
240
-                  <el-col :span="8" v-if="this.$store.getters.xt_user.template_info.org_id == 9987 || this.$store.getters.xt_user.template_info.org_id == 3877">
240
+                  <el-col :span="8" v-if="this.$store.getters.xt_user.template_info.org_id == 9987 || this.$store.getters.xt_user.template_info.org_id == 3877 || this.$store.getters.xt_user.template_info.org_id == 10090">
241 241
                     <el-form-item label="透析器:">
242 242
                       <el-input
243 243
                         v-model="dialysis_dialyszers" @focus="showInnerDialog('6')"></el-input>
244 244
                     </el-form-item>
245 245
                   </el-col>
246 246
 
247
-                  <el-col :span="8" v-if="this.$store.getters.xt_user.template_info.org_id == 9987 || this.$store.getters.xt_user.template_info.org_id == 3877">
247
+                  <el-col :span="8" v-if="this.$store.getters.xt_user.template_info.org_id == 9987 || this.$store.getters.xt_user.template_info.org_id == 3877 || this.$store.getters.xt_user.template_info.org_id == 10090">
248 248
                     <el-form-item label="灌流器:">
249 249
                       <el-input
250 250
                         v-model="dialysis_irrigation" @focus="showInnerDialog('7')"></el-input>

+ 5 - 3
src/xt_pages/data/printTemplate.vue Целия файл

@@ -20,7 +20,9 @@
20 20
         <el-tab-pane label="透析记录单模板" name="4">
21 21
           <dialysis-print></dialysis-print>
22 22
         </el-tab-pane>
23
-       
23
+        <el-tab-pane label="排班打印模板" name="6">
24
+          <schedule-print></schedule-print>
25
+        </el-tab-pane>
24 26
       </el-tabs>
25 27
     </div>
26 28
   </div>
@@ -33,10 +35,10 @@ import prescriptionPrint from './printTemplate/prescriptionPrint'
33 35
 import treatPrint from './printTemplate/treatPrint'
34 36
 import dialysisPrint from './printTemplate/dialysisPrint'
35 37
 import chargePrint from './printTemplate/chargePrint'
36
-
38
+import schedulePrint from './printTemplate/schedulePrint'
37 39
 export default {
38 40
   name: "printTemplate",
39
-  components: { BreadCrumb,recordPrint,prescriptionPrint,treatPrint,dialysisPrint,chargePrint },
41
+  components: { BreadCrumb,recordPrint,prescriptionPrint,treatPrint,dialysisPrint,chargePrint,schedulePrint },
40 42
   data() {
41 43
     return {
42 44
       showViewer:false,

+ 165 - 0
src/xt_pages/data/printTemplate/schedulePrint.vue Целия файл

@@ -0,0 +1,165 @@
1
+<template>
2
+    <div
3
+      v-loading="loading"
4
+      element-loading-text="服务器处理数据中,请稍候......."
5
+      element-loading-spinner="el-icon-loading"
6
+      element-loading-background="rgba(0, 0, 0, 0.8)"
7
+    >
8
+    <p style="margin-top: 10px;margin-bottom: 30px">
9
+        请选择你需要打印的排班打印单样式
10
+    </p>
11
+    <el-row :gutter="20" type="flex" justify="center">
12
+        <el-col :span="6" style="text-align: center">
13
+        <div
14
+            @click="imgClick('https://kuyi.shengws.com/tempSchedule1.jpg')"
15
+        >
16
+            <el-tooltip
17
+            class="item"
18
+            effect="dark"
19
+            :hide-after="2000"
20
+            content="点击查看大图"
21
+            placement="top-start"
22
+            >
23
+         
24
+            <el-image
25
+                style="width: 200px; height: 200px"
26
+                :src="require('@/assets/home/111.jpg')"
27
+            ></el-image>
28
+
29
+            </el-tooltip>
30
+        </div>
31
+        <el-radio v-model="radio" label="1" @change="change">模版一</el-radio>
32
+        </el-col>
33
+        <el-col
34
+        :span="6"
35
+        style="margin-left: 100px;margin-right: 100px;text-align: center"
36
+        >
37
+        <div
38
+            @click="imgClick('https://kuyi.shengws.com/tempSchedule2.jpg')"
39
+
40
+        >
41
+            <el-tooltip
42
+            class="item"
43
+            effect="dark"
44
+            content="点击查看大图"
45
+            placement="top-start"
46
+            :hide-after="2000"
47
+            >
48
+          
49
+
50
+            <el-image
51
+                style="width: 200px; height: 200px"
52
+                :src="require('@/assets/home/222.jpg')"
53
+            ></el-image>
54
+            </el-tooltip>
55
+        </div>
56
+        <el-radio v-model="radio" label="2" @change="change">模版二</el-radio
57
+        >
58
+        </el-col>
59
+    </el-row>
60
+   
61
+
62
+
63
+      <el-image-viewer
64
+        v-if="showViewer"
65
+        :on-close="closeViewer"
66
+        :url-list="imgs"
67
+      ></el-image-viewer>
68
+
69
+    </div>
70
+  </div>
71
+</template>
72
+
73
+<script>
74
+import BreadCrumb from "@/xt_pages/components/bread-crumb";
75
+import ElImageViewer from 'element-ui/packages/image/src/image-viewer'
76
+import { getScheduleTemplate, postScheduleTemplate } from "@/api/schedule";
77
+import store from "@/store";
78
+
79
+export default {
80
+  name: "printTemplate",
81
+  components: { ElImageViewer, BreadCrumb },
82
+  data() {
83
+    return {
84
+      showViewer:false,
85
+      crumbs: [
86
+        { path: false, name: "管理中心" },
87
+        { path: "data/print", name: "打印模版" }
88
+      ],
89
+      imgUrl_One: require("@/assets/home/111.jpg"),
90
+      imgUrl_Two: require("@/assets/home/222.jpg"),
91
+   
92
+
93
+      imgs:[],
94
+
95
+      imgs_one: ["https://kuyi.shengws.com/template1.png"],
96
+      imgs_two: ["https://kuyi.shengws.com/template2.png"],
97
+      delay: 500,
98
+      radio: 0,
99
+      tempRadio: 0,
100
+      loading: false
101
+    };
102
+  },
103
+  methods: {
104
+    imgClick(val){
105
+      this.imgs = []
106
+      this.imgs.push(val)
107
+      this.showViewer = true
108
+
109
+    },
110
+    closeViewer() {
111
+      this.showViewer = false
112
+    },
113
+    change: function(val) {
114
+       var params = {
115
+            template_id:val
116
+        }
117
+     postScheduleTemplate(params).then(response=>{
118
+         if(response.data.state == 1){
119
+            var template = response.data.data.template
120
+            this.$message.success("保存成功!")
121
+            this.getlist()
122
+         }   
123
+      })
124
+    },
125
+    getlist(){
126
+       getScheduleTemplate().then(response=>{
127
+          if(response.data.state == 1){
128
+            var template = response.data.data.template
129
+            console.log("template222222",template)
130
+            if(template.template_id == 0){
131
+               this.radio = "1"
132
+            }
133
+            if(template.template_id!=0){
134
+               this.radio = template.template_id.toString()
135
+            }
136
+           
137
+          }
138
+       })
139
+    }
140
+  },
141
+  created() {
142
+    this.getlist()
143
+  }
144
+};
145
+</script>
146
+
147
+<style scoped>
148
+.el-row {
149
+  margin-bottom: 20px;
150
+
151
+  & :last-child {
152
+    margin-bottom: 0;
153
+  }
154
+}
155
+.el-col {
156
+  border-radius: 4px;
157
+}
158
+</style>
159
+<style lang="scss">
160
+.app-print {
161
+  .el-radio__label {
162
+    padding-left: 10px;
163
+  }
164
+}
165
+</style>

+ 1 - 0
src/xt_pages/dialysis/PatientBox.vue Целия файл

@@ -551,6 +551,7 @@ export default {
551 551
           this.getLongAdvice()
552 552
         } else {
553 553
           this.$message.error(resp.msg);
554
+         
554 555
         }
555 556
 
556 557
         if (this.lastDialysisPrescribe != null) {

+ 9 - 1
src/xt_pages/dialysis/batch_print/batch_print_order.vue Целия файл

@@ -2049,10 +2049,18 @@ export default {
2049 2049
 
2050 2050
 
2051 2051
           for (const index in this.records) {
2052
+            for(const index2 in this.records[index].his_project){
2053
+              if(this.records[index].his_project[index2].type == 2){
2054
+                this.records[index].his_project[index2]['advice_name'] = this.records[index].his_project[index2].project.project_name
2055
+              }else if(this.records[index].his_project[index2].type == 3){
2056
+                this.records[index].his_project[index2]['advice_name'] =this.records[index].his_project[index2].good_info.good_name
2057
+              }
2058
+              this.records[index].his_project[index2]['advice_doctor'] = this.records[index].his_project[index2].doctor
2059
+            }
2052 2060
             this.records[index].advices = this.records[index].advices.concat(this.records[index].his_advices)
2061
+            this.records[index].advices = this.records[index].advices.concat(this.records[index].his_project)
2053 2062
           }
2054 2063
 
2055
-
2056 2064
           for (const recordIndex in this.records) {
2057 2065
             var dlegh = 0;
2058 2066
             if (

+ 49 - 14
src/xt_pages/dialysis/batch_print/batch_print_order_six.vue Целия файл

@@ -81,9 +81,9 @@
81 81
               <div
82 82
                 class="under_line"
83 83
                 style="width: 70px;text-align: left"
84
-                v-if="record.patient.admission_number"
84
+                v-if="record.receive_assessment.admission_number"
85 85
               >
86
-                {{ record.patient.admission_number }}
86
+                {{ record.receive_assessment.admission_number }}
87 87
               </div>
88 88
               <div
89 89
                 class="under_line"
@@ -556,6 +556,20 @@
556 556
                           >
557 557
                             IUF+HD
558 558
                           </div>
559
+                           <div
560
+                            class="under_line"
561
+                            style="width: 100px;text-align: center;font-weight:600;"
562
+                            v-if="record.prescription.mode_id == 22"
563
+                          >
564
+                            血浆胆红素吸附+HDF
565
+                          </div>
566
+                           <div
567
+                            class="under_line"
568
+                            style="width: 100px;text-align: center;font-weight:600;"
569
+                            v-if="record.prescription.mode_id == 23"
570
+                          >
571
+                            血浆胆红素吸附
572
+                          </div>
559 573
                         </div>
560 574
                       </div>
561 575
 
@@ -656,21 +670,27 @@
656 670
                           {{record.prescription && record.prescription.dialysis_irrigation?record.prescription.dialysis_irrigation:"/"}}
657 671
                         </div>
658 672
                       </div>
659
-                      <div class="inline_block" style="flex:1;">
660
-                        干体重
673
+                      <div class="inline_block" style="flex:1;" v-if="org_id == 9538">
674
+                        血浆分离器
661 675
                         <div
662 676
                           class="under_line"
663
-                          style="width: 150px;text-align: center"
677
+                          style="width: 70px;text-align: center"
664 678
                         >
665
-                          {{
666
-                            record.assessment_before_dislysis &&
667
-                            record.assessment_before_dislysis.dry_weight
668
-                              ? record.assessment_before_dislysis.dry_weight
669
-                              : "/"
670
-                          }}
679
+                          <span v-if="record.prescription.plasma_separator ? record.prescription.plasma_separator != 0 && record.prescription.plasma_separator != '0' : false">{{ record.prescription.plasma_separator }}</span>
680
+                          <span v-else>/</span>
681
+                        </div>
682
+                      </div>
683
+                      <div class="inline_block" style="flex:1;" v-if="org_id == 9538">
684
+                        胆红素吸附柱:
685
+                        <div
686
+                          class="under_line"
687
+                          style="width: 70px;text-align: center"
688
+                        >
689
+                          <span v-if="record.prescription.bilirubin_adsorption_column ? record.prescription.bilirubin_adsorption_column != 0 && record.prescription.bilirubin_adsorption_column != '0' : false">{{ record.prescription.bilirubin_adsorption_column }}</span>
690
+                          <span v-else>/</span>
671 691
                         </div>
672
-                        kg
673 692
                       </div>
693
+                      
674 694
                     </div>
675 695
 
676 696
                     <div
@@ -722,7 +742,7 @@
722 742
                         计划超滤量:
723 743
                         <div
724 744
                           class="under_line"
725
-                          style="width: 150px;text-align: center"
745
+                          style="width: 100px;text-align: center"
726 746
                         >
727 747
                           {{
728 748
                             record.prescription &&
@@ -733,6 +753,21 @@
733 753
                         </div>
734 754
                         ml
735 755
                       </div>
756
+                      <div class="inline_block" style="flex:1;">
757
+                        干体重:
758
+                        <div
759
+                          class="under_line"
760
+                          style="width: 100px;text-align: center"
761
+                        >
762
+                          {{
763
+                            record.assessment_before_dislysis &&
764
+                            record.assessment_before_dislysis.dry_weight
765
+                              ? record.assessment_before_dislysis.dry_weight
766
+                              : "/"
767
+                          }}
768
+                        </div>
769
+                        kg
770
+                      </div>
736 771
                     </div>
737 772
 
738 773
                     <div class="row" style="padding: 2px 0;line-height:23px;">
@@ -1027,7 +1062,7 @@
1027 1062
                           </td>
1028 1063
                           <td>
1029 1064
                             {{
1030
-                              monitor_record.ultrafiltration_volume? monitor_record.ultrafiltration_volume: ""}}
1065
+                              monitor_record.ultrafiltration_volume? monitor_record.ultrafiltration_volume: "0"}}
1031 1066
                           </td>
1032 1067
                           <td v-if=" record.prescription.mode_id == 2 || record.prescription.mode_id == 5 ||(record.prescription.mode_id == 12 &&monitor_record.operate_time >record.dialysis_order.end_time) " style="width:50px">
1033 1068
                             {{

Файловите разлики са ограничени, защото са твърде много
+ 1516 - 0
src/xt_pages/dialysis/batch_print/batch_print_order_thirtyNine.vue


+ 12 - 0
src/xt_pages/dialysis/bloodPresssWatch.vue Целия файл

@@ -249,6 +249,16 @@
249 249
           >批量打印</el-button
250 250
         >
251 251
       </template>
252
+      <template v-if="this.template_id == 39">
253
+        <el-button
254
+          size="small"
255
+          icon="el-icon-printer"
256
+          :disabled="selecting_schs.length == 0"
257
+          @click="batchPrintAction"
258
+          type="primary"
259
+          >批量打印</el-button
260
+        >
261
+      </template>
252 262
     </div>
253 263
     <div class="app-container">
254 264
       <!-- <div class="filter-container">
@@ -827,6 +837,8 @@ export default {
827 837
         this.$router.push({ path: "/dialysis/print/batch/thirtyTwo" });
828 838
       } else if (this.template_id == 33) {
829 839
         this.$router.push({ path: "/dialysis/print/batch/thirtyThree" });
840
+      } else if (this.template_id == 39) {
841
+        this.$router.push({ path: "/dialysis/print/batch/thirtyNine" });
830 842
       }
831 843
     },
832 844
     batchPrintActionOne: function() {

+ 1 - 1
src/xt_pages/dialysis/details/BasicInfor.vue Целия файл

@@ -138,7 +138,7 @@ export default {
138 138
     }
139 139
   },
140 140
   created() {
141
-    this.dialysis_time = parseTime(this.$route.query.date, '{y}-{m}-{d}')
141
+    this.dialysis_time = this.$route.query.date ? parseTime(this.$route.query.date, '{y}-{m}-{d}') : parseTime(new Date(), '{y}-{m}-{d}')
142 142
   }
143 143
 }
144 144
 </script>

+ 61 - 13
src/xt_pages/dialysis/details/DialysisPrescription.vue Целия файл

@@ -15,8 +15,8 @@
15 15
           <span class="content">{{
16 16
             replacement_total != "0" ? replacement_total : ""
17 17
           }}</span>
18
-          <span v-if="this.$store.getters.xt_user.template_info.template_id != 20 && this.$store.getters.xt_user.template_info.template_id != 28 && this.$store.getters.xt_user.template_info.template_id != 29" class="unit">{{ replacement_total != "0" ? "L" : "" }}</span>
19
-          <span v-if="this.$store.getters.xt_user.template_info.template_id == 20 || this.$store.getters.xt_user.template_info.template_id == 28 || this.$store.getters.xt_user.template_info.template_id == 29" class="unit">{{ replacement_total != "0" ? "ml" : "" }}</span>
18
+          <span v-if="this.$store.getters.xt_user.template_info.template_id != 20 && this.$store.getters.xt_user.template_info.template_id != 28 && this.$store.getters.xt_user.template_info.template_id != 29 && this.$store.getters.xt_user.template_info.template_id != 40" class="unit">{{ replacement_total != "0" ? "L" : "" }}</span>
19
+          <span v-if="this.$store.getters.xt_user.template_info.template_id == 20 || this.$store.getters.xt_user.template_info.template_id == 28 || this.$store.getters.xt_user.template_info.template_id == 29 || this.$store.getters.xt_user.template_info.template_id == 40" class="unit">{{ replacement_total != "0" ? "ml" : "" }}</span>
20 20
 
21 21
         </li>
22 22
 
@@ -57,8 +57,8 @@
57 57
           <label>总量: </label>
58 58
           <span class="content" v-if="getValueStr('anticoagulant', 'anticoagulant') != 1">{{anticoagulant_zongliang != "0" ? anticoagulant_zongliang : ""}}</span>
59 59
           <span class="content" v-if="getValueStr('anticoagulant', 'anticoagulant') == 1" ></span>
60
-          <span class="unit" v-if="getValueStr('anticoagulant', 'anticoagulant') == 2 && this.$store.getters.xt_user.template_info.template_id != 13 &&  this.$store.getters.xt_user.template_info.template_id != 23 ">{{ anticoagulant_zongliang != "0" ? "iu" : "" }}</span>
61
-          <span class="unit" v-if="getValueStr('anticoagulant', 'anticoagulant') == 2 && (this.$store.getters.xt_user.template_info.template_id == 13 || this.$store.getters.xt_user.template_info.template_id == 23)">{{ anticoagulant_zongliang != "0" ? "mg" : "" }}</span>
60
+          <span class="unit" v-if="getValueStr('anticoagulant', 'anticoagulant') == 2 && this.$store.getters.xt_user.template_info.template_id != 13 &&  this.$store.getters.xt_user.template_info.template_id != 23 &&  this.$store.getters.xt_user.template_info.template_id != 40">{{ anticoagulant_zongliang != "0" ? "iu" : "" }}</span>
61
+          <span class="unit" v-if="getValueStr('anticoagulant', 'anticoagulant') == 2 && (this.$store.getters.xt_user.template_info.template_id == 13 || this.$store.getters.xt_user.template_info.template_id == 23 || this.$store.getters.xt_user.template_info.template_id == 40)">{{ anticoagulant_zongliang != "0" ? "mg" : "" }}</span>
62 62
           <span class="unit" v-if="getValueStr('anticoagulant', 'anticoagulant') == 3" >{{ anticoagulant_zongliang != "0" ? "iu" : "" }}</span>
63 63
           <span class="unit" v-if="getValueStr('anticoagulant', 'anticoagulant') == 1">{{ anticoagulant_zongliang != "0" ? "mg" : "" }}</span>
64 64
           <span class="unit" v-if="getValueStr('anticoagulant', 'anticoagulant') == 4">{{ anticoagulant_zongliang != "0" ? "mg" : "" }}</span>
@@ -106,8 +106,8 @@
106 106
           <span class="content">{{
107 107
             target_ultrafiltration != "0" ? target_ultrafiltration : ""
108 108
           }}</span>
109
-          <span v-if="this.$store.getters.xt_user.template_info.template_id != 17 && this.$store.getters.xt_user.template_info.template_id != 9 && this.$store.getters.xt_user.template_info.template_id != 20 && this.$store.getters.xt_user.template_info.template_id != 21 && this.$store.getters.xt_user.template_info.template_id != 22 && this.$store.getters.xt_user.template_info.template_id != 23 && this.$store.getters.xt_user.template_info.template_id != 24 && this.$store.getters.xt_user.template_info.template_id != 26 && this.$store.getters.xt_user.template_info.template_id != 28 && this.$store.getters.xt_user.template_info.template_id != 27 && this.$store.getters.xt_user.template_info.template_id != 29 && this.$store.getters.xt_user.template_info.template_id != 30 && this.$store.getters.xt_user.template_info.template_id != 31 && this.$store.getters.xt_user.template_info.template_id != 32 && this.$store.getters.xt_user.template_info.template_id != 34 && this.$store.getters.xt_user.template_info.template_id != 36 && this.$store.getters.xt_user.template_info.template_id != 38 && this.$store.getters.xt_user.template_info.org_id != 9555" class="unit">{{ target_ultrafiltration != "0" ? "L" : "" }}</span>
110
-          <span v-if="this.$store.getters.xt_user.template_info.template_id == 17 || this.$store.getters.xt_user.template_info.template_id == 9 || this.$store.getters.xt_user.template_info.template_id == 20 || this.$store.getters.xt_user.template_info.template_id == 21 || this.$store.getters.xt_user.template_info.template_id == 22 || this.$store.getters.xt_user.template_info.template_id == 23 || this.$store.getters.xt_user.template_info.template_id == 24 || this.$store.getters.xt_user.template_info.template_id == 26 || this.$store.getters.xt_user.template_info.template_id == 28 || this.$store.getters.xt_user.template_info.template_id == 27 || this.$store.getters.xt_user.template_info.template_id == 29 || this.$store.getters.xt_user.template_info.template_id == 30 || this.$store.getters.xt_user.template_info.template_id == 31 || this.$store.getters.xt_user.template_info.template_id == 32 || this.$store.getters.xt_user.template_info.template_id == 34 || this.$store.getters.xt_user.template_info.template_id == 36 || this.$store.getters.xt_user.template_info.template_id == 38 || this.$store.getters.xt_user.template_info.org_id == 9555" class="unit">{{ target_ultrafiltration != "0" ? "ml" : "" }}</span>
109
+          <span v-if="this.$store.getters.xt_user.template_info.template_id != 17 && this.$store.getters.xt_user.template_info.template_id != 9 && this.$store.getters.xt_user.template_info.template_id != 20 && this.$store.getters.xt_user.template_info.template_id != 21 && this.$store.getters.xt_user.template_info.template_id != 22 && this.$store.getters.xt_user.template_info.template_id != 23 && this.$store.getters.xt_user.template_info.template_id != 24 && this.$store.getters.xt_user.template_info.template_id != 26 && this.$store.getters.xt_user.template_info.template_id != 28 && this.$store.getters.xt_user.template_info.template_id != 27 && this.$store.getters.xt_user.template_info.template_id != 29 && this.$store.getters.xt_user.template_info.template_id != 30 && this.$store.getters.xt_user.template_info.template_id != 31 && this.$store.getters.xt_user.template_info.template_id != 32 && this.$store.getters.xt_user.template_info.template_id != 34 && this.$store.getters.xt_user.template_info.template_id != 36 && this.$store.getters.xt_user.template_info.template_id != 38 && this.$store.getters.xt_user.template_info.template_id != 40 && this.$store.getters.xt_user.template_info.org_id != 9555" class="unit">{{ target_ultrafiltration != "0" ? "L" : "" }}</span>
110
+          <span v-if="this.$store.getters.xt_user.template_info.template_id == 17 || this.$store.getters.xt_user.template_info.template_id == 9 || this.$store.getters.xt_user.template_info.template_id == 20 || this.$store.getters.xt_user.template_info.template_id == 21 || this.$store.getters.xt_user.template_info.template_id == 22 || this.$store.getters.xt_user.template_info.template_id == 23 || this.$store.getters.xt_user.template_info.template_id == 24 || this.$store.getters.xt_user.template_info.template_id == 26 || this.$store.getters.xt_user.template_info.template_id == 28 || this.$store.getters.xt_user.template_info.template_id == 27 || this.$store.getters.xt_user.template_info.template_id == 29 || this.$store.getters.xt_user.template_info.template_id == 30 || this.$store.getters.xt_user.template_info.template_id == 31 || this.$store.getters.xt_user.template_info.template_id == 32 || this.$store.getters.xt_user.template_info.template_id == 34 || this.$store.getters.xt_user.template_info.template_id == 36 || this.$store.getters.xt_user.template_info.template_id == 38 || this.$store.getters.xt_user.template_info.template_id != 40 || this.$store.getters.xt_user.template_info.org_id == 9555" class="unit">{{ target_ultrafiltration != "0" ? "ml" : "" }}</span>
111 111
         </li>
112 112
         <li v-if="isShow('葡萄糖')">
113 113
           <label>葡萄糖 : </label>
@@ -135,8 +135,8 @@
135 135
           <label>首剂 : </label>
136 136
           <span class="content" v-if="getValueStr('anticoagulant', 'anticoagulant') != 1">{{ anticoagulant_shouji != "0" ? anticoagulant_shouji : "" }}</span>
137 137
           <span class="content" v-if="getValueStr('anticoagulant', 'anticoagulant') == 1" ></span>
138
-          <span class="unit"  v-if="getValueStr('anticoagulant', 'anticoagulant') == 2  && this.$store.getters.xt_user.template_info.template_id != 13  && this.$store.getters.xt_user.template_info.template_id != 23 " >{{ anticoagulant_shouji != "0" ? "iu" : "" }}</span>
139
-          <span class="unit"  v-if="getValueStr('anticoagulant', 'anticoagulant') == 2  && (this.$store.getters.xt_user.template_info.template_id == 13 ||  this.$store.getters.xt_user.template_info.template_id == 23)" >{{ anticoagulant_shouji != "0" ? "mg" : "" }}</span>
138
+          <span class="unit"  v-if="getValueStr('anticoagulant', 'anticoagulant') == 2  && this.$store.getters.xt_user.template_info.template_id != 13  && this.$store.getters.xt_user.template_info.template_id != 23 && this.$store.getters.xt_user.template_info.template_id != 40" >{{ anticoagulant_shouji != "0" ? "iu" : "" }}</span>
139
+          <span class="unit"  v-if="getValueStr('anticoagulant', 'anticoagulant') == 2  && (this.$store.getters.xt_user.template_info.template_id == 13 ||  this.$store.getters.xt_user.template_info.template_id == 23 ||  this.$store.getters.xt_user.template_info.template_id == 40)" >{{ anticoagulant_shouji != "0" ? "mg" : "" }}</span>
140 140
           <span class="unit" v-if="getValueStr('anticoagulant', 'anticoagulant') == 3">{{ anticoagulant_shouji != "0" ? "iu" : "" }}</span>
141 141
           <span class="unit" v-if="getValueStr('anticoagulant', 'anticoagulant') == 1" >{{ anticoagulant_shouji != "0" ? "mg" : "" }}</span>
142 142
           <span class="unit" v-if="getValueStr('anticoagulant', 'anticoagulant') == 4" >{{ anticoagulant_shouji != "0" ? "mg" : "" }}</span >
@@ -225,8 +225,8 @@
225 225
           <label>维持 : </label>
226 226
           <span class="content" v-if="getValueStr('anticoagulant', 'anticoagulant') != 1">{{ anticoagulant_weichi != "0" ? anticoagulant_weichi : "" }}</span>
227 227
           <span class="content" v-if="getValueStr('anticoagulant', 'anticoagulant') == 1"></span>
228
-          <span class="unit" v-if="getValueStr('anticoagulant', 'anticoagulant') == 2 && this.$store.getters.xt_user.template_info.template_id != 13 && this.$store.getters.xt_user.template_info.template_id != 23 ">{{ anticoagulant_weichi != "0" ? "iu/h" : "" }}</span>
229
-          <span class="unit" v-if="getValueStr('anticoagulant', 'anticoagulant') == 2 && (this.$store.getters.xt_user.template_info.template_id == 13 ||  this.$store.getters.xt_user.template_info.template_id == 23)">{{ anticoagulant_weichi != "0" ? "mg/h" : "" }}</span>
228
+          <span class="unit" v-if="getValueStr('anticoagulant', 'anticoagulant') == 2 && this.$store.getters.xt_user.template_info.template_id != 13 && this.$store.getters.xt_user.template_info.template_id != 23 && this.$store.getters.xt_user.template_info.template_id != 40">{{ anticoagulant_weichi != "0" ? "iu/h" : "" }}</span>
229
+          <span class="unit" v-if="getValueStr('anticoagulant', 'anticoagulant') == 2 && (this.$store.getters.xt_user.template_info.template_id == 13 ||  this.$store.getters.xt_user.template_info.template_id == 23 ||  this.$store.getters.xt_user.template_info.template_id == 40)">{{ anticoagulant_weichi != "0" ? "mg/h" : "" }}</span>
230 230
           <span class="unit" v-if="getValueStr('anticoagulant', 'anticoagulant') == 3">{{ anticoagulant_weichi != "0" ? "iu/h" : "" }}</span>
231 231
           <span class="unit" v-if="getValueStr('anticoagulant', 'anticoagulant') == 1">{{ anticoagulant_weichi != "0" ? "mg/h" : "" }}</span>
232 232
           <span class="unit" v-if="getValueStr('anticoagulant', 'anticoagulant') == 4">{{ anticoagulant_weichi != "0" ? "mg/h" : "" }}</span>
@@ -312,7 +312,7 @@
312 312
           <span class="content" v-if="this.prescription.anticoagulant_stop_time_hour == 0 && this.prescription.anticoagulant_stop_time_min == 0 "></span>
313 313
           <span class="unit"></span>
314 314
         </li>
315
-       
315
+
316 316
         <li v-if="isShow('病情')">
317 317
           <label>病情: </label>
318 318
           <span class="content">{{getIllness(this.prescription.illness)}}</span>
@@ -323,6 +323,54 @@
323 323
           <span class="content">{{this.prescription.amylaceum}}</span>
324 324
         </li>
325 325
 
326
+        <li v-if="isShow('单超时长')">
327
+          <label>单超时长(h): </label>
328
+          <span class="content">{{this.prescription.single_time}}</span>
329
+        </li>
330
+
331
+        <li v-if="isShow('单超脱水')">
332
+          <label>单超脱水(L): </label>
333
+          <span class="content">{{this.prescription.single_water}}</span>
334
+        </li>
335
+
336
+
337
+         <li v-if="isShow('置换流量')">
338
+          <label>置换流量(L/h): </label>
339
+          <span class="content">{{this.prescription.replacement_flow}}</span>
340
+        </li>
341
+
342
+        <li v-if="isShow('血浆分离器')">
343
+          <label>血浆分离器: </label>
344
+          <span class="content">{{this.prescription.plasma_separator}}</span>
345
+        </li>
346
+
347
+       <li v-if="isShow('胆红素吸附柱')">
348
+          <label>胆红素吸附柱: </label>
349
+          <span class="content">{{this.prescription.bilirubin_adsorption_column}}</span>
350
+        </li>
351
+
352
+        <li v-if="isShow('吸氧')">
353
+          <label>吸氧:</label>
354
+          <span class="content">
355
+            <span v-if="this.prescription.oxygen_uptake == 1">需</span>
356
+            <span v-if="this.prescription.oxygen_uptake == 2">无</span>
357
+           </span>
358
+        </li>
359
+
360
+       <li v-if="isShow('吸氧')">
361
+          <label>吸氧流量(L/分):</label>
362
+          <span class="content">
363
+            <span>{{this.prescription.oxygen_flow}}</span>
364
+           </span>
365
+        </li>
366
+       
367
+        <li v-if="isShow('吸氧')">
368
+          <label>吸氧时长(h):</label>
369
+          <span class="content">
370
+            <span>{{this.prescription.oxygen_time}}</span>
371
+           </span>
372
+        </li>
373
+       
326 374
       </ul>
327 375
     </div>
328 376
     <div style="color:#34495e;margin: 12px 100px 0 100px;">备注: <span style="color:#409eff;">{{ note }}</span></div>
@@ -551,7 +599,7 @@ export default {
551 599
               if(arr[i] == this.preparestock[j].specification_name){
552 600
                 if(this.preparestock[j].commdity_code!=""){
553 601
                   arr[i] = arr[i]+"("+this.preparestock[j].commdity_code+")"
554
-                } 
602
+                }
555 603
               }
556 604
            }
557 605
          }
@@ -638,7 +686,7 @@ export default {
638 686
     displace_speed:function(){
639 687
       return this.getValueStr('displace_speed','displace_speed')
640 688
     },
641
-   
689
+
642 690
   },
643 691
   created() {
644 692
 

+ 3 - 0
src/xt_pages/dialysis/details/NavIgation.vue Целия файл

@@ -147,6 +147,7 @@
147 147
       :admins="admin_users"
148 148
       :device_numbers="device_numbers"
149 149
       :special_premission="special_premission"
150
+      :patient="patient"
150 151
     ></computer-dialog>
151 152
 
152 153
     <monitor-dialog
@@ -154,6 +155,7 @@
154 155
       ref="monitor_dialog"
155 156
       :monitors="monitor_records"
156 157
       @monitor="add_monitor"
158
+      :patient="patient"
157 159
     ></monitor-dialog>
158 160
 
159 161
     <finish-dialog
@@ -165,6 +167,7 @@
165 167
       :prescription="prescription"
166 168
       @assessmentAfterDislysis="assessmentAfterDislysisFunc"
167 169
       :special_premission="special_premission"
170
+      :patient="patient"
168 171
     ></finish-dialog>
169 172
 
170 173
     <assessment-after-dislysis

+ 3 - 2
src/xt_pages/dialysis/details/assessmentAfter.vue Целия файл

@@ -40,7 +40,7 @@
40 40
         <li v-if="isShow('实际置换量')">
41 41
           <label>实际置换量 : </label>
42 42
           <span class="content">{{ actual_displacement }}</span>
43
-          <span class="unit" v-if="this.$store.getters.xt_user.template_info.template_id != 13">ml</span>
43
+          <span class="unit" v-if="this.$store.getters.xt_user.template_info.template_id != 13 || this.$store.getters.xt_user.template_info.template_id == 40">ml</span>
44 44
           <span class="unit" v-else>L</span>
45 45
         </li>
46 46
         <li v-if="isShow('压迫后内瘘震颤')">
@@ -190,7 +190,8 @@
190 190
         <li v-if="isShow('透析中进食')">
191 191
           <label>透析中进食: </label>
192 192
           <span class="content" >{{ this.record.dialysis_during ? this.record.dialysis_during : ""  }}</span>
193
-          <span class="unit">{{ this.record.dialysis_during ? "ml" : "" }}</span>
193
+          <span class="unit" v-if="this.$store.getters.xt_user.template_info.template_id != 36">{{ this.record.dialysis_during ? "ml" : "" }}</span>
194
+          <span class="unit" v-if="this.$store.getters.xt_user.template_info.template_id == 36">{{ this.record.dialysis_during ? "g" : "" }}</span>
194 195
         </li>
195 196
       </ul>
196 197
       <ul>

+ 6 - 0
src/xt_pages/dialysis/details/assessmentBefore.vue Целия файл

@@ -363,6 +363,12 @@
363 363
           <span class="content">{{this.record.estimated_food_intake}}</span>
364 364
           <span class="unit"></span>
365 365
         </li>
366
+
367
+       <li v-if="isShow('透析期间血压')">
368
+          <label>透析期间血压: </label>
369
+          <span class="content">{{this.record.blood_pressure_during_dialysis}}</span>
370
+          <span class="unit"></span>
371
+        </li>
366 372
        
367 373
       </ul>
368 374
     </div>

+ 7 - 3
src/xt_pages/dialysis/details/dialog/AssessmentAfterDislysis.vue Целия файл

@@ -384,7 +384,10 @@
384 384
         </el-col>
385 385
 
386 386
         <el-col :span="8" v-if="isShow('透析中进食')">
387
-          <el-form-item label="透析中进食(ml): ">
387
+          <el-form-item label="透析中进食(ml): " v-if="template_id != 36">
388
+            <el-input v-model="form.dialysis_during"></el-input>
389
+          </el-form-item>
390
+          <el-form-item label="透析中进食(g): " v-if="template_id == 36">
388 391
             <el-input v-model="form.dialysis_during"></el-input>
389 392
           </el-form-item>
390 393
         </el-col>
@@ -429,7 +432,7 @@
429 432
         <el-row :gutter="20"> -->
430 433
 
431 434
         <el-col :span="8" v-if="isShow('实际置换量')">
432
-          <el-form-item v-if="this.template_id == 20 || this.template_id == 21" label="实际置换量(ml): ">
435
+          <el-form-item v-if="this.template_id == 20 || this.template_id == 21 || this.template_id == 40" label="实际置换量(ml): ">
433 436
             <el-input v-model="form.actual_displacement"></el-input>
434 437
           </el-form-item>
435 438
           <el-form-item v-else label="实际置换量(L): ">
@@ -709,6 +712,7 @@ import MultiSelectBox from './MultiSelectBox'
709 712
 import { postAssessmentAfterDislysis } from '@/api/dialysis'
710 713
 import { uParseTime } from '@/utils/tools'
711 714
 import store from '@/store'
715
+import { parseTime } from '@/utils'
712 716
 
713 717
 import request from '@/utils/request'
714 718
 
@@ -1353,7 +1357,7 @@ export default {
1353 1357
     this.channels = this.$store.getters.channels
1354 1358
 
1355 1359
     var date = this.$route.query && this.$route.query.date
1356
-    this.record_date = uParseTime(date, '{y}-{m}-{d}')
1360
+    this.record_date = date ? uParseTime(date, '{y}-{m}-{d}') : parseTime(new Date(), '{y}-{m}-{d}')
1357 1361
   },
1358 1362
   components: {
1359 1363
     MultiSelectBox

+ 2 - 2
src/xt_pages/dialysis/details/dialog/DoctorAdviceDialog.vue Целия файл

@@ -2430,7 +2430,7 @@
2430 2430
                 obj.type = 2
2431 2431
                 obj.custom_id = this.rand(10000000, 99999999)
2432 2432
                 obj.drug_specs = medicalList[i].drug_specs
2433
-                console.log("222",this.all_drug)
2433
+                // console.log("222",this.all_drug)
2434 2434
                 this.all_drug.push(obj)
2435 2435
               }
2436 2436
             }
@@ -2467,7 +2467,7 @@
2467 2467
                 obj.custom_id = this.rand(10000000, 99999999)
2468 2468
                 obj.drug_specs = base_drug_list[i].drug_specs
2469 2469
                 this.all_drug.push(obj)
2470
-                console.log("2222",this.all_drug)
2470
+                // console.log("2222",this.all_drug)
2471 2471
               }
2472 2472
             }
2473 2473
         })

+ 3 - 1
src/xt_pages/dialysis/details/dialog/acceptsTreatmentDialog.vue Целия файл

@@ -255,6 +255,7 @@ import { postAccepts } from "@/api/dialysis";
255 255
 import { uParseTime } from "@/utils/tools";
256 256
 import store from "@/store";
257 257
 import { getDataConfig } from "@/utils/data";
258
+import { parseTime } from '@/utils'
258 259
 
259 260
 import request from "@/utils/request";
260 261
 
@@ -488,7 +489,8 @@ export default {
488 489
   created() {
489 490
     // console.log("接诊评估", this.receiver_treatment_access);
490 491
     var date = this.$route.query && this.$route.query.date;
491
-    this.record_date = uParseTime(date, "{y}-{m}-{d}");
492
+    this.record_date = date ? uParseTime(date, "{y}-{m}-{d}") : parseTime(new Date(), '{y}-{m}-{d}');
493
+    console.log('this.record_date',this.record_date)
492 494
 
493 495
     this.way_arr = getDataConfig("hemodialysis", "way");
494 496
     this.consciousness_arr = getDataConfig("hemodialysis", "consciousness");

+ 9 - 1
src/xt_pages/dialysis/details/dialog/assessmentBeforeDislysisDialog.vue Целия файл

@@ -570,6 +570,12 @@
570 570
              <el-input v-model="assessmentBeforeDislysis.estimated_food_intake"></el-input>
571 571
             </el-form-item>
572 572
           </el-col>
573
+
574
+         <el-col :span="8">
575
+            <el-form-item label="透析期间血压:" v-if="isShow('透析期间血压')">
576
+             <el-input v-model="assessmentBeforeDislysis.blood_pressure_during_dialysis"></el-input>
577
+            </el-form-item>
578
+          </el-col>
573 579
          
574 580
           <el-col :span="24">
575 581
             <el-form-item label="备注: ">
@@ -626,6 +632,7 @@
626 632
   import { postAssessmentBeforeDislysis, CreateDryWeight } from '@/api/dialysis'
627 633
   import store from '@/store'
628 634
   import { uParseTime } from '@/utils/tools'
635
+  import { parseTime } from '@/utils'
629 636
 
630 637
   import request from '@/utils/request'
631 638
 
@@ -737,6 +744,7 @@
737 744
           pre_dialysis_drugs:"",
738 745
           period:"",
739 746
           estimated_food_intake:"",
747
+          blood_pressure_during_dialysis:"",
740 748
         },
741 749
 
742 750
         InnerDialogProps: {
@@ -1310,7 +1318,7 @@
1310 1318
 
1311 1319
       this.blood_access_noise = this.$store.getters.blood_access_noise
1312 1320
       var date = this.$route.query && this.$route.query.date
1313
-      this.record_date = uParseTime(date, '{y}-{m}-{d}')
1321
+      this.record_date = date ? uParseTime(date, "{y}-{m}-{d}") : parseTime(new Date(), '{y}-{m}-{d}')
1314 1322
       //获取皮肤
1315 1323
       this.skins = getDataConfig('hemodialysis','skin')
1316 1324
       console.log("皮肤",this.skins)

+ 10 - 1
src/xt_pages/dialysis/details/dialog/computer_dialog.vue Целия файл

@@ -140,6 +140,9 @@
140 140
       },
141 141
       special_premission: {
142 142
         type: Array
143
+      },
144
+      patient:{
145
+        type: Object
143 146
       }
144 147
     }, mounted() {
145 148
 
@@ -161,6 +164,12 @@
161 164
      
162 165
     },
163 166
     watch: {
167
+      patient:{
168
+        handler(newVal){
169
+          this.patient_id = newVal.id
170
+        },
171
+        deep:true
172
+      },
164 173
       'schedule.id': function() {
165 174
       },
166 175
       'dialysis_order.id': function() {
@@ -347,7 +356,7 @@
347 356
         this.loading = true
348 357
         let mode = '1'
349 358
 
350
-        startDialysis(this.patient_id, parseTime(this.schedule_date, '{y}-{m}-{d}'), this.form.nurse_id, this.form.bed_id, this.form.lood_drawing, this.form.puncture_nurse_id, this.form.start_time, this.schedual_type, mode,this.form.washpipe_nurse,this.form.change_nurse,this.form.difficult_puncture_nurse,this.form.new_fistula_nurse).then(rs => {
359
+        startDialysis(this.patient_id, this.schedule_date ? parseTime(this.schedule_date, '{y}-{m}-{d}') : parseTime(new Date(), '{y}-{m}-{d}'), this.form.nurse_id, this.form.bed_id, this.form.lood_drawing, this.form.puncture_nurse_id, this.form.start_time, this.schedual_type, mode,this.form.washpipe_nurse,this.form.change_nurse,this.form.difficult_puncture_nurse,this.form.new_fistula_nurse).then(rs => {
351 360
           this.loading = false
352 361
           var resp = rs.data
353 362
           if (resp.state == 1) {

+ 206 - 45
src/xt_pages/dialysis/details/dialog/dialysisPrescriptionDialog.vue Целия файл

@@ -87,7 +87,7 @@
87 87
           </el-col>
88 88
 
89 89
           <el-col :span="8"
90
-                  v-if="isShows('目标超滤量') && (this.$store.getters.xt_user.template_info.template_id == 17 || this.$store.getters.xt_user.template_info.template_id == 9 || this.$store.getters.xt_user.template_info.template_id == 20 || this.$store.getters.xt_user.template_info.template_id == 21 || this.$store.getters.xt_user.template_info.template_id == 22  || this.$store.getters.xt_user.template_info.template_id == 23 || this.$store.getters.xt_user.template_info.template_id == 24 || this.$store.getters.xt_user.template_info.template_id == 26 || this.$store.getters.xt_user.template_info.template_id == 28  || this.$store.getters.xt_user.template_info.template_id == 27 || this.$store.getters.xt_user.template_info.template_id == 29 || this.$store.getters.xt_user.template_info.template_id == 30 || this.$store.getters.xt_user.template_info.template_id == 31 || this.$store.getters.xt_user.template_info.template_id == 32 || this.$store.getters.xt_user.template_info.template_id == 34 || this.$store.getters.xt_user.template_info.template_id == 36 || this.$store.getters.xt_user.template_info.template_id == 38 || this.$store.getters.xt_user.template_info.org_id == 9555 )">
90
+                  v-if="isShows('目标超滤量') && (this.$store.getters.xt_user.template_info.template_id == 17 || this.$store.getters.xt_user.template_info.template_id == 9 || this.$store.getters.xt_user.template_info.template_id == 20 || this.$store.getters.xt_user.template_info.template_id == 21 || this.$store.getters.xt_user.template_info.template_id == 22  || this.$store.getters.xt_user.template_info.template_id == 23 || this.$store.getters.xt_user.template_info.template_id == 24 || this.$store.getters.xt_user.template_info.template_id == 26 || this.$store.getters.xt_user.template_info.template_id == 28  || this.$store.getters.xt_user.template_info.template_id == 27 || this.$store.getters.xt_user.template_info.template_id == 29 || this.$store.getters.xt_user.template_info.template_id == 30 || this.$store.getters.xt_user.template_info.template_id == 31 || this.$store.getters.xt_user.template_info.template_id == 32 || this.$store.getters.xt_user.template_info.template_id == 34 || this.$store.getters.xt_user.template_info.template_id == 36 || this.$store.getters.xt_user.template_info.template_id == 38 ||  this.$store.getters.xt_user.template_info.template_id == 40 || this.$store.getters.xt_user.template_info.org_id == 9555 )">
91 91
             <el-form-item label="目标超滤量(ml):">
92 92
               <el-input
93 93
                 type="number"
@@ -96,8 +96,10 @@
96 96
             </el-form-item>
97 97
           </el-col>
98 98
 
99
+
100
+
99 101
           <el-col :span="8"
100
-                  v-if="isShows('目标超滤量')  && this.$store.getters.xt_user.template_info.template_id != 17 && this.$store.getters.xt_user.template_info.template_id != 9 && this.$store.getters.xt_user.template_info.template_id != 20 && this.$store.getters.xt_user.template_info.template_id != 21 && this.$store.getters.xt_user.template_info.template_id != 22 && this.$store.getters.xt_user.template_info.template_id != 23 && this.$store.getters.xt_user.template_info.template_id != 24 && this.$store.getters.xt_user.template_info.template_id != 26 && this.$store.getters.xt_user.template_info.template_id != 28 && this.$store.getters.xt_user.template_info.template_id != 27 && this.$store.getters.xt_user.template_info.template_id != 29 && this.$store.getters.xt_user.template_info.template_id != 30 && this.$store.getters.xt_user.template_info.template_id != 31 && this.$store.getters.xt_user.template_info.template_id != 32 && this.$store.getters.xt_user.template_info.template_id != 34 && this.$store.getters.xt_user.template_info.template_id != 36 && this.$store.getters.xt_user.template_info.template_id != 38 && this.$store.getters.xt_user.template_info.org_id != 9555 ">
102
+                  v-if="isShows('目标超滤量')  && this.$store.getters.xt_user.template_info.template_id != 17 && this.$store.getters.xt_user.template_info.template_id != 9 && this.$store.getters.xt_user.template_info.template_id != 20 && this.$store.getters.xt_user.template_info.template_id != 21 && this.$store.getters.xt_user.template_info.template_id != 22 && this.$store.getters.xt_user.template_info.template_id != 23 && this.$store.getters.xt_user.template_info.template_id != 24 && this.$store.getters.xt_user.template_info.template_id != 26 && this.$store.getters.xt_user.template_info.template_id != 28 && this.$store.getters.xt_user.template_info.template_id != 27 && this.$store.getters.xt_user.template_info.template_id != 29 && this.$store.getters.xt_user.template_info.template_id != 30 && this.$store.getters.xt_user.template_info.template_id != 31 && this.$store.getters.xt_user.template_info.template_id != 32 && this.$store.getters.xt_user.template_info.template_id != 34 && this.$store.getters.xt_user.template_info.template_id != 36 && this.$store.getters.xt_user.template_info.template_id != 38 &&  this.$store.getters.xt_user.template_info.template_id != 40 && this.$store.getters.xt_user.template_info.org_id != 9555 ">
101 103
             <el-form-item label="目标超滤量(L):">
102 104
               <el-input
103 105
                 type="number"
@@ -106,6 +108,19 @@
106 108
             </el-form-item>
107 109
           </el-col>
108 110
 
111
+
112
+          <el-col :span="8" v-if="isShows('单超时长')">
113
+             <el-form-item label="单超时长(h):">
114
+                <el-input v-model="dialysisPrescription.single_time"></el-input>
115
+             </el-form-item>
116
+          </el-col>
117
+
118
+          <el-col :span="8" v-if="isShows('单超脱水')">
119
+             <el-form-item label="单超脱水(L):">
120
+                <el-input v-model="dialysisPrescription.single_water"></el-input>
121
+             </el-form-item>
122
+          </el-col>
123
+
109 124
           <el-col :span="8" v-if="isShows('透析液配方')">
110 125
             <el-form-item label="透析液配方:">
111 126
               <!-- <el-input type="number" v-model="dialysisPrescription.dialysate_formulation"></el-input> -->
@@ -183,51 +198,83 @@
183 198
           </el-col>
184 199
 
185 200
           <el-col :span="8" v-if="anticoagulant.shouji != -1 && isShows('首剂')">
186
-
187
-            <el-form-item v-if='this.$store.getters.xt_user.template_info.template_id != 21 && this.$store.getters.xt_user.template_info.template_id != 23 && this.$store.getters.xt_user.template_info.org_id != 9987' :label="'首剂(' + anticoagulant.shouji_unit + ') : '">
188
-              <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
189
-                        v-model="dialysisPrescription.anticoagulant_shouji"></el-input>
190
-              <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
191
-                        v-model="dialysisPrescription.no_anticoagulant_shouji"></el-input>
192
-            </el-form-item>
193
-
194
-            <el-form-item v-if='this.$store.getters.xt_user.template_info.template_id == 21 || this.$store.getters.xt_user.template_info.template_id == 23 || this.$store.getters.xt_user.template_info.org_id == 9987' :label="'首剂(mg) : '">
195
-              <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
196
-                        v-model="dialysisPrescription.anticoagulant_shouji"></el-input>
197
-              <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
198
-                        v-model="dialysisPrescription.no_anticoagulant_shouji"></el-input>
199
-            </el-form-item>
201
+            <div v-if="this.$store.getters.xt_user.template_info.org_id != 10157">
202
+              <el-form-item v-if='this.$store.getters.xt_user.template_info.template_id != 21 && this.$store.getters.xt_user.template_info.template_id != 23 && this.$store.getters.xt_user.template_info.org_id != 9987 ' :label="'首剂(' + anticoagulant.shouji_unit + ') : '">
203
+                <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
204
+                          v-model="dialysisPrescription.anticoagulant_shouji"></el-input>
205
+                <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
206
+                          v-model="dialysisPrescription.no_anticoagulant_shouji"></el-input>
207
+              </el-form-item>
208
+
209
+              <el-form-item v-if='this.$store.getters.xt_user.template_info.template_id == 21 || this.$store.getters.xt_user.template_info.template_id == 23 || this.$store.getters.xt_user.template_info.org_id == 9987' :label="'首剂(mg) : '">
210
+                <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
211
+                          v-model="dialysisPrescription.anticoagulant_shouji"></el-input>
212
+                <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
213
+                          v-model="dialysisPrescription.no_anticoagulant_shouji"></el-input>
214
+              </el-form-item>
215
+            </div>
216
+            <div v-else>
217
+              <el-form-item :label="'首剂(mg) : '">
218
+                <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
219
+                          v-model="dialysisPrescription.anticoagulant_shouji"></el-input>
220
+                <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
221
+                          v-model="dialysisPrescription.no_anticoagulant_shouji"></el-input>
222
+              </el-form-item>
223
+            </div>
224
+            
200 225
           </el-col>
201 226
 
202 227
 
203 228
           <el-col :span="8" v-if="anticoagulant.weichi != -1 && isShows('维持')">
204
-            <el-form-item :label="'维持(' + anticoagulant.weichi_unit + ') : '" v-if="anticoagulant.weichi != -1 && this.$store.getters.xt_user.template_info.template_id != 21 && this.$store.getters.xt_user.template_info.template_id != 23 && this.$store.getters.xt_user.template_info.org_id != 9987">
205
-              <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
206
-                        v-model="dialysisPrescription.anticoagulant_weichi"></el-input>
207
-              <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
208
-                        v-model="dialysisPrescription.no_anticoagulant_weichi"></el-input>
209
-            </el-form-item>
210
-            <el-form-item :label="'维持(mg/h) : '" v-if="anticoagulant.weichi != -1 && this.$store.getters.xt_user.template_info.template_id == 21 || this.$store.getters.xt_user.template_info.template_id == 23 || this.$store.getters.xt_user.template_info.org_id == 9987">
211
-              <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
212
-                        v-model="dialysisPrescription.anticoagulant_weichi"></el-input>
213
-              <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
214
-                        v-model="dialysisPrescription.no_anticoagulant_weichi"></el-input>
215
-            </el-form-item>
229
+              <div v-if="this.$store.getters.xt_user.template_info.org_id != 10157">
230
+                <el-form-item :label="'维持(' + anticoagulant.weichi_unit + ') : '" v-if="anticoagulant.weichi != -1 && this.$store.getters.xt_user.template_info.template_id != 21 && this.$store.getters.xt_user.template_info.template_id != 23 && this.$store.getters.xt_user.template_info.org_id != 9987">
231
+                  <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
232
+                            v-model="dialysisPrescription.anticoagulant_weichi"></el-input>
233
+                  <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
234
+                            v-model="dialysisPrescription.no_anticoagulant_weichi"></el-input>
235
+                </el-form-item>
236
+                <el-form-item :label="'维持(mg/h) : '" v-if="anticoagulant.weichi != -1 && this.$store.getters.xt_user.template_info.template_id == 21 || this.$store.getters.xt_user.template_info.template_id == 23 || this.$store.getters.xt_user.template_info.org_id == 9987">
237
+                  <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
238
+                            v-model="dialysisPrescription.anticoagulant_weichi"></el-input>
239
+                  <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
240
+                            v-model="dialysisPrescription.no_anticoagulant_weichi"></el-input>
241
+                </el-form-item>
242
+              </div>
243
+              <div v-else>
244
+                <el-form-item :label="'维持(mg/h) : '">
245
+                  <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
246
+                            v-model="dialysisPrescription.anticoagulant_weichi"></el-input>
247
+                  <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
248
+                            v-model="dialysisPrescription.no_anticoagulant_weichi"></el-input>
249
+                </el-form-item>
250
+              </div>
251
+            
216 252
           </el-col>
217 253
 
218 254
           <el-col :span="8" v-if="anticoagulant.zongliang != -1 && isShows('总量')">
219
-            <el-form-item v-if='this.$store.getters.xt_user.template_info.template_id != 21 && this.$store.getters.xt_user.template_info.template_id != 23 && this.$store.getters.xt_user.template_info.org_id != 9987' :label="'总量(' + anticoagulant.zongliang_unit + ') : '">
220
-              <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
221
-                        v-model="dialysisPrescription.anticoagulant_zongliang"></el-input>
222
-              <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
223
-                        v-model="dialysisPrescription.no_anticoagulant_zongliang"></el-input>
224
-            </el-form-item>
225
-            <el-form-item v-if='this.$store.getters.xt_user.template_info.template_id == 21 || this.$store.getters.xt_user.template_info.template_id == 23 || this.$store.getters.xt_user.template_info.org_id == 9987' :label="'总量(mg) : '">
226
-              <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
227
-                        v-model="dialysisPrescription.anticoagulant_zongliang"></el-input>
228
-              <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
229
-                        v-model="dialysisPrescription.no_anticoagulant_zongliang"></el-input>
230
-            </el-form-item>
255
+            <div v-if="this.$store.getters.xt_user.template_info.org_id != 10157">
256
+              <el-form-item v-if='this.$store.getters.xt_user.template_info.template_id != 21 && this.$store.getters.xt_user.template_info.template_id != 23 && this.$store.getters.xt_user.template_info.org_id != 9987' :label="'总量(' + anticoagulant.zongliang_unit + ') : '">
257
+                <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
258
+                          v-model="dialysisPrescription.anticoagulant_zongliang"></el-input>
259
+                <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
260
+                          v-model="dialysisPrescription.no_anticoagulant_zongliang"></el-input>
261
+              </el-form-item>
262
+              <el-form-item v-if='this.$store.getters.xt_user.template_info.template_id == 21 || this.$store.getters.xt_user.template_info.template_id == 23 || this.$store.getters.xt_user.template_info.org_id == 9987' :label="'总量(mg) : '">
263
+                <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
264
+                          v-model="dialysisPrescription.anticoagulant_zongliang"></el-input>
265
+                <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
266
+                          v-model="dialysisPrescription.no_anticoagulant_zongliang"></el-input>
267
+              </el-form-item>
268
+            </div>
269
+            <div v-else>
270
+              <el-form-item :label="'总量(mg) : '">
271
+                <el-input type="number" v-if="dialysisPrescription.anticoagulant != 1"
272
+                          v-model="dialysisPrescription.anticoagulant_zongliang"></el-input>
273
+                <el-input type="number" disabled v-if="dialysisPrescription.anticoagulant == 1"
274
+                          v-model="dialysisPrescription.no_anticoagulant_zongliang"></el-input>
275
+              </el-form-item>
276
+            </div>
277
+            
231 278
           </el-col>
232 279
 
233 280
 
@@ -243,7 +290,7 @@
243 290
               ></el-input>
244 291
             </el-form-item>
245 292
           </el-col>
246
-          <el-col :span="8" v-if="isShows('置换量') && this.$store.getters.xt_user.template_info.template_id != 20 && this.$store.getters.xt_user.template_info.template_id != 28 && this.$store.getters.xt_user.template_info.template_id != 29"
293
+          <el-col :span="8" v-if="isShows('置换量') && this.$store.getters.xt_user.template_info.template_id != 20 && this.$store.getters.xt_user.template_info.template_id != 28 && this.$store.getters.xt_user.template_info.template_id != 29 && this.$store.getters.xt_user.template_info.template_id != 40" 
247 294
                   v-show="zhiShow">
248 295
             <el-form-item label="置换量(L):">
249 296
               <el-input
@@ -381,6 +428,20 @@
381 428
              </el-form-item>
382 429
           </el-col>
383 430
 
431
+          <el-col :span="8" v-if="isShows('血浆分离器')">
432
+             <el-form-item label="血浆分离器:">
433
+                  <el-input v-model="dialysisPrescription.plasma_separator" @focus="showInnerDialog('9')"></el-input>
434
+             </el-form-item>
435
+          </el-col>
436
+
437
+         
438
+         <el-col :span="8" v-if="isShows('胆红素吸附柱')">
439
+             <el-form-item label="胆红素吸附柱:">
440
+                  <el-input v-model="dialysisPrescription.bilirubin_adsorption_column" @focus="showInnerDialog('10')"></el-input>
441
+             </el-form-item>
442
+         </el-col>
443
+
444
+
384 445
           <el-col :span="8" v-if="isShows('体液过多症状')">
385 446
             <el-form-item label="体液过多症状:">
386 447
               <el-select
@@ -547,6 +608,40 @@
547 608
              </el-form-item>
548 609
           </el-col>
549 610
 
611
+        
612
+          <el-col :span="8" v-if="isShows('置换流量')">
613
+             <el-form-item label="置换流量(L/h):">
614
+                <el-input v-model="dialysisPrescription.replacement_flow"></el-input>
615
+             </el-form-item>
616
+          </el-col>
617
+
618
+          <el-col :span="8" v-if="isShows('吸氧')">
619
+              <el-form-item label="吸氧:">
620
+                <el-select v-model="dialysisPrescription.oxygen_uptake" placeholder="请选择" @change="changeOxygenList">
621
+                <el-option :key="0" label="请选择" :value="0"></el-option>
622
+                <el-option
623
+                  v-for="(item, index) in  oxygenList "
624
+                  :key="index"
625
+                  :label="item.name"
626
+                  :value="item.id"
627
+                ></el-option>
628
+              </el-select>
629
+            </el-form-item>
630
+          </el-col>
631
+
632
+          
633
+           <el-col :span="8" v-if="isShows('吸氧') && oxygenShow == true">
634
+             <el-form-item label="吸氧流量(L/分):">
635
+                <el-input v-model="dialysisPrescription.oxygen_flow"></el-input>
636
+             </el-form-item>
637
+          </el-col>
638
+         
639
+         <el-col :span="8" v-if="isShows('吸氧') && oxygenShow == true">
640
+             <el-form-item label="吸氧时长(h):">
641
+                <el-input v-model="dialysisPrescription.oxygen_time"></el-input>
642
+             </el-form-item>
643
+          </el-col>
644
+       
550 645
         </el-row>
551 646
 
552 647
         <el-row :gutter="20">
@@ -1042,6 +1137,14 @@
1042 1137
           displace_speed:"",
1043 1138
           illness:"",
1044 1139
           amylaceum:"",
1140
+          single_time:"",
1141
+          single_water:"",
1142
+          replacement_flow:"",
1143
+          plasma_separator:"",
1144
+          bilirubin_adsorption_column:"",
1145
+          oxygen_uptake:"",
1146
+          oxygen_flow:"",
1147
+          oxygen_time:"",
1045 1148
         },
1046 1149
 
1047 1150
         anticoagulant: {
@@ -1065,10 +1168,27 @@
1065 1168
         bloods:[],
1066 1169
         irrigations:[],
1067 1170
         dialyzers:[],
1068
-        illnessList:[]
1171
+        illnessList:[],
1172
+        plasmaSeparatorList:[],
1173
+        bilirubinAdsorptionColumn:[],
1174
+        oxygenList:[
1175
+         {id:1,name:"需"},
1176
+         {id:2,name:"无"}
1177
+        ],
1178
+        oxygenShow:false,
1069 1179
       }
1070 1180
     },
1071 1181
     methods: {
1182
+      changeOxygenList(val){
1183
+          if(val == 1){
1184
+            this.oxygenShow = true
1185
+          }
1186
+          if(val == 2){
1187
+            this.oxygenShow = false
1188
+            this.prescription.oxygen_flow = ""
1189
+            this.prescription.oxygen_time = ""
1190
+          }
1191
+       },
1072 1192
       changeTime:function(val){
1073 1193
         this.advice_start_time = val
1074 1194
 
@@ -1150,6 +1270,25 @@
1150 1270
             this.InnerDialogProps.selected = this.dialysisPrescription.dialysis_irrigation
1151 1271
             this.InnerDialogProps.isShowTextArea = false
1152 1272
             break
1273
+           case '9': // 血浆灌流器
1274
+
1275
+           
1276
+            this.InnerDialogProps.values = this.plasmaSeparatorList
1277
+            this.InnerDialogProps.titles = '血浆灌流器'
1278
+            this.InnerDialogProps.type = 'plasma_separator'
1279
+            this.InnerDialogProps.selected = this.dialysisPrescription.plasma_separator
1280
+            this.InnerDialogProps.isShowTextArea = false
1281
+            break
1282
+
1283
+           case '10': // 胆红素吸附柱
1284
+
1285
+           
1286
+            this.InnerDialogProps.values = this.bilirubinAdsorptionColumn
1287
+            this.InnerDialogProps.titles = '胆红素吸附柱'
1288
+            this.InnerDialogProps.type = 'bilirubin_adsorption_column'
1289
+            this.InnerDialogProps.selected = this.dialysisPrescription.bilirubin_adsorption_column
1290
+            this.InnerDialogProps.isShowTextArea = false
1291
+            break
1153 1292
         }
1154 1293
       },
1155 1294
       innerDialogComfirm: function(val) {
@@ -1167,6 +1306,12 @@
1167 1306
           case 'irrigations':
1168 1307
            this.dialysisPrescription.dialysis_irrigation = val.value.join(',')
1169 1308
           break
1309
+          case 'plasma_separator':
1310
+          this.dialysisPrescription.plasma_separator = val.value.join(',')
1311
+          break
1312
+          case 'bilirubin_adsorption_column':
1313
+          this.dialysisPrescription.bilirubin_adsorption_column = val.value.join(',')
1314
+          break
1170 1315
         }
1171 1316
       },
1172 1317
       innerDialogCancle: function() {
@@ -1618,7 +1763,17 @@
1618 1763
         return uParseTime(val, '{y}-{m}-{d} {h}:{i}')
1619 1764
       },
1620 1765
       show(pre,schedual,last,his_is_open) {
1621
-        
1766
+        console.log("pre222222",pre)
1767
+        if(pre!=undefined){
1768
+          if(pre.oxygen_uptake == 1){
1769
+             this.oxygenShow = true
1770
+          }
1771
+        if(pre.oxygen_uptake == 2){
1772
+            this.oxygenShow = false
1773
+            this.prescription.oxygen_flow = ""
1774
+            this.prescription.oxygen_time = ""
1775
+         }
1776
+        }
1622 1777
         if(his_is_open == 1){
1623 1778
           this.is_open = 0
1624 1779
         }
@@ -1657,6 +1812,7 @@
1657 1812
         if (pre.anticoagulant == 3) {
1658 1813
           this.dialysisPrescription.anticoagulant = '低分子肝素'
1659 1814
         }
1815
+
1660 1816
         // 入口
1661 1817
         var pre = pre
1662 1818
         this.dialysisPrescription.mode_id = this.$route.query.mode_id
@@ -3552,11 +3708,16 @@
3552 3708
         this.irrigations = irrigation
3553 3709
         console.log("透析器",this.dialyzers)
3554 3710
         console.log("灌流器",this.irrigations)
3555
-      }
3711
+      },
3556 3712
     },
3557 3713
     created(){
3714
+      
3558 3715
       this.illnessList = getDataConfig('hemodialysis','illness')
3559
-      console.log("列表22222222222",this.illnessList)
3716
+      
3717
+      this.plasmaSeparatorList = getDataConfig('hemodialysis','plasma_separator')
3718
+      
3719
+      this.bilirubinAdsorptionColumn = getDataConfig('hemodialysis','bilirubin_adsorption_column')
3720
+
3560 3721
     }
3561 3722
   }
3562 3723
 </script>

+ 9 - 6
src/xt_pages/dialysis/details/dialog/doubleCheckDialog.vue Целия файл

@@ -599,7 +599,7 @@
599 599
          } 
600 600
 
601 601
          if(str.indexOf('透析时长')!=-1 && this.prescription!=null){
602
-            arr.push("透析时长:"+(this.prescription.dialysis_duration?this.prescription.dialysis_duration:""))
602
+            arr.push("透析时长:"+(this.prescription.dialysis_duration_hour?this.prescription.dialysis_duration_hour:"") +"小时"+this.prescription.dialysis_duration_minute+"分")
603 603
          }
604 604
 
605 605
         if(str.indexOf('透析时长')!=-1 && this.prescription==null){
@@ -930,9 +930,12 @@
930 930
       isVisibility(val) {
931 931
         
932 932
         if(this.prescription!=null && this.prescription.id!=0){
933
-
933
+          
934 934
           this.diazes = this.diazes + this.prescription.dialyzer_perfusion_apparatus
935
+          this.diazes = this.diazes + this.prescription.dialysis_dialyszers+this.prescription.dialysis_irrigation
935 936
           this.prescription.dialyzer_perfusion_apparatus = ""
937
+          this.prescription.dialysis_dialyszers = ""
938
+          this.prescription.dialysis_irrigation = ""
936 939
           this.dialysate_formulation = this.dialysate_formulation + this.GetDialysateFormulationById(this.prescription.dialysate_formulation)
937 940
           // this.prescription.dialysate_formulation = ""
938 941
           this.kalium = this.kalium + (this.prescription.kalium?this.prescription.kalium:"")
@@ -941,8 +944,8 @@
941 944
           this.prescription.calcium = ""
942 945
           this.dialys_mode = this.dialys_mode + this.getMode(this.prescription.mode_id)
943 946
           this.prescription.mode_id= ""
944
-          this.long_time = this.long_time + (this.prescription.dialysis_duration?this.prescription.dialysis_duration:"")
945
-          this.prescription.dialysis_duration=""
947
+          this.long_time = this.long_time + (this.prescription.dialysis_duration_hour?this.prescription.dialysis_duration_hour:"") +"小时" +this.prescription.dialysis_duration_minute +"分"
948
+          this.prescription.dialysis_duration_hour=""
946 949
           this.target_ultrafiltration = this.target_ultrafiltration + (this.prescription.target_ultrafiltration?this.prescription.target_ultrafiltration:"")
947 950
           this.prescription.target_ultrafiltration = ""
948 951
           this.anticoagulant = this.anticoagulant + this.getAnticoagulant(this.prescription.anticoagulant)
@@ -986,7 +989,7 @@
986 989
               this.checkListOne.push("透析模式:"+this.getMode(this.prescription.mode_id))
987 990
            }
988 991
            if(this.double_check.dialysis_parameter_desc.indexOf("透析时长")!=-1){
989
-              this.checkListOne.push("透析时长:"+(this.prescription.dialysis_duration?this.prescription.dialysate_formulation:""))
992
+              this.checkListOne.push("透析时长:"+(this.prescription.dialysis_duration_hour?this.prescription.dialysis_duration_hour:""))
990 993
            }
991 994
            if(this.double_check.dialysis_parameter_desc.indexOf("目标超滤量")!=-1){
992 995
               this.checkListOne.push("目标超滤量:"+(this.prescription.target_ultrafiltration?this.prescription.target_ultrafiltration:""))
@@ -1131,7 +1134,7 @@
1131 1134
     created() {
1132 1135
      
1133 1136
       var date = this.$route.query && this.$route.query.date
1134
-      this.record_date = uParseTime(date, '{y}-{m}-{d}')
1137
+      this.record_date = date ? uParseTime(date, '{y}-{m}-{d}') : parseTime(new Date(), '{y}-{m}-{d}')
1135 1138
 
1136 1139
       var nowDate = new Date()
1137 1140
       var nowYear = nowDate.getFullYear()

+ 14 - 2
src/xt_pages/dialysis/details/dialog/finish_dialog.vue Целия файл

@@ -84,6 +84,9 @@
84 84
       }, special_premission: {
85 85
         type: Array,
86 86
       },
87
+      patient:{
88
+        type: Object
89
+      }
87 90
     },
88 91
     created() {
89 92
 
@@ -97,6 +100,12 @@
97 100
         } else {
98 101
           this.form.nurse_id = this.dialysis_order.finish_nurse
99 102
         }
103
+      },
104
+      patient:{
105
+        handler(newVal){
106
+          this.patient_id = newVal.id
107
+        },
108
+        deep:true
100 109
       }
101 110
     },
102 111
     methods: {
@@ -117,7 +126,10 @@
117 126
           (nowMonth < 10 ? '0' + nowMonth : nowMonth) +
118 127
           '-' +
119 128
           (nowDay < 10 ? '0' + nowDay : nowDay) + ' ' + (nowHours < 10 ? '0' + nowHours : nowHours) + ':' + (nowMinutes < 10 ? '0' + nowMinutes : nowMinutes)
120
-        this.patient_id = this.$route.query.patient_id
129
+        if(this.$route.query.patient_id){
130
+          this.patient_id = this.$route.query.patient_id
131
+        }
132
+        
121 133
         this.schedule_date = this.$route.query.date
122 134
 
123 135
         if (this.dialysis_order.id == 0) {
@@ -203,7 +215,7 @@
203 215
       submit: function() {
204 216
         this.loading = true
205 217
         let mode = "1"
206
-        finishDialysis(this.patient_id, parseTime(this.schedule_date, '{y}-{m}-{d}'), this.end_time, this.form.nurse_id,mode).then(rs => {
218
+        finishDialysis(this.patient_id,this.schedule_date ? parseTime(this.schedule_date, '{y}-{m}-{d}') : parseTime(new Date(), '{y}-{m}-{d}'), this.end_time, this.form.nurse_id,mode).then(rs => {
207 219
           this.loading = false
208 220
           var resp = rs.data
209 221
           if (resp.state == 1) {

+ 19 - 3
src/xt_pages/dialysis/details/dialog/monitor_dialog.vue Целия файл

@@ -166,6 +166,8 @@
166 166
                   template_id == 35 ||
167 167
                   template_id == 36 ||
168 168
                   template_id == 38 ||
169
+                  template_id == 39 ||
170
+                  template_id == 40 ||
169 171
                   org_id == 9555)
170 172
             "
171 173
           >
@@ -208,6 +210,8 @@
208 210
                 template_id != 35 &&
209 211
                 template_id != 36 &&
210 212
                 template_id != 38 &&
213
+                template_id != 39 &&
214
+                template_id != 40 &&
211 215
                 org_id!=9555
212 216
             "
213 217
           >
@@ -923,6 +927,9 @@ export default {
923 927
   props: {
924 928
     monitors: {
925 929
       type: Array
930
+    },
931
+    patient:{
932
+      type: Object
926 933
     }
927 934
   },
928 935
   computed: {
@@ -935,9 +942,10 @@ export default {
935 942
     this.org_id = this.$store.getters.xt_user.template_info.org_id;
936 943
     var date = this.$route.query.date;
937 944
     var patient_id = this.$route.query.patient_id;
938
-    this.patient_id = patient_id;
939
-    this.schedule_date = date;
940
-    this.form.monitoring_date = date;
945
+    this.patient_id = patient_id ? patient_id : this.patient.id;
946
+    console.log('this.patient_id',this.patient_id)
947
+    this.schedule_date = date ? date : new Date(new Date().toLocaleDateString()).getTime() / 1000;
948
+    this.form.monitoring_date = date ? date : new Date(new Date().toLocaleDateString()).getTime() / 1000;
941 949
     // this.form.operate_date = parseInt((new Date()).getTime() / 1000)
942 950
     // this.form.monitoring_time = parseTime(new Date(), "{h}:{i}")
943 951
     this.form.operate_time = new Date().getTime();
@@ -1460,6 +1468,14 @@ export default {
1460 1468
       }
1461 1469
       return name
1462 1470
     }
1471
+  },
1472
+  watch:{
1473
+    patient:{
1474
+      handler(newVal){
1475
+        this.patient_id = newVal.id
1476
+      },
1477
+      deep:true
1478
+    }
1463 1479
   }
1464 1480
 }
1465 1481
 </script>

+ 1 - 0
src/xt_pages/dialysis/details/dialog/treatmentSummaryDialog.vue Целия файл

@@ -130,6 +130,7 @@ import { postTreatmentsummary } from '@/api/dialysis'
130 130
 import { uParseTime } from '@/utils/tools'
131 131
 import store from '@/store'
132 132
 import request from '@/utils/request'
133
+import { parseTime } from '@/utils'
133 134
 
134 135
 export default {
135 136
   name: 'treatmentSummaryDialog',

+ 4 - 4
src/xt_pages/dialysis/details/dialysisMonitoring.vue Целия файл

@@ -14,8 +14,8 @@
14 14
           <th width="76px">静脉压/动脉压({{monitores[0]&&monitores[0]['venous_pressure_type'] == 2 ? 'kpa' : 'mmHg'}})</th>
15 15
           <th v-if="isShow('血流量')" width="92px">血流量(ml/min)</th>
16 16
           <th v-if="isShow('跨膜压')" width="76px">跨膜压({{monitores[0]&&monitores[0]['transmembrane_pressure_type'] == 2 ? 'kpa' : 'mmHg'}})</th>
17
-          <th v-if=" isShow('超滤量') &&(template_id == 6 || template_id == 9 || template_id == 10 || template_id == 11 || template_id == 13 || template_id == 17 || template_id == 18 || template_id == 19 || template_id == 20 || template_id == 21 || template_id == 22 || template_id == 23 || template_id == 24 || template_id == 26 || template_id == 27 || template_id == 28 || template_id == 29 || template_id == 30 || template_id == 31 || template_id == 32 || template_id == 34 || template_id == 35 || template_id == 36 || template_id == 38 || this.$store.getters.xt_user.template_info.org_id == 9555)" width="76px" > 超滤量(ml)</th>
18
-          <th v-if=" isShow('超滤量') && template_id != 6 && template_id != 9 && template_id != 10 && template_id != 11 && template_id != 13 && template_id != 17 && template_id != 18 && template_id != 19 && template_id != 20 && template_id != 21 && template_id != 22 && template_id != 23 && template_id != 24 && template_id != 26 && template_id !=27 && template_id!=28 && template_id!=29 && template_id!=30 && template_id!=31 && template_id!=32 && template_id!=34 && template_id!=35 && template_id!=36 && template_id!=38 && this.$store.getters.xt_user.template_info.org_id != 9555"  width="76px"> 超滤量(L) </th>
17
+          <th v-if=" isShow('超滤量') &&(template_id == 6 || template_id == 9 || template_id == 10 || template_id == 11 || template_id == 13 || template_id == 17 || template_id == 18 || template_id == 19 || template_id == 20 || template_id == 21 || template_id == 22 || template_id == 23 || template_id == 24 || template_id == 26 || template_id == 27 || template_id == 28 || template_id == 29 || template_id == 30 || template_id == 31 || template_id == 32 || template_id == 34 || template_id == 35 || template_id == 36 || template_id == 38 || template_id == 39 || template_id == 40 || this.$store.getters.xt_user.template_info.org_id == 9555)" width="76px" > 超滤量(ml)</th>
18
+          <th v-if=" isShow('超滤量') && template_id != 6 && template_id != 9 && template_id != 10 && template_id != 11 && template_id != 13 && template_id != 17 && template_id != 18 && template_id != 19 && template_id != 20 && template_id != 21 && template_id != 22 && template_id != 23 && template_id != 24 && template_id != 26 && template_id !=27 && template_id!=28 && template_id!=29 && template_id!=30 && template_id!=31 && template_id!=32 && template_id!=34 && template_id!=35 && template_id!=36 && template_id!=38 && template_id != 39 && template_id == 40 && this.$store.getters.xt_user.template_info.org_id != 9555"  width="76px"> 超滤量(L) </th>
19 19
           <th v-if="isShow('超滤率') && (template_id ==6 || template_id == 10 || template_id == 11 || template_id == 12 || template_id == 13 || template_id == 17 || template_id == 18 || template_id == 19 || template_id == 20 || template_id == 21 || template_id == 22 || template_id == 23 || template_id == 24 || template_id == 26 || template_id == 29 || template_id == 30 || template_id == 31 || template_id == 34 || template_id == 35 || template_id == 38)" width="50px"> 超滤率 <br />(ml/h) </th>
20 20
           <th v-if="isShow('超滤率') && template_id !=6 && template_id !=10 && template_id !=11 && template_id !=12 && template_id !=13 && template_id !=17 && template_id !=18 && template_id !=19 && template_id !=20 && template_id !=21 && template_id !=22 && template_id !=23 && template_id !=24 && template_id !=26 && template_id !=29 && template_id !=30 && template_id !=31 && template_id !=34 && template_id !=35 && template_id !=38" width="50px"> 超滤率 <br />(L/h) </th>
21 21
           <th v-if="isShow('钠浓度')" width="92px">钠浓度(mmol/L)</th>
@@ -46,7 +46,7 @@
46 46
           <td v-if="isShow('脉搏')"> {{ monitor.pulse_frequency ? monitor.pulse_frequency : "" }} </td>
47 47
           <td v-if="isShow('呼吸频率')"> {{ monitor.breathing_rate ? monitor.breathing_rate : "" }} </td>
48 48
           <td> {{ monitor.venous_pressure ? monitor.venous_pressure : "" }} /{{ monitor.arterial_pressure ? monitor.arterial_pressure : "" }}  </td>
49
-          
49
+
50 50
           <td v-if="isShow('血流量')"> {{ monitor.blood_flow_volume ? monitor.blood_flow_volume : "" }} </td>
51 51
           <td v-if="isShow('跨膜压')"> {{ monitor.transmembrane_pressure ? monitor.transmembrane_pressure : "" }} </td>
52 52
           <td v-if="isShow('超滤量')"> {{ monitor.ultrafiltration_volume ? monitor.ultrafiltration_volume : "" }} </td>
@@ -59,7 +59,7 @@
59 59
           <td v-if="isShow('电导度')"> {{ monitor.conductivity ? monitor.conductivity : "" }} </td>
60 60
           <td v-if="isShow('置换液流量')"> {{ monitor.displacement_flow_quantity  ? monitor.displacement_flow_quantity : "" }} </td>
61 61
           <td v-if="isShow('透析液流量')"> {{ monitor.dialysate_flow  ? monitor.dialysate_flow : "" }} </td>
62
-          <td v-if="isShow('肝素用量余量')"> {{ monitor.heparin ? monitor.heparin : "" }} </td> 
62
+          <td v-if="isShow('肝素用量余量')"> {{ monitor.heparin ? monitor.heparin : "" }} </td>
63 63
           <td v-if="isShow('抗凝剂')">
64 64
             <span v-if="monitor.monitor_anticoagulant == 1">无肝素</span>
65 65
             <span v-if="monitor.monitor_anticoagulant == 2">普通肝素</span>

+ 10 - 0
src/xt_pages/dialysis/details/index.vue Целия файл

@@ -985,6 +985,13 @@ export default {
985 985
             if (prescription.body_fluid == -2) {
986 986
               prescription.body_fluid = 0
987 987
             }
988
+            if(prescription.bilirubin_adsorption_column == 0){
989
+               prescription.bilirubin_adsorption_column  = ""
990
+            }
991
+
992
+             if(prescription.plasma_separator == 0){
993
+               prescription.plasma_separator  = ""
994
+            }
988 995
           }
989 996
 
990 997
           var solution = resp.data.solution // 透析方案
@@ -997,6 +1004,9 @@ export default {
997 1004
             if (predialysis_evaluation.blood_access_part_id == -2) {
998 1005
               predialysis_evaluation.blood_access_part_id = 0
999 1006
             }
1007
+            if(predialysis_evaluation.blood_pressure_during_dialysis == 0){
1008
+              predialysis_evaluation.blood_pressure_during_dialysis = ""
1009
+            }
1000 1010
           }
1001 1011
           var doctor_advices = resp.data.doctor_advices // 临时医嘱
1002 1012
 

+ 3 - 2
src/xt_pages/dialysis/dialysisDoctorAdvice.vue Целия файл

@@ -2,13 +2,14 @@
2 2
   <div class="main-contain">
3 3
     <div class="position">
4 4
       <bread-crumb :crumbs="crumbs"></bread-crumb>
5
+      <div>
5 6
        <el-button
6 7
           size="small"
7 8
           icon="el-icon-printer"
8 9
           :disabled="selecting_schs.length == 0"
9 10
           @click="signPrintAction"
10 11
           type="primary"
11
-          style="float:right"
12
+          style="margin-right:10"
12 13
         >标签打印
13 14
       </el-button>
14 15
       <el-button
@@ -19,7 +20,7 @@
19 20
           type="primary"
20 21
           >医嘱打印
21 22
       </el-button>
22
-   
23
+    </div>
23 24
     </div>
24 25
     <div class="app-container">
25 26
       <!-- <div class="filter-container">

+ 24 - 0
src/xt_pages/dialysis/dialysisPrintOrder.vue Целия файл

@@ -553,6 +553,16 @@
553 553
           >打印</el-button
554 554
         >
555 555
       </template>
556
+      <template v-if="org_template_info.template_id == 40">
557
+        <el-button
558
+          :loading="loading"
559
+          size="small"
560
+          icon="el-icon-printer"
561
+          @click="printThisPage"
562
+          type="primary"
563
+          >打印</el-button
564
+        >
565
+      </template>
556 566
     </div>
557 567
     <div class="app-container" style="min-height:0;">
558 568
       <!--<div class="order-print-btn"-->
@@ -828,6 +838,11 @@
828 838
             v-if="org_template_info.template_id == 39"
829 839
           >
830 840
           </DialysisPrintOrderThirtyNine>
841
+          <DialysisPrintOrderForty
842
+            v-bind:childResponse="childResponse"
843
+            v-if="org_template_info.template_id == 40"
844
+          >
845
+          </DialysisPrintOrderForty>
831 846
         </div>
832 847
       </el-container>
833 848
     </div>
@@ -886,9 +901,11 @@ import DialysisPrintOrderThirtySix from "./template/DialysisPrintOrderThirtySix"
886 901
 import DialysisPrintOrderThirtySeven from "./template/DialysisPrintOrderThirtySeven";
887 902
 import DialysisPrintOrderThirtyEight from "./template/DialysisPrintOrderThirtyEight";
888 903
 import DialysisPrintOrderThirtyNine from "./template/DialysisPrintOrderThirtyNine";
904
+import DialysisPrintOrderForty from "./template/DialysisPrintOrderForty";
889 905
 export default {
890 906
   name: "dialysisPrintOrder",
891 907
   components: {
908
+    DialysisPrintOrderForty,
892 909
     DialysisPrintOrderThirtyNine,
893 910
     DialysisPrintOrderThirtyEight,
894 911
     DialysisPrintOrderThirtySeven,
@@ -1366,6 +1383,13 @@ export default {
1366 1383
           style: style3,
1367 1384
           scanStyles: false
1368 1385
         });
1386
+      } else if (this.org_template_info.template_id == 40) {
1387
+        printJS({
1388
+          printable: "dialysis-print-box",
1389
+          type: "html",
1390
+          style: style5,
1391
+          scanStyles: false
1392
+        });
1369 1393
       }
1370 1394
     },
1371 1395
     printThisOnePage() {

+ 10 - 10
src/xt_pages/dialysis/schedualPatient.vue Целия файл

@@ -280,13 +280,13 @@ import { getDialysisRecordInitData, getDialysisSchedules } from '@/api/dialysis_
280 280
     },
281 281
     created() {
282 282
       if(sessionStorage.getItem('signInKey') != null){
283
-        setTimeout(() => {    
283
+        setTimeout(() => {
284 284
           if(sessionStorage.getItem('signInKey') == 1){
285 285
             this.$router.replace({ path: '/signIn' })
286 286
           }
287 287
         },1000)
288 288
       }else if(sessionStorage.getItem('lineUpKey') != null){
289
-        setTimeout(() => { 
289
+        setTimeout(() => {
290 290
           if(sessionStorage.getItem('lineUpKey') == 1){
291 291
             this.$router.replace({ path: '/lineUp' })
292 292
           }
@@ -317,7 +317,7 @@ import { getDialysisRecordInitData, getDialysisSchedules } from '@/api/dialysis_
317 317
         data: {type:3,page:0,size:0},
318 318
       };
319 319
       this.websocketSend(this.initData)
320
-      
320
+
321 321
 
322 322
       this.getInitData()
323 323
 
@@ -353,7 +353,7 @@ import { getDialysisRecordInitData, getDialysisSchedules } from '@/api/dialysis_
353 353
       const timer = setInterval(() => {
354 354
         // this.getInitData();
355 355
         this.requestDialysisSchedules()
356
-      }, 1000 * 30)
356
+      }, 1000 * 60)
357 357
       // 通过$once来监听定时器,在beforeDestroy钩子可以被清除。
358 358
       this.$once('hook:beforeDestroy', () => {
359 359
         clearInterval(timer)
@@ -377,7 +377,7 @@ import { getDialysisRecordInitData, getDialysisSchedules } from '@/api/dialysis_
377 377
       websocketSend(data) {
378 378
         try {
379 379
           this.websocket.send(JSON.stringify(data))
380
-            
380
+
381 381
         } catch (error) {
382 382
           this.showError = true;
383 383
           this.showIndex = 4;
@@ -524,7 +524,7 @@ import { getDialysisRecordInitData, getDialysisSchedules } from '@/api/dialysis_
524 524
           }else if(this.schedule_type_selected == 2){
525 525
             schedule_type = 2
526 526
           }
527
-          
527
+
528 528
           console.log('patient_id',patient_id)
529 529
           let org_id =  parseInt(sessionStorage.getItem("org_id"));
530 530
           let admin_user_id = parseInt(sessionStorage.getItem("admin_user_id"));
@@ -543,7 +543,7 @@ import { getDialysisRecordInitData, getDialysisSchedules } from '@/api/dialysis_
543 543
                       type: 'success'
544 544
                   });
545 545
               }
546
-              
546
+
547 547
           })
548 548
       },
549 549
       handleCallChange: function(index) {
@@ -870,7 +870,7 @@ import { getDialysisRecordInitData, getDialysisSchedules } from '@/api/dialysis_
870 870
         }
871 871
         // let arr5 = JSON.parse(JSON.stringify(this.allPatient))
872 872
 
873
-        
873
+
874 874
         // if(this.callVal == 1){
875 875
         //   let arr = []
876 876
         //   arr = JSON.parse(JSON.stringify(arr5))
@@ -912,8 +912,8 @@ import { getDialysisRecordInitData, getDialysisSchedules } from '@/api/dialysis_
912 912
         //   }
913 913
         //   console.log('arr222222222',arr)
914 914
         // }
915
-        
916
-        
915
+
916
+
917 917
       },
918 918
       compare(property){
919 919
         return function(a,b){

Файловите разлики са ограничени, защото са твърде много
+ 2580 - 0
src/xt_pages/dialysis/template/DialysisPrintOrderForty.vue


+ 32 - 10
src/xt_pages/dialysis/template/DialysisPrintOrderSix.vue Целия файл

@@ -64,8 +64,8 @@
64 64
         </div>
65 65
         <div class="inline_block" style="margin-left: 5px;">
66 66
           住院号/门诊号:
67
-          <div class="under_line" style="width: 70px;text-align: left" v-if="patientInfo.admission_number">
68
-            {{ patientInfo.admission_number }}
67
+          <div class="under_line" style="width: 70px;text-align: left" v-if="receiverTreatmentAccess.admission_number">
68
+            {{ receiverTreatmentAccess.admission_number }}
69 69
           </div>
70 70
           <div class="under_line" style="width: 70px;text-align: left" v-else>
71 71
             {{ "/" }}
@@ -300,6 +300,12 @@
300 300
                     <div class="under_line" style="width: 100px;text-align: center;font-weight:600;" v-if="prescription.mode_id == 19">
301 301
                       IUF+HD
302 302
                     </div>
303
+                    <div class="under_line" style="width: 150px;text-align: center;font-weight:600;" v-if="prescription.mode_id == 22">
304
+                      血浆胆红素吸附+HDF
305
+                    </div>
306
+                    <div class="under_line" style="width: 150px;text-align: center;font-weight:600;" v-if="prescription.mode_id == 23">
307
+                      血浆胆红素吸附
308
+                    </div>
303 309
                   </div>
304 310
 
305 311
                   <div class="inline_block" style="margin-left:10px;flex:1;">
@@ -344,12 +350,19 @@
344 350
                      {{prescription.dialysis_irrigation?prescription.dialysis_irrigation:'/'}}
345 351
                     </div>
346 352
                   </div>
347
-                  <div class="inline_block" style="flex:1;">
348
-                    干体重:
349
-                    <div class="under_line" style="width: 150px;text-align: center">
350
-                      {{ predialysis.dry_weight ? predialysis.dry_weight : "/" }}
353
+                  <div class="inline_block" style="flex:1;" v-if="org_id == 9538">
354
+                    血浆分离器:
355
+                    <div class="under_line" style="width: 70px;text-align: center">
356
+                      <span v-if="prescription.plasma_separator ? prescription.plasma_separator != 0 && prescription.plasma_separator != '0' : false">{{ prescription.plasma_separator }}</span>
357
+                      <span v-else>/</span>
358
+                    </div>
359
+                  </div>
360
+                  <div class="inline_block" style="flex:1;" v-if="org_id == 9538">
361
+                    胆红素吸附柱:
362
+                    <div class="under_line" style="width: 70px;text-align: center">
363
+                      <span v-if="prescription.bilirubin_adsorption_column ? prescription.bilirubin_adsorption_column != 0 && prescription.bilirubin_adsorption_column != '0' : false">{{ prescription.bilirubin_adsorption_column }}</span>
364
+                      <span v-else>/</span>
351 365
                     </div>
352
-                    kg
353 366
                   </div>
354 367
                 </div>
355 368
 
@@ -357,7 +370,8 @@
357 370
                   <div class="inline_block" style="flex:1;">
358 371
                     上次透后体重:
359 372
                     <div class="under_line" style="width: 100px;text-align: center">
360
-                      {{ lastafterdialysis.weight_after_last_transparency ? parseFloat(lastafterdialysis.weight_after - lastafterdialysis.additional_weight).toFixed(1) : "未称重" }}
373
+                      {{predialysis.weight_after_last_transparency?predialysis.weight_after_last_transparency:'未称重'}}
374
+                      <!-- {{ predialysis.weight_after_last_transparency ? parseFloat(lastafterdialysis.weight_after - lastafterdialysis.additional_weight).toFixed(1) : "未称重" }} -->
361 375
                     </div>
362 376
                     kg
363 377
                   </div>
@@ -370,11 +384,18 @@
370 384
                   </div>
371 385
                   <div class="inline_block" style="flex:1;">
372 386
                     计划超滤量:
373
-                    <div class="under_line" style="width: 150px;text-align: center">
387
+                    <div class="under_line" style="width: 100px;text-align: center">
374 388
                       {{ prescription.target_ultrafiltration ? prescription.target_ultrafiltration : "/" }}
375 389
                     </div>
376 390
                     L
377 391
                   </div>
392
+                  <div class="inline_block" style="flex:1;">
393
+                    干体重:
394
+                    <div class="under_line" style="width: 100px;text-align: center">
395
+                      {{ predialysis.dry_weight ? predialysis.dry_weight : "/" }}
396
+                    </div>
397
+                    kg
398
+                  </div>
378 399
                 </div>
379 400
 
380 401
                 <div class="row" style="padding: 2px 0;line-height:23px;">
@@ -553,7 +574,7 @@
553 574
                         {{ monitor.ultrafiltration_volume ? monitor.ultrafiltration_volume : "" }}
554 575
                       </td>
555 576
                       <td v-if="(dialysisOrder && monitor.operate_time <= dialysisOrder.end_time) && ( dialysisOrder && monitor.operate_time >= dialysisOrder.start_time)">
556
-                        {{ monitor.ultrafiltration_volume ? monitor.ultrafiltration_volume : "" }}
577
+                        {{ monitor.ultrafiltration_volume ? monitor.ultrafiltration_volume : "0" }}
557 578
                       </td>
558 579
                       <td v-if="(prescription.mode_id == 2 || prescription.mode_id == 5 || prescription.mode_id == 12) && ((dialysisOrder && monitor.operate_time <= dialysisOrder.end_time) && (dialysisOrder && monitor.operate_time >= dialysisOrder.start_time))" style="width:50px">
559 580
                         {{ monitor.displacement_quantity ? monitor.displacement_quantity : 0 }}
@@ -1342,6 +1363,7 @@ export default {
1342 1363
         this.check = response.data.data.check
1343 1364
         this.xtdate = response.data.data.xtdate
1344 1365
         this.predialysis = response.data.data.PredialysisEvaluation
1366
+        console.log("透前评估",this.predialysis)
1345 1367
         this.predialysis.blood_access_part_opera_name = this.bloodAccessParOperaName(
1346 1368
           this.predialysis.blood_access_part_opera_id
1347 1369
         )

+ 2 - 2
src/xt_pages/dialysis/template/DialysisPrintOrderTen.vue Целия файл

@@ -35,7 +35,7 @@
35 35
             <check-box :checked="receiverTreatmentAccess.condition == 2 ? true : false"></check-box>
36 36
           </div>
37 37
         </div>
38
-        
38
+
39 39
         <div class="inline_block" v-if="receiverTreatmentAccess.condition == 1">
40 40
           住院:
41 41
           <div class="under_line" style="width: 30px;text-align: center;">
@@ -1657,7 +1657,7 @@ export default {
1657 1657
           this.doctor_advices = doctor_advices_1;
1658 1658
           this.doctor_advices_2 = doctor_advices_2;
1659 1659
         }
1660
-        console.log(this.advice_groups);
1660
+          console.log(this.advice_groups);
1661 1661
       } else {
1662 1662
         this.loading = false;
1663 1663
         this.$message.error("请求数据失败");

+ 1 - 0
src/xt_pages/dialysis/template/DialysisPrintOrderThirtyFour.vue Целия файл

@@ -207,6 +207,7 @@
207 207
                         </div>
208 208
                     </div>
209 209
                 </div>
210
+                
210 211
                 <div class="row" style="padding: 2px 0;line-height:23px;">
211 212
                   <div class="inline_block" style="flex:1;">
212 213
                     置换方式:

+ 4 - 4
src/xt_pages/dialysis/template/DialysisPrintOrderThirtyNine.vue Целия файл

@@ -143,22 +143,22 @@
143 143
                                 <div style="height:40px;line-height:40px;">
144 144
                                     单超
145 145
                                     <div class="inline_block under_line" style="width:50px;">
146
-                                        
146
+                                      {{ prescription.single_time ? prescription.single_time : '' }} 
147 147
                                     </div>h
148 148
                                     <div class="inline_block under_line" style="width:50px;">
149
-                                        
149
+                                      {{ prescription.single_water ? prescription.single_water : '' }}
150 150
                                     </div>L
151 151
                                 </div>
152 152
                                 <div style="height:40px;line-height:40px;">
153 153
                                     预超滤量
154 154
                                     <div class="inline_block under_line" style="width:100px;text-align:center">
155
-                                    {{ prescription.target_ultrafiltration ? prescription.target_ultrafiltration : "" }}
155
+                                      {{ prescription.target_ultrafiltration ? prescription.target_ultrafiltration : "" }}
156 156
                                     </div>L
157 157
                                 </div>
158 158
                                 <div style="height:40px;line-height:40px;">
159 159
                                     置换流量
160 160
                                     <div class="inline_block under_line" style="width:50px;text-align:center">
161
-                                    {{ prescription.replacement_total ? prescription.replacement_total : "" }}
161
+                                      {{ prescription.replacement_flow ? prescription.replacement_flow : "" }}
162 162
                                     </div>L/h
163 163
                                 </div>
164 164
                             </div>

+ 10 - 2
src/xt_pages/dialysis/template/dialysisPrintOrderTwelve.vue Целия файл

@@ -1061,10 +1061,18 @@
1061 1061
             核对护士
1062 1062
             <span style="display: inline-block;width:100px;text-align: left;">
1063 1063
               &nbsp;
1064
-              <span v-if="setAdminUserES(check == null ? 0 : check.modifier) == ''">
1064
+              <span v-if="doctor_advices[0].execution_staff != check.modifier">
1065
+                <span v-if="setAdminUserES(check == null ? 0 : check.modifier) == ''">
1065 1066
                 {{ getAdminUser(check == null ? 0 : check.modifier) }}
1067
+                </span>
1068
+                <img style="height:30px;" :src="setAdminUserES(check == null ? 0 : check.modifier)" alt srcset v-else />
1069
+              </span>
1070
+              <span v-else>
1071
+                <span v-if="setAdminUserES(check == null ? 0 : check.creater) == ''">
1072
+                {{ getAdminUser(check == null ? 0 : check.creater) }}
1073
+                </span>
1074
+                <img style="height:30px;" :src="setAdminUserES(check == null ? 0 : check.creater)" alt srcset v-else />
1066 1075
               </span>
1067
-              <img style="height:20px;" :src="setAdminUserES(check == null ? 0 : check.modifier)" alt srcset v-else />
1068 1076
             </span>
1069 1077
             护士签名
1070 1078
             <span style="display: inline-block;width:100px;text-align: left;">

+ 8 - 1
src/xt_pages/dialysis/template/dialysisPrintOrderTwo.vue Целия файл

@@ -2,7 +2,7 @@
2 2
   <div id="dialysis-print-box-1">
3 3
     <div id="dialysis-print-box-1-1" :class="(this.monitors.length > 8 && this.print_length == 8) || (this.monitors.length > 9 && this.print_length == 9) ? 'margin-bottom-900 dialysis-print-order print-template-two print_page_main_content' : 'margin-bottom-50 dialysis-print-order print-template-two print_page_main_content'">
4 4
       <div class="order-yy-name">{{ orgname }}</div>
5
-      <div class="order-title">血液净化专科护理记录单</div>
5
+      <div class="order-title">血液净化透析治疗记录单</div>
6 6
       <div class="row">
7 7
         <div class="inline_block">
8 8
           科室:
@@ -985,6 +985,13 @@
985 985
                   </div>
986 986
                   kg
987 987
                 </div>
988
+                <div class="inline_block" v-if="orgid == 9566">
989
+                  碳酸氢根:
990
+                  <div class="under_line" style="width: 50px;text-align: left">
991
+                    {{ prescription.bicarbonate ? prescription.bicarbonate : '' }}
992
+                  </div>
993
+                  mmol/L
994
+                </div>
988 995
                 <div class="inline_block" v-if="orgid == 9566">
989 996
                   医生签名:
990 997
                   <div class="under_line" style="width: 70px;text-align: left">

+ 14 - 9
src/xt_pages/hospitalStation/allListPrint.vue Целия файл

@@ -168,21 +168,26 @@
168 168
 
169 169
         if (new_drug_ids.length == 0 && new_project_ids.length > 0) {
170 170
           for (let i = 0; i < new_project_ids.length; i++) {
171
-            let obj = {};
172
-            let count = 0;
171
+            let obj = {}
172
+            let count = 0
173 173
             for (let a = 0; a < details.length; a++) {
174 174
               if (new_project_ids[i].id == details[a].project.project_id && new_project_ids[i].price == details[a].project.price) {
175
-                obj['name'] = details[a].project.project.project_name;
176
-                obj['spec'] = '1';
177
-                obj['unit'] = details[a].project.project.unit;
178
-                obj['med_chrgitm_type'] = this.getType(details[a].med_chrgitm_type);
179
-                obj['price'] = parseFloat(details[a].pric);
180
-                obj['is_total'] = 2;
175
+                if( details[a].project.type == 2){
176
+                  obj['name'] = details[a].project.project.project_name
177
+                }else if(details[a].project.type == 3){
178
+                  obj['name'] = details[a].project.good_info.good_name
179
+                }
180
+                obj['unit'] = details[a].project.unit
181
+
182
+                obj['spec'] = '1'
183
+                obj['med_chrgitm_type'] = this.getType(details[a].med_chrgitm_type)
184
+                obj['price'] = parseFloat(details[a].pric)
185
+                obj['is_total'] = 2
181 186
 
182 187
                 count = count + details[a].cnt
183 188
               }
184 189
             }
185
-            obj['count'] = count;
190
+            obj['count'] = count
186 191
             list.push(obj)
187 192
           }
188 193
         }

+ 1 - 1
src/xt_pages/hospitalStation/components/ChargePrescriptionTable.vue Целия файл

@@ -61,7 +61,7 @@
61 61
         <template slot-scope="scope">{{ scope.row.project_name }}</template>
62 62
       </el-table-column>
63 63
       <el-table-column align="center" prop="statistical_classification" width="100" label="组">
64
-        <template slot-scope="scope">{{getGroup(scope.row.statistical_classification)}}</template>
64
+        <template slot-scope="scope">{{scope.row.type == 2 ?getGroup(scope.row.statistical_classification):'耗材'}}</template>
65 65
       </el-table-column>
66 66
       <el-table-column align="center" prop="single_dose" width="80" label="单次用量">
67 67
         <template slot-scope="scope">{{scope.row.single_dose}}{{scope.row.unit}}</template>

+ 52 - 33
src/xt_pages/hospitalStation/components/callPrescription.vue Целия файл

@@ -1,36 +1,36 @@
1 1
 <template>
2 2
   <el-dialog
3
-    :title="name"
4
-    :visible.sync="isLastOrNextVisible"
5
-    @close="hide"
6
-    width="1010px"
7
-    class="callPrescription"
8
-    :modal-append-to-body="false"
3
+          :title="name"
4
+          :visible.sync="isLastOrNextVisible"
5
+          @close="hide"
6
+          width="1010px"
7
+          class="callPrescription"
8
+          :modal-append-to-body="false"
9 9
   >
10 10
     <el-date-picker
11
-      v-model="start_time"
12
-      prefix-icon="el-icon-date"
13
-      @change="changeTime"
14
-      :editable="false"
15
-      style="width: 150px;"
16
-      type="date"
17
-      placeholder="选择日期时间"
18
-      align="right"
19
-      format="yyyy-MM-dd"
20
-      value-format="yyyy-MM-dd"
11
+            v-model="start_time"
12
+            prefix-icon="el-icon-date"
13
+            @change="changeTime"
14
+            :editable="false"
15
+            style="width: 150px;"
16
+            type="date"
17
+            placeholder="选择日期时间"
18
+            align="right"
19
+            format="yyyy-MM-dd"
20
+            value-format="yyyy-MM-dd"
21 21
     ></el-date-picker>
22 22
     <span class>-</span>
23 23
     <el-date-picker
24
-      v-model="end_time"
25
-      prefix-icon="el-icon-date"
26
-      @change="changeEndTime"
27
-      :editable="false"
28
-      style="width: 150px;"
29
-      type="date"
30
-      placeholder="选择日期时间"
31
-      align="right"
32
-      format="yyyy-MM-dd"
33
-      value-format="yyyy-MM-dd"
24
+            v-model="end_time"
25
+            prefix-icon="el-icon-date"
26
+            @change="changeEndTime"
27
+            :editable="false"
28
+            style="width: 150px;"
29
+            type="date"
30
+            placeholder="选择日期时间"
31
+            align="right"
32
+            format="yyyy-MM-dd"
33
+            value-format="yyyy-MM-dd"
34 34
     ></el-date-picker>
35 35
 
36 36
 
@@ -93,11 +93,11 @@
93 93
             <el-table-column align="center" type="index" width="60" label="序号"></el-table-column>
94 94
             <el-table-column align="center" prop="project_name" width="160" label="名称">
95 95
               <template slot-scope="scope">
96
-                <span>{{ scope.row.project.project_name }}</span>
96
+                <span>{{ scope.row.type == 2?scope.row.project.project_name:scope.row.good_info.good_name}}</span>
97 97
               </template>
98 98
             </el-table-column>
99 99
             <el-table-column align="center" prop="statistical_classification" width="100" label="组">
100
-              <template slot-scope="scope">{{getGroup(scope.row.statistical_classification)}}</template>
100
+              <template slot-scope="scope">{{scope.row.type == 2 ?getGroup(scope.row.statistical_classification):"耗材"}}</template>
101 101
             </el-table-column>
102 102
             <el-table-column align="center" prop="single_dose" width="90" label="单次用量">
103 103
               <template slot-scope="scope">
@@ -190,7 +190,6 @@
190 190
           start_time: this.start_time,
191 191
           end_time:this.end_time,
192 192
           p_type:1,
193
-
194 193
         };
195 194
         this.GetCallHisPrescription(params)
196 195
       },changeEndTime(){
@@ -261,13 +260,15 @@
261 260
                 single_dose_unit:prescription.doctor_advice[b].single_dose_unit,
262 261
                 prescribing_number_unit:prescription.doctor_advice[b].prescribing_number_unit,
263 262
                 medical_insurance_number:prescription.doctor_advice[b].med_list_codg,
264
-                id:prescription.doctor_advice[b].drug_id
263
+                id:prescription.doctor_advice[b].drug_id,
264
+                drug:prescription.doctor_advice[b].drug,
265 265
               };
266 266
               tempAdvice.push(obj)
267 267
 
268 268
             }
269 269
 
270 270
 
271
+
271 272
             for (let b = 0; b < prescription.project.length; b++) {
272 273
               let obj = {
273 274
                 id: 0,
@@ -281,8 +282,26 @@
281 282
                 total:prescription.project[b].count,
282 283
                 price:prescription.project[b].price,
283 284
                 remark:prescription.project[b].remark,
284
-                medical_code:prescription.project[b].project.medical_code,
285
+                unit: prescription.project[b].unit,
286
+                type: prescription.project[b].type,
287
+
288
+
289
+                // medical_code:prescription.project[b].project.medical_code,
285 290
               };
291
+              console.log(prescription.project[b].type)
292
+              if(prescription.project[b].type == 2){
293
+
294
+                obj['statistical_classification'] =  prescription.project[b].project.statistical_classification
295
+                obj['medical_code'] =  prescription.project[b].project.medical_code
296
+                obj['project_name'] =  prescription.project[b].project.project_name
297
+
298
+              }else if(prescription.project[b].type == 3){
299
+
300
+                obj['statistical_classification'] = ""
301
+                obj['medical_code'] =  prescription.project[b].good_info.medical_insurance_number
302
+                obj['project_name'] =  prescription.project[b].good_info.good_name
303
+              }
304
+
286 305
               tempProject.push(obj)
287 306
             }
288 307
             let obj = {
@@ -347,7 +366,7 @@
347 366
 </script>
348 367
 
349 368
 <style lang="scss">
350
-.callPrescription{
369
+  .callPrescription{
351 370
   .el-dialog__body{
352 371
     padding:0px 20px 30px;
353 372
   }
@@ -355,5 +374,5 @@
355 374
     margin-top: 10px;
356 375
     font-size: 14px;
357 376
   }
358
-}
377
+  }
359 378
 </style>

+ 188 - 47
src/xt_pages/hospitalStation/components/deskPrescription.vue Целия файл

@@ -264,12 +264,7 @@
264 264
                       <template slot-scope="scope">{{ scope.row.drug_spec }}</template>
265 265
                     </el-table-column>
266 266
                     <el-table-column label="库存" width="60">
267
-                      <template slot-scope="scope">{{
268
-                        stockInCount(scope.row) -
269
-                        salesReturnCount(scope.row) -
270
-                        stockOutCount(scope.row) +
271
-                        cancelStockCount(scope.row)
272
-                        }}
267
+                      <template slot-scope="scope">{{scope.row.total }}
273 268
                       </template>
274 269
                     </el-table-column>
275 270
                     <el-table-column label="单价" width="40">
@@ -279,6 +274,10 @@
279 274
                 </div>
280 275
 
281 276
               </el-tab-pane>
277
+              <!--// stockInCount(scope.row) - -->
278
+              <!--// salesReturnCount(scope.row) - -->
279
+              <!--// stockOutCount(scope.row) +-->
280
+              <!--// cancelStockCount(scope.row)-->
282 281
               <!--<el-tab-pane label="医嘱模板" name="2">-->
283 282
               <!--<div style="margin-bottom:5px;">-->
284 283
               <!--&lt;!&ndash;<el-input style="width:50%;" v-model="input" placeholder=""></el-input>&ndash;&gt;-->
@@ -577,7 +576,6 @@
577 576
       }
578 577
     },
579 578
     methods: {
580
-
581 579
       changeClass(id) {
582 580
         this.tabProject = [];
583 581
         if (id == 0) {
@@ -591,6 +589,9 @@
591 589
         }
592 590
       },
593 591
       setMonthPrescription(month_prescriptions) {
592
+
593
+
594
+
594 595
         this.month_prescriptions = [];
595 596
 
596 597
         let drug_month_prescriptions = {
@@ -663,12 +664,6 @@
663 664
           return cur
664 665
         }, []); // 设置cur默认类型为数组,并且初始值为空的数组
665 666
 
666
-        console.log(drug_ids);
667
-        console.log(project_ids);
668
-        console.log(additions_ids);
669
-
670
-        console.log(additions_ids);
671
-
672 667
         let drugs = [];
673 668
         let projects = [];
674 669
         let additions = [];
@@ -689,7 +684,10 @@
689 684
               obj['id'] = drug_month_prescriptions.advices[a].drug_id;
690 685
               // obj['retail_price'] = obj['retail_price'] +  drug_month_prescriptions.advices[a].drug.retail_price
691 686
               obj['retail_price'] = parseFloat(drug_month_prescriptions.advices[a].price);
692
-              count = count + drug_month_prescriptions.advices[a].prescribing_number
687
+              obj['drug'] = drug_month_prescriptions.advices[a].drug;
688
+
689
+
690
+                      count = count + drug_month_prescriptions.advices[a].prescribing_number
693 691
 
694 692
             }
695 693
           }
@@ -702,19 +700,35 @@
702 700
           let count = 0;
703 701
           for (let a = 0; a < project_month_prescriptions.project.length; a++) {
704 702
             if (project_ids[i].price == project_month_prescriptions.project[a].price) {
705
-              obj['project_name'] = project_month_prescriptions.project[a].project.project_name;
706
-              obj['statistical_classification'] = project_month_prescriptions.project[a].project.statistical_classification;
703
+              // obj['project_name'] = project_month_prescriptions.project[a].project.project_name;
704
+              // obj['statistical_classification'] = project_month_prescriptions.project[a].project.statistical_classification;
707 705
               obj['single_dose'] = project_month_prescriptions.project[a].single_dose;
708 706
               obj['delivery_way'] = project_month_prescriptions.project[a].delivery_way;
709 707
               obj['execution_frequency'] = project_month_prescriptions.project[a].execution_frequency;
710 708
               obj['number_days'] = project_month_prescriptions.project[a].day;
711
-              obj['medical_code'] = project_month_prescriptions.project[a].project.medical_code;
709
+              // obj['medical_code'] = project_month_prescriptions.project[a].project.medical_code;
712 710
               obj['unit'] = project_month_prescriptions.project[a].unit;
713 711
               obj['project_id'] = project_month_prescriptions.project[a].project_id;
714 712
               count = count + project_month_prescriptions.project[a].count;
715 713
               // price = price + project_month_prescriptions.project[a].price
716 714
               obj['price'] = parseFloat(project_month_prescriptions.project[a].price)
717 715
 
716
+
717
+              if (project_month_prescriptions.project[a].type == 2) {
718
+                console.log("~~~~~~~????????")
719
+
720
+                obj['statistical_classification'] = project_month_prescriptions.project[a].project.statistical_classification
721
+                obj['medical_code'] = project_month_prescriptions.project[a].project.medical_code
722
+                obj['project_name'] = project_month_prescriptions.project[a].project.project_name
723
+
724
+              } else if (project_month_prescriptions.project[a].type == 3) {
725
+                console.log("~~~~~~~????????2222222")
726
+
727
+                obj['statistical_classification'] = ''
728
+                obj['medical_code'] = project_month_prescriptions.project[a].good_info.medical_insurance_number
729
+                obj['project_name'] = project_month_prescriptions.project[a].good_info.good_name
730
+              }
731
+
718 732
             }
719 733
           }
720 734
           obj['total'] = count;
@@ -767,6 +781,12 @@
767 781
 
768 782
         this.curMonthPrescriptions = this.month_prescriptions[0]
769 783
 
784
+        console.log("~~~~~~~~~")
785
+
786
+        console.log(this.curMonthPrescriptions)
787
+        console.log("~~~~~~~~~")
788
+
789
+
770 790
       },
771 791
 
772 792
       // setMonthPrescription(month_prescriptions) {
@@ -999,7 +1019,10 @@
999 1019
                       single_dose_unit: prescription.advices[b].single_dose_unit,
1000 1020
                       prescribing_number_unit: prescription.advices[b].prescribing_number_unit,
1001 1021
                       medical_insurance_number: prescription.advices[b].med_list_codg,
1002
-                      id: prescription.advices[b].drug_id
1022
+                      id: prescription.advices[b].drug_id,
1023
+                      drug:prescription.advices[b].drug,
1024
+
1025
+
1003 1026
                     };
1004 1027
                     tempAdvice.push(obj)
1005 1028
                   }
@@ -1019,8 +1042,18 @@
1019 1042
                       price: prescription.project[b].price,
1020 1043
                       remark: prescription.project[b].remark,
1021 1044
                       medical_code: prescription.project[b].project.medical_code,
1022
-                      unit: prescription.project[b].project.unit
1045
+                      unit: prescription.project[b].unit
1023 1046
                     };
1047
+                    if (prescription.project[b].type == 2) {
1048
+                      obj['statistical_classification'] = prescription.project[b].project.statistical_classification
1049
+                      obj['medical_code'] = prescription.project[b].project.medical_code
1050
+                      obj['project_name'] = prescription.project[b].project.project_name
1051
+
1052
+                    } else if (prescription.project[b].type == 3) {
1053
+                      obj['statistical_classification'] = ''
1054
+                      obj['medical_code'] = prescription.project[b].good_info.medical_insurance_number
1055
+                      obj['project_name'] = prescription.project[b].good_info.good_name
1056
+                    }
1024 1057
                     tempProject.push(obj)
1025 1058
                   }
1026 1059
 
@@ -1104,7 +1137,9 @@
1104 1137
                       single_dose_unit: prescription.advices[b].single_dose_unit,
1105 1138
                       prescribing_number_unit: prescription.advices[b].prescribing_number_unit,
1106 1139
                       medical_insurance_number: prescription.advices[b].med_list_codg,
1107
-                      id: prescription.advices[b].drug_id
1140
+                      id: prescription.advices[b].drug_id,
1141
+                      drug:prescription.advices[b].drug,
1142
+
1108 1143
                     };
1109 1144
                     tempAdvice.push(obj)
1110 1145
                   }
@@ -1124,8 +1159,18 @@
1124 1159
                       price: prescription.project[b].price,
1125 1160
                       remark: prescription.project[b].remark,
1126 1161
                       medical_code: prescription.project[b].project.medical_code,
1127
-                      unit: prescription.project[b].project.unit
1162
+                      unit: prescription.project[b].unit
1128 1163
                     };
1164
+                    if (prescription.project[b].type == 2) {
1165
+                      obj['statistical_classification'] = prescription.project[b].project.statistical_classification
1166
+                      obj['medical_code'] = prescription.project[b].project.medical_code
1167
+                      obj['project_name'] = prescription.project[b].project.project_name
1168
+
1169
+                    } else if (prescription.project[b].type == 3) {
1170
+                      obj['statistical_classification'] = ''
1171
+                      obj['medical_code'] = prescription.project[b].good_info.medical_insurance_number
1172
+                      obj['project_name'] = prescription.project[b].good_info.good_name
1173
+                    }
1129 1174
                     tempProject.push(obj)
1130 1175
                   }
1131 1176
 
@@ -2257,8 +2302,6 @@
2257 2302
       },
2258 2303
 
2259 2304
       comfirm() {
2260
-        console.log("222222222222",this.curPrescriptions);
2261
-
2262 2305
 
2263 2306
         if (this.curPrescriptions.order_status == 2) {
2264 2307
           this.$message.error('该处方已经结算,无法继续添加药品或者项目');
@@ -2377,7 +2420,8 @@
2377 2420
                   prescribing_number: temp[b].prescribing_number,
2378 2421
                   single_dose_unit: temp[b].min_unit,
2379 2422
                   prescribing_number_unit: temp[b].max_unit,
2380
-                  medical_insurance_number: temp[b].medical_insurance_number
2423
+                  medical_insurance_number: temp[b].medical_insurance_number,
2424
+                  drug: temp[b],
2381 2425
 
2382 2426
                 };
2383 2427
 
@@ -2389,20 +2433,19 @@
2389 2433
               this.curStatus = 1
2390 2434
             }
2391 2435
 
2392
-           if(this.activeName == 2){
2393
-
2394
-              for(let i = 0; i<temp2.length;i++){
2395
-               for(let j=0;j<this.hisList.length;j++){
2396
-                   if(temp2[i].id == this.hisList[j].project_id){
2397
-                      temp2[i].total =  this.hisList[j].number
2398
-                   }
2399
-               }
2400
-              }
2401
-            }
2436
+           // if(this.activeName == 2){
2437
+           //
2438
+           //  //   for(let i = 0; i<temp2.length;i++){
2439
+           //  //    for(let j=0;j<this.hisList.length;j++){
2440
+           //  //        if(temp2[i].id == this.hisList[j].project_id){
2441
+           //  //           temp2[i].total =  this.hisList[j].number
2442
+           //  //        }
2443
+           //  //    }
2444
+           //  //   }
2445
+           //  // }
2402 2446
 
2403 2447
 
2404 2448
             if (temp2.length > 0) {
2405
-              console.log("temp2222222222",temp2);
2406 2449
               for (let b = 0; b < temp2.length; b++) {
2407 2450
                 let obj = {
2408 2451
                   id: 0,
@@ -2417,19 +2460,22 @@
2417 2460
                   price: temp2[b].price,
2418 2461
                   remark: '',
2419 2462
                   medical_code: temp2[b].medical_code,
2420
-                  unit: temp2[b].unit
2421
-                };
2463
+                  unit: temp2[b].unit,
2464
+                  type: temp2[b].type
2465
+                }
2422 2466
                 if (obj.total == 0) {
2423 2467
                   obj.total = 1
2424 2468
                 }
2469
+                if (obj.type == 3) {
2470
+                  obj.single_dose = 1
2471
+                }
2472
+                console.log(obj)
2425 2473
                 this.prescriptions[i].project.push(obj)
2426 2474
               }
2427 2475
               this.curStatus = 2
2428 2476
             }
2429 2477
 
2430 2478
             this.curPrescriptions = this.prescriptions[i];
2431
-            console.log("~~~~~~~~~");
2432
-            console.log("~~~~~~~~~");
2433 2479
 
2434 2480
             this.$refs.multipleTable.clearSelection();
2435 2481
             this.$refs.tables.clearSelection()
@@ -2440,7 +2486,8 @@
2440 2486
         this.preDrugs = [];
2441 2487
         this.teamList = []
2442 2488
 
2443
-      }, changeAllGoodInfoTableDataTwo(row) {
2489
+      },
2490
+      changeAllGoodInfoTableDataTwo(row) {
2444 2491
         this.teamList = row
2445 2492
       },
2446 2493
       selectChange(row) {
@@ -2449,12 +2496,49 @@
2449 2496
       getlist() {
2450 2497
         getHisProject().then(response => {
2451 2498
           if (response.data.state == 1) {
2452
-            var project = response.data.data.project;
2453
-            this.tabProject = project;
2454
-            this.allProject = project
2499
+            var project = response.data.data.project
2500
+            for (let i = 0; i < project.length; i++) {
2501
+              let obj = {
2502
+                id: project[i].id,
2503
+                project_name: project[i].project_name,
2504
+                statistical_classification: project[i].statistical_classification,
2505
+                single_dose: project[i].single_dose,
2506
+                delivery_way: project[i].delivery_way,
2507
+                execution_frequency: project[i].execution_frequency,
2508
+                number_days: project[i].number_days,
2509
+                price: project[i].price,
2510
+                medical_code: project[i].medical_code,
2511
+                unit: project[i].unit,
2512
+                type: 2
2513
+              }
2514
+
2515
+              this.tabProject.push(obj)
2516
+            }
2517
+
2518
+            var good_info = response.data.data.good_info
2519
+
2520
+            for (let i = 0; i < good_info.length; i++) {
2521
+              let obj = {
2522
+                id: good_info[i].id,
2523
+                project_name: good_info[i].good_name,
2524
+                statistical_classification: 0,
2525
+                single_dose: 1,
2526
+                delivery_way: '',
2527
+                execution_frequency: '',
2528
+                number_days: 1,
2529
+                price: good_info[i].retail_price,
2530
+                medical_code: good_info[i].medical_insurance_number,
2531
+                unit: this.getGoodUnit(good_info[i].good_unit),
2532
+                type: 3
2533
+              }
2534
+              this.tabProject.push(obj)
2535
+            }
2536
+
2537
+            this.allProject = this.tabProject
2455 2538
 
2456 2539
           }
2457 2540
         })
2541
+
2458 2542
       }, deepClone(source) {
2459 2543
         if (!source && typeof source !== 'object') {
2460 2544
           throw new Error('error arguments', 'shallowClone')
@@ -2477,12 +2561,19 @@
2477 2561
             this.tabPrjectTeam = team
2478 2562
           }
2479 2563
         })
2564
+      }, getGoodUnit(id) {
2565
+        var goodUnit = this.$store.getters.good_unit
2566
+        for (let i = 0; i < goodUnit.length; i++) {
2567
+          if (goodUnit[i].id == id) {
2568
+            return goodUnit[i].name
2569
+          }
2570
+        }
2480 2571
       },
2481 2572
       selectTeam(row) {
2482 2573
         console.log("row",row);
2483 2574
         var arr = [];
2484 2575
         for (let i = 0; i < row.length; i++) {
2485
-          arr.push(row[i].project_id)
2576
+          arr.push(row[i].item_id)
2486 2577
         }
2487 2578
         var ids = arr.join(',');
2488 2579
         var strArr = ids.split(',');
@@ -2507,11 +2598,61 @@
2507 2598
         };
2508 2599
         getPojectListById(params).then(response => {
2509 2600
           if (response.data.state == 1) {
2510
-            var project = response.data.data.project;
2511
-            this.teamList = [];
2512
-            this.teamList = project
2601
+            this.teamList = []
2602
+            var project = response.data.data.project
2603
+            for (let i = 0; i < project.length; i++) {
2604
+              if (project[i].type == 2) {
2605
+
2606
+                let obj = {
2607
+                  id: project[i].project_id,
2608
+                  project_name: project[i].project.project_name,
2609
+                  statistical_classification: project[i].project.statistical_classification,
2610
+                  single_dose: project[i].project.single_dose,
2611
+                  delivery_way: project[i].project.delivery_way,
2612
+                  execution_frequency: project[i].project.execution_frequency,
2613
+                  number_days: project[i].project.number_days,
2614
+                  total: project[i].number,
2615
+                  price: project[i].project.price,
2616
+                  remark: '',
2617
+                  medical_code: project[i].project.medical_code,
2618
+                  unit: project[i].project.unit,
2619
+                  type: project[i].type
2620
+                }
2621
+                if (obj.total == 0) {
2622
+                  obj.total = 1
2623
+                }
2624
+
2625
+                this.teamList.push(obj)
2626
+              } else if (project[i].type == 3) {
2627
+                let obj = {
2628
+                  id: project[i].project_id,
2629
+                  project_name: project[i].good_info.good_name,
2630
+                  statistical_classification: "",
2631
+                  single_dose: "",
2632
+                  delivery_way: "",
2633
+                  execution_frequency:"",
2634
+                  number_days:"",
2635
+                  total: project[i].number,
2636
+                  price: project[i].good_info.retail_price,
2637
+                  remark: '',
2638
+                  medical_code: project[i].good_info.medical_insurance_number,
2639
+                  unit: project[i].good_info.unit,
2640
+                  type: project[i].type
2641
+                }
2642
+                if (obj.total == 0) {
2643
+                  obj.total = 1
2644
+                }
2645
+                this.teamList.push(obj)
2646
+
2647
+                console.log( this.teamList)
2648
+
2649
+              }
2650
+            }
2651
+
2652
+
2513 2653
           }
2514 2654
         })
2655
+
2515 2656
       }, changeDoctor(val) {
2516 2657
         for (let i = 0; i < this.doctors.length; i++) {
2517 2658
           if (this.doctors[i].admin_user_id == this.doctorValue) {

+ 20 - 1
src/xt_pages/hospitalStation/components/inquiriesDetail.vue Целия файл

@@ -295,8 +295,25 @@
295 295
                   medical_code: prescription.project[b].project.medical_code,
296 296
                   unit:prescription.project[b].project.unit,
297 297
                 };
298
+                if(prescription.project[b].type == 2){
299
+                  obj['statistical_classification'] =  prescription.project[b].project.statistical_classification
300
+                  obj['medical_code'] =  prescription.project[b].project.medical_code
301
+                  obj['project_name'] =  prescription.project[b].project.project_name
302
+                  obj['type'] =  2
303
+
304
+
305
+
306
+                }else if(prescription.project[b].type == 3){
307
+                  obj['statistical_classification'] = ""
308
+                  obj['medical_code'] =  prescription.project[b].good_info.medical_insurance_number
309
+                  obj['project_name'] =  prescription.project[b].good_info.good_name
310
+                  obj['type'] =  3
311
+
312
+                }
298 313
                 tempProject.push(obj)
299 314
               }
315
+
316
+              console.log(tempProject)
300 317
               let index = i + 1;
301 318
               let obj = {
302 319
                 id: prescription.id,
@@ -306,9 +323,11 @@
306 323
                 type: response.data.data.prescription[i].type
307 324
               };
308 325
               this.prescriptions.push(obj);
309
-              console.log(this.prescriptions);
310 326
 
311 327
               this.curPrescriptions = this.prescriptions[0]
328
+
329
+
330
+
312 331
             }
313 332
           }
314 333
         });

+ 1 - 1
src/xt_pages/hospitalStation/components/newPrescriptionTable.vue Целия файл

@@ -63,7 +63,7 @@
63 63
       </el-table-column>
64 64
       <el-table-column align="center" prop="statistical_classification" width="100" label="组">
65 65
         <template slot-scope="scope">
66
-          <div>{{getGroup(scope.row.statistical_classification)}}</div>
66
+          <div>{{scope.row.type == 2?getGroup(scope.row.statistical_classification):"耗材"}}</div>
67 67
         </template>
68 68
       </el-table-column>
69 69
       <el-table-column align="center" prop="single_dose" width="100" label="单次用量">

+ 43 - 24
src/xt_pages/hospitalStation/components/nextOrLastPrescription.vue Целия файл

@@ -1,23 +1,23 @@
1 1
 <template>
2 2
   <el-dialog
3
-    :title="name"
4
-    :visible.sync="isLastOrNextVisible"
5
-    @close="hide"
6
-    width="1010px"
7
-    :modal-append-to-body="false"
8
-    class="isLastOrNext"
3
+          :title="name"
4
+          :visible.sync="isLastOrNextVisible"
5
+          @close="hide"
6
+          width="1010px"
7
+          :modal-append-to-body="false"
8
+          class="isLastOrNext"
9 9
   >
10 10
     <div class="txsj" style="text-align:center;">
11 11
       <el-button
12
-        round
12
+              round
13 13
 
14
-        @click="openLast(3)"
14
+              @click="openLast(3)"
15 15
       >上一方
16 16
       </el-button>
17 17
 
18 18
       <el-button
19
-        round
20
-        @click="openNext(4)"
19
+              round
20
+              @click="openNext(4)"
21 21
       >下一方
22 22
       </el-button>
23 23
     </div>
@@ -39,7 +39,7 @@
39 39
 
40 40
             <el-table-column align="center" prop="single_dose" width="90" label="单次用量">
41 41
               <template slot-scope="scope">
42
-                  <div>{{scope.row.single_dose}}{{scope.row.single_dose_unit}}</div>
42
+                <div>{{scope.row.single_dose}}{{scope.row.single_dose_unit}}</div>
43 43
               </template>
44 44
             </el-table-column>
45 45
             <el-table-column align="center" prop="delivery_way" width="100" label="用法">
@@ -81,11 +81,11 @@
81 81
             <el-table-column align="center" type="index" width="60" label="序号"></el-table-column>
82 82
             <el-table-column align="center" prop="project_name" width="160" label="名称">
83 83
               <template slot-scope="scope">
84
-                <span>{{ scope.row.project.project_name }}</span>
84
+                <span>{{ scope.row.type == 2 ?scope.row.project.project_name:scope.row.good_info.good_name}}</span>
85 85
               </template>
86 86
             </el-table-column>
87 87
             <el-table-column align="center" prop="statistical_classification" width="100" label="组">
88
-              <template slot-scope="scope">{{getGroup(scope.row.statistical_classification)}}</template>
88
+              <template slot-scope="scope">{{ scope.row.type == 2 ?getGroup(scope.row.statistical_classification):"耗材"}}</template>
89 89
             </el-table-column>
90 90
             <el-table-column align="center" prop="single_dose" width="90" label="单次用量">
91 91
               <template slot-scope="scope">
@@ -117,7 +117,7 @@
117 117
             </el-table-column>
118 118
             <el-table-column align="center" prop="total" width="70" label="总量">
119 119
               <template slot-scope="scope">
120
-                  <div>{{ scope.row.total }}{{scope.row.unit}}</div>
120
+                <div>{{ scope.row.total }}{{scope.row.unit}}</div>
121 121
               </template>
122 122
             </el-table-column>
123 123
             <el-table-column align="center" prop="name" width="60" label="单价">
@@ -165,7 +165,7 @@
165 165
         name:"",
166 166
         request_record_date:'',
167 167
         patient_id:0,
168
-         allPrescription: [
168
+        allPrescription: [
169 169
           {
170 170
             check_group: [],
171 171
             prescriptions: [
@@ -235,11 +235,12 @@
235 235
       }
236 236
     }, methods: {
237 237
       openLast(val) {
238
-       if (val == 3) {
238
+        if (val == 3) {
239 239
           let params = {
240 240
             patient_id: this.patient_id,
241 241
             record_time: this.request_record_date,
242
-            type: 1
242
+            type: 1,
243
+            p_type:1,
243 244
           };
244 245
 
245 246
           this.GetNextOrLastHisPrescription(params)
@@ -251,7 +252,9 @@
251 252
           let params = {
252 253
             patient_id: this.patient_id,
253 254
             record_time: this.request_record_date,
254
-            type: 2
255
+            type: 2,
256
+            p_type:1,
257
+
255 258
           };
256 259
           this.GetNextOrLastHisPrescription(params)
257 260
         }
@@ -314,7 +317,8 @@
314 317
                 single_dose_unit:prescription.doctor_advice[b].single_dose_unit,
315 318
                 prescribing_number_unit:prescription.doctor_advice[b].prescribing_number_unit,
316 319
                 medical_insurance_number:prescription.doctor_advice[b].med_list_codg,
317
-                id:prescription.doctor_advice[b].drug_id
320
+                id:prescription.doctor_advice[b].drug_id,
321
+                drug:prescription.doctor_advice[b].drug,
318 322
               };
319 323
               tempAdvice.push(obj)
320 324
 
@@ -325,8 +329,8 @@
325 329
               let obj = {
326 330
                 id: 0,
327 331
                 project_id: prescription.project[b].project_id,
328
-                project_name: prescription.project[b].project.project_name,
329
-                statistical_classification: prescription.project[b].project.statistical_classification,
332
+                // project_name: prescription.project[b].project.project_name,
333
+                // statistical_classification: prescription.project[b].project.statistical_classification,
330 334
                 single_dose: prescription.project[b].single_dose,
331 335
                 delivery_way: prescription.project[b].delivery_way,
332 336
                 execution_frequency: prescription.project[b].execution_frequency,
@@ -334,8 +338,23 @@
334 338
                 total:prescription.project[b].count.toString(),
335 339
                 price:prescription.project[b].price,
336 340
                 remark:prescription.project[b].remark,
337
-                medical_code:prescription.project[b].project.medical_code,
341
+                unit: prescription.project[b].unit,
342
+                type: prescription.project[b].type,
343
+
344
+                // medical_code:prescription.project[b].project.medical_code,
338 345
               };
346
+
347
+              if(prescription.project[b].type == 2){
348
+                obj['statistical_classification'] =  prescription.project[b].project.statistical_classification
349
+                obj['medical_code'] =  prescription.project[b].project.medical_code
350
+                obj['project_name'] =  prescription.project[b].project.project_name
351
+
352
+              }else if(prescription.project[b].type == 3){
353
+                obj['statistical_classification'] = ""
354
+                obj['medical_code'] =  prescription.project[b].good_info.medical_insurance_number
355
+                obj['project_name'] =  prescription.project[b].good_info.good_name
356
+              }
357
+
339 358
               tempProject.push(obj)
340 359
             }
341 360
             let obj = {
@@ -405,7 +424,7 @@
405 424
 </script>
406 425
 
407 426
 <style lang="scss">
408
-.isLastOrNext{
427
+  .isLastOrNext{
409 428
   .el-dialog__body{
410 429
     padding:0px 20px 30px;
411 430
   }
@@ -413,5 +432,5 @@
413 432
     margin-top: 10px;
414 433
     font-size: 14px;
415 434
   }
416
-}
435
+  }
417 436
 </style>

+ 13 - 12
src/xt_pages/hospitalStation/components/prescriptionTable.vue Целия файл

@@ -75,15 +75,14 @@
75 75
         </template>
76 76
       </el-table-column>
77 77
     </el-table>
78
-
79 78
     <el-table v-if="activeType == 2" :data="prescription.project" border style="width: 99%;" :row-style="{ color: '#303133' }"
80 79
               :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}" highlight-current-row>
81
-       <el-table-column align="center" type="index" width="40" label="序号"></el-table-column>
80
+      <el-table-column align="center" type="index" width="40" label="序号"></el-table-column>
82 81
       <el-table-column align="center" prop="project_name" label="名称">
83 82
         <template slot-scope="scope"><span :title="scope.row.project_name">{{ scope.row.project_name }}</span></template>
84 83
       </el-table-column>
85 84
       <el-table-column align="center" prop="statistical_classification" width="100" label="组">
86
-        <template slot-scope="scope">{{getGroup(scope.row.statistical_classification)}}</template>
85
+        <template slot-scope="scope">{{scope.row.type == 2?getGroup(scope.row.statistical_classification):"耗材"}}</template>
87 86
       </el-table-column>
88 87
       <el-table-column align="center" prop="single_dose" width="80" label="单次用量">
89 88
         <template slot-scope="scope">
@@ -95,11 +94,11 @@
95 94
       <el-table-column align="center" prop="delivery_way" width="80" label="用法">
96 95
         <template slot-scope="scope">
97 96
           <el-autocomplete
98
-            style="width:100%;"
99
-            class="inline-input"
100
-            v-model="scope.row.delivery_way"
101
-            :fetch-suggestions="querySearch2"
102
-            placeholder="请输入内容"
97
+                  style="width:100%;"
98
+                  class="inline-input"
99
+                  v-model="scope.row.delivery_way"
100
+                  :fetch-suggestions="querySearch2"
101
+                  placeholder="请输入内容"
103 102
           ></el-autocomplete>
104 103
         </template>
105 104
       </el-table-column>
@@ -108,10 +107,12 @@
108 107
           <el-input v-model="scope.row.execution_frequency" placeholder=""></el-input>
109 108
         </template>
110 109
       </el-table-column>
111
-      <el-table-column align="center" prop="number_days" width="50" label="天数">
110
+      <el-table-column align="center" prop="number_days" width="70" label="天数">
112 111
         <template slot-scope="scope">
113
-          <el-input v-model="scope.row.number_days" @input="getProjectDay(scope)" placeholder=""></el-input>
114
-          <div>{{'天'}}</div>
112
+          <div style="display:flex;align-items:center;">
113
+            <el-input v-model="scope.row.number_days" @input="getProjectDay(scope)" placeholder=""></el-input>
114
+            <div>{{'天'}}</div>
115
+          </div>
115 116
         </template>
116 117
       </el-table-column>
117 118
       <el-table-column align="center" prop="total" width="70" label="总量">
@@ -132,7 +133,7 @@
132 133
       </el-table-column>
133 134
       <el-table-column align="center" prop="name" width="50" label="备注">
134 135
         <template slot-scope="scope">
135
-           <el-input v-model="scope.row.remark" :title="scope.row.remark"></el-input>
136
+          <el-input v-model="scope.row.remark" :title="scope.row.remark"></el-input>
136 137
         </template>
137 138
       </el-table-column>
138 139
       <el-table-column align="center" width="40" prop="name" label="操作">

+ 125 - 17
src/xt_pages/hospitalStation/doctorDesk.vue Целия файл

@@ -463,6 +463,8 @@
463 463
               obj['id'] = drug_month_prescriptions.advices[a].drug_id;
464 464
               // obj['retail_price'] = obj['retail_price'] +  drug_month_prescriptions.advices[a].drug.retail_price
465 465
               obj['retail_price'] = parseFloat(drug_month_prescriptions.advices[a].price);
466
+              obj['drug'] = drug_month_prescriptions.advices[a].drug
467
+
466 468
               count = count + drug_month_prescriptions.advices[a].prescribing_number
467 469
 
468 470
             }
@@ -476,6 +478,21 @@
476 478
           let count = 0;
477 479
           for (let a = 0; a < project_month_prescriptions.project.length; a++) {
478 480
             if (project_ids[i].price == project_month_prescriptions.project[a].price) {
481
+
482
+              if(project_month_prescriptions.project[a].type == 2){
483
+                obj['statistical_classification'] =  project_month_prescriptions.project[a].project.statistical_classification
484
+                obj['medical_code'] =  project_month_prescriptions.project[a].project.medical_code
485
+                obj['project_name'] =  project_month_prescriptions.project[a].project.project_name
486
+
487
+
488
+              }else if(project_month_prescriptions.project[a].type == 3){
489
+                obj['statistical_classification'] = ""
490
+                obj['medical_code'] =  project_month_prescriptions.project[a].good_info.medical_insurance_number
491
+                obj['project_name'] =  project_month_prescriptions.project[a].good_info.good_name
492
+
493
+              }
494
+              obj['type'] = project_month_prescriptions.project[a].type
495
+
479 496
               obj['project_name'] = project_month_prescriptions.project[a].project.project_name;
480 497
               obj['statistical_classification'] = project_month_prescriptions.project[a].project.statistical_classification;
481 498
               obj['single_dose'] = project_month_prescriptions.project[a].single_dose;
@@ -776,7 +793,6 @@
776 793
             this.patientInfo = response.data.data.xt_info;
777 794
             this.hisPatientInfo = response.data.data.his_info;
778 795
             this.case_history = response.data.data.case_history;
779
-            console.log("病历222222",this.case_history);
780 796
             this.info = response.data.data.info;
781 797
             this.doctors = response.data.data.doctors;
782 798
             this.department = response.data.data.department;
@@ -833,6 +849,9 @@
833 849
             //处方相关
834 850
             this.prescriptionList = response.data.data.prescription;
835 851
 
852
+
853
+
854
+
836 855
             if (response.data.data.prescription.length > 0) {
837 856
               for (let i = 0; i < response.data.data.prescription.length; i++) {
838 857
                 var prescription = response.data.data.prescription[i];
@@ -856,7 +875,8 @@
856 875
                     single_dose_unit: prescription.advices[b].single_dose_unit,
857 876
                     prescribing_number_unit: prescription.advices[b].prescribing_number_unit,
858 877
                     medical_insurance_number: prescription.advices[b].med_list_codg,
859
-                    id: prescription.advices[b].drug_id
878
+                    id: prescription.advices[b].drug_id,
879
+                    drug:prescription.advices[b].drug,
860 880
                   };
861 881
                   tempAdvice.push(obj)
862 882
                 }
@@ -878,7 +898,19 @@
878 898
                     remark: prescription.project[b].remark,
879 899
                     medical_code: prescription.project[b].project.medical_code,
880 900
                     unit: prescription.project[b].project.unit,
901
+                    type: prescription.project[b].type
881 902
                   };
903
+
904
+                  if(prescription.project[b].type == 2){
905
+                    obj['statistical_classification'] =  prescription.project[b].project.statistical_classification
906
+                    obj['medical_code'] =  prescription.project[b].project.medical_code
907
+                    obj['project_name'] =  prescription.project[b].project.project_name
908
+
909
+                  }else if(prescription.project[b].type == 3){
910
+                    obj['statistical_classification'] = ""
911
+                    obj['medical_code'] =  prescription.project[b].good_info.medical_insurance_number
912
+                    obj['project_name'] =  prescription.project[b].good_info.good_name
913
+                  }
882 914
                   tempProject.push(obj)
883 915
                 }
884 916
 
@@ -916,13 +948,16 @@
916 948
                 this.prescriptions.push(obj)
917 949
               }
918 950
             } else {
951
+
952
+
953
+
919 954
               let obj = {
920 955
                 id: 0,
921 956
                 name: '处方' + 1,
922 957
                 advices: [],
923 958
                 project: [],
924 959
                 addition: [],
925
-                orderStatus: 0,
960
+                order_status: 0,
926 961
                 pre_time: nowTime,
927 962
 
928 963
               };
@@ -1046,7 +1081,8 @@
1046 1081
                           single_dose_unit: prescription.advices[b].single_dose_unit,
1047 1082
                           prescribing_number_unit: prescription.advices[b].prescribing_number_unit,
1048 1083
                           medical_insurance_number: prescription.advices[b].med_list_codg,
1049
-                          id: prescription.advices[b].drug_id
1084
+                          id: prescription.advices[b].drug_id,
1085
+                          drug:prescription.advices[b].drug,
1050 1086
                         };
1051 1087
                         tempAdvice.push(obj)
1052 1088
                       }
@@ -1064,8 +1100,19 @@
1064 1100
                           price: prescription.project[b].price,
1065 1101
                           remark: prescription.project[b].remark,
1066 1102
                           medical_code: prescription.project[b].project.medical_code,
1067
-                          unit: prescription.project[b].unit
1103
+                          unit: prescription.project[b].unit,
1104
+                          type: prescription.project[b].type,
1068 1105
                         };
1106
+                        if(prescription.project[b].type == 2){
1107
+                          obj['statistical_classification'] =  prescription.project[b].project.statistical_classification
1108
+                          obj['medical_code'] =  prescription.project[b].project.medical_code
1109
+                          obj['project_name'] =  prescription.project[b].project.project_name
1110
+
1111
+                        }else if(prescription.project[b].type == 3){
1112
+                          obj['statistical_classification'] = ""
1113
+                          obj['medical_code'] =  prescription.project[b].good_info.medical_insurance_number
1114
+                          obj['project_name'] =  prescription.project[b].good_info.good_name
1115
+                        }
1069 1116
                         tempProject.push(obj)
1070 1117
                       }
1071 1118
                       for (let b = 0; b < prescription.addition.length; b++) {
@@ -1106,7 +1153,7 @@
1106 1153
                       advices: [],
1107 1154
                       project: [],
1108 1155
                       addition: [],
1109
-                      orderStatus: 0,
1156
+                      order_status: 0,
1110 1157
                       pre_time: nowTime,
1111 1158
                     };
1112 1159
                     this.prescriptions.push(obj)
@@ -1215,7 +1262,9 @@
1215 1262
                           single_dose_unit: prescription.advices[b].single_dose_unit,
1216 1263
                           prescribing_number_unit: prescription.advices[b].prescribing_number_unit,
1217 1264
                           medical_insurance_number: prescription.advices[b].med_list_codg,
1218
-                          id: prescription.advices[b].drug_id
1265
+                          id: prescription.advices[b].drug_id,
1266
+                          drug:prescription.advices[b].drug,
1267
+
1219 1268
                         };
1220 1269
                         tempAdvice.push(obj)
1221 1270
                       }
@@ -1233,8 +1282,22 @@
1233 1282
                           price: prescription.project[b].price,
1234 1283
                           remark: prescription.project[b].remark,
1235 1284
                           medical_code: prescription.project[b].project.medical_code,
1236
-                          unit: prescription.project[b].unit
1285
+                          unit: prescription.project[b].unit,
1286
+                          type:prescription.project[b].type,
1287
+
1237 1288
                         };
1289
+                        if(prescription.project[b].type == 2){
1290
+                          obj['statistical_classification'] =  prescription.project[b].project.statistical_classification
1291
+                          obj['medical_code'] =  prescription.project[b].project.medical_code
1292
+                          obj['project_name'] =  prescription.project[b].project.project_name
1293
+
1294
+                        }else if(prescription.project[b].type == 3){
1295
+                          obj['statistical_classification'] = ""
1296
+                          obj['medical_code'] =  prescription.project[b].good_info.medical_insurance_number
1297
+                          obj['project_name'] =  prescription.project[b].good_info.good_name
1298
+                        }
1299
+
1300
+
1238 1301
                         tempProject.push(obj)
1239 1302
                       }
1240 1303
                       for (let b = 0; b < prescription.addition.length; b++) {
@@ -1275,7 +1338,7 @@
1275 1338
                       advices: [],
1276 1339
                       project: [],
1277 1340
                       addition: [],
1278
-                      orderStatus: 0,
1341
+                      order_status: 0,
1279 1342
                       pre_time: nowTime,
1280 1343
                     };
1281 1344
                     this.prescriptions.push(obj)
@@ -1385,7 +1448,9 @@
1385 1448
                           single_dose_unit: prescription.advices[b].single_dose_unit,
1386 1449
                           prescribing_number_unit: prescription.advices[b].prescribing_number_unit,
1387 1450
                           medical_insurance_number: prescription.advices[b].med_list_codg,
1388
-                          id: prescription.advices[b].drug_id
1451
+                          id: prescription.advices[b].drug_id,
1452
+                          drug:prescription.advices[b].drug,
1453
+
1389 1454
                         };
1390 1455
                         tempAdvice.push(obj)
1391 1456
                       }
@@ -1403,8 +1468,21 @@
1403 1468
                           price: prescription.project[b].price,
1404 1469
                           remark: prescription.project[b].remark,
1405 1470
                           medical_code: prescription.project[b].project.medical_code,
1406
-                          unit: prescription.project[b].unit
1471
+                          unit: prescription.project[b].unit,
1472
+                          type:prescription.project[b].type,
1473
+
1407 1474
                         };
1475
+                        if(prescription.project[b].type == 2){
1476
+                          obj['statistical_classification'] =  prescription.project[b].project.statistical_classification
1477
+                          obj['medical_code'] =  prescription.project[b].project.medical_code
1478
+                          obj['project_name'] =  prescription.project[b].project.project_name
1479
+
1480
+                        }else if(prescription.project[b].type == 3){
1481
+                          obj['statistical_classification'] = ""
1482
+                          obj['medical_code'] =  prescription.project[b].good_info.medical_insurance_number
1483
+                          obj['project_name'] =  prescription.project[b].good_info.good_name
1484
+                        }
1485
+
1408 1486
                         tempProject.push(obj)
1409 1487
                       }
1410 1488
                       for (let b = 0; b < prescription.addition.length; b++) {
@@ -1445,7 +1523,7 @@
1445 1523
                       advices: [],
1446 1524
                       project: [],
1447 1525
                       addition: [],
1448
-                      orderStatus: 0,
1526
+                      order_status: 0,
1449 1527
                       pre_time: nowTime,
1450 1528
                     };
1451 1529
                     this.prescriptions.push(obj)
@@ -1607,7 +1685,9 @@
1607 1685
                         single_dose_unit: prescription.advices[b].single_dose_unit,
1608 1686
                         prescribing_number_unit: prescription.advices[b].prescribing_number_unit,
1609 1687
                         medical_insurance_number: prescription.advices[b].med_list_codg,
1610
-                        id: prescription.advices[b].drug_id
1688
+                        id: prescription.advices[b].drug_id,
1689
+                        drug:prescription.advices[b].drug,
1690
+
1611 1691
                       };
1612 1692
                       tempAdvice.push(obj)
1613 1693
                     }
@@ -1625,8 +1705,21 @@
1625 1705
                         price: prescription.project[b].price,
1626 1706
                         remark: prescription.project[b].remark,
1627 1707
                         medical_code: prescription.project[b].project.medical_code,
1628
-                        unit: prescription.project[b].unit
1708
+                        unit: prescription.project[b].unit,
1709
+                        type:prescription.project[b].type,
1710
+
1629 1711
                       };
1712
+                      if(prescription.project[b].type == 2){
1713
+                        obj['statistical_classification'] =  prescription.project[b].project.statistical_classification
1714
+                        obj['medical_code'] =  prescription.project[b].project.medical_code
1715
+                        obj['project_name'] =  prescription.project[b].project.project_name
1716
+
1717
+                      }else if(prescription.project[b].type == 3){
1718
+                        obj['statistical_classification'] = ""
1719
+                        obj['medical_code'] =  prescription.project[b].good_info.medical_insurance_number
1720
+                        obj['project_name'] =  prescription.project[b].good_info.good_name
1721
+                      }
1722
+
1630 1723
                       tempProject.push(obj)
1631 1724
                     }
1632 1725
                     for (let b = 0; b < prescription.addition.length; b++) {
@@ -1669,7 +1762,7 @@
1669 1762
                     advices: [],
1670 1763
                     project: [],
1671 1764
                     addition: [],
1672
-                    orderStatus: 0,
1765
+                    order_status: 0,
1673 1766
                     pre_time: nowTime
1674 1767
 
1675 1768
                   };
@@ -1782,7 +1875,9 @@
1782 1875
                       single_dose_unit: prescription.advices[b].single_dose_unit,
1783 1876
                       prescribing_number_unit: prescription.advices[b].prescribing_number_unit,
1784 1877
                       medical_insurance_number: prescription.advices[b].med_list_codg,
1785
-                      id: prescription.advices[b].drug_id
1878
+                      id: prescription.advices[b].drug_id,
1879
+                      drug:prescription.advices[b].drug,
1880
+
1786 1881
                     };
1787 1882
                     tempAdvice.push(obj)
1788 1883
                   }
@@ -1800,8 +1895,21 @@
1800 1895
                       price: prescription.project[b].price,
1801 1896
                       remark: prescription.project[b].remark,
1802 1897
                       medical_code: prescription.project[b].project.medical_code,
1898
+                      type:prescription.project[b].type,
1899
+
1803 1900
                       unit: prescription.project[b].unit
1804 1901
                     };
1902
+                    if(prescription.project[b].type == 2){
1903
+                      obj['statistical_classification'] =  prescription.project[b].project.statistical_classification
1904
+                      obj['medical_code'] =  prescription.project[b].project.medical_code
1905
+                      obj['project_name'] =  prescription.project[b].project.project_name
1906
+
1907
+                    }else if(prescription.project[b].type == 3){
1908
+                      obj['statistical_classification'] = ""
1909
+                      obj['medical_code'] =  prescription.project[b].good_info.medical_insurance_number
1910
+                      obj['project_name'] =  prescription.project[b].good_info.good_name
1911
+                    }
1912
+
1805 1913
                     tempProject.push(obj)
1806 1914
                   }
1807 1915
                   for (let b = 0; b < prescription.addition.length; b++) {
@@ -1842,7 +1950,7 @@
1842 1950
                   advices: [],
1843 1951
                   project: [],
1844 1952
                   addition: [],
1845
-                  orderStatus: 0,
1953
+                  order_status: 0,
1846 1954
                   pre_time: nowTime,
1847 1955
                 };
1848 1956
                 this.prescriptions.push(obj)

+ 26 - 16
src/xt_pages/hospitalStation/listPrint.vue Целия файл

@@ -51,41 +51,50 @@
51 51
       getInfo(order_id) {
52 52
         let params = {
53 53
           id: order_id
54
-        };
54
+        }
55 55
         getHisOrderDetail(params).then(response => {
56 56
           if (response.data.state == 0) {
57
-            this.$message.error(response.data.msg);
57
+            this.$message.error(response.data.msg)
58 58
             return false
59 59
           } else {
60
-            this.order = response.data.data.order;
61
-            this.patient = response.data.data.patient;
62
-            console.log(this.patient);
63
-            this.admin = response.data.data.admin_info;
60
+            this.order = response.data.data.order
61
+            this.patient = response.data.data.patient
62
+            console.log(this.patient)
63
+            this.admin = response.data.data.admin_info
64 64
 
65 65
 
66 66
             for (let i = 0; i < response.data.data.order_info.length; i++) {
67
-              var infos = response.data.data.order_info[i];
67
+              var infos = response.data.data.order_info[i]
68 68
               let obj = {
69 69
                 med_chrgitm_type: this.getType(infos.med_chrgitm_type),
70 70
                 price: infos.pric,
71 71
                 count: infos.cnt
72
-              };
72
+              }
73
+              console.log(infos)
73 74
               if (infos.advice && infos.advice.id == 0 && infos.project && infos.project.id > 0) {
74
-                obj['p_time'] = this.getTimes(infos.project.prescription.ctime);
75
-                obj['name'] = infos.project.project.project_name;
76
-                obj['spec'] = 1;
77
-                obj['unit'] = infos.project.project.unit
75
+                obj['p_time'] = this.getTimes(infos.project.prescription.ctime)
76
+                if(infos.project.type == 2){
77
+                  obj['name'] = infos.project.project.project_name
78
+
79
+
80
+                }else if (infos.project.type == 3){
81
+
82
+                  obj['name'] = infos.project.good_info.good_name
83
+
84
+                }
85
+                obj['spec'] = 1
86
+                obj['unit'] = infos.project.unit
78 87
 
79 88
               }
80 89
 
81 90
               if (infos.advice && infos.advice.id > 0 && infos.project && infos.project.id == 0) {
82
-                obj['p_time'] = this.getTimes(infos.advice.prescription.ctime);
83
-                obj['name'] = infos.advice.advice_name;
84
-                obj['spec'] = infos.advice.drug.drug_spec;
91
+                obj['p_time'] = this.getTimes(infos.advice.prescription.ctime)
92
+                obj['name'] = infos.advice.advice_name
93
+                obj['spec'] = infos.advice.drug.drug_spec
85 94
                 obj['unit'] = infos.advice.drug.max_unit
86 95
 
87 96
               }
88
-              this.list.push(obj);
97
+              this.list.push(obj)
89 98
               this.list.sort(function(a, b) {
90 99
                 return b.p_time < a.p_time ? 1 : -1
91 100
               })
@@ -94,6 +103,7 @@
94 103
           }
95 104
         })
96 105
       },
106
+
97 107
       getType(med_chrgitm_type) {
98 108
         switch (med_chrgitm_type) {
99 109
           case '01':

+ 7 - 1
src/xt_pages/hospitalStation/newStatementPrint.vue Целия файл

@@ -147,6 +147,8 @@
147 147
         //       console.log("doctorporject",doctorPorject)
148 148
         //     }
149 149
         // })
150
+      },  getTimes(time) {
151
+        return uParseTime(time, '{y}-{m}-{d}')
150 152
       },
151 153
       searchAction(){
152 154
 
@@ -221,7 +223,11 @@
221 223
                 that.info['treat_cost_total'] = response.data.data.treatCostTotal;
222 224
                 that.info['treat_cost_self_total'] = response.data.data.treatCostSelfTotal;
223 225
                 that.info['treat_cost_part_self_total'] = response.data.data.treatCostPartSelfTotal;
224
-                console.log(this.info)
226
+
227
+                if(that.paramsObj.settle_type != 1){
228
+                  that.info.begndate = that.getTimes(that.paramsObj.start_time)
229
+                  that.info.enddate = that.getTimes(that.paramsObj.end_time)
230
+                }
225 231
               }
226 232
             })
227 233
             .catch(function (error) {

+ 54 - 13
src/xt_pages/hospitalStation/outpatientChargesManagement.vue Целия файл

@@ -1028,12 +1028,9 @@
1028 1028
               }
1029 1029
 
1030 1030
               for (let b = 0; b < prescription.project.length; b++) {
1031
-                console.log(prescription.project[b].project.project_name);
1032 1031
                 let obj = {
1033 1032
                   id: prescription.project[b].id,
1034 1033
                   project_id: prescription.project[b].project.id,
1035
-                  project_name: prescription.project[b].project.project_name,
1036
-                  statistical_classification: prescription.project[b].project.statistical_classification,
1037 1034
                   single_dose: prescription.project[b].single_dose,
1038 1035
                   delivery_way: prescription.project[b].delivery_way,
1039 1036
                   execution_frequency: prescription.project[b].execution_frequency,
@@ -1041,9 +1038,22 @@
1041 1038
                   total: prescription.project[b].count.toString(),
1042 1039
                   price: prescription.project[b].price,
1043 1040
                   remark: prescription.project[b].remark,
1044
-                  medical_code: prescription.project[b].project.medical_code,
1045
-                  unit: prescription.project[b].unit
1041
+                  // medical_code: prescription.project[b].project.medical_code,
1042
+                  unit: prescription.project[b].unit,
1043
+                  type:prescription.project[b].type,
1044
+
1046 1045
                 };
1046
+                if(prescription.project[b].type == 2){
1047
+                  obj['statistical_classification'] =  prescription.project[b].project.statistical_classification
1048
+                  obj['medical_code'] =  prescription.project[b].project.medical_code
1049
+                  obj['project_name'] =  prescription.project[b].project.project_name
1050
+
1051
+                }else if(prescription.project[b].type == 3){
1052
+                  obj['statistical_classification'] = ""
1053
+                  obj['medical_code'] =  prescription.project[b].good_info.medical_insurance_number
1054
+                  obj['project_name'] =  prescription.project[b].good_info.good_name
1055
+                }
1056
+
1047 1057
 
1048 1058
                 tempProject.push(obj)
1049 1059
               }
@@ -2606,13 +2616,29 @@
2606 2616
           let count = 0;
2607 2617
           for (let a = 0; a < project_month_prescriptions.project.length; a++) {
2608 2618
             if (project_ids[i].price == project_month_prescriptions.project[a].price && project_ids[i].id == project_month_prescriptions.project[a].project_id) {
2609
-              obj['project_name'] = project_month_prescriptions.project[a].project.project_name;
2610
-              obj['statistical_classification'] = project_month_prescriptions.project[a].project.statistical_classification;
2619
+
2620
+              if(project_month_prescriptions.project[a].type == 2){
2621
+                obj['statistical_classification'] =  project_month_prescriptions.project[a].project.statistical_classification
2622
+                obj['medical_code'] =  project_month_prescriptions.project[a].project.medical_code
2623
+                obj['project_name'] =  project_month_prescriptions.project[a].project.project_name
2624
+                obj['type'] = 2
2625
+
2626
+              }else if(project_month_prescriptions.project[a].type == 3){
2627
+                obj['statistical_classification'] = ""
2628
+                obj['medical_code'] =  project_month_prescriptions.project[a].good_info.medical_insurance_number
2629
+                obj['project_name'] =  project_month_prescriptions.project[a].good_info.good_name
2630
+                obj['type'] = 3
2631
+
2632
+              }
2633
+
2634
+
2635
+              // obj['project_name'] = project_month_prescriptions.project[a].project.project_name;
2636
+              // obj['statistical_classification'] = project_month_prescriptions.project[a].project.statistical_classification;
2611 2637
               obj['single_dose'] = project_month_prescriptions.project[a].single_dose;
2612 2638
               obj['delivery_way'] = project_month_prescriptions.project[a].delivery_way;
2613 2639
               obj['execution_frequency'] = project_month_prescriptions.project[a].execution_frequency;
2614 2640
               obj['number_days'] = project_month_prescriptions.project[a].day;
2615
-              obj['medical_code'] = project_month_prescriptions.project[a].project.medical_code;
2641
+              // obj['medical_code'] = project_month_prescriptions.project[a].project.medical_code;
2616 2642
               obj['unit'] = project_month_prescriptions.project[a].unit;
2617 2643
               obj['project_id'] = project_month_prescriptions.project[a].project_id;
2618 2644
               count = count + project_month_prescriptions.project[a].count;
@@ -2800,12 +2826,11 @@
2800 2826
               }
2801 2827
 
2802 2828
               for (let b = 0; b < prescription.project.length; b++) {
2803
-                console.log(prescription.project[b].project.project_name);
2804 2829
                 let obj = {
2805 2830
                   id: prescription.project[b].id,
2806 2831
                   project_id: prescription.project[b].project.id,
2807
-                  project_name: prescription.project[b].project.project_name,
2808
-                  statistical_classification: prescription.project[b].project.statistical_classification,
2832
+                  // project_name: prescription.project[b].project.project_name,
2833
+                  // statistical_classification: prescription.project[b].project.statistical_classification,
2809 2834
                   single_dose: prescription.project[b].single_dose,
2810 2835
                   delivery_way: prescription.project[b].delivery_way,
2811 2836
                   execution_frequency: prescription.project[b].execution_frequency,
@@ -2813,9 +2838,25 @@
2813 2838
                   total: prescription.project[b].count.toString(),
2814 2839
                   price: prescription.project[b].price,
2815 2840
                   remark: prescription.project[b].remark,
2816
-                  medical_code: prescription.project[b].project.medical_code,
2817
-                  unit: prescription.project[b].project.unit
2841
+                  // medical_code: prescription.project[b].project.medical_code,
2842
+                  unit: prescription.project[b].project.unit,
2843
+                  type:prescription.project[b].type,
2844
+
2818 2845
                 };
2846
+
2847
+                if(prescription.project[b].type == 2){
2848
+                  obj['statistical_classification'] =  prescription.project[b].project.statistical_classification
2849
+                  obj['medical_code'] =  prescription.project[b].project.medical_code
2850
+                  obj['project_name'] =  prescription.project[b].project.project_name
2851
+
2852
+                }else if(prescription.project[b].type == 3){
2853
+                  obj['statistical_classification'] = ""
2854
+                  obj['medical_code'] =  prescription.project[b].good_info.medical_insurance_number
2855
+                  obj['project_name'] =  prescription.project[b].good_info.good_name
2856
+                }
2857
+
2858
+
2859
+
2819 2860
                 tempProject.push(obj)
2820 2861
               }
2821 2862
 

+ 7 - 2
src/xt_pages/hospitalStation/summary.vue Целия файл

@@ -505,13 +505,18 @@
505 505
             order_id: row.id,
506 506
             patient_id: row.patient_id,
507 507
             record_time: this.getTimes(row.settle_accounts_date),
508
-            admin_user_id: this.$store.getters.xt_user.user.id
508
+            admin_user_id: this.$store.getters.xt_user.user.id,
509
+
510
+
509 511
           };
510 512
           this.orderObj9504 = obj
511 513
         } else {
512 514
           this.statementVisible = true;
513 515
           let obj = {
514
-            order_id: row.id
516
+            order_id: row.id,
517
+            settle_type:row.settle_type,
518
+            start_time:row.settle_start_time,
519
+            end_time:row.settle_end_time,
515 520
           };
516 521
           this.orderObj = obj
517 522
         }

+ 294 - 284
src/xt_pages/hospitalStation/summaryDetail.vue Целия файл

@@ -3,99 +3,99 @@
3 3
         <div class="position">
4 4
             <bread-crumb :crumbs='crumbs'></bread-crumb>
5 5
         </div>
6
-      <el-popover
7
-        placement="bottom"
8
-        width="210"
9
-        trigger="click">
10
-        <el-button size="small" ref="button_two" @click="open(1)">打印清单</el-button>
11
-        <el-button size="small" ref="button_six" @click="open(2)">打印汇总</el-button>
12
-        <el-button  slot="reference" style="margin:10px 10px;float: right" type="primary" size="small" >打印</el-button>
13
-
14
-      </el-popover>
6
+        <el-popover
7
+                placement="bottom"
8
+                width="210"
9
+                trigger="click">
10
+            <el-button size="small" ref="button_two" @click="open(1)">打印清单</el-button>
11
+            <el-button size="small" ref="button_six" @click="open(2)">打印汇总</el-button>
12
+            <el-button  slot="reference" style="margin:10px 10px;float: right" type="primary" size="small" >打印</el-button>
13
+
14
+        </el-popover>
15 15
         <div class="app-container" style="display:flex;flex: 1;padding: 20px 20px 0px 20px;">
16 16
             <div class="mainCenter">
17 17
                 <div class="centerLeft">
18 18
                     <div class="tabsBox">
19
-                      <el-table  :data="tableData" border style="width: 100%;"
20
-                                :row-style="{ color: '#303133' }"
21
-                                :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}" highlight-current-row>
22
-
23
-                        <el-table-column align="center" prop="project_name" label="名称">
24
-                          <template slot-scope="scope">{{ scope.row.name }}</template>
25
-                        </el-table-column>
26
-
27
-                        <el-table-column align="center" prop="project_name" label="分类" width="100">
28
-                          <template slot-scope="scope">{{ scope.row.type == 1?'药品':'项目' }}</template>
29
-                        </el-table-column>
30
-
31
-
32
-                        <el-table-column align="center" prop="single_dose" width="80" label="单次用量">
33
-                          <template slot-scope="scope">{{scope.row.single_dose}}&nbsp;&nbsp;{{scope.row.single_dose_unit}}</template>
34
-
35
-                        </el-table-column>
36
-                        <el-table-column align="center" prop="delivery_way" width="90" label="用法">
37
-                          <template slot-scope="scope">
38
-                            <!--<el-input v-model="scope.row.delivery_way" placeholder="" readonly></el-input>-->
39
-                            {{scope.row.delivery_way}}
40
-
41
-                          </template>
42
-                        </el-table-column>
43
-                        <el-table-column align="center" prop="execution_frequency" width="90" label="频率">
44
-                          <template slot-scope="scope">{{scope.row.execution_frequency}}</template>
45
-                        </el-table-column>
46
-                        <el-table-column align="center" prop="number_days" width="60" label="天数">
47
-                          <template slot-scope="scope">
48
-                            <!--<el-input v-model="scope.row.number_days" placeholder="" readonly></el-input>-->
49
-                            {{scope.row.day}}天
50
-
51
-                          </template>
52
-                        </el-table-column>
53
-                        <el-table-column align="center" prop="total" width="60" label="总量">
54
-                          <template slot-scope="scope">{{scope.row.count}}&nbsp;&nbsp;{{scope.row.prescribing_number_unit}}</template>
55
-                        </el-table-column>
56
-                        <el-table-column align="center" prop="name" width="60" label="单价">
57
-                          <template slot-scope="scope">
58
-                            <!--<el-input v-model="scope.row.price" placeholder="" readonly></el-input>-->
59
-                            {{scope.row.price}}元
60
-
61
-                          </template>
62
-                        </el-table-column>
63
-
64
-                          <el-table-column align="center" prop="name" width="60" label="总价">
65
-                              <template slot-scope="scope">
66
-                                  <!--<el-input v-model="scope.row.price" placeholder="" readonly></el-input>-->
67
-                                  {{scope.row.price}}元
68
-
69
-                              </template>
70
-                          </el-table-column>
71
-
72
-
73
-                        <el-table-column align="center" prop="name" width="80" label="备注">
74
-                          <template slot-scope="scope">
75
-                            <!--<el-input v-model="scope.row.remark" readonly></el-input>-->
76
-                            {{scope.row.remark}}
77
-
78
-                          </template>
79
-                        </el-table-column>
80
-                      </el-table>
81
-
82
-                      <div class="additionalBox">
83
-                        <div class="additionalOne" v-for="(item,index) in additions" :key="index">
84
-                          <span :title="item.item_name">{{item.item_name}}</span>
85
-                          <el-input v-model="item.price" placeholder="" style="width:50px;" readonly></el-input>
86
-                          共
87
-                          <el-input v-model="item.count" placeholder="" style="width:50px;" readonly></el-input>
88
-                          次
89
-                          <!--<i class="el-icon-delete deleteIcon" @click="delAddition(index,item)"></i>-->
19
+                        <el-table  :data="tableData" border style="width: 100%;"
20
+                                   :row-style="{ color: '#303133' }"
21
+                                   :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}" highlight-current-row>
22
+
23
+                            <el-table-column align="center" prop="project_name" label="名称">
24
+                                <template slot-scope="scope">{{ scope.row.name }}</template>
25
+                            </el-table-column>
26
+
27
+                            <el-table-column align="center" prop="project_name" label="分类" width="100">
28
+                                <template slot-scope="scope">{{ scope.row.type == 1?'药品': scope.row.project_type == 2? '项目':'耗材'}}</template>
29
+                            </el-table-column>
30
+
31
+
32
+                            <el-table-column align="center" prop="single_dose" width="80" label="单次用量">
33
+                                <template slot-scope="scope">{{scope.row.single_dose}}&nbsp;&nbsp;{{scope.row.single_dose_unit}}</template>
34
+
35
+                            </el-table-column>
36
+                            <el-table-column align="center" prop="delivery_way" width="90" label="用法">
37
+                                <template slot-scope="scope">
38
+                                    <!--<el-input v-model="scope.row.delivery_way" placeholder="" readonly></el-input>-->
39
+                                    {{scope.row.delivery_way}}
40
+
41
+                                </template>
42
+                            </el-table-column>
43
+                            <el-table-column align="center" prop="execution_frequency" width="90" label="频率">
44
+                                <template slot-scope="scope">{{scope.row.execution_frequency}}</template>
45
+                            </el-table-column>
46
+                            <el-table-column align="center" prop="number_days" width="60" label="天数">
47
+                                <template slot-scope="scope">
48
+                                    <!--<el-input v-model="scope.row.number_days" placeholder="" readonly></el-input>-->
49
+                                    {{scope.row.day}}天
50
+
51
+                                </template>
52
+                            </el-table-column>
53
+                            <el-table-column align="center" prop="total" width="60" label="总量">
54
+                                <template slot-scope="scope">{{scope.row.count}}&nbsp;&nbsp;{{scope.row.prescribing_number_unit}}</template>
55
+                            </el-table-column>
56
+                            <el-table-column align="center" prop="name" width="60" label="单价">
57
+                                <template slot-scope="scope">
58
+                                    <!--<el-input v-model="scope.row.price" placeholder="" readonly></el-input>-->
59
+                                    {{scope.row.price}}元
60
+
61
+                                </template>
62
+                            </el-table-column>
63
+
64
+                            <el-table-column align="center" prop="name" width="60" label="总价">
65
+                                <template slot-scope="scope">
66
+                                    <!--<el-input v-model="scope.row.price" placeholder="" readonly></el-input>-->
67
+                                    {{scope.row.price}}元
68
+
69
+                                </template>
70
+                            </el-table-column>
71
+
72
+
73
+                            <el-table-column align="center" prop="name" width="80" label="备注">
74
+                                <template slot-scope="scope">
75
+                                    <!--<el-input v-model="scope.row.remark" readonly></el-input>-->
76
+                                    {{scope.row.remark}}
77
+
78
+                                </template>
79
+                            </el-table-column>
80
+                        </el-table>
81
+
82
+                        <div class="additionalBox">
83
+                            <div class="additionalOne" v-for="(item,index) in additions" :key="index">
84
+                                <span :title="item.item_name">{{item.item_name}}</span>
85
+                                <el-input v-model="item.price" placeholder="" style="width:50px;" readonly></el-input>
86
+                                共
87
+                                <el-input v-model="item.count" placeholder="" style="width:50px;" readonly></el-input>
88
+                                次
89
+                                <!--<i class="el-icon-delete deleteIcon" @click="delAddition(index,item)"></i>-->
90
+                            </div>
90 91
                         </div>
91
-                      </div>
92 92
 
93 93
                     </div>
94 94
                     <div class="costBox">
95
-                      <span>当前处方总费用:<span style="color:red;">{{ order.medfee_sumamt}}元</span></span>
96
-                      <span v-if="order.order_status == 1">待结算</span>
97
-                      <span v-if="order.order_status == 2">已结算</span>
98
-                      <span v-if="order.order_status == 3">已退费</span>
95
+                        <span>当前处方总费用:<span style="color:red;">{{ order.medfee_sumamt}}元</span></span>
96
+                        <span v-if="order.order_status == 1">待结算</span>
97
+                        <span v-if="order.order_status == 2">已结算</span>
98
+                        <span v-if="order.order_status == 3">已退费</span>
99 99
 
100 100
 
101 101
                     </div>
@@ -121,37 +121,36 @@
121 121
                     </ul>
122 122
                     <!--<p class="centerRightTitle">发票费用</p>-->
123 123
                     <!--<ul class="basicUl">-->
124
-                        <!--<li style="width:100%;">西药费:0.00元</li>-->
124
+                    <!--<li style="width:100%;">西药费:0.00元</li>-->
125 125
                     <!--</ul>-->
126 126
                 </div>
127 127
             </div>
128 128
         </div>
129 129
 
130
-      <div v-if="listVisible">
131
-      <el-dialog
132
-        class="centerDialog"
133
-        width="900px"
134
-        title="打印"
135
-        :visible.sync="listVisible">
136
-        <list-print  :paramsObj='paramsObj'></list-print>
137
-      </el-dialog>
138
-      </div>
139
-
140
-      <div v-if="allListVisible">
141
-      <el-dialog
142
-        class="centerDialog"
143
-        width="900px"
144
-        title="打印"
145
-        :visible.sync="allListVisible">
146
-        <all-list-print :paramsObj='paramsObj'></all-list-print>
147
-      </el-dialog>
148
-      </div>
130
+        <div v-if="listVisible">
131
+            <el-dialog
132
+                    class="centerDialog"
133
+                    width="900px"
134
+                    title="打印"
135
+                    :visible.sync="listVisible">
136
+                <list-print  :paramsObj='paramsObj'></list-print>
137
+            </el-dialog>
138
+        </div>
139
+
140
+        <div v-if="allListVisible">
141
+            <el-dialog
142
+                    class="centerDialog"
143
+                    width="900px"
144
+                    title="打印"
145
+                    :visible.sync="allListVisible">
146
+                <all-list-print :paramsObj='paramsObj'></all-list-print>
147
+            </el-dialog>
148
+        </div>
149 149
 
150 150
 
151 151
     </div>
152 152
 </template>
153 153
 
154
-
155 154
 <script>
156 155
 import BreadCrumb from '@/xt_pages/components/bread-crumb'
157 156
 import { getHisOrder } from '@/api/his/his'
@@ -161,65 +160,65 @@ import ListPrint from './listPrint'
161 160
 import AllListPrint from './allListPrint'
162 161
 
163 162
 export default {
164
-    components:{
165
-      AllListPrint,
166
-      ListPrint,
167
-        BreadCrumb,
168
-      prescriptionTable,
169
-
170
-    },
171
-    data(){
172
-        return{
173
-          listVisible:false,
174
-          allListVisible:false,
175
-          paramsObj:{
176
-            id:this.$route.query.id
177
-          },
178
-            crumbs: [
179
-                { path: false, name: '门诊收费' },
180
-                { path: false, name: '项目消费明细汇总详情' }
181
-            ],
182
-          info: {},
183
-          curPrescriptions: {},
184
-          prescriptions: [],
185
-          record_date: '',
186
-          tableData: [],
187
-          additions:[],
188
-          editableTabsValue: '1',
189
-          loadingone: false,
190
-          editableTabs: [{
191
-            title: '处方1',
192
-            name: '1'
193
-          }],
194
-          tabIndex: 1,
195
-          hisPatientInfo: {},
196
-          loadingtwo: false,
197
-          patientTableData: [{
198
-            name: '杨美英',
199
-            mdtrt_id: '1709946'
200
-          }],
201
-          patientInfo: { id: 0 },
202
-          doctor: {},
203
-          total: 0,
204
-          state: '未收费',
205
-          radio: 1,
206
-          radioStatus: 1,
207
-          search_input: '',
208
-          order:{},
209
-        }
210
-    },created(){
211
-      this.GetOrderDetail()
212
-  },methods:{
213
-      open(val){
214
-        if(val == 1){
215
-          this.paramsObj.id == this.$route.query.id;
216
-          this.listVisible = true
217
-
218
-        }else if(val == 2){
219
-          this.paramsObj.id == this.$route.query.id;
220
-          this.allListVisible = true
221
-        }
163
+  components:{
164
+    AllListPrint,
165
+    ListPrint,
166
+    BreadCrumb,
167
+    prescriptionTable,
168
+
169
+  },
170
+  data(){
171
+    return{
172
+      listVisible:false,
173
+      allListVisible:false,
174
+      paramsObj:{
175
+        id:this.$route.query.id
222 176
       },
177
+      crumbs: [
178
+        { path: false, name: '门诊收费' },
179
+        { path: false, name: '项目消费明细汇总详情' }
180
+      ],
181
+      info: {},
182
+      curPrescriptions: {},
183
+      prescriptions: [],
184
+      record_date: '',
185
+      tableData: [],
186
+      additions:[],
187
+      editableTabsValue: '1',
188
+      loadingone: false,
189
+      editableTabs: [{
190
+        title: '处方1',
191
+        name: '1'
192
+      }],
193
+      tabIndex: 1,
194
+      hisPatientInfo: {},
195
+      loadingtwo: false,
196
+      patientTableData: [{
197
+        name: '杨美英',
198
+        mdtrt_id: '1709946'
199
+      }],
200
+      patientInfo: { id: 0 },
201
+      doctor: {},
202
+      total: 0,
203
+      state: '未收费',
204
+      radio: 1,
205
+      radioStatus: 1,
206
+      search_input: '',
207
+      order:{},
208
+    }
209
+  },created(){
210
+    this.GetOrderDetail()
211
+  },methods:{
212
+    open(val){
213
+      if(val == 1){
214
+        this.paramsObj.id == this.$route.query.id
215
+        this.listVisible = true
216
+
217
+      }else if(val == 2){
218
+        this.paramsObj.id == this.$route.query.id
219
+        this.allListVisible = true
220
+      }
221
+    },
223 222
     // getTotal() {
224 223
     //   var total = 0
225 224
     //   for (let i = 0; i < this.prescriptions.length; i++) {
@@ -253,8 +252,8 @@ export default {
253 252
     tabclickEvent(val) {
254 253
       for (let i = 0; i < this.prescriptions.length; i++) {
255 254
         if (this.prescriptions[i].name == val.name) {
256
-          this.curPrescriptions = {};
257
-          var temp = this.deepClone(this.prescriptions[i]);
255
+          this.curPrescriptions = {}
256
+          var temp = this.deepClone(this.prescriptions[i])
258 257
           this.curPrescriptions = temp
259 258
         }
260 259
       }
@@ -263,18 +262,18 @@ export default {
263 262
       if (!source && typeof source !== 'object') {
264 263
         throw new Error('error arguments', 'shallowClone')
265 264
       }
266
-      const targetObj = source.constructor === Array ? [] : {};
265
+      const targetObj = source.constructor === Array ? [] : {}
267 266
       Object.keys(source).forEach((keys) => {
268 267
         if (source[keys] && typeof source[keys] === 'object') {
269 268
           targetObj[keys] = this.deepClone(source[keys])
270 269
         } else {
271 270
           targetObj[keys] = source[keys]
272 271
         }
273
-      });
272
+      })
274 273
       return targetObj
275 274
     },  getGroup(id){
276
-      var name = "";
277
-      var statistics_category =  getDictionaryDataConfig('system','statistics_category');
275
+      var name = ""
276
+      var statistics_category =  getDictionaryDataConfig('system','statistics_category')
278 277
       for(let i=0;i<statistics_category.length;i++){
279 278
         if(id == statistics_category[i].id){
280 279
           name = statistics_category[i].name
@@ -283,7 +282,7 @@ export default {
283 282
       return name
284 283
     },
285 284
     getTotal() {
286
-      var total = 0;
285
+      var total = 0
287 286
       for (let i = 0; i < this.prescriptions.length; i++) {
288 287
         if (this.prescriptions[i].advices != null) {
289 288
           for (let a = 0; a < this.prescriptions[i].advices.length; a++) {
@@ -304,7 +303,7 @@ export default {
304 303
       }
305 304
     },  unique(array) {
306 305
       // res用来存储结果
307
-      var res = [];
306
+      var res = []
308 307
       for (var i = 0, arrayLen = array.length; i < arrayLen; i++) {
309 308
         for (var j = 0, resLen = res.length; j < resLen; j++) {
310 309
           if (array[i].id === res[j].id && array[i].price === res[j].price) {
@@ -319,22 +318,22 @@ export default {
319 318
       return res
320 319
     },
321 320
     setMonthPrescription(month_prescriptions) {
322
-      console.log(month_prescriptions);
321
+      console.log(month_prescriptions)
323 322
       let drug_month_prescriptions = {
324 323
         advices: []
325
-      };
326
-      let drug_ids = [];
324
+      }
325
+      let drug_ids = []
327 326
       let project_month_prescriptions = {
328 327
         project: []
329 328
 
330
-      };
331
-      let project_ids = [];
329
+      }
330
+      let project_ids = []
332 331
 
333 332
       let addition_month_prescriptions = {
334 333
         addition: []
335 334
 
336
-      };
337
-      let additions_ids = [];
335
+      }
336
+      let additions_ids = []
338 337
 
339 338
       for (let i = 0; i < month_prescriptions.length; i++) {
340 339
         if (month_prescriptions[i].type == 1) { //药品
@@ -343,8 +342,8 @@ export default {
343 342
               id: month_prescriptions[i].advices[a].drug_id,
344 343
               price: month_prescriptions[i].advices[a].price
345 344
 
346
-            };
347
-            drug_ids.push(obj);
345
+            }
346
+            drug_ids.push(obj)
348 347
             drug_month_prescriptions.advices.push(month_prescriptions[i].advices[a])
349 348
           }
350 349
 
@@ -354,8 +353,8 @@ export default {
354 353
               id: month_prescriptions[i].project[a].project_id,
355 354
               price: month_prescriptions[i].project[a].price
356 355
 
357
-            };
358
-            project_ids.push(obj);
356
+            }
357
+            project_ids.push(obj)
359 358
             project_month_prescriptions.project.push(month_prescriptions[i].project[a])
360 359
           }
361 360
         }
@@ -365,84 +364,94 @@ export default {
365 364
             id: month_prescriptions[i].addition[a].item_id,
366 365
             price: month_prescriptions[i].addition[a].price
367 366
 
368
-          };
369
-          additions_ids.push(obj);
367
+          }
368
+          additions_ids.push(obj)
370 369
           addition_month_prescriptions.addition.push(month_prescriptions[i].addition[a])
371 370
 
372 371
         }
373 372
 
374 373
       }
375 374
 
376
-      drug_ids = this.unique(drug_ids);
377
-      project_ids= this.unique(project_ids);
378
-      additions_ids= this.unique(additions_ids);
375
+      drug_ids = this.unique(drug_ids)
376
+      project_ids= this.unique(project_ids)
377
+      additions_ids= this.unique(additions_ids)
379 378
 
380 379
 
381 380
 
382 381
 
383 382
 
384 383
       for (let i = 0; i < drug_ids.length; i++) {
385
-        let obj = {};
386
-        let count = 0;
384
+        let obj = {}
385
+        let count = 0
387 386
         for (let a = 0; a < drug_month_prescriptions.advices.length; a++) {
388 387
           if (drug_ids[i].price == drug_month_prescriptions.advices[a].price && drug_ids[i].id ==  drug_month_prescriptions.advices[a].drug_id) {
389
-            obj['name'] = drug_month_prescriptions.advices[a].advice_name;
390
-            obj['statistical_classification'] = '';
391
-            obj['type'] = 1;
392
-            obj['single_dose'] = drug_month_prescriptions.advices[a].single_dose;
393
-            obj['delivery_way'] = drug_month_prescriptions.advices[a].delivery_way;
394
-            obj['execution_frequency'] = drug_month_prescriptions.advices[a].execution_frequency;
395
-            obj['day'] = drug_month_prescriptions.advices[a].day;
396
-            obj['prescribing_number_unit'] = drug_month_prescriptions.advices[a].prescribing_number_unit;
397
-            obj['remark'] = drug_month_prescriptions.advices[a].remark;
398
-            obj['price'] = parseFloat(drug_month_prescriptions.advices[a].price);
388
+            obj['name'] = drug_month_prescriptions.advices[a].advice_name
389
+            obj['statistical_classification'] = ''
390
+            obj['type'] = 1
391
+            obj['single_dose'] = drug_month_prescriptions.advices[a].single_dose
392
+            obj['delivery_way'] = drug_month_prescriptions.advices[a].delivery_way
393
+            obj['execution_frequency'] = drug_month_prescriptions.advices[a].execution_frequency
394
+            obj['day'] = drug_month_prescriptions.advices[a].day
395
+            obj['prescribing_number_unit'] = drug_month_prescriptions.advices[a].prescribing_number_unit
396
+            obj['remark'] = drug_month_prescriptions.advices[a].remark
397
+            obj['price'] = parseFloat(drug_month_prescriptions.advices[a].price)
399 398
             count = count + drug_month_prescriptions.advices[a].prescribing_number
400 399
 
401 400
           }
402 401
         }
403
-        obj['count'] = count;
402
+        obj['count'] = count
404 403
         this.tableData.push(obj)
405 404
       }
406 405
 
407 406
       for (let i = 0; i < project_ids.length; i++) {
408
-        let obj = {};
409
-        let count = 0;
407
+        let obj = {}
408
+        let count = 0
410 409
         for (let a = 0; a < project_month_prescriptions.project.length; a++) {
411 410
           if (project_ids[i].price == project_month_prescriptions.project[a].price &&project_ids[i].id == project_month_prescriptions.project[a].project_id ) {
412
-            obj['name'] = project_month_prescriptions.project[a].project.project_name;
413
-            obj['statistical_classification'] = '';
414
-            obj['single_dose'] = project_month_prescriptions.project[a].single_dose;
415
-            obj['delivery_way'] = project_month_prescriptions.project[a].delivery_way;
416
-            obj['execution_frequency'] = project_month_prescriptions.project[a].execution_frequency;
417
-            obj['day'] = project_month_prescriptions.project[a].day;
418
-            obj['single_dose_unit'] = project_month_prescriptions.project[a].unit;
419
-            obj['prescribing_number_unit'] = project_month_prescriptions.project[a].unit;
420
-            count = count + project_month_prescriptions.project[a].count;
421
-            obj['price'] = parseFloat(project_month_prescriptions.project[a].price);
422
-            obj['remark'] = project_month_prescriptions.project[a].remark;
411
+
412
+            if(project_month_prescriptions.project[a].type == 2){
413
+              obj['name'] = project_month_prescriptions.project[a].project.project_name
414
+              obj['statistical_classification'] = ''
415
+              obj['project_type'] = 2
416
+
417
+
418
+            }else if (project_month_prescriptions.project[a].type == 3){
419
+              obj['name'] = project_month_prescriptions.project[a].good_info.good_name
420
+              obj['statistical_classification'] = ''
421
+              obj['project_type'] = 3
422
+            }
423
+            obj['single_dose'] = project_month_prescriptions.project[a].single_dose
424
+            obj['delivery_way'] = project_month_prescriptions.project[a].delivery_way
425
+            obj['execution_frequency'] = project_month_prescriptions.project[a].execution_frequency
426
+            obj['day'] = project_month_prescriptions.project[a].day
427
+            obj['single_dose_unit'] = project_month_prescriptions.project[a].unit
428
+            obj['prescribing_number_unit'] = project_month_prescriptions.project[a].unit
429
+            count = count + project_month_prescriptions.project[a].count
430
+            obj['price'] = parseFloat(project_month_prescriptions.project[a].price)
431
+            obj['remark'] = project_month_prescriptions.project[a].remark
423 432
             obj['type'] = 2
424 433
 
425 434
 
426 435
           }
427 436
         }
428
-        obj['count'] = count;
437
+        obj['count'] = count
429 438
         this.tableData.push(obj)
430 439
 
431 440
       }
432 441
 
433 442
       for (let i = 0; i < additions_ids.length; i++) {
434
-        let obj = {};
435
-        let count = 0;
436
-        console.log(addition_month_prescriptions.addition);
443
+        let obj = {}
444
+        let count = 0
445
+        console.log(addition_month_prescriptions.addition)
437 446
         if (addition_month_prescriptions.addition) {
438 447
           for (let a = 0; a < addition_month_prescriptions.addition.length; a++) {
439 448
             if (additions_ids[i].price == addition_month_prescriptions.addition[a].price &&additions_ids[i].id == addition_month_prescriptions.addition[a].item_id) {
440
-              obj['item_name'] = addition_month_prescriptions.addition[a].item_name;
441
-              count = count + addition_month_prescriptions.addition[a].count;
449
+              obj['item_name'] = addition_month_prescriptions.addition[a].item_name
450
+              count = count + addition_month_prescriptions.addition[a].count
442 451
               obj['price'] = parseFloat(addition_month_prescriptions.addition[a].price)
443 452
             }
444 453
           }
445
-          obj['count'] = count;
454
+          obj['count'] = count
446 455
           this.additions.push(obj)
447 456
 
448 457
         }
@@ -454,23 +463,23 @@ export default {
454 463
       let params={
455 464
         number:this.$route.query.number,
456 465
         patient_id:this.$route.query.patient_id,
457
-      };
466
+      }
458 467
       getHisOrder(params).then(response => {
459 468
         if (response.data.state == 0) {
460
-          this.$message.error(response.data.msg);
469
+          this.$message.error(response.data.msg)
461 470
           return false
462 471
         } else {
463
-          this.patientInfo = response.data.data.order.patient;
464
-          this.hisPatientInfo = response.data.data.order.his_patient;
465
-          this.info = response.data.data.p_info;
466
-          this.order = response.data.data.order;
472
+          this.patientInfo = response.data.data.order.patient
473
+          this.hisPatientInfo = response.data.data.order.his_patient
474
+          this.info = response.data.data.p_info
475
+          this.order = response.data.data.order
467 476
 
468
-          this.prescriptions = [];
469
-          this.tableData = [];
477
+          this.prescriptions = []
478
+          this.tableData = []
470 479
 
471 480
 
472
-          var prescription = response.data.data.prescription;
473
-          this.prescriptions = prescription;
481
+          var prescription = response.data.data.prescription
482
+          this.prescriptions = prescription
474 483
           this.setMonthPrescription(prescription)
475 484
 
476 485
 
@@ -478,59 +487,59 @@ export default {
478 487
           //   var prescription = response.data.data.prescription[i]
479 488
 
480 489
 
481
-            // for (let b = 0; b < prescription.advices.length; b++) {
482
-            //   let obj = {
483
-            //     name: prescription.advices[b].advice_name,
484
-            //     statistical_classification:"",
485
-            //     type:1,
486
-            //     single_dose: prescription.advices[b].single_dose,
487
-            //     delivery_way: prescription.advices[b].delivery_way,
488
-            //     execution_frequency: prescription.advices[b].execution_frequency,
489
-            //     price: prescription.advices[b].price.toString(),
490
-            //     day: prescription.advices[b].day,
491
-            //     count:prescription.advices[b].prescribing_number.toString(),
492
-            //     remark: prescription.advices[b].remark,
493
-            //     single_dose_unit: prescription.advices[b].single_dose_unit,
494
-            //     prescribing_number_unit: prescription.advices[b].prescribing_number_unit,
495
-            //
496
-            //   }
497
-            //   this.tableData.push(obj)
498
-            // }
499
-            //
500
-            // for (let b = 0; b < prescription.project.length; b++) {
501
-            //   let obj = {
502
-            //     name: prescription.project[b].project.project_name,
503
-            //     statistical_classification: prescription.project[b].project.statistical_classification,
504
-            //     single_dose: prescription.project[b].single_dose,
505
-            //     delivery_way: prescription.project[b].delivery_way,
506
-            //     execution_frequency: prescription.project[b].execution_frequency,
507
-            //     price: prescription.project[b].price,
508
-            //     day: prescription.project[b].day,
509
-            //     count: prescription.project[b].count.toString(),
510
-            //     remark: prescription.project[b].remark,
511
-            //     single_dose_unit:prescription.project[b].project.unit,
512
-            //     prescribing_number_unit:prescription.project[b].project.unit,
513
-            //     type:2,
514
-            //   }
515
-            //   this.tableData.push(obj)
516
-            // }
517
-            //
518
-            // for (let b = 0; b < prescription.addition.length; b++) {
519
-            //     this.additions.push( prescription.addition[b])
520
-            // }
521
-
522
-
523
-
524
-            // let index = i + 1
525
-            // let obj = {
526
-            //   id: prescription.id,
527
-            //   name: '处方' + index,
528
-            //   advices: tempAdvice,
529
-            //   project: tempProject,
530
-            //   type: response.data.data.prescription[i].type
531
-            // }
532
-            // this.prescriptions.push(obj)
533
-            // this.curPrescriptions = this.prescriptions[0]
490
+          // for (let b = 0; b < prescription.advices.length; b++) {
491
+          //   let obj = {
492
+          //     name: prescription.advices[b].advice_name,
493
+          //     statistical_classification:"",
494
+          //     type:1,
495
+          //     single_dose: prescription.advices[b].single_dose,
496
+          //     delivery_way: prescription.advices[b].delivery_way,
497
+          //     execution_frequency: prescription.advices[b].execution_frequency,
498
+          //     price: prescription.advices[b].price.toString(),
499
+          //     day: prescription.advices[b].day,
500
+          //     count:prescription.advices[b].prescribing_number.toString(),
501
+          //     remark: prescription.advices[b].remark,
502
+          //     single_dose_unit: prescription.advices[b].single_dose_unit,
503
+          //     prescribing_number_unit: prescription.advices[b].prescribing_number_unit,
504
+          //
505
+          //   }
506
+          //   this.tableData.push(obj)
507
+          // }
508
+          //
509
+          // for (let b = 0; b < prescription.project.length; b++) {
510
+          //   let obj = {
511
+          //     name: prescription.project[b].project.project_name,
512
+          //     statistical_classification: prescription.project[b].project.statistical_classification,
513
+          //     single_dose: prescription.project[b].single_dose,
514
+          //     delivery_way: prescription.project[b].delivery_way,
515
+          //     execution_frequency: prescription.project[b].execution_frequency,
516
+          //     price: prescription.project[b].price,
517
+          //     day: prescription.project[b].day,
518
+          //     count: prescription.project[b].count.toString(),
519
+          //     remark: prescription.project[b].remark,
520
+          //     single_dose_unit:prescription.project[b].project.unit,
521
+          //     prescribing_number_unit:prescription.project[b].project.unit,
522
+          //     type:2,
523
+          //   }
524
+          //   this.tableData.push(obj)
525
+          // }
526
+          //
527
+          // for (let b = 0; b < prescription.addition.length; b++) {
528
+          //     this.additions.push( prescription.addition[b])
529
+          // }
530
+
531
+
532
+
533
+          // let index = i + 1
534
+          // let obj = {
535
+          //   id: prescription.id,
536
+          //   name: '处方' + index,
537
+          //   advices: tempAdvice,
538
+          //   project: tempProject,
539
+          //   type: response.data.data.prescription[i].type
540
+          // }
541
+          // this.prescriptions.push(obj)
542
+          // this.curPrescriptions = this.prescriptions[0]
534 543
 
535 544
           // }
536 545
           // this.tableData = response.data.data.order
@@ -540,6 +549,7 @@ export default {
540 549
     }
541 550
   }
542 551
 }
552
+
543 553
 </script>
544 554
 
545 555
 <style lang="scss" scoped>

+ 7 - 2
src/xt_pages/outpatientCharges/allListPrint.vue Целия файл

@@ -172,9 +172,14 @@
172 172
             let count = 0
173 173
             for (let a = 0; a < details.length; a++) {
174 174
               if (new_project_ids[i].id == details[a].project.project_id && new_project_ids[i].price == details[a].project.price) {
175
-                obj['name'] = details[a].project.project.project_name
175
+               if( details[a].project.type == 2){
176
+                 obj['name'] = details[a].project.project.project_name
177
+               }else if(details[a].project.type == 3){
178
+                 obj['name'] = details[a].project.good_info.good_name
179
+               }
180
+                obj['unit'] = details[a].project.unit
181
+
176 182
                 obj['spec'] = '1'
177
-                obj['unit'] = details[a].project.project.unit
178 183
                 obj['med_chrgitm_type'] = this.getType(details[a].med_chrgitm_type)
179 184
                 obj['price'] = parseFloat(details[a].pric)
180 185
                 obj['is_total'] = 2

+ 1 - 1
src/xt_pages/outpatientCharges/components/chargeMonthPrescriptionTable.vue Целия файл

@@ -61,7 +61,7 @@
61 61
         <template slot-scope="scope">{{ scope.row.project_name }}</template>
62 62
       </el-table-column>
63 63
       <el-table-column align="center" prop="statistical_classification" width="100" label="组">
64
-        <template slot-scope="scope">{{getGroup(scope.row.statistical_classification)}}</template>
64
+        <template slot-scope="scope">{{scope.row.type == 2?getGroup(scope.row.statistical_classification):"耗材"}}</template>
65 65
       </el-table-column>
66 66
       <el-table-column align="center" prop="single_dose" width="80" label="单次用量">
67 67
         <template slot-scope="scope">{{scope.row.single_dose}}{{scope.row.unit}}</template>

+ 2 - 4
src/xt_pages/outpatientCharges/components/prescriptionTable.vue Целия файл

@@ -61,7 +61,7 @@
61 61
         <template slot-scope="scope">{{ scope.row.project_name }}</template>
62 62
       </el-table-column>
63 63
       <el-table-column align="center" prop="statistical_classification" width="100" label="组">
64
-        <template slot-scope="scope">{{getGroup(scope.row.statistical_classification)}}</template>
64
+        <template slot-scope="scope">{{scope.row.type == 2?getGroup(scope.row.statistical_classification):"耗材"}}</template>
65 65
       </el-table-column>
66 66
       <el-table-column align="center" prop="single_dose" width="80" label="单次用量">
67 67
         <template slot-scope="scope">{{scope.row.single_dose}}{{scope.row.unit}}</template>
@@ -93,9 +93,7 @@
93 93
         <template slot-scope="scope">
94 94
           <div style="display:flex;">
95 95
             <!--<el-input v-model="scope.row.total" placeholder="" readonly></el-input>-->
96
-            {{scope.row.total}}
97
-
98
-            <div>{{scope.row.unit}}</div>
96
+            {{scope.row.total}} {{scope.row.unit}}
99 97
 
100 98
           </div>
101 99
         </template>

+ 324 - 326
src/xt_pages/outpatientCharges/components/registerDialog.vue Целия файл

@@ -1,192 +1,192 @@
1 1
 <template>
2
-  <el-dialog width="854px" class="registerDialog" :title="titles" :visible.sync="visibility"
3
-             :close-on-click-modal="isClose"
4
-             :close-on-press-escape="isClose">
5
-
6
-    <el-form :model="form" :rules="rules" ref="formValue" label-width="100px">
7
-      <el-form-item label="患者姓名:" prop="name" :validate-event="is_Name">
8
-        <el-autocomplete
9
-          class="checkSearch"
10
-          popper-class="my-autocomplete"
11
-          v-model="form.name"
12
-          :fetch-suggestions="querySearchAsync"
13
-          :trigger-on-focus="false"
14
-          placeholder="请输入病人名字"
15
-          @select="handleSelect"
16
-          style="width:160px;"
17
-        >
18
-          <i class="el-icon-search el-input__icon" slot="suffix"></i>
19
-          <template slot-scope="{ item }">
20
-            <div class="name">{{ item.name }}</div>
21
-          </template>
22
-        </el-autocomplete>
23
-      </el-form-item>
24
-
25
-      <el-form-item label="性别:" prop="gender" :validate-event="is_Name">
26
-        <el-select v-model="form.gender" placeholder="请选择" style="width:100%;">
27
-          <el-option
28
-            v-for="item in sex"
29
-            :key="item.value"
30
-            :label="item.label"
31
-            :value="item.value">
32
-          </el-option>
33
-        </el-select>
34
-
35
-
36
-      </el-form-item>
37
-
38
-      <el-form-item label="年龄:" prop="age" :validate-event="is_Name">
39
-        <el-input v-model="form.age"></el-input>
40
-      </el-form-item>
41
-
42
-
43
-      <el-form-item label="出生日期:" prop="birthday" :validate-event="is_Name">
44
-        <el-date-picker v-model="form.birthday" type="date" format="yyyy-MM-dd"
45
-                        value-format="yyyy-MM-dd" placeholder="选择日期" style="width:100%;"></el-date-picker>
46
-      </el-form-item>
47
-
48
-      <el-form-item label="手机号码:" prop="phone">
49
-        <el-input v-model="form.phone"></el-input>
50
-      </el-form-item>
51
-
52
-
53
-      <el-form-item label="医疗类别:">
54
-        <el-select v-model="form.medical_care" placeholder="请选择" style="width:100%;">
55
-          <el-option
56
-            v-for="(item,index) in medical_care"
57
-            :key="index"
58
-            :label="item.label"
59
-            :value="item.value">
60
-          </el-option>
61
-        </el-select>
62
-      </el-form-item>
63
-
64
-
65
-      <el-form-item label="证件类型:" prop="certificates" :validate-event="is_Name">
66
-        <el-select v-model="form.certificates" placeholder="请选择" style="width:100%;">
67
-          <el-option
68
-            v-for="item in certificates"
69
-            :key="item.value"
70
-            :label="item.label"
71
-            :value="item.value">
72
-          </el-option>
73
-        </el-select>
74
-      </el-form-item>
75
-
76
-      <el-form-item label="证件号码:" prop="id_card" :validate-event="is_Name">
77
-        <el-input v-model="form.id_card"></el-input>
78
-      </el-form-item>
79
-
80
-      <el-form-item label="处方类型:" prop="p_type" :validate-event="is_Name">
81
-        <el-select style="margin-right:5px;width:100px;" v-model="form.p_type" placeholder=""
82
-        >
83
-          <el-option
84
-            v-for="(item,index) in registers"
85
-            :key="index"
86
-            :label="item.label"
87
-            :value="item.value">
88
-          </el-option>
89
-        </el-select>
90
-      </el-form-item>
91
-      <el-form-item label="大病类别:" prop="sick_type" :validate-event="is_Name">
92
-        <el-select style="margin-right:5px;width:100px;" v-model="form.sick_type" placeholder="">
93
-          <el-option
94
-            v-for="(item,index) in sick"
95
-            :key="index"
96
-            :label="item.class_name"
97
-            :value="item.id">
98
-          </el-option>
99
-        </el-select>
100
-      </el-form-item>
101
-
102
-      <el-form-item label="诊断:" prop="diagnosis" :validate-event="is_Name">
103
-        <el-select style="margin-right:5px;width:100px;" v-model="form.diagnosis" placeholder="">
104
-          <el-option
105
-            v-for="(item,index) in diagnoses"
106
-            :key="index"
107
-            :label="item.class_name"
108
-            :value="item.id">
109
-          </el-option>
110
-        </el-select>
111
-      </el-form-item>
112
-
113
-
114
-      <el-form-item label="结算类型:">
115
-        <el-select v-model="form.settlement_value" placeholder="请选择" style="width:100%;">
116
-          <el-option
117
-            v-for="item in settlement"
118
-            :key="item.value"
119
-            :label="item.label"
120
-            :value="item.value">
121
-          </el-option>
122
-        </el-select>
123
-      </el-form-item>
124
-
125
-
126
-      <el-form-item label="社保类型:">
127
-        <el-select v-model="form.social_type" placeholder="请选择" style="width:100%;">
128
-          <el-option
129
-            v-for="item in medicalCare"
130
-            :key="item.value"
131
-            :label="item.label"
132
-            :value="item.value">
133
-          </el-option>
134
-        </el-select>
135
-      </el-form-item>
136
-
137
-
138
-      <el-form-item label="读卡类型:" prop="id_card_type" :validate-event="is_Name">
139
-        <el-select v-model="form.id_card_type" placeholder="请选择">
140
-          <el-option
141
-            v-for="item in IDCardTypes"
142
-            :key="item.value"
143
-            :label="item.label"
144
-            :value="item.value">
145
-          </el-option>
146
-        </el-select>
147
-      </el-form-item>
148
-
149
-
150
-      <el-form-item class="specialFormItem" label="医保卡号:">
151
-        <div style="display:flex;">
152
-          <el-input v-model="form.medical_insurance_card"></el-input>
153
-          <el-button style="margin-left:10px;" type="primary" @click="reading">读卡</el-button>
154
-
155
-        </div>
156
-      </el-form-item>
157
-
158
-      <el-form-item label="挂号类型:"  >
159
-        <el-select v-model="form.register" placeholder="请选择" style="width:100%;">
160
-          <el-option
161
-            v-for="item in register"
162
-            :key="item.value"
163
-            :label="item.label"
164
-            :value="item.value">
165
-          </el-option>
166
-        </el-select>
167
-      </el-form-item>
168
-      <el-form-item label="挂号费:">
169
-        <el-input v-model="form.registration_fee"></el-input>
170
-      </el-form-item>
171
-      <el-form-item label="诊疗费:">
172
-        <el-input v-model="form.medical_expenses"></el-input>
173
-      </el-form-item>
174
-    </el-form>
175
-
176
-    <span slot="footer" class="dialog-footer">
2
+    <el-dialog width="854px" class="registerDialog" :title="titles" :visible.sync="visibility"
3
+               :close-on-click-modal="isClose"
4
+               :close-on-press-escape="isClose">
5
+
6
+        <el-form :model="form" :rules="rules" ref="formValue" label-width="100px">
7
+            <el-form-item label="患者姓名:" prop="name" :validate-event="is_Name">
8
+                <el-autocomplete
9
+                        class="checkSearch"
10
+                        popper-class="my-autocomplete"
11
+                        v-model="form.name"
12
+                        :fetch-suggestions="querySearchAsync"
13
+                        :trigger-on-focus="false"
14
+                        placeholder="请输入病人名字"
15
+                        @select="handleSelect"
16
+                        style="width:160px;"
17
+                >
18
+                    <i class="el-icon-search el-input__icon" slot="suffix"></i>
19
+                    <template slot-scope="{ item }">
20
+                        <div class="name">{{ item.name }}</div>
21
+                    </template>
22
+                </el-autocomplete>
23
+            </el-form-item>
24
+
25
+            <el-form-item label="性别:" prop="gender" :validate-event="is_Name">
26
+                <el-select v-model="form.gender" placeholder="请选择" style="width:100%;">
27
+                    <el-option
28
+                            v-for="item in sex"
29
+                            :key="item.value"
30
+                            :label="item.label"
31
+                            :value="item.value">
32
+                    </el-option>
33
+                </el-select>
34
+
35
+
36
+            </el-form-item>
37
+
38
+            <el-form-item label="年龄:" prop="age" :validate-event="is_Name">
39
+                <el-input v-model="form.age"></el-input>
40
+            </el-form-item>
41
+
42
+
43
+            <el-form-item label="出生日期:" prop="birthday" :validate-event="is_Name">
44
+                <el-date-picker v-model="form.birthday" type="date" format="yyyy-MM-dd"
45
+                                value-format="yyyy-MM-dd" placeholder="选择日期" style="width:100%;"></el-date-picker>
46
+            </el-form-item>
47
+
48
+            <el-form-item label="手机号码:" prop="phone">
49
+                <el-input v-model="form.phone"></el-input>
50
+            </el-form-item>
51
+
52
+
53
+            <el-form-item label="医疗类别:">
54
+                <el-select v-model="form.medical_care" placeholder="请选择" style="width:100%;">
55
+                    <el-option
56
+                            v-for="(item,index) in medical_care"
57
+                            :key="index"
58
+                            :label="item.label"
59
+                            :value="item.value">
60
+                    </el-option>
61
+                </el-select>
62
+            </el-form-item>
63
+
64
+
65
+            <el-form-item label="证件类型:" prop="certificates" :validate-event="is_Name">
66
+                <el-select v-model="form.certificates" placeholder="请选择" style="width:100%;">
67
+                    <el-option
68
+                            v-for="item in certificates"
69
+                            :key="item.value"
70
+                            :label="item.label"
71
+                            :value="item.value">
72
+                    </el-option>
73
+                </el-select>
74
+            </el-form-item>
75
+
76
+            <el-form-item label="证件号码:" prop="id_card" :validate-event="is_Name">
77
+                <el-input v-model="form.id_card"></el-input>
78
+            </el-form-item>
79
+
80
+            <el-form-item label="处方类型:" prop="p_type" :validate-event="is_Name">
81
+                <el-select style="margin-right:5px;width:100px;" v-model="form.p_type" placeholder=""
82
+                >
83
+                    <el-option
84
+                            v-for="(item,index) in registers"
85
+                            :key="index"
86
+                            :label="item.label"
87
+                            :value="item.value">
88
+                    </el-option>
89
+                </el-select>
90
+            </el-form-item>
91
+            <el-form-item label="大病类别:" prop="sick_type" :validate-event="is_Name">
92
+                <el-select style="margin-right:5px;width:100px;" v-model="form.sick_type" placeholder="">
93
+                    <el-option
94
+                            v-for="(item,index) in sick"
95
+                            :key="index"
96
+                            :label="item.class_name"
97
+                            :value="item.id">
98
+                    </el-option>
99
+                </el-select>
100
+            </el-form-item>
101
+
102
+            <el-form-item label="诊断:" prop="diagnosis" :validate-event="is_Name">
103
+                <el-select style="margin-right:5px;width:100px;" v-model="form.diagnosis" placeholder="">
104
+                    <el-option
105
+                            v-for="(item,index) in diagnoses"
106
+                            :key="index"
107
+                            :label="item.class_name"
108
+                            :value="item.id">
109
+                    </el-option>
110
+                </el-select>
111
+            </el-form-item>
112
+
113
+
114
+            <el-form-item label="结算类型:">
115
+                <el-select v-model="form.settlement_value" placeholder="请选择" style="width:100%;">
116
+                    <el-option
117
+                            v-for="item in settlement"
118
+                            :key="item.value"
119
+                            :label="item.label"
120
+                            :value="item.value">
121
+                    </el-option>
122
+                </el-select>
123
+            </el-form-item>
124
+
125
+
126
+            <el-form-item label="社保类型:">
127
+                <el-select v-model="form.social_type" placeholder="请选择" style="width:100%;">
128
+                    <el-option
129
+                            v-for="item in medicalCare"
130
+                            :key="item.value"
131
+                            :label="item.label"
132
+                            :value="item.value">
133
+                    </el-option>
134
+                </el-select>
135
+            </el-form-item>
136
+
137
+
138
+            <el-form-item label="读卡类型:" prop="id_card_type" :validate-event="is_Name">
139
+                <el-select v-model="form.id_card_type" placeholder="请选择">
140
+                    <el-option
141
+                            v-for="item in IDCardTypes"
142
+                            :key="item.value"
143
+                            :label="item.label"
144
+                            :value="item.value">
145
+                    </el-option>
146
+                </el-select>
147
+            </el-form-item>
148
+
149
+
150
+            <el-form-item class="specialFormItem" label="医保卡号:">
151
+                <div style="display:flex;">
152
+                    <el-input v-model="form.medical_insurance_card"></el-input>
153
+                    <el-button style="margin-left:10px;" type="primary" @click="reading">读卡</el-button>
154
+
155
+                </div>
156
+            </el-form-item>
157
+
158
+            <el-form-item label="挂号类型:" prop="register" :validate-event="is_Name">
159
+                <el-select v-model="form.register" placeholder="请选择" style="width:100%;">
160
+                    <el-option
161
+                            v-for="item in register"
162
+                            :key="item.value"
163
+                            :label="item.label"
164
+                            :value="item.value">
165
+                    </el-option>
166
+                </el-select>
167
+            </el-form-item>
168
+            <el-form-item label="挂号费:">
169
+                <el-input v-model="form.registration_fee"></el-input>
170
+            </el-form-item>
171
+            <el-form-item label="诊疗费:">
172
+                <el-input v-model="form.medical_expenses"></el-input>
173
+            </el-form-item>
174
+        </el-form>
175
+
176
+        <span slot="footer" class="dialog-footer">
177 177
     <el-button @click="cancel('formValue')">取 消</el-button>
178 178
     <el-button type="primary" @click="confirm('formValue')">挂 号</el-button>
179 179
   </span>
180
-  </el-dialog>
180
+    </el-dialog>
181 181
 
182 182
 </template>
183 183
 
184 184
 <script>
185
-  import {jsGetAge, uParseTime} from "@/utils/tools";
185
+  import { jsGetAge, uParseTime } from '@/utils/tools'
186 186
   import axios from 'axios'
187
-  import {PostSearch} from '@/api/patient'
187
+  import { PostSearch } from '@/api/patient'
188 188
 
189
-  import {getDictionaryDataConfig} from '@/utils/data'
189
+  import { getDictionaryDataConfig } from '@/utils/data'
190 190
 
191 191
   export default {
192 192
 
@@ -196,28 +196,27 @@
196 196
 
197 197
       return {
198 198
         registers: [
199
-          {value: 11, label: "普通门诊"},
200
-          {value: 12, label: '门诊挂号'},
201
-          {value: 13, label: "急诊"},
202
-          {value: 14, label: "门诊特殊病"},
203
-          {value: 15, label: "门诊统筹"},
204
-          {value: 16, label: "门诊慢性病"},
205
-          {value: 21, label: "普通住院"},
199
+          { value: 11, label: '普通门诊' },
200
+          { value: 12, label: '门诊挂号' },
201
+          { value: 13, label: '急诊' },
202
+          { value: 14, label: '门诊特殊病' },
203
+          { value: 15, label: '门诊统筹' },
204
+          { value: 16, label: '门诊慢性病' },
205
+          { value: 21, label: '普通住院' }
206 206
         ],
207 207
         medical_care: [
208
-          {value: 11, label: "普通门诊"},
209
-          {value: 12, label: '家庭通道'},
210
-          {value: 13, label: "门诊大病"},
211
-          {value: 14, label: "重疾特药"},
212
-          {value: 15, label: "门诊慢病"},
213
-          {value: 16, label: "门诊特检"},
214
-          {value: 17, label: "健康体检"},
215
-          {value: 18, label: "预防接种"},
216
-          {value: 19, label: "门诊输血"},
217
-          {value: 91, label: "新冠肺炎门诊"},
208
+          { value: 11, label: '普通门诊' },
209
+          { value: 12, label: '家庭通道' },
210
+          { value: 13, label: '门诊大病' },
211
+          { value: 14, label: '重疾特药' },
212
+          { value: 15, label: '门诊慢病' },
213
+          { value: 16, label: '门诊特检' },
214
+          { value: 17, label: '健康体检' },
215
+          { value: 18, label: '预防接种' },
216
+          { value: 19, label: '门诊输血' },
217
+          { value: 91, label: '新冠肺炎门诊' }
218 218
         ],
219 219
 
220
-
221 220
         form: {
222 221
           id: '',
223 222
           settlement_value: '',
@@ -236,29 +235,29 @@
236 235
           doctor: '',
237 236
           id_card_type: 1,
238 237
           department: '',
239
-          registration_fee: 0,
240
-          medical_expenses: 0,
238
+          registration_fee: '',
239
+          medical_expenses: '',
241 240
           cost: '',
242 241
           phone: '',
243
-          social_type: '',
242
+          social_type: ''
244 243
         }, IDCardTypes: [{
245 244
           value: 1,
246 245
           label: '社保卡'
247 246
         }, {
248 247
           value: 2,
249
-          label: "身份证"
248
+          label: '身份证'
250 249
         }, {
251 250
           value: 3,
252
-          label: "电子凭证"
253
-        },],
251
+          label: '电子凭证'
252
+        }],
254 253
         settlement: [
255
-          {value: 1, label: '医保'},
256
-          {value: 2, label: '自费'},
257
-          {value: 3, label: '公费'},
258
-          {value: 4, label: '农保'},
259
-          {value: 5, label: '会员'},
260
-          {value: 6, label: '职工'},
261
-          {value: 7, label: '合同'}
254
+          { value: 1, label: '医保' },
255
+          { value: 2, label: '自费' },
256
+          { value: 3, label: '公费' },
257
+          { value: 4, label: '农保' },
258
+          { value: 5, label: '会员' },
259
+          { value: 6, label: '职工' },
260
+          { value: 7, label: '合同' }
262 261
         ],
263 262
         sex: [{
264 263
           value: 1,
@@ -272,72 +271,72 @@
272 271
           label: '内地身份证'
273 272
         }, {
274 273
           value: 2,
275
-          label: "社保卡"
274
+          label: '社保卡'
276 275
         }, {
277 276
           value: 3,
278
-          label: "护照"
277
+          label: '护照'
279 278
         }, {
280 279
           value: 4,
281
-          label: "军官证"
280
+          label: '军官证'
282 281
         }, {
283 282
           value: 5,
284
-          label: "台胞证"
283
+          label: '台胞证'
285 284
         }, {
286 285
           value: 6,
287
-          label: "港澳地区身份证"
286
+          label: '港澳地区身份证'
288 287
         }],
289 288
         medicalCare: [{
290 289
           value: 1,
291 290
           label: '职工基本医疗保险'
292 291
         }, {
293 292
           value: 2,
294
-          label: "公务员医疗补助"
293
+          label: '公务员医疗补助'
295 294
         }, {
296 295
           value: 3,
297
-          label: "大额医疗费用补助"
296
+          label: '大额医疗费用补助'
298 297
         }, {
299 298
           value: 4,
300
-          label: "离休人员医疗"
299
+          label: '离休人员医疗'
301 300
         }, {
302 301
           value: 5,
303
-          label: "城乡居民基本医疗保险"
302
+          label: '城乡居民基本医疗保险'
304 303
         }, {
305 304
           value: 6,
306
-          label: "城乡居民大病医疗保险"
305
+          label: '城乡居民大病医疗保险'
307 306
         }, {
308 307
           value: 7,
309
-          label: "生育保险"
308
+          label: '生育保险'
310 309
         }],
311 310
         register: [{
312 311
           value: 1,
313 312
           label: '普通'
314 313
         }, {
315 314
           value: 2,
316
-          label: "主治"
315
+          label: '主治'
317 316
         }, {
318 317
           value: 3,
319
-          label: "主任"
318
+          label: '主任'
320 319
         }, {
321 320
           value: 4,
322
-          label: "免收诊金"
321
+          label: '免收诊金'
323 322
         }, {
324 323
           value: 5,
325
-          label: "专家"
324
+          label: '专家'
326 325
         }],
327 326
         rules: {
328
-          name: [{required: true, message: "患者姓名不能为空", trigger: 'blur'}],
329
-          gender: [{required: true, message: "患者性别不能为空", trigger: 'blur'}],
330
-          id_card: [{required: true, message: '证件号码不能为空', trigger: 'blur'}],
331
-          register: [{required: true, message: '请选择挂号类型', trigger: 'blur'}],
332
-          doctor: [{required: true, message: '请选择医生', trigger: 'blur'}],
333
-          department: [{required: true, message: '请填写科室', trigger: 'blur'}],
334
-          age: [{required: true, message: "患者年龄不能为空", trigger: 'blur'}],
335
-          birthday: [{required: true, message: "患者出生日期不能为空", trigger: 'blur'}],
336
-          certificates: [{required: true, message: "证件类型不能为空", trigger: 'change'}],
337
-          id_card_type: [{required: true, message: "读卡类型不能为空", trigger: 'change'}],
338
-          p_type: [{required: true, message: "处方类型不能为空", trigger: 'change'}],
339
-          sick_type: [{required: true, message: "大病类别不能为空", trigger: 'change'}],
340
-          diagnosis: [{required: true, message: "诊断不能为空", trigger: 'change'}],
327
+          name: [{ required: true, message: '患者姓名不能为空', trigger: 'blur' }],
328
+          gender: [{ required: true, message: '患者性别不能为空', trigger: 'blur' }],
329
+          id_card: [{ required: true, message: '证件号码不能为空', trigger: 'blur' }],
330
+          register: [{ required: true, message: '请选择挂号类型', trigger: 'blur' }],
331
+          doctor: [{ required: true, message: '请选择医生', trigger: 'blur' }],
332
+          department: [{ required: true, message: '请填写科室', trigger: 'blur' }],
333
+          age: [{ required: true, message: '患者年龄不能为空', trigger: 'blur' }],
334
+          birthday: [{ required: true, message: '患者出生日期不能为空', trigger: 'blur' }],
335
+          certificates: [{ required: true, message: '证件类型不能为空', trigger: 'change' }],
336
+          id_card_type: [{ required: true, message: '读卡类型不能为空', trigger: 'change' }],
337
+          p_type: [{ required: true, message: '处方类型不能为空', trigger: 'change' }],
338
+          sick_type: [{ required: true, message: '大病类别不能为空', trigger: 'change' }],
339
+          diagnosis: [{ required: true, message: '诊断不能为空', trigger: 'change' }]
341 340
         },
342 341
         visibility: false,
343 342
         labelPosition: 'right',
@@ -360,8 +359,8 @@
360 359
           medical_expenses: '',
361 360
           cost: '',
362 361
           phone: '',
363
-          social_type: '',
364
-        },
362
+          social_type: ''
363
+        }
365 364
 
366 365
       }
367 366
     },
@@ -385,40 +384,40 @@
385 384
 
386 385
       },
387 386
       sick: Array,
388
-      diagnoses: Array,
387
+      diagnoses: Array
389 388
     },
390 389
     methods: {
391 390
       handleSelect(val) {
392
-        this.form.id = val.id;
393
-        this.form.name = val.name;
394
-        this.form.gender = val.gender;
395
-        this.form.birthday = uParseTime(val.birthday, '{y}-{m}-{d}');
396
-        this.form.phone = val.phone;
397
-        this.form.id_card = val.id_card_no;
398
-        var thisLen = this.form.id_card.length;
399
-        var birth = "";
391
+        this.form.id = val.id
392
+        this.form.name = val.name
393
+        this.form.gender = val.gender
394
+        this.form.birthday = uParseTime(val.birthday, '{y}-{m}-{d}')
395
+        this.form.phone = val.phone
396
+        this.form.id_card = val.id_card_no
397
+        var thisLen = this.form.id_card.length
398
+        var birth = ''
400 399
         if (thisLen == 15) {
401
-          birth = "19" + this.form.id_card.substr(6, 6);
400
+          birth = '19' + this.form.id_card.substr(6, 6)
402 401
         } else {
403
-          birth = this.form.id_card.substr(6, 8);
402
+          birth = this.form.id_card.substr(6, 8)
404 403
         }
405 404
         var births =
406 405
           birth.substr(0, 4) +
407
-          "-" +
406
+          '-' +
408 407
           birth.substr(4, 2) +
409
-          "-" +
410
-          birth.substr(6, 2);
411
-        this.form.age = jsGetAge(births, "-");
408
+          '-' +
409
+          birth.substr(6, 2)
410
+        this.form.age = jsGetAge(births, '-')
412 411
       },
413 412
       querySearchAsync(keyword, cb) {
414
-        let key = '';
413
+        let key = ''
415 414
         if (keyword != undefined) {
416 415
           key = keyword
417 416
         }
418
-        let searchArray = [];
417
+        let searchArray = []
419 418
         PostSearch(key).then(response => {
420 419
           if (response.data.state == 1) {
421
-            searchArray = response.data.data.patient;
420
+            searchArray = response.data.data.patient
422 421
             cb(searchArray)
423 422
           } else {
424 423
             cb([])
@@ -426,84 +425,83 @@
426 425
         })
427 426
       },
428 427
       reading(medicalInsuranceCard) {
429
-        var that = this;
428
+        var that = this
430 429
         if (this.form.id_card_type.length == 0 || this.form.id_card_type == 0) {
431
-          this.$message.error("请先选择读卡类型");
430
+          this.$message.error('请先选择读卡类型')
432 431
           return
433 432
         }
434 433
         let params = {
435 434
           'id_card_type': this.form.id_card_type,
436
-          'admin_user_id': this.$store.getters.xt_user.user.id,
435
+          'admin_user_id': this.$store.getters.xt_user.user.id
437 436
 
438
-        };
437
+        }
439 438
         axios.get('http://127.0.0.1:9532/api/sscard', {
440 439
           params: params
441 440
         })
442
-          .then(function (response) {
441
+          .then(function(response) {
443 442
             if (response.data.state == 0) {
444
-              that.$message.error(response.data.msg);
443
+              that.$message.error(response.data.msg)
445 444
               return false
446 445
             } else {
447
-              var patient = response.data.data.patient;
446
+              var patient = response.data.data.patient
448 447
 
449 448
               if (that.form.id_card_type == 1) {
450
-                this.form.id = patient.id;
451
-                that.form.name = patient.name;
452
-                that.form.sex = patient.gender;
453
-                that.form.age = patient.age;
454
-                that.form.birthday = uParseTime(patient.birthday, '{y}-{m}-{d}');
455
-                that.form.phone = patient.phone;
456
-                that.form.idCard = patient.id_card_no;
449
+                this.form.id = patient.id
450
+                that.form.name = patient.name
451
+                that.form.sex = patient.gender
452
+                that.form.age = patient.age
453
+                that.form.birthday = uParseTime(patient.birthday, '{y}-{m}-{d}')
454
+                that.form.phone = patient.phone
455
+                that.form.idCard = patient.id_card_no
457 456
                 that.form.medicalInsuranceCard = response.data.data.number
458 457
 
459 458
               } else if (that.form.id_card_type == 2) {
460
-                this.form.id = patient.id;
461
-                that.form.name = patient.name;
462
-                that.form.sex = patient.gender;
463
-                that.form.age = patient.age;
464
-                that.form.birthday = uParseTime(patient.birthday, '{y}-{m}-{d}');
465
-                that.form.phone = patient.phone;
459
+                this.form.id = patient.id
460
+                that.form.name = patient.name
461
+                that.form.sex = patient.gender
462
+                that.form.age = patient.age
463
+                that.form.birthday = uParseTime(patient.birthday, '{y}-{m}-{d}')
464
+                that.form.phone = patient.phone
466 465
                 that.form.idCard = patient.id_card_no
467 466
               }
468
-              that.$message({message: '读卡成功', type: 'success'})
467
+              that.$message({ message: '读卡成功', type: 'success' })
469 468
             }
470 469
           })
471
-          .catch(function (error) {
472
-
473
-          });
470
+          .catch(function(error) {
474 471
 
472
+          })
475 473
 
476 474
       },
477 475
       getDictionaryDataConfig(module, filed_name) {
478 476
         return getDictionaryDataConfig(module, filed_name)
479 477
       },
480
-      show: function () {
481
-        this.visibility = true;
478
+      show: function() {
479
+        this.visibility = true
482 480
         // this.form = Object.assign({}, this.resetForm)
483
-        this.form.id = 0;
484
-        this.form.settlement_value = '';
485
-        this.form.medical_insurance_card = '';
486
-        this.form.name = '';
487
-        this.form.gender = '';
488
-        this.form.medical_care = '';
489
-        this.form.birthda = '';
490
-        this.form.age = '';
491
-        this.form.id_card = '';
492
-        this.form.register = '';
493
-        this.form.doctor = '';
494
-        this.form.department = '';
495
-        this.form.registration_fee = 0;
496
-        this.form.medical_expenses = 0;
497
-        this.form.cost = '';
498
-        this.form.phone = '';
499
-        this.form.social_type = '';
500
-
501
-        this.form.p_type = 14;
502
-        this.form.sick_type = this.sick[0].id;
503
-        this.form.diagnosis = this.diagnoses[0].id;
504
-        this.form.id_card_type = 2;
505
-        this.form.certificates = 1;
506
-        this.form.settlement_value = 1
481
+        this.form.id = 0
482
+        this.form.settlement_value = ''
483
+        this.form.medical_insurance_card = ''
484
+        this.form.name = ''
485
+        this.form.gender = ''
486
+        this.form.medical_care = ''
487
+        this.form.birthda = ''
488
+        this.form.age = ''
489
+        this.form.id_card = ''
490
+        this.form.register = ''
491
+        this.form.doctor = ''
492
+        this.form.department = ''
493
+        this.form.registration_fee = ''
494
+        this.form.medical_expenses = ''
495
+        this.form.cost = ''
496
+        this.form.phone = ''
497
+        this.form.social_type = ''
498
+
499
+        this.form.p_type = 14
500
+        this.form.sick_type = this.sick[0].id
501
+        this.form.diagnosis = this.diagnoses[0].id
502
+        this.form.id_card_type = 2
503
+        this.form.certificates = 1
504
+
507 505
         // this.form.name = patientInfo.name
508 506
         // this.form.gender = patientInfo.gender
509 507
         // this.form.age = patientInfo.age
@@ -519,24 +517,24 @@
519 517
       },
520 518
 
521 519
       hide: function () {
522
-        this.visibility = false;
520
+        this.visibility = false
523 521
         this.$refs['formValue'].resetFields()
524
-      }, cancel: function (formName) {
525
-        this.$emit('cancel', this.getValue());
522
+      }, cancel: function(formName) {
523
+        this.$emit('cancel', this.getValue())
526 524
         this.$refs['formValue'].resetFields()
527 525
       },
528
-      confirm: function (formName) {
526
+      confirm: function(formName) {
529 527
         this.$refs['formValue'].validate((valid) => {
530 528
           if (valid) {
531
-            let value = {};
532
-            value = this.getValue();
529
+            let value = {}
530
+            value = this.getValue()
533 531
             this.$emit('confirm', value)
534 532
           }
535 533
         })
536 534
       },
537
-      getValue: function () {
538
-        let form = {};
539
-        form = this.form;
535
+      getValue: function() {
536
+        let form = {}
537
+        form = this.form
540 538
         return form
541 539
       }
542 540
     }
@@ -545,16 +543,16 @@
545 543
 </script>
546 544
 
547 545
 <style lang="scss" scoped>
548
-  .registerDialog {
546
+    .registerDialog {
549 547
 
550
-  .el-form {
551
-    display: flex;
552
-    flex-wrap: wrap;
553
-  }
548
+    .el-form {
549
+        display: flex;
550
+        flex-wrap: wrap;
551
+    }
554 552
 
555
-  .el-form-item {
556
-    width: 50%;
557
-  }
553
+    .el-form-item {
554
+        width: 50%;
555
+    }
558 556
 
559
-  }
557
+    }
560 558
 </style>

+ 3 - 3
src/xt_pages/outpatientCharges/costComparison.vue Целия файл

@@ -158,7 +158,7 @@
158 158
                 <el-form :model="form" label-width="100px">
159 159
                     <el-form-item label="时间" label-width="100px">
160 160
                         <el-date-picker v-model="start_time" prefix-icon="el-icon-date"
161
-                                        @change="handleStartTimeChange" :editable="false" :clearable="false"
161
+                                        :editable="false" :clearable="false"
162 162
                                         style="width: 200px;" type="date" placeholder="选择开始日期"
163 163
                                         format="yyyy-MM-dd"
164 164
                                         value-format="yyyy-MM-dd"
@@ -166,7 +166,7 @@
166 166
                         -
167 167
 
168 168
                         <el-date-picker v-model="end_time" prefix-icon="el-icon-date"
169
-                                        @change="handleEndTimeChange" :editable="false" :clearable="false"
169
+                                       :editable="false" :clearable="false"
170 170
                                         style="width: 200px;margin-right:10px;" type="date" placeholder="选择结束日期"
171 171
                                         format="yyyy-MM-dd"
172 172
                                         value-format="yyyy-MM-dd"
@@ -458,7 +458,7 @@
458 458
                   that.$alert(result_desc, '对账结果', {
459 459
                     confirmButtonText: '确定',
460 460
                     callback: action => {
461
-                      this.dialogFormVisible = false
461
+                      that.dialogFormVisible = false
462 462
                     }
463 463
                   })
464 464
 

+ 185 - 57
src/xt_pages/outpatientCharges/incomeStatistics.vue Целия файл

@@ -11,18 +11,7 @@
11 11
           <el-button size="small" style="margin-left:10px;" class="filter-item" type="primary" @click="searchAction">
12 12
             搜索
13 13
           </el-button>
14
-          <el-select size="small" v-model="admin_user_id" placeholder="请选择" style="width:150px;margin-left:10px;" @change="changeDoctor">
15
-            <el-option
16
-              label="全部"
17
-              value="0">
18
-            </el-option>
19
-            <el-option
20
-              v-for="(item,index) in type"
21
-              :key="index"
22
-              :label="item.user_name"
23
-              :value="item.admin_user_id">
24
-            </el-option>
25
-          </el-select>
14
+
26 15
           <el-date-picker size="small" v-model="start_time" prefix-icon="el-icon-date"
27 16
                           @change="handleStartTimeChange" :editable="false" :clearable="false"
28 17
                           style="width: 196px;margin-right:10px;" type="date" placeholder="选择开始日期"
@@ -36,13 +25,13 @@
36 25
                           format="yyyy-MM-dd"
37 26
                           value-format="yyyy-MM-dd"
38 27
                           align="right"></el-date-picker>
39
-          <!--<el-radio v-model="radio" label="1">明细</el-radio>-->
40
-          <!--<el-radio v-model="radio" label="2">汇总</el-radio>-->
28
+          <el-radio v-model="radio" label="1" @change="changeType">汇总</el-radio>
29
+          <el-radio v-model="radio" label="2"  @change="changeType">明细</el-radio>
41 30
         </div>
42 31
         <el-button size="small" type="primary" @click="export_detail">报表下载</el-button>
43 32
       </div>
44 33
       <el-table :data="tableData" border style="width: 100%;" :row-style="{ color: '#303133' }"
45
-                :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}" highlight-current-row>
34
+                :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}" highlight-current-row  v-if="radio == '1'">
46 35
         <el-table-column
47 36
           prop="date"
48 37
           label="序号"
@@ -52,51 +41,164 @@
52 41
         >
53 42
         </el-table-column>
54 43
         <el-table-column align="center" prop="name" label="收费日期">
55
-          <template slot-scope="scope">{{ scope.row.selt_time }}</template>
44
+          <template slot-scope="scope" >{{ scope.row.settle_accounts_date }}</template>
45
+        </el-table-column>
46
+        <el-table-column align="center" prop="name" label="总金额">
47
+          <template slot-scope="scope">{{scope.row.medfee_sumamt}}</template>
48
+        </el-table-column>
49
+        <el-table-column align="center" prop="name" label="医保统筹金额">
50
+          <template slot-scope="scope">{{scope.row.fund_pay_sumamt}}</template>
51
+        </el-table-column>
52
+        <el-table-column align="center" prop="name" label="大额基金金额">
53
+          <template slot-scope="scope">{{scope.row.hifob_pay}}</template>
54
+        </el-table-column>
55
+        <el-table-column align="center" prop="name" label="大病基金金额">
56
+          <template slot-scope="scope">{{scope.row.hifmi_pay}}</template>
57
+        </el-table-column>
58
+        <el-table-column align="center" prop="name" label="补充保险基金金额">
59
+          <template slot-scope="scope">{{scope.row.hifes_pay}}</template>
60
+        </el-table-column>
61
+        <el-table-column align="center" prop="name" label="医疗救助基金金额">
62
+          <template slot-scope="scope">{{scope.row.maf_pay}}</template>
63
+        </el-table-column>
64
+        <el-table-column align="center" prop="name" label="公务员基金">
65
+          <template slot-scope="scope">{{scope.row.cvlserv_pay}}</template>
66
+        </el-table-column>
67
+        <el-table-column align="center" prop="name" label="个人支付基金">
68
+          <template slot-scope="scope">{{scope.row.psn_cash_pay}}</template>
56 69
         </el-table-column>
70
+        <el-table-column align="center" prop="name" label="折扣金额">
71
+          <template slot-scope="scope">{{scope.row.discount_price}}</template>
72
+        </el-table-column>
73
+        <el-table-column align="center" prop="name" label="优惠金额">
74
+          <template slot-scope="scope">{{scope.row.preferential_price}}</template>
75
+        </el-table-column>
76
+        <el-table-column align="center" prop="name" label="个人账户支付金额">
77
+          <template slot-scope="scope">{{scope.row.acct_pay}}</template>
78
+        </el-table-column>
79
+        <!--<el-table-column align="center" prop="name" label="预交金">-->
80
+          <!--<template slot-scope="scope">{{scope.row.medfee_sumamt}}</template>-->
81
+        <!--</el-table-column>-->
57 82
 
83
+        <!--<el-table-column align="center" prop="name" label="现金">-->
84
+          <!--<template slot-scope="scope">{{scope.row.medfee_sumamt}}</template>-->
85
+        <!--</el-table-column>-->
58 86
 
59
-        <el-table-column align="center" prop="name" label="患者名字">
60
-          <template slot-scope="scope">{{ scope.row.psn_name }}</template>
61
-        </el-table-column>
62
-        <!--<el-table-column align="center" prop="name" label="患者类型">-->
63
-          <!--<template slot-scope="scope"></template>-->
87
+        <!--<el-table-column align="center" prop="name" label="微信">-->
88
+          <!--<template slot-scope="scope">{{scope.row.medfee_sumamt}}</template>-->
64 89
         <!--</el-table-column>-->
65
-        <el-table-column align="center" prop="name" label="总金额">
66
-          <template slot-scope="scope">{{scope.row.medfee_sumamt}}</template>
90
+
91
+        <!--<el-table-column align="center" prop="name" label="操作">-->
92
+          <!--<template slot-scope="scope">-->
93
+            <!--<el-button size="mini" type="primary" @click="toDetail(scope.row)">详情</el-button>-->
94
+          <!--</template>-->
95
+        <!--</el-table-column>-->
96
+      </el-table>
97
+
98
+      <el-table :data="tableData" border style="width: 100%;" :row-style="{ color: '#303133' }"  v-if="radio == '2'"
99
+                :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}" highlight-current-row>
100
+        <el-table-column
101
+                prop="date"
102
+                label="序号"
103
+                width="60"
104
+                align="center"
105
+                type="index"
106
+        >
67 107
         </el-table-column>
68 108
 
109
+        <el-table-column align="center" prop="name" label="收费日期">
110
+          <template slot-scope="scope" >{{ scope.row.setl_time }}</template>
111
+        </el-table-column>
112
+        <el-table-column align="center" prop="name" label="姓名">
113
+          <template slot-scope="scope" >{{ scope.row.psn_name }}</template>
114
+        </el-table-column>
69 115
         <el-table-column align="center" prop="name" label="总金额">
70 116
           <template slot-scope="scope">{{scope.row.medfee_sumamt}}</template>
71 117
         </el-table-column>
118
+        <el-table-column align="center" prop="name" label="基金支付">
119
+          <template slot-scope="scope">{{scope.row.fund_pay_sumamt}}</template>
120
+        </el-table-column>
121
+        <el-table-column align="center" prop="name" label="个人支付基金">
122
+          <template slot-scope="scope">{{scope.row.psn_cash_pay}}</template>
123
+        </el-table-column>
72 124
 
125
+        <el-table-column align="center" prop="name" label="床位费">
126
+          <template slot-scope="scope">{{getPrice(scope.row.order_info,'01')}}</template>
127
+        </el-table-column>
128
+
129
+        <el-table-column align="center" prop="name" label="诊察费">
130
+          <template slot-scope="scope">{{getPrice(scope.row.order_info,'02')}}</template>
131
+        </el-table-column>
73 132
 
74 133
 
75
-        <el-table-column align="center" prop="name" label="实收金额">
76
-          <template slot-scope="scope">{{scope.row.reality_price}}</template>
134
+        <el-table-column align="center" prop="name" label="检查费">
135
+          <template slot-scope="scope">{{getPrice(scope.row.order_info,'03')}}</template>
77 136
         </el-table-column>
78
-        <el-table-column align="center" prop="name" label="科室">
79
-          <template slot-scope="scope">{{scope.row.p_info.department.name}}</template>
137
+
138
+        <el-table-column align="center" prop="name" label="化验费">
139
+          <template slot-scope="scope">{{getPrice(scope.row.order_info,'04')}}</template>
80 140
         </el-table-column>
81
-        <el-table-column align="center" prop="name" label="收费日期">
82
-          <template slot-scope="scope">  {{getTimes(scope.row.settle_accounts_date)}}</template>
141
+
142
+        <el-table-column align="center" prop="name" label="治疗费">
143
+          <template slot-scope="scope">{{getPrice(scope.row.order_info,'05')}}</template>
83 144
         </el-table-column>
84
-        <el-table-column align="center" prop="name" label="收费员">
85
-          <template slot-scope="scope">{{ scope.row.p_info.doctor }}</template>
145
+
146
+
147
+        <el-table-column align="center" prop="name" label="手术费">
148
+          <template slot-scope="scope">{{getPrice(scope.row.order_info,'06')}}</template>
86 149
         </el-table-column>
87
-        <el-table-column align="center" prop="name" label="状态">
88
-          <template slot-scope="scope">
89
-            <div v-if="scope.row.order_status == 1">待结算</div>
90
-            <div v-if="scope.row.order_status == 2">已结算</div>
91
-            <div v-if="scope.row.order_status == 3">已退费</div>
92
-          </template>
150
+
151
+        <el-table-column align="center" prop="name" label="护理费">
152
+          <template slot-scope="scope">{{getPrice(scope.row.order_info,'07')}}</template>
93 153
         </el-table-column>
94
-        <el-table-column align="center" prop="name" label="操作">
95
-          <template slot-scope="scope">
96
-            <el-button size="mini" type="primary" @click="toDetail(scope.row)">详情</el-button>
97
-          </template>
154
+
155
+
156
+        <el-table-column align="center" prop="name" label="卫生材料费">
157
+          <template slot-scope="scope">{{getPrice(scope.row.order_info,'08')}}</template>
98 158
         </el-table-column>
159
+
160
+        <el-table-column align="center" prop="name" label="西药费">
161
+          <template slot-scope="scope">{{getPrice(scope.row.order_info,'09')}}</template>
162
+        </el-table-column>
163
+
164
+        <el-table-column align="center" prop="name" label="中药饮片费">
165
+          <template slot-scope="scope">{{getPrice(scope.row.order_info,'10')}}</template>
166
+        </el-table-column>
167
+
168
+
169
+        <el-table-column align="center" prop="name" label="中成药费">
170
+          <template slot-scope="scope">{{getPrice(scope.row.order_info,'11')}}</template>
171
+        </el-table-column>
172
+
173
+        <el-table-column align="center" prop="name" label="一般诊疗费">
174
+          <template slot-scope="scope">{{getPrice(scope.row.order_info,'12')}}</template>
175
+        </el-table-column>
176
+
177
+        <el-table-column align="center" prop="name" label="挂号费">
178
+          <template slot-scope="scope">{{getPrice(scope.row.order_info,'13')}}</template>
179
+        </el-table-column>
180
+
181
+        <el-table-column align="center" prop="name" label="其他费">
182
+          <template slot-scope="scope">{{getPrice(scope.row.order_info,'14')}}</template>
183
+        </el-table-column>
184
+        <el-table-column align="center" prop="name" label="医保支付">
185
+          <template slot-scope="scope">{{scope.row.psn_cash_pay}}</template>
186
+        </el-table-column>
187
+        <el-table-column align="center" prop="name" label="现金">
188
+        <template slot-scope="scope">{{scope.row.psn_cash_pay}}</template>
189
+        </el-table-column>
190
+        <el-table-column align="center" prop="name" label="微信">
191
+        <template slot-scope="scope">{{scope.row.psn_cash_pay}}</template>
192
+        </el-table-column>
193
+        <el-table-column align="center" prop="name" label="支付宝">
194
+          <template slot-scope="scope">{{scope.row.psn_cash_pay}}</template>
195
+        </el-table-column>
196
+        <el-table-column align="center" prop="name" label="银行卡">
197
+          <template slot-scope="scope">{{scope.row.psn_cash_pay}}</template>
198
+        </el-table-column>
199
+
99 200
       </el-table>
201
+
100 202
       <el-pagination
101 203
         @size-change="handleSizeChange"
102 204
         @current-change="handleCurrentChange"
@@ -118,7 +220,7 @@
118 220
 
119 221
 <script>
120 222
   import BreadCrumb from '@/xt_pages/components/bread-crumb'
121
-  import { getHisOrderList,getDoctorList,getExportConsumeDetailList } from '@/api/his/his'
223
+  import { getIncomeStatisticsDataList,getDoctorList,getExportConsumeDetailList } from '@/api/his/his'
122 224
   import { uParseTime } from '@/utils/tools'
123 225
 
124 226
   export default {
@@ -132,6 +234,7 @@
132 234
           { path: false, name: '项目消费明细汇总' }
133 235
         ],
134 236
         tableData: [],
237
+        radio:'1',
135 238
         limit:10,
136 239
         page:1,
137 240
         keywords:"",
@@ -144,6 +247,35 @@
144 247
       }
145 248
     },
146 249
     methods: {
250
+      getPrice(order_info, number){
251
+
252
+
253
+
254
+
255
+
256
+      },
257
+      changeType(val){
258
+
259
+        let params= {
260
+          page : this.page,
261
+          limit: this.limit,
262
+          keywords:this.keywords,
263
+          start_time:this.start_time,
264
+          end_time: this.end_time,
265
+          statistics_type: this.radio
266
+        }
267
+        getIncomeStatisticsDataList(params).then(response => {
268
+          if (response.data.state == 0) {
269
+            this.$message.error(response.data.msg)
270
+            return false
271
+          } else {
272
+            this.tableData = response.data.data.list
273
+            this.total = response.data.data.total
274
+          }
275
+        })
276
+
277
+
278
+      },
147 279
       export_detail(){
148 280
         let params= {
149 281
           start_time:this.start_time,
@@ -248,33 +380,29 @@
248 380
       },  formatJson(filterVal, jsonData) {
249 381
         return jsonData.map(v => filterVal.map(j => v[j]))
250 382
       },
251
-      changeDoctor(){
252
-        this.page = 1
253
-        this.keywords=""
254
-        this.getHisOrderList()
255
-      },
383
+
256 384
       handleSizeChange(limit){
257 385
         this.limit = limit;
258
-        this.getHisOrderList()
386
+        this.getIncomeStatisticsDataList()
259 387
 
260 388
       },handleCurrentChange(page){
261 389
         this.page = page;
262
-        this.getHisOrderList()
390
+        this.getIncomeStatisticsDataList()
263 391
 
264 392
 
265 393
       },
266 394
       handleStartTimeChange(){
267 395
         this.page = 1
268 396
         this.keywords=""
269
-        this.getHisOrderList()
397
+        this.getIncomeStatisticsDataList()
270 398
       },handleEndTimeChange(){
271 399
         this.page = 1
272 400
         this.keywords=""
273
-        this.getHisOrderList()
401
+        this.getIncomeStatisticsDataList()
274 402
       },
275 403
       searchAction(){
276 404
         this.page = 1
277
-        this.getHisOrderList()
405
+        this.getIncomeStatisticsDataList()
278 406
 
279 407
 
280 408
       },
@@ -288,21 +416,21 @@
288 416
           return uParseTime(value, temp)
289 417
         }
290 418
         return ''
291
-      },getHisOrderList(){
419
+      },getIncomeStatisticsDataList(){
292 420
         let params= {
293 421
           page : this.page,
294 422
           limit: this.limit,
295 423
           keywords:this.keywords,
296 424
           start_time:this.start_time,
297 425
           end_time: this.end_time,
298
-          type: this.admin_user_id
426
+          statistics_type: this.radio
299 427
         }
300
-        getHisOrderList(params).then(response => {
428
+        getIncomeStatisticsDataList(params).then(response => {
301 429
           if (response.data.state == 0) {
302 430
             this.$message.error(response.data.msg)
303 431
             return false
304 432
           } else {
305
-            this.tableData = response.data.data.order
433
+            this.tableData = response.data.data.list
306 434
             this.total = response.data.data.total
307 435
           }
308 436
         })
@@ -321,7 +449,7 @@
321 449
       }
322 450
     }, created() {
323 451
      this.getDoctorList()
324
-     this.getHisOrderList()
452
+     this.getIncomeStatisticsDataList()
325 453
 
326 454
 
327 455
     }

+ 1 - 1
src/xt_pages/outpatientCharges/invoiceTemplate/printTwo.vue Целия файл

@@ -11,7 +11,7 @@
11 11
             <div>
12 12
                 <span style="position: absolute;left:590px;top:40px;">{{ printDate.slice(0,4) }}</span>
13 13
                 <span style="position: absolute;left:630px;top:40px;">{{ printDate.slice(5,7) }}</span>
14
-                <span style="position: absolute;left:660px;top:40px;">{{ printDate.slice(8,11) }}</span>
14
+                <span style="position: absolute;left:690px;top:40px;">{{ printDate.slice(8,11) }}</span>
15 15
             </div>
16 16
         </div>
17 17
         <div style="display:flex;justify-content: space-between;">

+ 10 - 5
src/xt_pages/outpatientCharges/listPrint.vue Целия файл

@@ -56,7 +56,7 @@
56 56
       if(this.org_id == 10106){
57 57
         this.getInfo10106(this.paramsObj.id)
58 58
       }
59
-      
59
+
60 60
     },
61 61
 
62 62
     methods: {
@@ -85,11 +85,16 @@
85 85
                 price: infos.pric,
86 86
                 count: infos.cnt
87 87
               }
88
+              console.log(infos)
88 89
               if (infos.advice && infos.advice.id == 0 && infos.project && infos.project.id > 0) {
89 90
                 obj['p_time'] = this.getTimes(infos.project.prescription.ctime)
90
-                obj['name'] = infos.project.project.project_name
91
+                if(infos.project.type == 2){
92
+                  obj['name'] = infos.project.project.project_name
93
+                }else if (infos.project.type == 3){
94
+                  obj['name'] = infos.project.good_info.good_name
95
+                }
91 96
                 obj['spec'] = 1
92
-                obj['unit'] = infos.project.project.unit
97
+                obj['unit'] = infos.project.unit
93 98
 
94 99
               }
95 100
 
@@ -189,7 +194,7 @@
189 194
             scanStyles: false
190 195
           });
191 196
         }
192
-        
197
+
193 198
 
194 199
         // if (this.org_template_info.template_id == 1) {
195 200
         //   printJS({
@@ -464,4 +469,4 @@
464 469
   .newContainer::-webkit-scrollbar {
465 470
     height: 15px !important;
466 471
   }
467
-</style>
472
+</style>

+ 10 - 10
src/xt_pages/outpatientCharges/listTemplate/printTwo.vue Целия файл

@@ -84,9 +84,9 @@
84 84
         <div>
85 85
             <div v-if="Object.values(obj)[index].length > 0" v-for="(item,itemIndex) in Object.values(obj)[index]" :key="itemIndex" style="border-bottom:1px solid #000;padding:10px 0;display:flex;" >
86 86
                 <div style="width:20%;text-align:center;" v-if="item.advice_id > 0">{{ item.advice.drug.medical_insurance_number }}</div>
87
-                <div style="width:20%;text-align:center;" v-if="item.project_id > 0">{{ item.project.project.medical_code }}</div>
87
+                <div style="width:20%;text-align:center;" v-if="item.project_id > 0">{{item.project.type == 2?item.project.project.medical_code: item.project.good_info.medical_insurance_number}}</div>
88 88
                 <div style="width:20%;text-align:center;" v-if="item.advice_id > 0">{{item.advice.drug.drug_name}}</div>
89
-                <div style="width:20%;text-align:center;" v-if="item.project_id > 0">{{item.project.project.project_name}}</div>
89
+                <div style="width:20%;text-align:center;" v-if="item.project_id > 0">{{item.project.type == 2?item.project.project.project_name:item.project.good_info.good_name}}</div>
90 90
 
91 91
                 <div style="width:10%;text-align:center;">{{item.pric}}</div>
92 92
                 <div style="width:10%;text-align:center;">{{item.cnt}}</div>
@@ -97,7 +97,7 @@
97 97
             </div>
98 98
         </div>
99 99
     </div>
100
-    
100
+
101 101
     <div style="display:flex;border-bottom:1px solid #000;padding:20px 0 10px;">
102 102
       <div style="width:70%;">合计:</div>
103 103
       <div style="width:10%;text-align:center;">{{info.medfee_sumamt}}</div>
@@ -135,13 +135,13 @@ export default {
135 135
         default: function () {
136 136
           return {}
137 137
         }
138
-      }, 
138
+      },
139 139
       order_infos: {
140 140
         type: Object,
141 141
         default: function () {
142 142
           return {}
143 143
         }
144
-      }, 
144
+      },
145 145
       p_admin: {
146 146
         type: Object,
147 147
         default: function () {
@@ -153,7 +153,7 @@ export default {
153 153
           return {}
154 154
         }
155 155
       }
156
-    }, 
156
+    },
157 157
     data(){
158 158
         return{
159 159
             obj:{},
@@ -224,9 +224,9 @@ export default {
224 224
                     'med_chrgitm_type11':[],
225 225
                     'med_chrgitm_type14':[],
226 226
                 }
227
-                
227
+
228 228
                 newVal.map(item => {
229
-                    
229
+
230 230
                     if(item.med_chrgitm_type == '01'){
231 231
                         obj.med_chrgitm_type01.push(item)
232 232
                         this.price01 += item.det_item_fee_sumamt
@@ -255,7 +255,7 @@ export default {
255 255
                         obj.med_chrgitm_type14.push(item)
256 256
                         this.price14 += item.det_item_fee_sumamt
257 257
                     }
258
-                    
258
+
259 259
                 })
260 260
                 this.obj = obj
261 261
                 console.log('this.obj',this.obj)
@@ -264,7 +264,7 @@ export default {
264 264
         }
265 265
     }
266 266
 }
267
-    
267
+
268 268
 
269 269
 
270 270
 </script>

+ 16 - 33
src/xt_pages/outpatientCharges/newStatementPrint.vue Целия файл

@@ -13,8 +13,7 @@
13 13
     </template>
14 14
 
15 15
     <div class='dialysisPage' style="padding-top:40px;">
16
-      <printOne v-if="org_id != 9990" :info="info" :p_admin="p_admin" :charge_admin="charge_admin"></printOne>
17
-      <printTwo v-if="org_id == 9990" :info="info" :order_infos="order_infos" :p_admin="p_admin" :charge_admin="charge_admin"></printTwo>
16
+      <printOne :info="info" :p_admin="p_admin" :charge_admin="charge_admin"></printOne>
18 17
     </div>
19 18
   </div>
20 19
 </template>
@@ -31,14 +30,12 @@
31 30
   import BreadCrumb from "@/xt_pages/components/bread-crumb";
32 31
   import print from "print-js";
33 32
   import printOne from "./statementTemplate/printOne"
34
-  import printTwo from "./statementTemplate/printTwo"
35 33
   import { getAllDoctorList,getAllHisPatientList,getPrescriptionPrint } from "@/api/project/project"
36 34
   export default {
37 35
     name: "newStatementPrint",
38 36
     components: {
39 37
       BreadCrumb,
40
-      printOne,
41
-      printTwo
38
+      printOne
42 39
     },
43 40
     props:{
44 41
       paramsObj:Object
@@ -62,8 +59,6 @@
62 59
         info:null,
63 60
         p_admin:{},
64 61
         charge_admin:{},
65
-        org_id:'',
66
-        order_infos:null
67 62
       };
68 63
     },
69 64
     methods:{
@@ -71,26 +66,14 @@
71 66
         var ptime = Math.round(new Date().getTime() / 1000);
72 67
         this.print_time = uParseTime(ptime, "{y}-{m}-{d} {h}:{i}");
73 68
 
74
-        if(this.org_id != 9990){
75
-          const style =
69
+        const style =
76 70
           '@media print {.statementTitle{font-size: 28px;text-align: center;font-weight: bold;margin-bottom: 10px;}.statementTable{width: 100%;text-align: center;border-collapse: collapse;line-height: 40px;font-size: 16px;border-color: #000;}}';
77
-          printJS({
78
-            printable: "statement-print",
79
-            type: "html",
80
-            style: style,
81
-            scanStyles: false
82
-          });
83
-        }else {
84
-          const style =
85
-          '@media print {#statement-print{font-size:12px;width:600px;margin:0 auto;}.statementTitle{font-size: 22px;text-align: center;margin-bottom: 10px;}.statementTable{width: 100%;text-align: center;border-collapse: collapse;line-height: 40px;font-size: 16px;border-color: #000;}}';
86
-          printJS({
87
-            printable: "statement-print",
88
-            type: "html",
89
-            style: style,
90
-            scanStyles: false
91
-          });
92
-        }
93
-
71
+        printJS({
72
+          printable: "statement-print",
73
+          type: "html",
74
+          style: style,
75
+          scanStyles: false
76
+        });
94 77
 
95 78
         // if (this.org_template_info.template_id == 1) {
96 79
         //   printJS({
@@ -164,6 +147,8 @@
164 147
         //       console.log("doctorporject",doctorPorject)
165 148
         //     }
166 149
         // })
150
+      },  getTimes(time) {
151
+        return uParseTime(time, '{y}-{m}-{d}')
167 152
       },
168 153
       searchAction(){
169 154
 
@@ -190,8 +175,6 @@
190 175
                 that.info = response.data.data.info;
191 176
                 that.p_admin = response.data.data.printor_admin;
192 177
                 that.charge_admin = response.data.data.charge_admin;
193
-                that.order_infos = response.data.data;
194
-
195 178
 
196 179
 
197 180
                 that.info['p_admin'] =  that.p_admin;
@@ -203,8 +186,6 @@
203 186
                 that.info['diagnosis'] =  response.data.data.diagnosis;
204 187
 
205 188
 
206
-                console.log(that.info);
207
-
208 189
                 that.info['bed_cost_total'] = response.data.data.bedCostTotal;
209 190
                 that.info['bed_cost_self_total'] = response.data.data.bedCostSelfTotal;
210 191
                 that.info['bed_cost_part_self_total'] = response.data.data.bedCostPartSelfTotal;
@@ -242,7 +223,11 @@
242 223
                 that.info['treat_cost_total'] = response.data.data.treatCostTotal;
243 224
                 that.info['treat_cost_self_total'] = response.data.data.treatCostSelfTotal;
244 225
                 that.info['treat_cost_part_self_total'] = response.data.data.treatCostPartSelfTotal;
245
-                console.log(this.info)
226
+
227
+                if(that.paramsObj.settle_type != 1){
228
+                  that.info.begndate = that.getTimes(that.paramsObj.start_time)
229
+                  that.info.enddate = that.getTimes(that.paramsObj.end_time)
230
+                }
246 231
               }
247 232
             })
248 233
             .catch(function (error) {
@@ -254,9 +239,7 @@
254 239
     },
255 240
 
256 241
     created() {
257
-      this.org_id = this.$store.getters.xt_user.org_id;
258 242
       this.getInfo(this.paramsObj.order_id)
259
-
260 243
     },
261 244
     watch:{
262 245
       paramsObj:{//深度监听,可监听到对象、数组的变化

Файловите разлики са ограничени, защото са твърде много
+ 1047 - 661
src/xt_pages/outpatientCharges/outpatientChargesManagement.vue


+ 140 - 133
src/xt_pages/outpatientCharges/statementPrint.vue Целия файл

@@ -149,6 +149,8 @@ export default {
149 149
       //       console.log("doctorporject",doctorPorject)
150 150
       //     }
151 151
       // })
152
+    }, getTimes(time) {
153
+      return uParseTime(time, '{y}-{m}-{d}')
152 154
     },
153 155
     searchAction(){
154 156
 
@@ -229,6 +231,11 @@ export default {
229 231
               that.info['order_infos'] =  response.data.data.order_infos;
230 232
               that.info['diagnosis'] =  response.data.data.diagnosis
231 233
 
234
+              if(that.paramsObj.settle_type != 1){
235
+                that.info.begndate = that.getTimes(that.paramsObj.start_time)
236
+                that.info.enddate = that.getTimes(that.paramsObj.end_time)
237
+              }
238
+
232 239
             }
233 240
           })
234 241
           .catch(function (error) {
@@ -271,168 +278,168 @@ export default {
271 278
   letter-spacing: 5px;
272 279
 }
273 280
 
274
-.dialysis-print-order .order-title {
275
-  margin: auto;
276
-  font-weight: 600;
277
-  text-align: center;
278
-  font-size: 22px;
279
-  padding: 10px;
280
-}
281
+  .dialysis-print-order .order-title {
282
+    margin: auto;
283
+    font-weight: 600;
284
+    text-align: center;
285
+    font-size: 22px;
286
+    padding: 10px;
287
+  }
281 288
 
282
-.dialysis-print-order .table-box {
283
-  width: 100%;
284
-  line-height: 23px;
285
-  font-size: 14px;
286
-}
289
+  .dialysis-print-order .table-box {
290
+    width: 100%;
291
+    line-height: 23px;
292
+    font-size: 14px;
293
+  }
287 294
 
288
-.dialysis-print-order .print-table {
289
-  width: 100%;
290
-  text-align: center;
291
-  border-collapse: collapse;
292
-  line-height: 40px;
293
-  font-size: 14px;
294
-  border-color: #000;
295
-}
295
+  .dialysis-print-order .print-table {
296
+    width: 100%;
297
+    text-align: center;
298
+    border-collapse: collapse;
299
+    line-height: 40px;
300
+    font-size: 14px;
301
+    border-color: #000;
302
+  }
296 303
 
297
-.dialysis-print-order .print-table-no {
298
-  width: 100%;
299
-  text-align: center;
300
-  border-collapse: collapse;
301
-  font-size: 14px;
302
-}
304
+  .dialysis-print-order .print-table-no {
305
+    width: 100%;
306
+    text-align: center;
307
+    border-collapse: collapse;
308
+    font-size: 14px;
309
+  }
303 310
 
304
-.dialysis-print-order .under-line {
305
-  border-bottom: 1px solid #999;
306
-  width: 95%;
307
-  text-align: center;
308
-  margin-left: 2px;
309
-}
311
+  .dialysis-print-order .under-line {
312
+    border-bottom: 1px solid #999;
313
+    width: 95%;
314
+    text-align: center;
315
+    margin-left: 2px;
316
+  }
310 317
 
311
-.dialysis-print-order .title-box {
312
-  text-align: center;
313
-  font-size: 16px;
314
-}
318
+  .dialysis-print-order .title-box {
319
+    text-align: center;
320
+    font-size: 16px;
321
+  }
315 322
 
316
-.dialysis-print-order .radio-lebel-box {
317
-  font-weight: 400;
318
-  cursor: pointer;
319
-}
323
+  .dialysis-print-order .radio-lebel-box {
324
+    font-weight: 400;
325
+    cursor: pointer;
326
+  }
320 327
 
321
-.dialysis-print-order .radio-no {
322
-  opacity: 0;
323
-  outline: none;
324
-  position: absolute;
325
-  margin: 0;
326
-  width: 0;
327
-  height: 0;
328
-  z-index: -1;
329
-}
328
+  .dialysis-print-order .radio-no {
329
+    opacity: 0;
330
+    outline: none;
331
+    position: absolute;
332
+    margin: 0;
333
+    width: 0;
334
+    height: 0;
335
+    z-index: -1;
336
+  }
330 337
 
331
-.dialysis-print-order .radio-inner {
332
-  white-space: nowrap;
333
-  cursor: pointer;
334
-  outline: none;
335
-  display: inline-block;
336
-  line-height: 1;
337
-  position: relative;
338
-  vertical-align: middle;
339
-}
338
+  .dialysis-print-order .radio-inner {
339
+    white-space: nowrap;
340
+    cursor: pointer;
341
+    outline: none;
342
+    display: inline-block;
343
+    line-height: 1;
344
+    position: relative;
345
+    vertical-align: middle;
346
+  }
340 347
 
341
-.dialysis-print-order .radio-fang {
342
-  display: inline-block;
343
-  position: relative;
344
-  border: 1px solid #000;
345
-  box-sizing: border-box;
346
-  width: 14px;
347
-  height: 14px;
348
-  background-color: #fff;
349
-  z-index: 1;
350
-  transition: border-color 0.25s cubic-bezier(0.71, -0.46, 0.29, 1.46),
348
+  .dialysis-print-order .radio-fang {
349
+    display: inline-block;
350
+    position: relative;
351
+    border: 1px solid #000;
352
+    box-sizing: border-box;
353
+    width: 14px;
354
+    height: 14px;
355
+    background-color: #fff;
356
+    z-index: 1;
357
+    transition: border-color 0.25s cubic-bezier(0.71, -0.46, 0.29, 1.46),
351 358
     background-color 0.25s cubic-bezier(0.71, -0.46, 0.29, 1.46);
352
-}
359
+  }
353 360
 
354
-.dialysis-print-order .is-checked-radio::after {
355
-  content: "√";
356
-  font-size: 15px;
357
-}
361
+  .dialysis-print-order .is-checked-radio::after {
362
+    content: "√";
363
+    font-size: 15px;
364
+  }
358 365
 
359
-.dialysis-print-order .print-table-no tr td {
360
-  padding: 8px 5px;
361
-  line-height: 25px;
362
-}
366
+  .dialysis-print-order .print-table-no tr td {
367
+    padding: 8px 5px;
368
+    line-height: 25px;
369
+  }
363 370
 
364
-.dialysis-print-order .print-table tr td {
365
-  padding: 1px 1px;
366
-  /*line-height: 25px;*/
367
-}
371
+  .dialysis-print-order .print-table tr td {
372
+    padding: 1px 1px;
373
+    /*line-height: 25px;*/
374
+  }
368 375
 
369
-.es-img {
370
-  height: 30px;
371
-}
376
+  .es-img {
377
+    height: 30px;
378
+  }
372 379
 
373
-.advice-name {
374
-  text-align: left;
375
-}
380
+  .advice-name {
381
+    text-align: left;
382
+  }
376 383
 
377
-.advice-children {
378
-  display: flex;
379
-}
384
+  .advice-children {
385
+    display: flex;
386
+  }
380 387
 
381
-.title-box-pro {
382
-  border: 0 #fff;
383
-  line-height: 25px;
384
-  height: 25px;
385
-  text-align: left;
386
-  padding-left: 10px !important;
387
-}
388
-.title-box-pro-tr {
389
-  border: 0 #fff;
390
-}
391
-.text-align-left {
392
-  text-align: left !important;
393
-  padding-left: 10px !important;
394
-  font-size: 14px !important;
395
-  line-height: 25px;
396
-}
397
-.print-table-tr-new td {
398
-  line-height: 20px !important;
399
-}
400
-.border-top-solid {
401
-  border: solid 1px #000;
402
-}
403
-.print-template-two tr {
404
-  line-height: 30px;
405
-}
388
+  .title-box-pro {
389
+    border: 0 #fff;
390
+    line-height: 25px;
391
+    height: 25px;
392
+    text-align: left;
393
+    padding-left: 10px !important;
394
+  }
395
+  .title-box-pro-tr {
396
+    border: 0 #fff;
397
+  }
398
+  .text-align-left {
399
+    text-align: left !important;
400
+    padding-left: 10px !important;
401
+    font-size: 14px !important;
402
+    line-height: 25px;
403
+  }
404
+  .print-table-tr-new td {
405
+    line-height: 20px !important;
406
+  }
407
+  .border-top-solid {
408
+    border: solid 1px #000;
409
+  }
410
+  .print-template-two tr {
411
+    line-height: 30px;
412
+  }
406 413
 
407
-.table-box1 {
408
-  border: 1px solid #000;
409
-  width: 100%;
410
-  line-height: 30px;
411
-  font-size: 14px;
412
-  border-collapse: collapse;
413
-}
414
-.table-box1 tr {
415
-  border-bottom: 1px solid #000;
416
-}
414
+  .table-box1 {
415
+    border: 1px solid #000;
416
+    width: 100%;
417
+    line-height: 30px;
418
+    font-size: 14px;
419
+    border-collapse: collapse;
420
+  }
421
+  .table-box1 tr {
422
+    border-bottom: 1px solid #000;
423
+  }
417 424
 </style>
418 425
 
419 426
 <style lang="scss">
420 427
 
421
-.newContainer{
428
+  .newContainer{
422 429
   .dialysisPage::-webkit-scrollbar {
423 430
     height: 15px;
424 431
   }
425 432
 
426 433
   .el-date-editor{
427
-    .el-input__inner{
428
-      padding-right:0px;
429
-    }
434
+  .el-input__inner{
435
+    padding-right:0px;
436
+  }
430 437
   }
431 438
   .el-table td, .el-table th{
432 439
     text-align: center;
433 440
   }
434
-}
435
-.newContainer::-webkit-scrollbar{
436
-  height: 15px !important;
437
-}
441
+  }
442
+  .newContainer::-webkit-scrollbar{
443
+    height: 15px !important;
444
+  }
438 445
 </style>

+ 12 - 9
src/xt_pages/outpatientCharges/summary.vue Целия файл

@@ -65,34 +65,34 @@
65 65
           type="index"
66 66
         >
67 67
         </el-table-column>
68
-        <el-table-column align="center" prop="name" label="就诊号">
68
+        <el-table-column align="center" width="100" prop="name" label="就诊号">
69 69
           <template slot-scope="scope">{{ scope.row.his_patient.number }}</template>
70 70
         </el-table-column>
71
-        <el-table-column align="center" prop="name" label="患者名字">
71
+        <el-table-column align="center" width="90" prop="name" label="患者名字">
72 72
           <template slot-scope="scope">{{ scope.row.patient.name }}</template>
73 73
         </el-table-column>
74 74
         <!--<el-table-column align="center" prop="name" label="患者类型">-->
75 75
         <!--<template slot-scope="scope"></template>-->
76 76
         <!--</el-table-column>-->
77 77
 
78
-        <el-table-column align="center" prop="name" label="应收金额">
78
+        <el-table-column align="center" width="90" prop="name" label="应收金额">
79 79
           <template slot-scope="scope">{{scope.row.medfee_sumamt}}</template>
80 80
         </el-table-column>
81
-        <el-table-column align="center" prop="name" label="实收金额">
81
+        <el-table-column align="center" width="90" prop="name" label="实收金额">
82 82
           <template slot-scope="scope">{{scope.row.reality_price}}</template>
83 83
         </el-table-column>
84
-        <el-table-column align="center" prop="name" label="科室">
84
+        <el-table-column align="center" width="90" prop="name" label="科室">
85 85
           <template slot-scope="scope">{{scope.row.department_name}}</template>
86 86
         </el-table-column>
87
-        <el-table-column align="center" prop="name" label="收费日期">
87
+        <el-table-column align="center" width="100" prop="name" label="收费日期">
88 88
           <template slot-scope="scope">
89 89
             {{scope.row.setl_time?scope.row.setl_time:getTimes(scope.row.settle_accounts_date)}}
90 90
           </template>
91 91
         </el-table-column>
92
-        <el-table-column align="center" prop="name" label="收费员">
92
+        <el-table-column align="center" width="90" prop="name" label="收费员">
93 93
           <template slot-scope="scope">{{ getName(scope.row.creator) }}</template>
94 94
         </el-table-column>
95
-        <el-table-column align="center" prop="name" label="状态">
95
+        <el-table-column align="center" width="80" prop="name" label="状态">
96 96
           <template slot-scope="scope">
97 97
             <div v-if="scope.row.order_status == 1">待结算</div>
98 98
             <div v-if="scope.row.order_status == 2">已结算</div>
@@ -371,7 +371,10 @@
371 371
         } else {
372 372
           this.statementVisible = true;
373 373
           let obj = {
374
-            order_id: row.id
374
+            order_id: row.id,
375
+            settle_type:row.settle_type,
376
+            start_time:row.settle_start_time,
377
+            end_time:row.settle_end_time,
375 378
           };
376 379
           this.orderObj = obj
377 380
         }

+ 13 - 3
src/xt_pages/outpatientCharges/summaryDetail.vue Целия файл

@@ -25,7 +25,7 @@
25 25
                         </el-table-column>
26 26
 
27 27
                         <el-table-column align="center" prop="project_name" label="分类" width="100">
28
-                          <template slot-scope="scope">{{ scope.row.type == 1?'药品':'项目' }}</template>
28
+                          <template slot-scope="scope">{{ scope.row.type == 1?'药品': scope.row.project_type == 2? '项目':'耗材'}}</template>
29 29
                         </el-table-column>
30 30
 
31 31
 
@@ -409,8 +409,18 @@ export default {
409 409
         let count = 0
410 410
         for (let a = 0; a < project_month_prescriptions.project.length; a++) {
411 411
           if (project_ids[i].price == project_month_prescriptions.project[a].price &&project_ids[i].id == project_month_prescriptions.project[a].project_id ) {
412
-            obj['name'] = project_month_prescriptions.project[a].project.project_name
413
-            obj['statistical_classification'] = ''
412
+
413
+            if(project_month_prescriptions.project[a].type == 2){
414
+              obj['name'] = project_month_prescriptions.project[a].project.project_name
415
+              obj['statistical_classification'] = ''
416
+              obj['project_type'] = 2
417
+
418
+
419
+            }else if (project_month_prescriptions.project[a].type == 3){
420
+              obj['name'] = project_month_prescriptions.project[a].good_info.good_name
421
+              obj['statistical_classification'] = ''
422
+              obj['project_type'] = 3
423
+            }
414 424
             obj['single_dose'] = project_month_prescriptions.project[a].single_dose
415 425
             obj['delivery_way'] = project_month_prescriptions.project[a].delivery_way
416 426
             obj['execution_frequency'] = project_month_prescriptions.project[a].execution_frequency

+ 26 - 4
src/xt_pages/outpatientDoctorStation/components/callPrescription.vue Целия файл

@@ -93,11 +93,11 @@
93 93
             <el-table-column align="center" type="index" width="60" label="序号"></el-table-column>
94 94
             <el-table-column align="center" prop="project_name" width="160" label="名称">
95 95
               <template slot-scope="scope">
96
-                <span>{{ scope.row.project.project_name }}</span>
96
+                <span>{{ scope.row.type == 2?scope.row.project.project_name:scope.row.good_info.good_name}}</span>
97 97
               </template>
98 98
             </el-table-column>
99 99
             <el-table-column align="center" prop="statistical_classification" width="100" label="组">
100
-              <template slot-scope="scope">{{getGroup(scope.row.statistical_classification)}}</template>
100
+              <template slot-scope="scope">{{scope.row.type == 2 ?getGroup(scope.row.statistical_classification):"耗材"}}</template>
101 101
             </el-table-column>
102 102
             <el-table-column align="center" prop="single_dose" width="90" label="单次用量">
103 103
               <template slot-scope="scope">
@@ -260,13 +260,16 @@
260 260
                 single_dose_unit:prescription.doctor_advice[b].single_dose_unit,
261 261
                 prescribing_number_unit:prescription.doctor_advice[b].prescribing_number_unit,
262 262
                 medical_insurance_number:prescription.doctor_advice[b].med_list_codg,
263
-                id:prescription.doctor_advice[b].drug_id
263
+                id:prescription.doctor_advice[b].drug_id,
264
+                drug:prescription.doctor_advice[b].drug,
265
+
264 266
               };
265 267
               tempAdvice.push(obj)
266 268
 
267 269
             }
268 270
 
269 271
 
272
+
270 273
             for (let b = 0; b < prescription.project.length; b++) {
271 274
               let obj = {
272 275
                 id: 0,
@@ -280,8 +283,27 @@
280 283
                 total:prescription.project[b].count,
281 284
                 price:prescription.project[b].price,
282 285
                 remark:prescription.project[b].remark,
283
-                medical_code:prescription.project[b].project.medical_code,
286
+                unit: prescription.project[b].unit,
287
+                type: prescription.project[b].type
288
+
289
+                // medical_code:prescription.project[b].project.medical_code,
284 290
               };
291
+              console.log(prescription.project[b].type)
292
+              if(prescription.project[b].type == 2){
293
+                console.log("pre")
294
+
295
+                obj['statistical_classification'] =  prescription.project[b].project.statistical_classification
296
+                obj['medical_code'] =  prescription.project[b].project.medical_code
297
+                obj['project_name'] =  prescription.project[b].project.project_name
298
+
299
+              }else if(prescription.project[b].type == 3){
300
+                console.log("pre2")
301
+
302
+                obj['statistical_classification'] = ""
303
+                obj['medical_code'] =  prescription.project[b].good_info.medical_insurance_number
304
+                obj['project_name'] =  prescription.project[b].good_info.good_name
305
+              }
306
+
285 307
               tempProject.push(obj)
286 308
             }
287 309
             let obj = {

Файловите разлики са ограничени, защото са твърде много
+ 1302 - 1101
src/xt_pages/outpatientDoctorStation/components/deskPrescription.vue


+ 990 - 0
src/xt_pages/outpatientDoctorStation/components/dialysisIndex.vue Целия файл

@@ -0,0 +1,990 @@
1
+<template>
2
+  <div class="main-contain">
3
+
4
+    <div
5
+      class="loadingBox"
6
+      v-loading="loading"
7
+      element-loading-text="拼命加载中"
8
+      element-loading-spinner="el-icon-loading"
9
+      element-loading-background="rgba(0, 0, 0, 0.8)"
10
+      v-if="dialysisShow"
11
+    >
12
+      <div style="padding-top: 56px;width:100%;" >
13
+
14
+        <nav-igation
15
+          ref="nav"
16
+          title="弹窗导航"
17
+          @advice="adviceFunc"
18
+          :patient="patient"
19
+          :schedual="schedual"
20
+          :prescription="prescription"
21
+          :solution="solution"
22
+          :receiver_treatment_access="receiver_treatment_access"
23
+          :predialysis_evaluation="predialysis_evaluation"
24
+          :doctor_advices="doctor_advices"
25
+          :double_check="double_check"
26
+          :assessment_after_dislysis="assessment_after_dislysis"
27
+          :treatment_summary="treatment_summary"
28
+          :monitor_records="monitor_records"
29
+          :dialysis_order="dialysis_order"
30
+          :admin_users="admin_users"
31
+          :devices="devices"
32
+          :device_numbers="device_numbers"
33
+          :admin_user_map="admin_user_map"
34
+          :device_map="device_map"
35
+          :device_number_map="device_number_map"
36
+          :niprocart_info="niprocart_info"
37
+          :jms_info="jms_info"
38
+          :fistula_needle_set_info="fistula_needle_set_info"
39
+          :fistula_needle_set_16_info="fistula_needle_set_16_info"
40
+          :hemoperfusion_info="hemoperfusion_info"
41
+          :dialyser_sterilised_info="dialyser_sterilised_info"
42
+          :filtryzer_info="filtryzer_info"
43
+          :dialyzers_info="dialyzers_info"
44
+          :injector_info="injector_info"
45
+          :bloodlines_info="bloodlines_info"
46
+          :tubingHemodialysis_info="tubingHemodialysis_info"
47
+          :safe_package_info="safe_package_info"
48
+          :aliquid_info="aliquid_info"
49
+          :config="config"
50
+          :longAdvices="longAdvices"
51
+          :waitUploadAdvices="waitUploadAdvices"
52
+          :is_open="is_open"
53
+          :last_predialysis_evaluation="lastPredialysisEvaluation"
54
+          :last_monitor_record="lastMonitorRecord"
55
+          :last_assessment_after_dislysis="lastAssessmentAfterDislysis"
56
+          :last_dialysis_prescribe="lastDialysisPrescribe"
57
+          :last_dryWeight_dislysis="lastDryWeightDislysis"
58
+          :special_premission="headNurses"
59
+          @assessmentAfterDislysis="assessmentAfterDislysisFunc"
60
+          :system_prescribe="system_prescribe"
61
+          :his_is_open="his_is_open"
62
+          :lastAssessment="lastAssessment"
63
+          :stockType="stockType"
64
+        >
65
+        </nav-igation>
66
+
67
+
68
+
69
+        <basic-infor
70
+          :patient="patient"
71
+          :device_number="schedual.id == 0 ? '' : schedual.device_number.number"
72
+          :steps="steps"
73
+          title="基本信息"
74
+        ></basic-infor>
75
+
76
+        <dialysis-prescription
77
+          :prescription="prescription"
78
+          :solution="solution"
79
+          :device_map="device_map"
80
+          :preparestock="preparestock"
81
+          title="透析处方"
82
+        ></dialysis-prescription>
83
+
84
+
85
+
86
+      <!-- <past-data class="往期数据"></past-data> -->
87
+        <div style="height: 20px;background-color: #f6f8f9"></div>
88
+        <accepts-assessment
89
+          :record="receiver_treatment_access"
90
+          title="接诊评估"
91
+        ></accepts-assessment>
92
+
93
+        <assessment-before
94
+          :record="predialysis_evaluation"
95
+          ref="assessment_before"
96
+          title="透前评估"
97
+        ></assessment-before>
98
+
99
+        <stat-order
100
+          ref="stat_order"
101
+          :advices="doctor_advices"
102
+          :doctor_map="admin_user_map"
103
+          title="临时医嘱"
104
+        ></stat-order>
105
+
106
+        <double-check
107
+          ref="double_check"
108
+          :record="double_check"
109
+          :admin_map="admin_user_map"
110
+          title="双人核对 "
111
+        ></double-check>
112
+
113
+        <dialysis-computer
114
+          ref="dialysis_computer"
115
+          :record="dialysis_order"
116
+          :admin_map="admin_user_map"
117
+          :device_number_map="device_number_map"
118
+          title="透析上机 "
119
+        ></dialysis-computer>
120
+
121
+        <dialysis-monitoring
122
+          ref="monitoring"
123
+          :monitores="monitor_records"
124
+          title="透析监测"
125
+        ></dialysis-monitoring>
126
+
127
+
128
+        <dialysis-off
129
+          ref="dialysis_off"
130
+          :record="dialysis_order"
131
+          :admin_map="admin_user_map"
132
+          title="透析下机 "
133
+        ></dialysis-off>
134
+
135
+        <assessment-after
136
+          ref="assessment_after"
137
+          :record="assessment_after_dislysis"
138
+          title="透后评估"
139
+        ></assessment-after>
140
+
141
+        <treatment-of
142
+          ref="treatment_of"
143
+          :record="treatment_summary"
144
+          title="治疗小结"
145
+        ></treatment-of>
146
+      </div>
147
+      
148
+    </div>
149
+    <div style="padding-top: 56px;width:100%;text-align:center;font-size:22px;color:red;" v-else>该患者未排班,请先去排班</div>
150
+  </div>
151
+</template>
152
+
153
+<script>
154
+const moment = require('moment')
155
+import axios from 'axios'
156
+import NavIgation from '@/xt_pages/dialysis/details/NavIgation'
157
+import BasicInfor from '@/xt_pages/dialysis/details/BasicInfor'
158
+import DialysisPrescription from '@/xt_pages/dialysis/details/DialysisPrescription'
159
+import PastData from '@/xt_pages/dialysis/details/pastData'
160
+import AcceptsAssessment from '@/xt_pages/dialysis/details/acceptsAssessment'
161
+import AssessmentBefore from '@/xt_pages/dialysis/details/assessmentBefore'
162
+import StatOrder from '@/xt_pages/dialysis/details/statOrder'
163
+import DialysisComputer from '@/xt_pages/dialysis/details/dialysisComputer'
164
+import DoubleCheck from '@/xt_pages/dialysis/details/doubleCheck'
165
+import DialysisMonitoring from '@/xt_pages/dialysis/details/dialysisMonitoring'
166
+import DialysisOff from '@/xt_pages/dialysis/details/dialysisOff'
167
+import AssessmentAfter from '@/xt_pages/dialysis/details/assessmentAfter'
168
+import TreatmentOf from '@/xt_pages/dialysis/details/treatmentOf'
169
+import OperationStaff from '@/xt_pages/dialysis/details/operationStaff'
170
+import {
171
+  getDialysisScheduleDetail,
172
+  getLongAdvice,
173
+  getDialysisRecordInitData,
174
+  getDialysisSchedules
175
+} from '@/api/dialysis_record'
176
+import { parseTime } from '@/utils'
177
+import BreadCrumb from '@/xt_pages/components/bread-crumb'
178
+
179
+export default {
180
+  name: 'index',
181
+  components: {
182
+    NavIgation,
183
+    BasicInfor,
184
+    DialysisPrescription,
185
+    PastData,
186
+    AcceptsAssessment,
187
+    AssessmentBefore,
188
+    StatOrder,
189
+    DialysisComputer,
190
+    DoubleCheck,
191
+    DialysisMonitoring,
192
+    DialysisOff,
193
+    AssessmentAfter,
194
+    TreatmentOf,
195
+    OperationStaff,
196
+    BreadCrumb
197
+  },
198
+  props:{
199
+    record_date:String,
200
+    patientid:Number,
201
+    dialysisShow:Boolean
202
+  },
203
+  data() {
204
+    return {
205
+      crumbs: [
206
+        { path: false, name: '透析管理' },
207
+        { path: false, name: '透析记录' },
208
+        { path: false, name: '透析单' }
209
+      ],
210
+      dialogFormVisible: false,
211
+      orders: false,
212
+      loading: false,
213
+      patient_id: 0,
214
+      date: 0,
215
+
216
+      longAdvices: [],
217
+      waitUploadAdvices: [],
218
+      is_open: 0,
219
+      targetAdvices: [],
220
+
221
+      patient: { id: 0 }, // 患者信息
222
+      schedual: { id: 0 }, // 患者排班信息
223
+      prescription: { id: 0 }, // 透析处方
224
+      solution: { id: 0 }, // 透析方案
225
+      system_prescribe: { id: 0 },
226
+      receiver_treatment_access: { id: 0 }, // 接诊评估
227
+      predialysis_evaluation: { id: 0 }, // 透前评估
228
+      doctor_advices: [], // 临时医嘱
229
+      double_check: { id: 0 }, // 双人核对
230
+      assessment_after_dislysis: { id: 0 }, // 透后评估
231
+      treatment_summary: { id: 0 }, // 治疗小结
232
+      monitor_records: [], // 透析监测
233
+      dialysis_order: { id: 0 }, // 透析记录
234
+      admin_users: [], // 系统用户列表
235
+      devices: [], // 设备
236
+      device_numbers: [], // 床位号
237
+
238
+      admin_user_map: {}, // {user_id: admin_user object}
239
+      device_map: {}, // {device_id: device}
240
+      device_number_map: {}, // {device_number_id: device_number}
241
+
242
+      niprocart_info: [],
243
+      jms_info: [],
244
+      fistula_needle_set_info: [],
245
+      fistula_needle_set_16_info: [],
246
+      hemoperfusion_info: [],
247
+      dialyser_sterilised_info: [],
248
+      filtryzer_info: [],
249
+      dialyzers_info: [],
250
+      injector_info: [],
251
+      bloodlines_info: [],
252
+      tubingHemodialysis_info: [],
253
+      safe_package_info: [],
254
+      aliquid_info: [],
255
+      config: {},
256
+
257
+      his_is_open:0,
258
+
259
+      lastPredialysisEvaluation: { id: 0 },
260
+      lastMonitorRecord: { id: 0 },
261
+      lastAssessmentAfterDislysis: { id: 0 },
262
+      lastDryWeightDislysis: { id: 0 },
263
+      lastAssessment:{id:0},
264
+      headNurses: [],
265
+      lastDialysisPrescribe: { id: 0 },
266
+      //
267
+      activeName: 'first',
268
+      selected_date: new Date(),
269
+      // search_input 和 search_keyword,使输入关键字时不会经常刷新 filtedSchedules
270
+      search_keyword: '', // 确定用于搜索的关键字
271
+      search_input: '', // 输入中的关键字
272
+      patient_state: [
273
+        { value: 0, label: '全部患者' },
274
+        { value: 1, label: '已签到' },
275
+        { value: 2, label: '未签到' },
276
+        { value: 3, label: '已上机' },
277
+        { value: 4, label: '已下机' }
278
+      ],
279
+      patientStateVal: 0,
280
+      treat_state: [
281
+        { value: 0, label: '全部治疗' },
282
+        { value: 1, label: '待开处方' },
283
+        { value: 2, label: '待开小结' },
284
+        { value: 3, label: '待医嘱核对' },
285
+      ],
286
+      treatStateVal: 0,
287
+      schedule_options: [
288
+        { value: 0, label: '全部班' },
289
+        { value: 1, label: '上午' },
290
+        { value: 2, label: '下午' },
291
+        { value: 3, label: '晚上' }
292
+      ],
293
+      scheduleStateVal: 0,
294
+      zone_options: [
295
+        { id: 0, text: '全部分区' }
296
+      ],
297
+      zoneVal: 0,
298
+      tableData: [],
299
+      tableData1: [],
300
+      arr: [],
301
+      newName: '',
302
+      newTime: '',
303
+      scheudle_mode:"",
304
+
305
+
306
+      showView:false,
307
+      curPatient:{},
308
+
309
+      queueConfig:{},
310
+      stockType:[],
311
+      preparestock:[],
312
+      dialysisShow:false
313
+    }
314
+  },
315
+  created() {
316
+    var patient_id = this.patientid
317
+    var date = this.record_date
318
+    this.patient_id = patient_id
319
+    this.date = date
320
+    var ymd = parseTime(new Date(), '{y}-{m}-{d}')
321
+    getDialysisSchedules(ymd).then(rs => {
322
+      var resp = rs.data
323
+      if (resp.state == 1) {
324
+        var schedules = resp.data.schedules
325
+        let arr = []
326
+        schedules.map(item => {
327
+          if(item.patient_id == this.patient_id){
328
+            arr.push(item.patient_id)
329
+          }
330
+        })
331
+        if(arr.length > 0){
332
+          this.dialysisShow = true
333
+        }else{
334
+          this.dialysisShow = false
335
+        }
336
+        console.log('this.dialysisShowthis.dialysisShowthis.dialysisShow',this.dialysisShow)
337
+      } else {
338
+        this.$message.error(resp.msg)
339
+      }
340
+    })
341
+
342
+    
343
+
344
+  },
345
+  mounted() {
346
+    if(this.dialysisShow == true){
347
+      
348
+      this.getScheduleDetail()
349
+      this.getLongAdvice()
350
+    }
351
+    
352
+  },
353
+  watch:{
354
+        patientid:{
355
+            handler(newVal){
356
+              var ymd = parseTime(new Date(), '{y}-{m}-{d}')
357
+              getDialysisSchedules(ymd).then(rs => {
358
+                var resp = rs.data
359
+                if (resp.state == 1) {
360
+                  var schedules = resp.data.schedules
361
+                  let arr = []
362
+                  schedules.map(item => {
363
+                    if(item.patient_id == this.patient_id){
364
+                      arr.push(item.patient_id)
365
+                    }
366
+                  })
367
+                  if(arr.length > 0){
368
+                    this.dialysisShow = true
369
+                  }else{
370
+                    this.dialysisShow = false
371
+                  }
372
+                  console.log('this.dialysisShowthis.dialysisShowthis.dialysisShow',this.dialysisShow)
373
+                } else {
374
+                  this.$message.error(resp.msg)
375
+                }
376
+              })
377
+              console.log('执行执行执行执行执行执行',this.dialysisShow)
378
+              if(this.dialysisShow == true){
379
+                console.log('执行')
380
+                this.patient_id = newVal
381
+                this.getScheduleDetail()
382
+                this.getLongAdvice()
383
+              }
384
+            },
385
+            deep:true
386
+        },
387
+  },
388
+  computed: {
389
+    websocket() {
390
+      return this.$store.state.user.websocket;
391
+    },
392
+    steps: function() {
393
+      var steps = [
394
+        { title: '透析处方', finish: false },
395
+        { title: '接诊评估', finish: false },
396
+        { title: '透前评估', finish: false },
397
+        { title: '临时医嘱', finish: false },
398
+        { title: '双人核对', finish: false },
399
+        { title: '透析上机', finish: false },
400
+        { title: '透析监测', finish: false },
401
+        { title: '透析下机', finish: false },
402
+        { title: '透后评估', finish: false },
403
+        { title: '治疗小结', finish: false }
404
+      ]
405
+
406
+      steps[0].finish = this.prescription.id && this.prescription.creater > 0
407
+      steps[1].finish = this.receiver_treatment_access.id > 0
408
+      steps[2].finish =
409
+        this.predialysis_evaluation.id > 0 &&
410
+        this.predialysis_evaluation.creater > 0
411
+      steps[3].finish = this.doctor_advices.length > 0
412
+      steps[5].finish = this.dialysis_order.id > 0
413
+      steps[7].finish =
414
+        this.dialysis_order.id > 0 && this.dialysis_order.stage == 2
415
+
416
+      steps[4].finish =
417
+        this.double_check.id > 0 &&
418
+        this.double_check.creater > 0 &&
419
+        this.double_check.modifier > 0
420
+      steps[6].finish = this.monitor_records.length > 0
421
+      steps[8].finish =
422
+        this.assessment_after_dislysis.id > 0 &&
423
+        this.assessment_after_dislysis.creater > 0
424
+      steps[9].finish = this.treatment_summary.id > 0
425
+
426
+      return steps
427
+    },
428
+    filtedSchedules: function() {
429
+      var search_keyword = this.search_keyword
430
+      if (search_keyword.length > 0) {
431
+        var schedules = []
432
+        for (let o_i = 0; o_i < this.zone_schedules.length; o_i++) {
433
+          const scheduleInfo = this.zone_schedules[o_i]
434
+          var originSchedules = scheduleInfo.schedules
435
+          if (originSchedules.length == 0) {
436
+            continue
437
+          }
438
+          var filtedSchedules = []
439
+          for (let s_i = 0; s_i < originSchedules.length; s_i++) {
440
+            const schedule = originSchedules[s_i]
441
+            if (schedule.patient.name.indexOf(search_keyword) != -1) {
442
+              filtedSchedules.push(schedule)
443
+              // break
444
+            }
445
+          }
446
+          if (filtedSchedules.length > 0) {
447
+            schedules.push({ zone_id: scheduleInfo.zone_id, zone_name: scheduleInfo.zone_name, schedules: filtedSchedules })
448
+          }
449
+        }
450
+        return schedules
451
+      }
452
+
453
+      // var zone_selected = this.zoneVal
454
+      // var timetype_selected = this.scheduleStateVal
455
+      // if ((zone_selected == 0 && timetype_selected == 0) || this.zone_options.length <= 1) {
456
+      //   var schedules = []
457
+      //   for (let index = 0; index < this.zone_schedules.length; index++) {
458
+      //     const scheduleInfo = this.zone_schedules[index]
459
+      //     if (scheduleInfo.schedules.length != 0) {
460
+      //       schedules.push(scheduleInfo)
461
+      //     }
462
+      //   }
463
+      //   return schedules
464
+      // }
465
+
466
+      // var schedules = []
467
+      // for (let o_i = 0; o_i < this.zone_schedules.length; o_i++) {
468
+      //   const scheduleInfo = this.zone_schedules[o_i]
469
+      //   if (zone_selected == scheduleInfo.zone_id && timetype_selected == 0) {
470
+      //     if (scheduleInfo.schedules.length == 0) {
471
+      //       return []
472
+      //     } else {
473
+      //       return [scheduleInfo]
474
+      //     }
475
+      //   }
476
+      //   var originSchedules = scheduleInfo.schedules
477
+      //   if (originSchedules.length == 0) {
478
+      //     continue
479
+      //   }
480
+      //   var filtedSchedules = []
481
+      //   for (let s_i = 0; s_i < originSchedules.length; s_i++) {
482
+      //     const schedule = originSchedules[s_i]
483
+      //     if (zone_selected != 0) {
484
+      //       if (zone_selected == schedule.device_number.zone.id) {
485
+      //         if (timetype_selected == 0 || schedule.schedule_type == timetype_selected) {
486
+      //           filtedSchedules.push(schedule)
487
+      //         }
488
+      //       }
489
+      //     } else {
490
+      //       if (timetype_selected == 0 || schedule.schedule_type == timetype_selected) {
491
+      //         filtedSchedules.push(schedule)
492
+      //       }
493
+      //     }
494
+      //   }
495
+      //   if (filtedSchedules.length > 0) {
496
+      //     schedules.push({ zone_id: scheduleInfo.zone_id, zone_name: scheduleInfo.zone_name, schedules: filtedSchedules })
497
+      //   }
498
+      // }
499
+
500
+      // return schedules
501
+    }
502
+  },
503
+  methods: {
504
+    adviceFunc() {
505
+      this.getScheduleDetail()
506
+    },
507
+    getLongAdvice() {
508
+      const params = {
509
+        patient_id: this.patient_id
510
+      }
511
+      getLongAdvice(params).then(rs => {
512
+        var resp = rs.data
513
+        if (resp.state == 1) {
514
+          var status = parseInt(resp.data.status)
515
+
516
+          switch (status) {
517
+            case 2:
518
+              var totalAdvice = resp.data.advices
519
+              var longAdvicesTwo = resp.data.advices_two
520
+              var waitUploadAdvices = []
521
+              for (let i = 0; i < totalAdvice.length; i++) {
522
+                totalAdvice[i]['isCheck'] = 1
523
+              }
524
+
525
+              for (let i = 0; i < totalAdvice.length; i++) {
526
+                for (let a = 0; a < longAdvicesTwo.length; a++) {
527
+                  if (
528
+                    totalAdvice[i].template_id ==
529
+                      longAdvicesTwo[a].template_id &&
530
+                    totalAdvice[i].frequency_type ==
531
+                      longAdvicesTwo[a].frequency_type
532
+                  ) {
533
+                    totalAdvice[i]['isCheck'] = 0
534
+                  }
535
+                }
536
+              }
537
+
538
+              for (let i = 0; i < totalAdvice.length; i++) {
539
+                if (totalAdvice[i].isCheck == 1) {
540
+                  waitUploadAdvices.push(totalAdvice[i])
541
+                }
542
+              }
543
+
544
+              this.is_open = resp.data.is_open_remind
545
+              if(this.his_is_open == 1){
546
+                this.is_open = 0
547
+              }
548
+              this.longAdvices = totalAdvice
549
+              this.waitUploadAdvices = waitUploadAdvices
550
+              break
551
+          }
552
+        } else {
553
+          this.$message.error(resp.msg)
554
+        }
555
+      })
556
+    },
557
+    assessmentAfterDislysisFunc: function(val) {
558
+      for (var index in val) {
559
+        this.$set(this.assessment_after_dislysis, index, val[index])
560
+      }
561
+    },
562
+    didDelMonitor(record_id) {
563
+      var mrl = this.monitor_records.length
564
+      for (let index = 0; index < mrl; index++) {
565
+        if (this.monitor_records[index].id == record_id) {
566
+          this.monitor_records.splice(index, 1)
567
+          break
568
+        }
569
+      }
570
+    },
571
+    getScheduleDetail: function() {
572
+      
573
+      this.loading = true
574
+    //   var dateStr = parseTime(this.date, '{y}-{m}-{d}')
575
+      // if(this.$route.query.showView == true){
576
+      //   this.loading = false
577
+      //   return
578
+      // }
579
+        console.log('this.patient_id',this.patient_id)
580
+        console.log('this.date',this.date)
581
+      this.doctor_advices = []
582
+      getDialysisScheduleDetail(this.patient_id, this.date).then(rs => {
583
+
584
+        var resp = rs.data
585
+        if (resp.state == 1) {
586
+          var patient = resp.data.patient // 患者信息
587
+          var schedual = resp.data.schedual // 患者排班信息
588
+         
589
+          var prescription = resp.data.prescription // 透析处方
590
+          if (prescription != null) {
591
+            if (prescription.body_fluid == -2) {
592
+              prescription.body_fluid = 0
593
+            }
594
+          }
595
+
596
+          var solution = resp.data.solution // 透析方案
597
+         
598
+          var receiver_treatment_access = resp.data.receiver_treatment_access // 接诊评估
599
+
600
+          var predialysis_evaluation = resp.data.predialysis_evaluation // 透前评估
601
+           console.log("透器评估",predialysis_evaluation)
602
+          if (predialysis_evaluation != null) {
603
+            if (predialysis_evaluation.blood_access_part_id == -2) {
604
+              predialysis_evaluation.blood_access_part_id = 0
605
+            }
606
+          }
607
+          var doctor_advices = resp.data.doctor_advices // 临时医嘱
608
+
609
+          var double_check = resp.data.double_check // 双人核对
610
+          var assessment_after_dislysis = resp.data.assessment_after_dislysis // 透后评估
611
+
612
+          var treatment_summary = resp.data.treatment_summary // 治疗小结
613
+          var monitor_records = resp.data.monitor_records // 透析监测
614
+          var dialysis_order = resp.data.dialysis_order // 透析记录
615
+
616
+          var niprocart_info = resp.data.niprocart_info
617
+          var jms_info = resp.data.jms_info
618
+          var fistula_needle_set_info = resp.data.fistula_needle_set_info
619
+          var fistula_needle_set_16_info = resp.data.fistula_needle_set_16_info
620
+          var hemoperfusion_info = resp.data.hemoperfusion_info
621
+          var dialyser_sterilised_info = resp.data.dialyser_sterilised_info
622
+          var filtryzer_info = resp.data.filtryzer_info
623
+          var dialyzers_info = resp.data.dialyzers_info
624
+          var injector_info = resp.data.injector_info
625
+          var bloodlines_info = resp.data.bloodlines_info
626
+          var tubingHemodialysis_info = resp.data.tubingHemodialysis_info
627
+          var safe_package_info = resp.data.safe_package_info
628
+          var aliquid_info = resp.data.aliquid_info
629
+
630
+          var lastPredialysisEvaluation = resp.data.lastPredialysisEvaluation
631
+
632
+          if (lastPredialysisEvaluation != null) {
633
+            if (lastPredialysisEvaluation.blood_access_part_id == -2) {
634
+              lastPredialysisEvaluation.blood_access_part_id = 0
635
+            }
636
+          }
637
+          var lastMonitorRecord = resp.data.lastMonitorRecord
638
+          var lastAssessmentAfterDislysis = resp.data.lastAssessmentAfterDislysis
639
+          var lastDialysisPrescribe = resp.data.lastDialysisPrescribe
640
+          var lastDryWeightDislysis = resp.data.lastDryWeightDislysis
641
+
642
+          var system_prescribe = resp.data.system_prescribe
643
+
644
+          var lastAssessment =  resp.data.lastAssessment
645
+          console.log("最后一次血管通路",lastAssessment)
646
+          this.$refs.nav.setLastRecord(
647
+            lastPredialysisEvaluation,
648
+            lastMonitorRecord,
649
+            lastAssessmentAfterDislysis,
650
+            lastDialysisPrescribe,
651
+            lastDryWeightDislysis,
652
+            schedual,
653
+            system_prescribe,
654
+            lastAssessment,
655
+          )
656
+
657
+          var headNurses = resp.data.headNurse
658
+
659
+          var config = resp.data.config
660
+          this.lastPredialysisEvaluation = lastPredialysisEvaluation
661
+          this.lastMonitorRecord = lastMonitorRecord
662
+          this.lastAssessmentAfterDislysis = lastAssessmentAfterDislysis
663
+          this.lastDialysisPrescribe = lastDialysisPrescribe
664
+          this.lastDryWeightDislysis = lastDryWeightDislysis
665
+          this.lastAssessment = lastAssessment
666
+          this.headNurses = headNurses
667
+          this.system_prescribe = system_prescribe
668
+
669
+
670
+
671
+          this.niprocart_info = []
672
+          this.jms_info = []
673
+          this.fistula_needle_set_info = []
674
+          this.fistula_needle_set_16_info = []
675
+          this.hemoperfusion_info = []
676
+          this.dialyser_sterilised_info = []
677
+
678
+          this.filtryzer_info = []
679
+          this.dialyzers_info = []
680
+          this.injector_info = []
681
+
682
+          this.bloodlines_info = []
683
+          this.tubingHemodialysis_info = []
684
+          this.safe_package_info = []
685
+          this.aliquid_info = []
686
+
687
+
688
+
689
+
690
+
691
+          this.niprocart_info = niprocart_info
692
+          this.jms_info = jms_info
693
+          this.fistula_needle_set_info = fistula_needle_set_info
694
+          this.fistula_needle_set_16_info = fistula_needle_set_16_info
695
+          this.hemoperfusion_info = hemoperfusion_info
696
+          this.dialyser_sterilised_info = dialyser_sterilised_info
697
+          this.filtryzer_info = filtryzer_info
698
+          this.dialyzers_info = dialyzers_info
699
+          this.injector_info = injector_info
700
+          this.bloodlines_info = bloodlines_info
701
+          this.tubingHemodialysis_info = tubingHemodialysis_info
702
+          this.safe_package_info = safe_package_info
703
+          this.aliquid_info = aliquid_info
704
+          this.config = config
705
+
706
+          this.patient = patient
707
+          this.schedual = schedual == null ? { id: 0 } : schedual
708
+          this.prescription = prescription == null ? { id: 0 } : prescription
709
+          this.solution = solution == null ? { id: 0 } : solution
710
+          this.receiver_treatment_access =
711
+            receiver_treatment_access == null
712
+              ? { id: 0 }
713
+              : receiver_treatment_access
714
+          this.predialysis_evaluation =
715
+            predialysis_evaluation == null ? { id: 0 } : predialysis_evaluation
716
+          this.doctor_advices = doctor_advices == null ? [] : doctor_advices
717
+          this.double_check = double_check == null ? { id: 0 } : double_check
718
+          this.assessment_after_dislysis =
719
+            assessment_after_dislysis == null
720
+              ? { id: 0 }
721
+              : assessment_after_dislysis
722
+          this.treatment_summary =
723
+            treatment_summary == null ? { id: 0 } : treatment_summary
724
+          this.monitor_records = monitor_records == null ? [] : monitor_records
725
+          this.dialysis_order =
726
+            dialysis_order == null ? { id: 0 } : dialysis_order
727
+
728
+
729
+
730
+          this.admin_users = resp.data.doctors
731
+          this.devices = resp.data.devices
732
+          this.device_numbers = resp.data.device_numbers
733
+
734
+          var his_doctor_advices = resp.data.his_advices
735
+
736
+          this.his_is_open = resp.data.is_open_config.is_open
737
+          console.log(this.his_is_open)
738
+
739
+
740
+
741
+          var stockType =  resp.data.stockType
742
+          this.stockType = stockType
743
+          console.log("stockTYPW",stockType)
744
+
745
+          var prepare = resp.data.prepare
746
+          this.preparestock = prepare
747
+          console.log("prepare222222",prepare)
748
+
749
+          for (let i = 0; i <  this.doctor_advices.length; i++){
750
+            this.doctor_advices[i]['origin'] = 1
751
+          }
752
+
753
+          if (his_doctor_advices != null) {
754
+            for (let i = 0; i < his_doctor_advices.length; i++) {
755
+              his_doctor_advices[i]['origin'] = 2
756
+              his_doctor_advices[i]['way'] = 1
757
+              this.doctor_advices.push(his_doctor_advices[i])
758
+            }
759
+          }
760
+
761
+          const obj = {}
762
+          this.doctor_advices = this.doctor_advices.reduce((cur, next) => {
763
+            obj[next.id] ? '' : obj[next.id] = true && cur.push(next)
764
+            return cur
765
+          }, []) // 设置cur默认类型为数组,并且初始值为空的数组
766
+
767
+          console.log(this.doctor_advices)
768
+
769
+
770
+          var device_map = {}
771
+          for (let index = 0; index < this.devices.length; index++) {
772
+            const device = this.devices[index]
773
+            device_map[device.id] = device
774
+          }
775
+          this.device_map = device_map
776
+
777
+          var admin_map = {}
778
+          for (let index = 0; index < this.admin_users.length; index++) {
779
+            const admin = this.admin_users[index]
780
+            admin_map[admin.id] = admin
781
+          }
782
+          this.admin_user_map = admin_map
783
+
784
+          var device_number_map = {}
785
+          for (let index = 0; index < this.device_numbers.length; index++) {
786
+            const device_number = this.device_numbers[index]
787
+            device_number_map[device_number.id] = device_number
788
+          }
789
+          this.device_number_map = device_number_map
790
+        } else {
791
+         // this.$message.error(resp.msg)
792
+          console.log("报错提示")
793
+          this.$message.error("该患者今日未排班,无法使用此模块,请先排班!")
794
+        }
795
+
796
+        if (this.lastDialysisPrescribe != null) {
797
+          delete this.lastDialysisPrescribe.target_ultrafiltration
798
+        }
799
+        if (this.solution != null) {
800
+          delete this.solution.target_ultrafiltration
801
+        }
802
+        if(this.predialysis_evaluation.id > 0){
803
+          this.newTime = parseTime(this.predialysis_evaluation.created_time, '{h}:{i}')
804
+        }
805
+
806
+        this.loading = false
807
+      })
808
+    },
809
+    printOrder() {
810
+      var xtdate = parseTime(this.date, '{y}-{m}-{d}')
811
+      this.$router.push(
812
+        '/dialysis/print?xtdate=' + xtdate + '&xtno=' + this.patient.dialysis_no
813
+      )
814
+    },
815
+    processedDialysisSchedules: function(schedules, zone_options) {
816
+      var zoneMap = {}
817
+      var scheduleMap = {}
818
+      for (let z_i = 0; z_i < zone_options.length; z_i++) {
819
+        const zone = zone_options[z_i]
820
+        if (zone.id == 0) {
821
+          continue
822
+        }
823
+        scheduleMap[zone.id] = []
824
+      }
825
+      for (let index = 0; index < schedules.length; index++) {
826
+        const schedule = schedules[index]
827
+        scheduleMap[schedule.device_number.zone.id].push(schedule)
828
+      }
829
+      var zone_schedules = []
830
+      for (let index = 0; index < zone_options.length; index++) {
831
+        const zone = zone_options[index]
832
+        if (zone.id == 0) {
833
+          continue
834
+        }
835
+        var schedules = scheduleMap[zone.id]
836
+        zone_schedules.push({ zone_id: zone.id, zone_name: zone.text, schedules: schedules })
837
+      }
838
+      return zone_schedules
839
+    },
840
+    getTime(date){
841
+      date = new Date(date * 1000)
842
+      var Y = date.getFullYear() + '-';
843
+      var M = (date.getMonth()+1 < 10 ? '0'+(date.getMonth()+1) : date.getMonth()+1);
844
+      var D = (date.getDate() < 10 ? '0'+date.getDate() : date.getDate());
845
+      var h = (date.getHours() < 10 ? '0'+date.getHours() : date.getHours());
846
+      var m = (date.getMinutes() < 10 ? '0'+date.getMinutes() : date.getMinutes());
847
+      var s = (date.getSeconds() < 10 ? '0'+date.getSeconds() : date.getSeconds());
848
+
849
+      let strDate = h  + ':' + m;
850
+      return strDate;
851
+    },
852
+    getDates(time){
853
+      return moment(time * 1000).format('HH:mm:ss')
854
+    }
855
+  }
856
+}
857
+</script>
858
+
859
+<style style="stylesheet/scss" lang="scss" scoped>
860
+.details-bg {
861
+  background: #fff;
862
+  margin: 0 15px;
863
+}
864
+.printForm {
865
+  .title {
866
+    font-size: 30px;
867
+    font-weight: 500;
868
+    text-align: center;
869
+    line-height: 60px;
870
+  }
871
+  .info {
872
+    ul {
873
+      display: -webkit-box;
874
+      display: -moz-box;
875
+      display: -ms-flexbox;
876
+      display: -webkit-flex;
877
+      display: flex;
878
+      align-items: center;
879
+      -moz-box-sizing: border-box;
880
+      -webkit-box-sizing: border-box;
881
+      -o-box-sizing: border-box;
882
+      -ms-box-sizing: border-box;
883
+      box-sizing: border-box;
884
+      -webkit-justify-content: space-around;
885
+      -moz-justify-content: space-around;
886
+      -ms-justify-content: space-around;
887
+      -o-justify-content: space-around;
888
+      justify-content: space-around;
889
+      li {
890
+        display: flex;
891
+        box-sizing: border-box;
892
+        justify-content: space-around;
893
+        .name {
894
+        }
895
+        .InputBox {
896
+          padding: 0;
897
+          border: none;
898
+          border-bottom: 1px #e5e5e5 solid;
899
+          width: 60px;
900
+          outline: none;
901
+        }
902
+      }
903
+    }
904
+  }
905
+  .printTable {
906
+    tr {
907
+      padding: 2px;
908
+      th {
909
+        padding: 6px 4px;
910
+      }
911
+      td {
912
+        padding: 6px 4px;
913
+      }
914
+    }
915
+  }
916
+}
917
+.loadingBox{
918
+  display: flex;
919
+  .patientBox{
920
+    background: #fff;
921
+  }
922
+  .tip1{
923
+    background: #4fc7cb;
924
+    border-radius: 5px;
925
+    text-align: center;
926
+    font-size: 12px;
927
+    display: inline-block;
928
+    width: 60px;
929
+    color: #fff;
930
+  }
931
+  .tip2{
932
+    background: #ee8556;
933
+    border-radius: 5px;
934
+    text-align: center;
935
+    font-size: 12px;
936
+    display: inline-block;
937
+    width: 60px;
938
+    color: #fff;
939
+  }
940
+  .tip3{
941
+    background: #409eff;
942
+    border-radius: 5px;
943
+    text-align: center;
944
+    font-size: 12px;
945
+    display: inline-block;
946
+    width: 60px;
947
+    color: #fff;
948
+  }
949
+  .tip4{
950
+    background: #a8b3ba;
951
+    border-radius: 5px;
952
+    text-align: center;
953
+    font-size: 12px;
954
+    display: inline-block;
955
+    width: 60px;
956
+    color: #fff;
957
+  }
958
+  .tip5{
959
+    background: #7bce91;
960
+    border-radius: 5px;
961
+    text-align: center;
962
+    font-size: 12px;
963
+    display: inline-block;
964
+    width: 60px;
965
+    color: #fff;
966
+  }
967
+}
968
+</style>
969
+
970
+<style lang="scss">
971
+.loadingBox{
972
+  .el-loading-spinner{
973
+    top:10%;
974
+  }
975
+  .el-button--small, .el-button--small.is-round{
976
+    padding:9px 10px;
977
+  }
978
+  .el-date-editor{
979
+    .el-input__inner{
980
+      padding-right:0px;
981
+    }
982
+  }
983
+  .el-table td, .el-table th{
984
+    text-align: center;
985
+  }
986
+  .el-table .cell{
987
+    padding: 0;
988
+  }
989
+}
990
+</style>

+ 15 - 3
src/xt_pages/outpatientDoctorStation/components/inquiriesDetail.vue Целия файл

@@ -285,8 +285,8 @@
285 285
                 let obj = {
286 286
                   id: prescription.project[b].id,
287 287
                   project_id: prescription.project[b].project.id,
288
-                  project_name: prescription.project[b].project.project_name,
289
-                  statistical_classification: prescription.project[b].project.statistical_classification,
288
+                  // project_name: prescription.project[b].project.project_name,
289
+                  // statistical_classification: prescription.project[b].project.statistical_classification,
290 290
                   single_dose: prescription.project[b].single_dose,
291 291
                   delivery_way: prescription.project[b].delivery_way,
292 292
                   execution_frequency: prescription.project[b].execution_frequency,
@@ -294,8 +294,20 @@
294 294
                   total: prescription.project[b].count.toString(),
295 295
                   price: prescription.project[b].price,
296 296
                   remark: prescription.project[b].remark,
297
-                  medical_code: prescription.project[b].project.medical_code,
297
+                  // medical_code: prescription.project[b].project.medical_code,
298 298
                   unit:prescription.project[b].project.unit,
299
+                  type:prescription.project[b].type,
300
+
301
+                }
302
+                if(prescription.project[b].type == 2){
303
+                  obj['statistical_classification'] =  prescription.project[b].project.statistical_classification
304
+                  obj['medical_code'] =  prescription.project[b].project.medical_code
305
+                  obj['project_name'] =  prescription.project[b].project.project_name
306
+
307
+                }else if(prescription.project[b].type == 3){
308
+                  obj['statistical_classification'] = ""
309
+                  obj['medical_code'] =  prescription.project[b].good_info.medical_insurance_number
310
+                  obj['project_name'] =  prescription.project[b].good_info.good_name
299 311
                 }
300 312
                 tempProject.push(obj)
301 313
               }

+ 1 - 1
src/xt_pages/outpatientDoctorStation/components/newPrescriptionTable.vue Целия файл

@@ -63,7 +63,7 @@
63 63
       </el-table-column>
64 64
       <el-table-column align="center" prop="statistical_classification" width="100" label="组">
65 65
         <template slot-scope="scope">
66
-          <div>{{getGroup(scope.row.statistical_classification)}}</div>
66
+          <div>{{scope.row.type == 2?getGroup(scope.row.statistical_classification):"耗材"}}</div>
67 67
         </template>
68 68
       </el-table-column>
69 69
       <el-table-column align="center" prop="single_dose" width="100" label="单次用量">

+ 22 - 7
src/xt_pages/outpatientDoctorStation/components/nextOrLastPrescription.vue Целия файл

@@ -81,11 +81,11 @@
81 81
             <el-table-column align="center" type="index" width="60" label="序号"></el-table-column>
82 82
             <el-table-column align="center" prop="project_name" width="160" label="名称">
83 83
               <template slot-scope="scope">
84
-                <span>{{ scope.row.project.project_name }}</span>
84
+                <span>{{ scope.row.type == 2 ?scope.row.project.project_name:scope.row.good_info.good_name}}</span>
85 85
               </template>
86 86
             </el-table-column>
87 87
             <el-table-column align="center" prop="statistical_classification" width="100" label="组">
88
-              <template slot-scope="scope">{{getGroup(scope.row.statistical_classification)}}</template>
88
+              <template slot-scope="scope">{{ scope.row.type == 2 ?getGroup(scope.row.statistical_classification):"耗材"}}</template>
89 89
             </el-table-column>
90 90
             <el-table-column align="center" prop="single_dose" width="90" label="单次用量">
91 91
               <template slot-scope="scope">
@@ -317,7 +317,8 @@
317 317
                 single_dose_unit:prescription.doctor_advice[b].single_dose_unit,
318 318
                 prescribing_number_unit:prescription.doctor_advice[b].prescribing_number_unit,
319 319
                 medical_insurance_number:prescription.doctor_advice[b].med_list_codg,
320
-                id:prescription.doctor_advice[b].drug_id
320
+                id:prescription.doctor_advice[b].drug_id,
321
+                drug:prescription.doctor_advice[b].drug,
321 322
               };
322 323
               tempAdvice.push(obj)
323 324
 
@@ -328,8 +329,8 @@
328 329
               let obj = {
329 330
                 id: 0,
330 331
                 project_id: prescription.project[b].project_id,
331
-                project_name: prescription.project[b].project.project_name,
332
-                statistical_classification: prescription.project[b].project.statistical_classification,
332
+                // project_name: prescription.project[b].project.project_name,
333
+                // statistical_classification: prescription.project[b].project.statistical_classification,
333 334
                 single_dose: prescription.project[b].single_dose,
334 335
                 delivery_way: prescription.project[b].delivery_way,
335 336
                 execution_frequency: prescription.project[b].execution_frequency,
@@ -337,8 +338,23 @@
337 338
                 total:prescription.project[b].count.toString(),
338 339
                 price:prescription.project[b].price,
339 340
                 remark:prescription.project[b].remark,
340
-                medical_code:prescription.project[b].project.medical_code,
341
+                unit: prescription.project[b].unit,
342
+                type: prescription.project[b].type
343
+
344
+                // medical_code:prescription.project[b].project.medical_code,
341 345
               };
346
+
347
+              if(prescription.project[b].type == 2){
348
+                obj['statistical_classification'] =  prescription.project[b].project.statistical_classification
349
+                obj['medical_code'] =  prescription.project[b].project.medical_code
350
+                obj['project_name'] =  prescription.project[b].project.project_name
351
+
352
+              }else if(prescription.project[b].type == 3){
353
+                obj['statistical_classification'] = ""
354
+                obj['medical_code'] =  prescription.project[b].good_info.medical_insurance_number
355
+                obj['project_name'] =  prescription.project[b].good_info.good_name
356
+              }
357
+
342 358
               tempProject.push(obj)
343 359
             }
344 360
             let obj = {
@@ -353,7 +369,6 @@
353 369
           }
354 370
         }
355 371
 
356
-        console.log(this.srcPrescriptions);
357 372
 
358 373
         if(this.srcPrescriptions.length == 1){
359 374
           if(this.srcPrescriptions[0].advices.length == 0 && this.srcPrescriptions[0].project.length == 0){

+ 113 - 30
src/xt_pages/outpatientDoctorStation/components/prescriptionTable.vue Целия файл

@@ -7,11 +7,15 @@
7 7
         <template slot-scope="scope"><span :title="scope.row.drug_name">{{ scope.row.drug_name }}</span></template>
8 8
       </el-table-column>
9 9
 
10
-      <el-table-column align="center" prop="single_dose" width="90" label="单次用量">
10
+      <el-table-column align="center" prop="single_dose" width="120" label="单次用量">
11 11
         <template slot-scope="scope">
12 12
           <div style="display:flex;align-items:center;">
13
-            <el-input v-model="scope.row.single_dose" @input="getSingleDose(scope)" style="width:65%;"></el-input>
14
-            <div>{{scope.row.single_dose_unit}}</div>
13
+            <el-input v-model="scope.row.single_dose" @input="getAllChange(scope)" style="width:50%;"></el-input>
14
+            <!-- <div>{{scope.row.single_dose_unit}}</div> -->
15
+            <el-select v-model="scope.row.single_dose_unit" placeholder="请选择" style="width:50%;" @change="getAllChange(scope)">
16
+              <el-option :label="scope.row.drug.min_unit" :value="scope.row.drug.min_unit"></el-option>
17
+              <el-option :label="scope.row.drug.dose_unit" :value="scope.row.drug.dose_unit"></el-option>
18
+            </el-select>
15 19
           </div>
16 20
         </template>
17 21
       </el-table-column>
@@ -29,7 +33,7 @@
29 33
       </el-table-column>
30 34
       <el-table-column align="center" prop="execution_frequency" width="100" label="频率">
31 35
         <template slot-scope="scope">
32
-          <el-select v-model="scope.row.execution_frequency" placehold er="请选择">
36
+          <el-select v-model="scope.row.execution_frequency" placeholder="请选择" @change="getAllChange(scope)">
33 37
             <el-option
34 38
               v-for="item,index in efs"
35 39
               :key="index"
@@ -44,16 +48,20 @@
44 48
       <el-table-column align="center" prop="day" width="70" label="天数">
45 49
         <template slot-scope="scope">
46 50
           <div style="display:flex;align-items:center;">
47
-          <el-input v-model="scope.row.day" @input="getDay(scope)" placeholder=""></el-input>{{'天'}}
51
+          <el-input v-model="scope.row.day" @input="getAllChange(scope)" placeholder=""></el-input>{{'天'}}
48 52
           </div>
49 53
         </template>
50 54
       </el-table-column>
51 55
 
52
-      <el-table-column align="center" prop="prescribing_number" width="80" label="总量">
56
+      <el-table-column align="center" prop="prescribing_number" width="120" label="总量">
53 57
         <template slot-scope="scope">
54 58
           <div style="display:flex;align-items:center;">
55
-            <el-input v-model="scope.row.prescribing_number" style="width:60%" placeholder=""></el-input>
56
-            <div> {{scope.row.prescribing_number_unit}}</div>
59
+            <el-input v-model="scope.row.prescribing_number" @input="changePrescribingNumber(scope)" style="width:50%" placeholder=""></el-input>
60
+            <!-- <div> {{scope.row.prescribing_number_unit}}</div> -->
61
+            <el-select v-model="scope.row.prescribing_number_unit" placeholder="请选择" style="width:50%;" @change="getAllChange(scope)">
62
+              <el-option :label="scope.row.drug.min_unit" :value="scope.row.drug.min_unit"></el-option>
63
+              <el-option :label="scope.row.drug.max_unit" :value="scope.row.drug.max_unit"></el-option>
64
+            </el-select>
57 65
           </div>
58 66
         </template>
59 67
       </el-table-column>
@@ -85,7 +93,7 @@
85 93
         <template slot-scope="scope"><span :title="scope.row.project_name">{{ scope.row.project_name }}</span></template>
86 94
       </el-table-column>
87 95
       <el-table-column align="center" prop="statistical_classification" width="100" label="组">
88
-        <template slot-scope="scope">{{getGroup(scope.row.statistical_classification)}}</template>
96
+        <template slot-scope="scope">{{scope.row.type == 2?getGroup(scope.row.statistical_classification):"耗材"}}</template>
89 97
       </el-table-column>
90 98
       <el-table-column align="center" prop="single_dose" width="80" label="单次用量">
91 99
         <template slot-scope="scope">
@@ -208,7 +216,7 @@
208 216
         input: 1,
209 217
       }
210 218
     },
211
-    
219
+
212 220
    methods:{
213 221
      createFilter(queryString) {
214 222
        return (restaurant) => {
@@ -381,49 +389,124 @@
381 389
           .catch(() => {});
382 390
 
383 391
       },
384
-      getSingleDose(scope){
385
-        this.prescription.advices[scope.$index].prescribing_number = scope.row.single_dose * scope.row.day
392
+      getAllChange(scope){
393
+        if(scope.row.drug.min_unit == scope.row.single_dose_unit){
394
+          if(scope.row.prescribing_number_unit == scope.row.drug.min_unit){
395
+            console.log(1)
396
+            scope.row.prescribing_number = scope.row.single_dose * this.getNum(scope.row.execution_frequency) * scope.row.day
397
+          }else{
398
+            console.log(12)
399
+            scope.row.prescribing_number = Math.ceil((scope.row.single_dose * this.getNum(scope.row.execution_frequency)) * scope.row.day / scope.row.drug.min_number) 
400
+          }
401
+        }else{
402
+          if(scope.row.prescribing_number_unit == scope.row.drug.min_unit){
403
+            console.log(123)
404
+            scope.row.prescribing_number = Math.ceil((scope.row.single_dose * this.getNum(scope.row.execution_frequency) * scope.row.day) / scope.row.drug.dose) 
405
+          }else{
406
+            console.log(1234)
407
+            scope.row.prescribing_number = Math.ceil((scope.row.single_dose * this.getNum(scope.row.execution_frequency) * scope.row.day) / scope.row.drug.dose / scope.row.drug.min_number)
408
+          }
409
+        }
410
+        if(scope.row.prescribing_number == 0){
411
+          scope.row.prescribing_number = 1
412
+        }
413
+        if(scope.row.prescribing_number_unit == scope.row.drug.min_unit){
414
+          scope.row.retail_price = scope.row.drug.min_price * scope.row.prescribing_number
415
+          if(scope.row.prescribing_number > scope.row.drug.total){
416
+            this.$message.error(scope.row.drug_name + '库存不足')
417
+          }
418
+        }else{
419
+          if((parseInt(scope.row.prescribing_number) * scope.row.drug.min_number) > scope.row.drug.total){
420
+            this.$message.error(scope.row.drug_name + '库存不足')
421
+          }
422
+          scope.row.retail_price = scope.row.drug.retail_price * scope.row.prescribing_number
423
+        }
424
+        
386 425
       },
387
-      getDay(scope){
388
-        this.prescription.advices[scope.$index].prescribing_number = scope.row.single_dose * scope.row.day
426
+      changePrescribingNumber(scope){
427
+        if(scope.row.prescribing_number_unit == scope.row.drug.min_unit){
428
+          if(parseInt(scope.row.prescribing_number) > scope.row.drug.total){
429
+            this.$message.error(scope.row.drug_name + '库存不足')
430
+          }
431
+        }else{
432
+          if((parseInt(scope.row.prescribing_number) * scope.row.drug.min_number) > scope.row.drug.total){
433
+            this.$message.error(scope.row.drug_name + '库存不足')
434
+          }
435
+        }
389 436
       },
390 437
       getProjectSingleDose(scope){
391 438
         this.prescription.project[scope.$index].total = scope.row.single_dose * scope.row.number_days
439
+        if(this.prescription.project[scope.$index].total == 0){
440
+          this.prescription.project[scope.$index].total = 1
441
+        }
392 442
       },
393 443
       getProjectDay(scope){
394 444
         this.prescription.project[scope.$index].total = scope.row.single_dose * scope.row.number_days
445
+        if(this.prescription.project[scope.$index].total == 0){
446
+          this.prescription.project[scope.$index].total = 1
447
+        }
448
+        
449
+      },
450
+      getNum(execution_frequency){
451
+        let arr = [
452
+          {name:'立即执行',count:1},
453
+          {name:'透析时',count:1},
454
+          {name:'透析1h一次',count:1},
455
+          {name:'透析2h一次',count:1},
456
+          {name:'透析3h一次',count:1},
457
+          {name:'每日一次',count:1},
458
+          {name:'每日两次',count:2},
459
+          {name:'每日三次',count:1},
460
+          {name:'每晚一次',count:1},
461
+          {name:'每晚',count:1},
462
+          {name:'上机前',count:1},
463
+          {name:'下机前',count:1},
464
+          {name:'透析后立即',count:1},
465
+          {name:'持续使用',count:1},
466
+          {name:'临时开药',count:1},
467
+          {name:'临睡前',count:1},
468
+          {name:'隔日一次',count:1},
469
+          {name:'隔三日一次',count:1},
470
+          {name:'每二小时一次',count:12},
471
+          {name:'每四小时一次',count:6},
472
+          {name:'每六小时一次',count:4},
473
+          {name:'每八小时一次',count:3},
474
+        ]
475
+        let num = ''
476
+        arr.map(item => {
477
+          if(item.name == execution_frequency){
478
+            num = item.count
479
+          }
480
+        })
481
+        if(num == ''){
482
+          num = 1
483
+        }
484
+        return num
395 485
       }
396 486
     },mounted(){
397 487
       this.getInitData()
398
-     
488
+
399 489
     },
400 490
     watch:{
401
-      // "prescription.advices":{
402
-      //   handler(newVal,oldVal){
403
-      //     newVal.map(item => {
404
-      //       item.prescribing_number = item.single_dose * item.day
405
-      //       if(item.single_dose != oldVal[index].single_dose || item.number_days != oldVal[index].number_days){
406
-      //         item.total = item.single_dose * item.number_days
407
-      //       }
408
-            
409
-            
410
-      //     })
411
-      //   },
412
-      //   deep:true
413
-      // },
491
+      "prescription.advices":{
492
+        handler(newVal,oldVal){
493
+          
494
+        },
495
+        deep:true
496
+      },
414 497
       // "prescription.project":{
415 498
       //   handler(newVal,oldVal){
416 499
       //     newVal.map((item,index) => {
417 500
       //       if(item.single_dose != oldVal[index].single_dose || item.number_days != oldVal[index].number_days){
418 501
       //         item.total = item.single_dose * item.number_days
419 502
       //       }
420
-            
503
+
421 504
       //     })
422 505
       //   },
423 506
       //   deep:true
424 507
       // }
425 508
     }
426
-    
509
+
427 510
   }
428 511
 </script>
429 512
 

+ 468 - 0
src/xt_pages/outpatientDoctorStation/components/prescriptionTemplateTable.vue Целия файл

@@ -0,0 +1,468 @@
1
+<template>
2
+    <div class="prescriptionTable">
3
+        <el-table v-if="prescription.advices && prescription.advices.length > 0" :data="prescription.advices" border style="width: 99%;" :row-style="{ color: '#303133' }"
4
+                  :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}" highlight-current-row>
5
+            <el-table-column align="center" type="index" width="40" label="序号"></el-table-column>
6
+            <el-table-column align="center" prop="drug_name" label="名称">
7
+                <template slot-scope="scope"><span :title="scope.row.drug_name">{{ scope.row.drug_name }}</span></template>
8
+            </el-table-column>
9
+
10
+            <el-table-column align="center" prop="single_dose" width="90" label="单次用量">
11
+                <template slot-scope="scope">
12
+                    <div style="display:flex;align-items:center;">
13
+                        <el-input v-model="scope.row.single_dose" @input="getSingleDose(scope)" style="width:65%;"></el-input>
14
+                        <div>{{scope.row.single_dose_unit}}</div>
15
+                    </div>
16
+                </template>
17
+            </el-table-column>
18
+            <el-table-column align="center" prop="delivery_way" width="100" label="用法">
19
+                <template slot-scope="scope">
20
+                    <el-select v-model="scope.row.delivery_way" placeholder="请选择">
21
+                        <el-option
22
+                                v-for="(item,index) in drugways"
23
+                                :key="index"
24
+                                :label="item.name"
25
+                                :value="item.name">
26
+                        </el-option>
27
+                    </el-select>
28
+                </template>
29
+            </el-table-column>
30
+            <el-table-column align="center" prop="execution_frequency" width="100" label="频率">
31
+                <template slot-scope="scope">
32
+                    <el-select v-model="scope.row.execution_frequency" placehold er="请选择">
33
+                        <el-option
34
+                                v-for="item,index in efs"
35
+                                :key="index"
36
+                                :label="item.name"
37
+                                :value="item.name">
38
+                        </el-option>
39
+                    </el-select>
40
+                </template>
41
+            </el-table-column>
42
+
43
+
44
+            <el-table-column align="center" prop="day" width="70" label="天数">
45
+                <template slot-scope="scope">
46
+                    <div style="display:flex;align-items:center;">
47
+                        <el-input v-model="scope.row.day" @input="getDay(scope)" placeholder=""></el-input>{{'天'}}
48
+                    </div>
49
+                </template>
50
+            </el-table-column>
51
+
52
+            <el-table-column align="center" prop="prescribing_number" width="80" label="总量">
53
+                <template slot-scope="scope">
54
+                    <div style="display:flex;align-items:center;">
55
+                        <el-input v-model="scope.row.prescribing_number" style="width:60%" placeholder=""></el-input>
56
+                        <div> {{scope.row.prescribing_number_unit}}</div>
57
+                    </div>
58
+                </template>
59
+            </el-table-column>
60
+            <el-table-column align="center" prop="retail_price" width="80" label="单价">
61
+                <template slot-scope="scope">
62
+                    <div style="display:flex;align-items:center;">
63
+                        <el-input v-model="scope.row.retail_price" placeholder="" readonly></el-input>
64
+                        <div>{{'元'}}</div>
65
+                    </div>
66
+
67
+                </template>
68
+            </el-table-column>
69
+            <el-table-column align="center" prop="remark" width="50" label="备注">
70
+                <template slot-scope="scope">
71
+                    <el-input v-model="scope.row.remark" :title="scope.row.remark" placeholder=""></el-input>
72
+                </template>
73
+            </el-table-column>
74
+            <el-table-column align="center" width="40" prop="name" label="操作">
75
+                <template slot-scope="scope">
76
+                    <i class="el-icon-delete" @click="deleteDrug(scope.$index, scope.row)"></i>
77
+                </template>
78
+            </el-table-column>
79
+        </el-table>
80
+
81
+        <el-table v-if="prescription.project &&prescription.project.length > 0" :data="prescription.project" border style="width: 99%;" :row-style="{ color: '#303133' }"
82
+                  :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}" highlight-current-row>
83
+            <el-table-column align="center" type="index" width="40" label="序号"></el-table-column>
84
+            <el-table-column align="center" prop="project_name" label="名称">
85
+                <template slot-scope="scope"><span :title="scope.row.project_name">{{ scope.row.project_name }}</span></template>
86
+            </el-table-column>
87
+            <el-table-column align="center" prop="statistical_classification" width="100" label="组">
88
+                <template slot-scope="scope">{{scope.row.type == 2?getGroup(scope.row.statistical_classification):"耗材"}}</template>
89
+            </el-table-column>
90
+            <el-table-column align="center" prop="single_dose" width="80" label="单次用量">
91
+                <template slot-scope="scope">
92
+                    <el-input v-model="scope.row.single_dose" @input="getProjectSingleDose(scope)" placeholder=""></el-input>
93
+                    <div>{{scope.row.unit}}</div>
94
+
95
+                </template>
96
+            </el-table-column>
97
+            <el-table-column align="center" prop="delivery_way" width="80" label="用法">
98
+                <template slot-scope="scope">
99
+                    <el-autocomplete
100
+                            style="width:100%;"
101
+                            class="inline-input"
102
+                            v-model="scope.row.delivery_way"
103
+                            :fetch-suggestions="querySearch2"
104
+                            placeholder="请输入内容"
105
+                    ></el-autocomplete>
106
+                </template>
107
+            </el-table-column>
108
+            <el-table-column align="center" prop="execution_frequency" width="80" label="频率">
109
+                <template slot-scope="scope">
110
+                    <el-input v-model="scope.row.execution_frequency" placeholder=""></el-input>
111
+                </template>
112
+            </el-table-column>
113
+            <el-table-column align="center" prop="number_days" width="70" label="天数">
114
+                <template slot-scope="scope">
115
+                    <div style="display:flex;align-items:center;">
116
+                        <el-input v-model="scope.row.number_days" @input="getProjectDay(scope)" placeholder=""></el-input>
117
+                        <div>{{'天'}}</div>
118
+                    </div>
119
+                </template>
120
+            </el-table-column>
121
+            <el-table-column align="center" prop="total" width="70" label="总量">
122
+                <template slot-scope="scope">
123
+                    <div style="display:flex;align-items:center;">
124
+                        <el-input v-model="scope.row.total" style="width:60%" placeholder=""></el-input>
125
+                        <div>{{scope.row.unit}}</div>
126
+
127
+                    </div>
128
+                </template>
129
+            </el-table-column>
130
+            <el-table-column align="center" prop="name" width="50" label="单价">
131
+                <template slot-scope="scope">
132
+                    <el-input v-model="scope.row.price" placeholder="" readonly></el-input>
133
+                    <div>{{'元'}}</div>
134
+
135
+                </template>
136
+            </el-table-column>
137
+            <el-table-column align="center" prop="name" width="50" label="备注">
138
+                <template slot-scope="scope">
139
+                    <el-input v-model="scope.row.remark" :title="scope.row.remark"></el-input>
140
+                </template>
141
+            </el-table-column>
142
+            <el-table-column align="center" width="40" prop="name" label="操作">
143
+                <template slot-scope="scope">
144
+                    <i class="el-icon-delete" @click="deleteProject(scope.row,scope.$index)"></i>
145
+                </template>
146
+            </el-table-column>
147
+        </el-table>
148
+
149
+        <div class="additionalBox">
150
+            <div class="additionalOne" v-for="(item,index) in prescription.addition" :key="index">
151
+                <span :title="item.item_name">{{item.item_name}}</span>
152
+                <el-input v-model="item.price" placeholder="" style="width:50px;"></el-input>
153
+                共
154
+                <el-input v-model="item.count" placeholder="" style="width:50px;"></el-input>
155
+                次
156
+                <i class="el-icon-delete deleteIcon" @click="delAddition(index,item)"></i>
157
+            </div>
158
+        </div>
159
+
160
+
161
+
162
+    </div>
163
+</template>
164
+
165
+<script>
166
+  import { getDictionaryDataConfig} from "@/utils/data";
167
+  import { getInitData,delHisAdvice,delHisProject,delHisAddition } from '@/api/his/his'
168
+  import { delHisPrescriptionAdviceTemplate,delHisPrescriptionProjectTemplate } from '@/api/his/his_config'
169
+
170
+  export default {
171
+    props: {
172
+      preDrugs: Array,
173
+      activeType: Number,
174
+      addtions_charge:Array,
175
+      prescription:{
176
+        type:Object,
177
+        default: function () {
178
+          return {
179
+            name:"",
180
+            advices:[],
181
+            project:[],
182
+            drugways:[],
183
+            efs:[],
184
+          };
185
+        }
186
+      },
187
+    },
188
+    data() {
189
+      return {
190
+        advices:[],
191
+        tableData: [],
192
+        newoptions: [{
193
+          value: '1',
194
+          label: '1'
195
+        }, {
196
+          value: '2',
197
+          label: '2'
198
+        }, {
199
+          value: '3',
200
+          label: '3'
201
+        }, {
202
+          value: '4',
203
+          label: '4'
204
+        }, {
205
+          value: '5',
206
+          label: '5'
207
+        }],
208
+        value: '1',
209
+        input: 1,
210
+      }
211
+    },
212
+
213
+    methods:{
214
+      createFilter(queryString) {
215
+        return (restaurant) => {
216
+          return (restaurant.name.toLowerCase().indexOf(queryString.toLowerCase()) === 0)
217
+        }
218
+      },
219
+      querySearch2(queryString, cb) {
220
+        var restaurants = this.getDictionaryDataConfig("system","project_use")
221
+        restaurants.map(item => {
222
+          item.value = item.name
223
+        })
224
+        var results = queryString ? restaurants.filter(this.createFilter(queryString)) : restaurants
225
+        // 调用 callback 返回建议列表的数据
226
+        cb(results)
227
+      },
228
+      delAddition(index, addition){
229
+        this.$confirm("附加费删除后不可恢复,是否确认删除", "删除", {
230
+          confirmButtonText: "确 定",
231
+          cancelButtonText: "取 消",
232
+          type: "warning"
233
+        }).then(() => {
234
+          this.$nextTick(function(){
235
+            if(addition.id == 0){
236
+              this.prescription.addition.splice(index, 1)
237
+            }else{
238
+              let params = {
239
+                'id': addition.id,
240
+              }
241
+              delHisAddition(params).then(response => {
242
+                if (response.data.state == 0) {
243
+                  this.$message.error(response.data.msg)
244
+                  return false
245
+                } else {
246
+                  var temp2 = this.deepClone(this.prescription.addition)
247
+                  temp2.splice(index, 1)
248
+                  this.prescription.addition = temp2
249
+                  this.$message.success(response.data.data.msg)
250
+                }
251
+              })
252
+            }
253
+          });
254
+
255
+        })
256
+          .catch(() => {});
257
+
258
+      },
259
+      getInitData(){
260
+        getInitData().then(response => {
261
+          if (response.data.state == 0) {
262
+            this.$message.error(response.data.msg)
263
+            return false
264
+          } else {
265
+            this.drugways = response.data.data.drugways
266
+            this.efs = response.data.data.efs
267
+          }
268
+        })
269
+
270
+      },deleteDrug:function(index, row){
271
+
272
+        this.$confirm("药品删除后不可恢复,是否确认删除", "删除", {
273
+          confirmButtonText: "确 定",
274
+          cancelButtonText: "取 消",
275
+          type: "warning"
276
+        }).then(() => {
277
+          this.$nextTick(function(){
278
+            if(row.advice_id == 0){
279
+              this.prescription.advices.splice(index, 1)
280
+            }else{
281
+              let params = {
282
+                'id': row.advice_id,
283
+              }
284
+              delHisPrescriptionAdviceTemplate(params).then(response => {
285
+                if (response.data.state == 0) {
286
+                  this.$message.error(response.data.msg)
287
+                  return false
288
+                } else {
289
+                  var temp2 = this.deepClone(this.prescription.advices)
290
+                  temp2.splice(index, 1)
291
+                  this.prescription.advices = temp2
292
+                  this.$message.success(response.data.data.msg)
293
+                }
294
+              })
295
+
296
+
297
+            }
298
+
299
+          });
300
+
301
+
302
+        })
303
+          .catch(() => {});
304
+
305
+
306
+
307
+
308
+
309
+      },deepClone(source) {
310
+        if (!source && typeof source !== 'object') {
311
+          throw new Error('error arguments', 'shallowClone')
312
+        }
313
+        const targetObj = source.constructor === Array ? [] : {}
314
+        Object.keys(source).forEach((keys) => {
315
+          if (source[keys] && typeof source[keys] === 'object') {
316
+            targetObj[keys] = this.deepClone(source[keys])
317
+          } else {
318
+            targetObj[keys] = source[keys]
319
+          }
320
+        })
321
+        return targetObj
322
+      },
323
+
324
+      setNewData:function(data){
325
+        this.prescription = data
326
+
327
+        // this.prescription.advices = data.advices
328
+      },
329
+      getDictionaryDataConfig(module, filed_name) {
330
+        return getDictionaryDataConfig(module, filed_name)
331
+      },
332
+      getGroup(id){
333
+        var name = ""
334
+        var statistics_category =  getDictionaryDataConfig('system','statistics_category')
335
+        console.log("2235",statistics_category)
336
+        for(let i=0;i<statistics_category.length;i++){
337
+          if(id == statistics_category[i].id){
338
+            name = statistics_category[i].name
339
+          }
340
+        }
341
+        return name
342
+      },
343
+      deleteProject(row,i){
344
+        if(this.prescription.order_status == 2){
345
+          this.$message.error('该处方已经结算,无法删除')
346
+          return
347
+        }
348
+        this.$confirm("项目删除后不可恢复,是否确认删除", "删除", {
349
+          confirmButtonText: "确 定",
350
+          cancelButtonText: "取 消",
351
+          type: "warning"
352
+        }).then(() => {
353
+          if(row.id == 0){
354
+            this.prescription.project.splice(i, 1)
355
+
356
+          }else{
357
+            let params = {
358
+              'id': row.id,
359
+            }
360
+            delHisPrescriptionProjectTemplate(params).then(response => {
361
+              if (response.data.state == 0) {
362
+                this.$message.error(response.data.msg)
363
+                return false
364
+              } else {
365
+                for (let i = 0; i < this.prescription.project.length; i++){
366
+                  if(this.prescription.project[i].id == row.id){
367
+                    this.prescription.project.splice(i, 1)
368
+                  }
369
+                }
370
+                this.$message.success(response.data.data.msg)
371
+              }
372
+            })
373
+          }
374
+        })
375
+          .catch(() => {});
376
+
377
+      },
378
+      getSingleDose(scope){
379
+        this.prescription.advices[scope.$index].prescribing_number = scope.row.single_dose * scope.row.day
380
+      },
381
+      getDay(scope){
382
+        this.prescription.advices[scope.$index].prescribing_number = scope.row.single_dose * scope.row.day
383
+      },
384
+      getProjectSingleDose(scope){
385
+        this.prescription.project[scope.$index].total = scope.row.single_dose * scope.row.number_days
386
+        if(this.prescription.project[scope.$index].total == 0){
387
+          this.prescription.project[scope.$index].total = 1
388
+        }
389
+      },
390
+      getProjectDay(scope){
391
+        this.prescription.project[scope.$index].total = scope.row.single_dose * scope.row.number_days
392
+        if(this.prescription.project[scope.$index].total == 0){
393
+          this.prescription.project[scope.$index].total = 1
394
+        }
395
+      }
396
+    },mounted(){
397
+      this.getInitData()
398
+
399
+    },
400
+    watch:{
401
+      // "prescription.advices":{
402
+      //   handler(newVal,oldVal){
403
+      //     newVal.map(item => {
404
+      //       item.prescribing_number = item.single_dose * item.day
405
+      //       if(item.single_dose != oldVal[index].single_dose || item.number_days != oldVal[index].number_days){
406
+      //         item.total = item.single_dose * item.number_days
407
+      //       }
408
+
409
+
410
+      //     })
411
+      //   },
412
+      //   deep:true
413
+      // },
414
+      // "prescription.project":{
415
+      //   handler(newVal,oldVal){
416
+      //     newVal.map((item,index) => {
417
+      //       if(item.single_dose != oldVal[index].single_dose || item.number_days != oldVal[index].number_days){
418
+      //         item.total = item.single_dose * item.number_days
419
+      //       }
420
+
421
+      //     })
422
+      //   },
423
+      //   deep:true
424
+      // }
425
+    }
426
+
427
+  }
428
+</script>
429
+
430
+<style lang="scss">
431
+    .prescriptionTable {
432
+    .el-input__inner{
433
+        padding: 0 5px;
434
+    }
435
+    .additionalBox{
436
+        margin-top: 20px;
437
+        display: flex;
438
+        flex-wrap: wrap;
439
+    .additionalOne{
440
+        margin-right:20px;
441
+        margin-bottom:10px;
442
+        display: flex;
443
+        align-items: center;
444
+    >span{
445
+        white-space: nowrap;
446
+        overflow: hidden;
447
+        text-overflow: ellipsis;
448
+        width:80px;
449
+        display: inline-block;
450
+        font-size: 14px;
451
+    }
452
+    }
453
+    .deleteIcon{
454
+        color:red;
455
+        margin-left:5px;
456
+    }
457
+    }
458
+    .el-table th .cell, .el-table td .cell {
459
+        padding: 0 2px;
460
+        white-space: pre-line;
461
+    }
462
+
463
+    .el-icon-delete {
464
+        color: red;
465
+    }
466
+
467
+    }
468
+</style>

+ 250 - 67
src/xt_pages/outpatientDoctorStation/components/saveTemplate.vue Целия файл

@@ -1,89 +1,272 @@
1 1
 <template>
2 2
     <el-dialog
3
-        title="模板信息"
4
-        width="600px"
5
-        :visible.sync="visible"
6
-        :before-close="_close"
3
+            title="长期处方模版"
4
+            width="600px"
5
+            :visible.sync="visible"
6
+            :before-close="_close"
7 7
     >
8 8
         <div>
9
-            <el-form :model="form"  class="adviceForm" ref="form" label-width="100px" style="display: flex;flex-wrap: wrap;justify-content: space-between;">
10
-                <el-form-item label="创建人 : " style="width: 100%;margin-bottom:0;">
11
-                    医生
12
-                </el-form-item>
13
-                <el-form-item label="处方类型 : " style="width: 100%;margin-bottom:0;">
14
-                    药品模板
15
-                </el-form-item>
16
-                <el-form-item label="模板类型 : " style="width: 100%;margin-bottom:0;">
17
-                    <el-radio v-model="radio" label="1">临时</el-radio>
18
-                    <el-radio v-model="radio" label="2">长期</el-radio>
9
+            <el-form :model="form" class="adviceForm" ref="form" label-width="100px"
10
+                     style="display: flex;flex-wrap: wrap;justify-content: space-between;">
11
+
12
+                <!--<el-form-item label="处方模板类别 : " style="width: 100%;margin-bottom:0;">-->
13
+                <!--<el-radio v-model="radio" label="1">临时</el-radio>-->
14
+                <!--<el-radio v-model="radio" label="2">长期</el-radio>-->
15
+                <!--</el-form-item>-->
16
+                <el-form-item label="处方模板名称:" style="width: 60%;margin-bottom:0;">
17
+                    <el-input v-model="form.name" placeholder=""></el-input>
19 18
                 </el-form-item>
20
-                <el-form-item label="科室 : " style="width: 100%;">
21
-                    <el-select v-model="value" style="width:100%;" placeholder="请选择">
19
+                <el-form-item label="透析模式 : " style="width: 60%;">
20
+                    <el-select v-model="form.mode" style="width:100%;" placeholder="请选择">
22 21
                         <el-option
23
-                        v-for="item in options"
24
-                        :key="item.value"
25
-                        :label="item.label"
26
-                        :value="item.value">
27
-                        </el-option>
22
+                                v-for="item in modeOptions"
23
+                                :key="item.id"
24
+                                :label="item.name"
25
+                                :value="item.id"
26
+                        ></el-option>
28 27
                     </el-select>
29 28
                 </el-form-item>
30
-                <el-form-item label="模板名称 : " style="width: 100%;">
31
-                    <el-input v-model="form.name" placeholder=""></el-input>
32
-                </el-form-item>
33
-                <el-form-item label="模板说明 : " style="width: 100%;">
34
-                    <el-input v-model="form.name" placeholder=""></el-input>
35
-                </el-form-item>
36
-                <el-form-item label="诊断信息 : " style="width: 100%;">
37
-                    <el-input v-model="form.name" placeholder=""></el-input>
38
-                </el-form-item>
39
-                <el-form-item label="医嘱说明 : " style="width: 100%;">
40
-                    <el-input v-model="form.name" placeholder=""></el-input>
41
-                </el-form-item>
42
-                <el-form-item label="备注说明 : " style="width: 100%;">
43
-                    <el-input v-model="form.name" placeholder=""></el-input>
44
-                </el-form-item>
45 29
             </el-form>
30
+
31
+
32
+            <div v-for="(item,index) in allPrescription" :key="index">
33
+                <el-checkbox-group v-model="item.check_group">
34
+                    <div v-for="(subItem,index2) in item.prescriptions" :key="index2">
35
+                        <el-checkbox style="margin:10px 0;" :label="subItem.id">{{'处方' + (index2+ 1)}}</el-checkbox>
36
+                        <el-table v-if="subItem.advices.length > 0" :data="subItem.advices" border style="width: 99%;"
37
+                                  :row-style="{ color: '#303133' }"
38
+                                  :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}"
39
+                                  highlight-current-row>
40
+                            <el-table-column align="center" type="index" width="60" label="序号"></el-table-column>
41
+                            <el-table-column align="center" prop="drug_name" width="160" label="名称">
42
+                                <template slot-scope="scope">
43
+                                    <span>{{ scope.row.drug_name }}</span>
44
+                                </template>
45
+                            </el-table-column>
46
+
47
+                            <el-table-column align="center" prop="single_dose" width="90" label="单次用量">
48
+                                <template slot-scope="scope">
49
+                                    <div>{{scope.row.single_dose}}{{scope.row.single_dose_unit}}</div>
50
+                                </template>
51
+                            </el-table-column>
52
+                            <el-table-column align="center" prop="delivery_way" width="100" label="用法">
53
+                                <template slot-scope="scope">
54
+                                    {{scope.row.delivery_way}}
55
+                                </template>
56
+                            </el-table-column>
57
+                            <el-table-column align="center" prop="execution_frequency" width="100" label="频率">
58
+                                <template slot-scope="scope">
59
+                                    {{scope.row.execution_frequency}}
60
+                                </template>
61
+                            </el-table-column>
62
+
63
+                            <el-table-column align="center" prop="day" width="60" label="天数">
64
+                                <template slot-scope="scope">
65
+                                    {{scope.row.day}}
66
+                                </template>
67
+                            </el-table-column>
68
+
69
+                            <el-table-column align="center" prop="prescribing_number" width="100" label="总量">
70
+                                <template slot-scope="scope">
71
+                                    <div>{{scope.row.prescribing_number}} {{scope.row.prescribing_number_unit}}</div>
72
+                                </template>
73
+                            </el-table-column>
74
+                            <el-table-column align="center" prop="retail_price" width="80" label="单价">
75
+                                <template slot-scope="scope">
76
+                                    <div>{{scope.row.retail_price}}</div>
77
+                                </template>
78
+                            </el-table-column>
79
+                            <el-table-column align="center" prop="remark" label="备注">
80
+                                <template slot-scope="scope">
81
+                                    <div>{{scope.row.remark}}</div>
82
+                                </template>
83
+                            </el-table-column>
84
+                        </el-table>
85
+                        <el-table v-if="subItem.project.length > 0" :data="subItem.project" border style="width: 99%;"
86
+                                  :row-style="{ color: '#303133' }"
87
+                                  :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}"
88
+                                  highlight-current-row>
89
+                            <el-table-column align="center" type="index" width="60" label="序号"></el-table-column>
90
+                            <el-table-column align="center" prop="project_name" width="160" label="名称">
91
+                                <template slot-scope="scope">
92
+                                    <span>{{ scope.row.project_name}}</span>
93
+                                </template>
94
+                            </el-table-column>
95
+                            <el-table-column align="center" prop="statistical_classification" width="100" label="组">
96
+                                <template slot-scope="scope">{{ scope.row.type == 2
97
+                                    ?getGroup(scope.row.statistical_classification):'耗材'}}
98
+                                </template>
99
+                            </el-table-column>
100
+                            <el-table-column align="center" prop="single_dose" width="90" label="单次用量">
101
+                                <template slot-scope="scope">
102
+                                    <!--<el-input v-model="scope.row.single_dose" placeholder=""></el-input>-->
103
+                                    <span>{{ scope.row.single_dose }}</span>
104
+
105
+                                </template>
106
+                            </el-table-column>
107
+                            <el-table-column align="center" prop="delivery_way" width="100" label="用法">
108
+                                <template slot-scope="scope">
109
+                                    <!--<el-input v-model="scope.row.delivery_way" placeholder=""></el-input>-->
110
+                                    <span>{{ scope.row.delivery_way }}</span>
111
+
112
+                                </template>
113
+                            </el-table-column>
114
+                            <el-table-column align="center" prop="execution_frequency" width="100" label="频率">
115
+                                <template slot-scope="scope">
116
+                                    <!--<el-input v-model="scope.row.execution_frequency" placeholder=""></el-input>-->
117
+                                    <span>{{ scope.row.execution_frequency }}</span>
118
+
119
+                                </template>
120
+                            </el-table-column>
121
+                            <el-table-column align="center" prop="number_days" width="70" label="天数">
122
+                                <template slot-scope="scope">
123
+                                    <!--<el-input v-model="scope.row.number_days" placeholder=""></el-input>-->
124
+                                    <span>{{ scope.row.number_days }}</span>
125
+
126
+                                </template>
127
+                            </el-table-column>
128
+                            <el-table-column align="center" prop="total" width="70" label="总量">
129
+                                <template slot-scope="scope">
130
+                                    <div>{{ scope.row.total }}{{scope.row.unit}}</div>
131
+                                </template>
132
+                            </el-table-column>
133
+                            <el-table-column align="center" prop="name" width="60" label="单价">
134
+                                <template slot-scope="scope">
135
+                                    <!--<el-input v-model="scope.row.price" placeholder="" readonly></el-input>-->
136
+                                    <span>{{ scope.row.price }}</span>
137
+
138
+                                </template>
139
+                            </el-table-column>
140
+                            <el-table-column align="center" prop="name" label="备注">
141
+                                <template slot-scope="scope">
142
+                                    <!--<el-input v-model="scope.row.remark" :title="scope.row.remark"></el-input>-->
143
+                                    <span>{{ scope.row.remark }}</span>
144
+
145
+                                </template>
146
+                            </el-table-column>
147
+                        </el-table>
148
+                    </div>
149
+                </el-checkbox-group>
150
+            </div>
151
+
152
+
46 153
         </div>
47 154
         <div slot="footer" class="dialog-footer">
48 155
             <el-button @click="hide">取 消</el-button>
49 156
             <el-button type="primary" @click="submitAction()">保 存</el-button>
50 157
         </div>
51
-    </el-dialog>         
158
+    </el-dialog>
52 159
 </template>
53 160
 
54 161
 <script>
55
-export default {
56
-    data(){
57
-        return{
58
-            visible:false,
59
-            form:{
60
-                name:''
61
-            },
62
-            radio:"1",
63
-            options:[],
64
-            value:''
65
-        }
66
-    },
67
-    methods:{
68
-        _close: function(done) {
69
-            // this.clear()
70
-            done()
71
-        },
72
-        clear: function() {
73
-            this.form.id = 0;
74
-            this.form.name = "";
75
-            this.form.intro = "";
76
-        },
77
-        show() {
78
-            // this.clear()
79
-            this.visible = true
80
-        },
81
-        hide() {
82
-            // this.clear()
83
-            this.visible = false
162
+  import { getDictionaryDataConfig } from '@/utils/data'
163
+
164
+  export default {
165
+    data() {
166
+      return {
167
+        visible: false,
168
+        modeOptions: {},
169
+        allPrescription: [],
170
+
171
+        form: {
172
+          name: '',
173
+          mode: ''
84 174
         },
175
+        radio: '1',
176
+        options: [],
177
+        value: ''
178
+      }
179
+    },
180
+    methods: {
181
+      getGroup(id) {
182
+        var name = ''
183
+        var statistics_category = getDictionaryDataConfig('system', 'statistics_category')
184
+        for (let i = 0; i < statistics_category.length; i++) {
185
+          if (id == statistics_category[i].id) {
186
+            name = statistics_category[i].name
187
+          }
188
+        }
189
+        return name
190
+      },
191
+      _close: function(done) {
192
+        // this.clear()
193
+        done()
194
+      },
195
+      clear: function() {
196
+        this.form.id = 0
197
+        this.form.name = ''
198
+        this.form.intro = ''
199
+      }, submitAction() {
200
+
201
+        let checkGroup = []
202
+        let allPrescriptions = []
203
+        let targetPrescriptions = []
204
+        let prescriptions = []
205
+        for (let i = 0; i < this.allPrescription.length; i++) {
206
+          for (let a = 0; a < this.allPrescription[i].check_group.length; a++) {
207
+            checkGroup.push(this.allPrescription[i].check_group[a])
208
+          }
209
+          for (let a = 0; a < this.allPrescription[i].prescriptions.length; a++) {
210
+            allPrescriptions.push(this.allPrescription[i].prescriptions[a])
211
+          }
212
+        }
213
+        for (let i = 0; i < allPrescriptions.length; i++) {
214
+          for (let a = 0; a < checkGroup.length; a++) {
215
+            if (allPrescriptions[i].id == checkGroup[a]) {
216
+              targetPrescriptions.push(allPrescriptions[i])
217
+            }
218
+          }
219
+        }
220
+
221
+
222
+        for(let i = 0; i < targetPrescriptions.length; i++){
223
+          if(targetPrescriptions[i].advices.length > 0 && targetPrescriptions[i].project.length == 0){
224
+            targetPrescriptions[i]["type"] = 1
225
+          } else if(targetPrescriptions[i].advices.length == 0 && targetPrescriptions[i].project.length > 0){
226
+            targetPrescriptions[i]["type"] = 2
227
+          }
228
+          for (let b = 0; b < targetPrescriptions[i].advices.length; b++) {
229
+            targetPrescriptions[i].advices[b].single_dose = targetPrescriptions[i].advices[b].single_dose.toString()
230
+            targetPrescriptions[i].advices[b].prescribing_number =targetPrescriptions[i].advices[b].prescribing_number.toString()
231
+            targetPrescriptions[i].advices[b].retail_price = targetPrescriptions[i].advices[b].retail_price.toString()
232
+            targetPrescriptions[i].advices[b].day = parseInt(targetPrescriptions[i].advices[b].day)
233
+          }
234
+          for (let b = 0; b < targetPrescriptions[i].project.length; b++) {
235
+            targetPrescriptions[i].project[b].price =targetPrescriptions[i].project[b].price.toString()
236
+            targetPrescriptions[i].project[b].total =targetPrescriptions[i].project[b].total.toString()
237
+            targetPrescriptions[i].project[b].delivery_way =targetPrescriptions[i].project[b].delivery_way.toString()
238
+          }
239
+        }
240
+
241
+        let params = {
242
+          name: this.form.name,
243
+          mode: this.form.mode,
244
+          prescriptions: targetPrescriptions,
245
+        }
246
+        this.$emit('save_template', params)
247
+      },
248
+      show(prescriptions) {
249
+        for (let i = 0; i < prescriptions.length; i++) {
250
+          if (prescriptions[i].id == 0) {
251
+            prescriptions[i].id = Math.floor((Math.random() + Math.floor(Math.random() * 9 + 1)) * Math.pow(10, 10 - 1))
252
+          }
253
+        }
254
+
255
+        this.allPrescription = []
256
+        this.modeOptions = this.$store.getters.treatment_mode
257
+        let obj = {
258
+          check_group: [],
259
+          prescriptions: prescriptions
260
+        }
261
+        this.allPrescription.push(obj)
262
+        this.visible = true
263
+      },
264
+      hide() {
265
+        // this.clear()
266
+        this.visible = false
267
+      }
85 268
     }
86
-}
269
+  }
87 270
 </script>
88 271
 
89 272
 

Файловите разлики са ограничени, защото са твърде много
+ 2287 - 767
src/xt_pages/outpatientDoctorStation/doctorDesk.vue


+ 7 - 7
src/xt_pages/outpatientDoctorStation/pastInquiries.vue Целия файл

@@ -22,24 +22,24 @@
22 22
           <template slot-scope="scope">{{scope.row.patients?scope.row.patients.name:''}}</template>
23 23
         </el-table-column>
24 24
         <el-table-column align="center" prop="name" label="处方日期" width="200">
25
-          <template slot-scope="scope"> {{scope.row.info?getTimes(scope.row.info.ctime):''}}</template>
25
+          <template slot-scope="scope"> {{getTimes(scope.row.ctime)}}</template>
26 26
 
27 27
         </el-table-column>
28 28
         <!--<el-table-column align="center" prop="name" label="患者类型">-->
29 29
           <!--<template slot-scope="scope">{{}}</template>-->
30 30
         <!--</el-table-column>-->
31 31
         <el-table-column align="center" prop="name" label="处方号">
32
-          <template slot-scope="scope">{{scope.row.info?scope.row.info.prescription_number:''}}</template>
32
+          <template slot-scope="scope">{{scope.row.prescription_number}}</template>
33 33
         </el-table-column>
34 34
         <el-table-column align="center" prop="name" label="开立医生">
35
-          <template slot-scope="scope">{{scope.row.info?scope.row.info.doctor:''}}</template>
35
+          <template slot-scope="scope">{{scope.row.doctor}}</template>
36 36
         </el-table-column>
37 37
         <el-table-column align="center" prop="name" label="诊断">
38
-          <template slot-scope="scope">{{getDiagnosis(scope.row.info.diagnosis)}}</template>
38
+          <template slot-scope="scope">{{getDiagnosis(scope.row.diagnosis)}}</template>
39 39
         </el-table-column>
40 40
         <el-table-column align="center" prop="name" label="状态" width="100">
41 41
           <template slot-scope="scope">
42
-            <div v-if=" scope.row.info && scope.row.info.id > 0">已就诊</div>
42
+            <div v-if="scope.row.id > 0">已就诊</div>
43 43
             <div v-else>未就诊</div>
44 44
           </template>
45 45
         </el-table-column>
@@ -121,11 +121,11 @@
121 121
         return uParseTime(time, "{y}-{m}-{d} {h}:{i}:{s}");
122 122
       },
123 123
       handerShowDetail(row) {
124
-        if(row.info.id == 0){
124
+        if(row.id == 0){
125 125
           this.$message.error("未就诊")
126 126
           return
127 127
         }
128
-        this.$refs.inquiriesDetail.show(row.info.id)
128
+        this.$refs.inquiriesDetail.show(row.id)
129 129
       }, getHisPrescriptionList() {
130 130
         let params = {
131 131
           record_date:this.record_date,

+ 488 - 0
src/xt_pages/outpatientDoctorStation/prescriptionTemplate.vue Целия файл

@@ -0,0 +1,488 @@
1
+<template>
2
+    <div class="main-contain new-main-contain">
3
+        <div class="position">
4
+            <bread-crumb :crumbs='crumbs'></bread-crumb>
5
+            <el-button type="primary" @click="add">新增</el-button>
6
+
7
+        </div>
8
+        <div class="app-container" style="display:flex;flex: 1;padding: 10px 20px 0px 20px;">
9
+            <div class="mainLeft">
10
+                <!--<div class="mainCell" style="margin-bottom:10px;">-->
11
+                    <!--<el-input size="small" placeholder="请输入姓名" @input="searchAction"-->
12
+                              <!--@keyup.enter.native='searchAction'-->
13
+                              <!--v-model="search_input" class="filter-item"/>-->
14
+                    <!--<el-button size="small" style="margin-left:10px;" class="filter-item" type="primary"-->
15
+                               <!--@click="searchAction">-->
16
+                        <!--搜索-->
17
+                    <!--</el-button>-->
18
+                <!--</div>-->
19
+                <div>
20
+                    <el-table :data="data" :height="tableHeight" @row-click='choosePatient'
21
+                               border style="width: 100%;"
22
+                              :row-style="{ color: '#303133' }"
23
+                              :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}"
24
+                              highlight-current-row
25
+                              ref="tab">
26
+                        <el-table-column prop="name" label="姓名">
27
+                            <template slot-scope="scope">{{scope.row.name}}</template>
28
+                        </el-table-column>
29
+                    </el-table>
30
+                </div>
31
+            </div>
32
+            <div class="mainRight">
33
+                <el-table :data="templates" :height="tableHeight"
34
+                           border style="width: 100%;"
35
+                          :row-style="{ color: '#303133' }"
36
+                          :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}"
37
+                          highlight-current-row
38
+                          ref="tab"
39
+                >
40
+                    <el-table-column prop="name" label="模版名称">
41
+                        <template slot-scope="scope">{{scope.row.name}}</template>
42
+                    </el-table-column>
43
+                    <el-table-column prop="name" label="透析模式">
44
+                        <template slot-scope="scope">{{getMode(scope.row.mode)}}</template>
45
+                    </el-table-column>
46
+                    <el-table-column prop="name" label="操作">
47
+                        <template slot-scope="scope">
48
+                            <el-button size="mini" type="primary" @click="jumpDetail(scope.row)">编辑</el-button>
49
+                            <el-button size="mini" type="danger" @click="deleteTemplate(scope.row)">删除</el-button>
50
+                        </template>
51
+                    </el-table-column>
52
+                </el-table>
53
+
54
+
55
+                <el-pagination
56
+                        @size-change="handleSizeChange"
57
+                        @current-change="handleCurrentChange"
58
+                        :page-sizes="[10, 50, 100]"
59
+                        :page-size="10"
60
+                        background
61
+                        align="right"
62
+                        style="margin-top:20px;"
63
+                        layout="total, sizes, prev, pager, next, jumper"
64
+                        :total="total"
65
+                >
66
+                </el-pagination>
67
+            </div>
68
+        </div>
69
+    </div>
70
+</template>
71
+
72
+<script>
73
+  import BreadCrumb from '@/xt_pages/components/bread-crumb'
74
+  import { delHisPrescriptionTemplate, getPatientList, getPrescriptionTemplateList } from '@/api/his/his_config'
75
+  import { uParseTime } from '@/utils/tools'
76
+
77
+  const moment = require('moment')
78
+  export default {
79
+    components: {
80
+      BreadCrumb
81
+    },
82
+    data() {
83
+      return {
84
+        crumbs: [
85
+          { path: false, name: '门诊医生站' },
86
+          { path: false, name: '处方模版' }
87
+        ],
88
+        search_input:'',
89
+        templates: [],
90
+        tableHeight: '',
91
+        fullHeight: document.documentElement.clientHeight,
92
+        isloading: false,
93
+        data: [],
94
+        page: 1,
95
+        limit: 10,
96
+        patient_id: 0,
97
+        total:0
98
+      }
99
+    },
100
+    methods: {
101
+      deleteTemplate(row) {
102
+        this.$confirm('处方模版删除后不可恢复,是否确认删除', '删除', {
103
+          confirmButtonText: '确 定',
104
+          cancelButtonText: '取 消',
105
+          type: 'warning'
106
+        }).then(() => {
107
+          let params = {
108
+            id: row.id
109
+          }
110
+          delHisPrescriptionTemplate(params).then(response => {
111
+            if (response.data.state == 1) {
112
+              this.GetPrescriptionTemplateList()
113
+            }
114
+          })
115
+
116
+        }).catch(() => {
117
+
118
+        })
119
+      },
120
+      jumpDetail(row) {
121
+        this.$router.push('/outpatientDoctorStation/prescriptionTemplatedetail?id=' + row.id + '&patient_id=' + this.patient_id)
122
+      },
123
+      getMode(id) {
124
+        let name = ''
125
+        this.treatment_mode = Object.values(this.$store.getters.treatment_mode)
126
+        this.treatment_mode.map(item => {
127
+          if (item.id == id) {
128
+            name = item.name
129
+          }
130
+        })
131
+        return name
132
+      },
133
+      handleSizeChange(val) {
134
+        this.limit = val
135
+        this.GetPrescriptionTemplateList()
136
+      },
137
+      handleCurrentChange(val) {
138
+        this.page = val
139
+        this.GetPrescriptionTemplateList()
140
+      },
141
+      GetPrescriptionTemplateList() {
142
+        let params = {
143
+          patient_id: this.patient_id,
144
+          page: this.page,
145
+          limit: this.limit
146
+        }
147
+        getPrescriptionTemplateList(params).then(response => {
148
+          if (response.data.state == 1) {
149
+            this.templates = response.data.data.list
150
+            this.total = response.data.data.total
151
+          }
152
+        })
153
+
154
+      },
155
+      choosePatient(val) {
156
+        this.page = 1
157
+        this.limit = 10
158
+        this.patient_id = val.id
159
+        let params = {
160
+          patient_id: val.id,
161
+          page: this.page,
162
+          limit: this.limit
163
+        }
164
+        getPrescriptionTemplateList(params).then(response => {
165
+          if (response.data.state == 1) {
166
+            this.templates = response.data.data.list
167
+            this.total = response.data.data.total
168
+          }
169
+        })
170
+      },
171
+      getList(id) {
172
+        getPatientList().then(response => {
173
+          if (response.data.state == 1) {
174
+            this.data = response.data.data.list
175
+            this.$refs.tab.setCurrentRow(this.data[0])
176
+            // this.patient_id = this.data[0].id
177
+            // this.GetPrescriptionTemplateList()
178
+
179
+          }
180
+        })
181
+      },
182
+      getTime(val, temp) {
183
+        if (val != 0) {
184
+          return uParseTime(val, temp)
185
+        } else {
186
+          return ''
187
+        }
188
+      },
189
+      add() {
190
+        if (this.patient_id == 0) {
191
+          this.$message.error('请选择病人')
192
+          return
193
+        }
194
+        this.$router.push('/outpatientDoctorStation/prescriptionTemplatedetail?id=' + 0 + '&patient_id=' + this.patient_id)
195
+
196
+      }
197
+    },
198
+    created() {
199
+      var nowDate = new Date()
200
+      var nowYear = nowDate.getFullYear()
201
+      var nowMonth = nowDate.getMonth() + 1
202
+      var nowDay = nowDate.getDate()
203
+      this.record_date =
204
+        nowYear +
205
+        '-' +
206
+        (nowMonth < 10 ? '0' + nowMonth : nowMonth) +
207
+        '-' +
208
+        (nowDay < 10 ? '0' + nowDay : nowDay)
209
+      this.getList()
210
+      let tableHeight = document.body.clientHeight - 263
211
+      this.tableHeight = tableHeight
212
+
213
+    },
214
+    mounted() {
215
+      const that = this
216
+      window.onresize = () => {
217
+        return (() => {
218
+          window.fullHeight = document.documentElement.clientHeight
219
+          that.fullHeight = window.fullHeight
220
+        })()
221
+      }
222
+    },
223
+    watch: {
224
+      fullHeight(val) {
225
+        if (!this.timer) {
226
+          this.fullHeight = val
227
+          let tableHeight = val - 263
228
+          this.tableHeight = tableHeight
229
+          this.timer = true
230
+          let that = this
231
+          setTimeout(function() {
232
+            that.timer = false
233
+          }, 400)
234
+        }
235
+      }
236
+
237
+    }
238
+  }
239
+</script>
240
+
241
+<style lang="scss" scoped>
242
+    .new-main-contain {
243
+        height: 100%;
244
+        display: flex;
245
+        flex-direction: column;
246
+    }
247
+
248
+    .app-container {
249
+        height: 100%;
250
+    }
251
+
252
+    .mainCell {
253
+        height: 36px;
254
+        display: flex;
255
+        align-items: center;
256
+    }
257
+
258
+    .mainLeft {
259
+        width: 200px;
260
+        height: 100%;
261
+        display: flex;
262
+        flex-direction: column;
263
+
264
+    .el-radio {
265
+        margin-right: 5px;
266
+    }
267
+
268
+    }
269
+    .mainRight {
270
+        margin-left: 10px;
271
+        flex: 1;
272
+        height: 100%;
273
+        display: flex;
274
+        flex-direction: column;
275
+        overflow-y: auto;
276
+
277
+    .cellSpan {
278
+        min-width: 80px;
279
+        display: inline-block;
280
+        margin-right: 10px;
281
+    }
282
+
283
+    }
284
+    .mainCenter {
285
+        display: flex;
286
+        flex: 1;
287
+    }
288
+
289
+    .centerLeft {
290
+        flex: 1;
291
+        display: flex;
292
+        flex-direction: column;
293
+        position: relative;
294
+
295
+    .el-form-item {
296
+        width: 32%;
297
+        margin-right: 1%;
298
+        float: left;
299
+    }
300
+
301
+    .el-form-item__label {
302
+        text-align: left;
303
+    }
304
+
305
+    }
306
+    .backColor {
307
+        background: #f6f8f9;
308
+        height: 5px;
309
+        margin-bottom: 5px;
310
+    }
311
+
312
+    .tabsBox {
313
+        position: relative;
314
+        height: 76%;
315
+        overflow-y: auto;
316
+        margin-bottom: 60px;
317
+
318
+    .el-tabs__item {
319
+        padding: 0 10px;
320
+    }
321
+
322
+    }
323
+    .preTabs {
324
+        height: 100%;
325
+        display: flex;
326
+        flex-direction: column;
327
+
328
+    .el-tabs__content {
329
+        flex: 1;
330
+        overflow-y: auto;
331
+    }
332
+
333
+    }
334
+
335
+    .costBox {
336
+        width: 100%;
337
+        height: 60px;
338
+        background: #fff;
339
+        position: absolute;
340
+        bottom: 0;
341
+        display: flex;
342
+        align-items: center;
343
+    }
344
+
345
+    .addTab {
346
+        position: absolute;
347
+        right: 0;
348
+        top: 14px;
349
+        z-index: 20;
350
+    }
351
+
352
+    .centerRight {
353
+        width: 300px;
354
+        margin-left: 10px;
355
+        display: flex;
356
+        flex-direction: column;
357
+        position: relative;
358
+    }
359
+
360
+    .rightTab {
361
+        height: 40px;
362
+        width: 100%;
363
+        border: 1px solid #d2d2d2;
364
+        box-sizing: border-box;
365
+
366
+    p {
367
+        width: 50%;
368
+        height: 40px;
369
+        line-height: 40px;
370
+        text-align: center;
371
+        background: #eee;
372
+        float: left;
373
+    }
374
+
375
+    > p:last-child {
376
+        border-left: 1px solid #d2d2d2;
377
+        float: right;
378
+    }
379
+
380
+    .activeP {
381
+        background: #409EFF;
382
+        color: #fff;
383
+    }
384
+
385
+    }
386
+    .comfirmBox {
387
+        width: 100%;
388
+        height: 60px;
389
+        background: #fff;
390
+        position: absolute;
391
+        bottom: 0;
392
+        display: flex;
393
+        align-items: center;
394
+        justify-content: space-between;
395
+    }
396
+
397
+    .mainHeader {
398
+        width: 100%;
399
+        background: #fff;
400
+        position: fixed;
401
+        z-index: 100;
402
+        height: 36px;
403
+    }
404
+
405
+    .titleBox {
406
+        position: fixed;
407
+        z-index: 99;
408
+        background: #fff;
409
+    }
410
+
411
+    .fixedCell {
412
+        position: fixed;
413
+        z-index: 99;
414
+        right: 30px;
415
+        background: #fff;
416
+        width: 300px;
417
+        display: flex;
418
+        justify-content: space-between;
419
+    }
420
+</style>
421
+
422
+<style lang="scss">
423
+    .centerLeft {
424
+
425
+    .el-form-item__label {
426
+        text-align: left;
427
+    }
428
+
429
+    }
430
+    .tabsBox {
431
+
432
+    .el-tabs__item {
433
+        padding: 0 10px;
434
+    }
435
+
436
+    .el-tabs--bottom .el-tabs--left > .el-tabs__header .el-tabs__item:nth-child(2), .el-tabs--bottom .el-tabs--right > .el-tabs__header .el-tabs__item:nth-child(2), .el-tabs--bottom.el-tabs--border-card > .el-tabs__header .el-tabs__item:nth-child(2), .el-tabs--bottom.el-tabs--card > .el-tabs__header .el-tabs__item:nth-child(2), .el-tabs--top .el-tabs--left > .el-tabs__header .el-tabs__item:nth-child(2), .el-tabs--top .el-tabs--right > .el-tabs__header .el-tabs__item:nth-child(2), .el-tabs--top.el-tabs--border-card > .el-tabs__header .el-tabs__item:nth-child(2), .el-tabs--top.el-tabs--card > .el-tabs__header .el-tabs__item:nth-child(2) {
437
+        padding: 0 10px;
438
+    }
439
+
440
+    .el-tabs--bottom .el-tabs--left > .el-tabs__header .el-tabs__item:last-child, .el-tabs--bottom .el-tabs--right > .el-tabs__header .el-tabs__item:last-child, .el-tabs--bottom.el-tabs--border-card > .el-tabs__header .el-tabs__item:last-child, .el-tabs--bottom.el-tabs--card > .el-tabs__header .el-tabs__item:last-child, .el-tabs--top .el-tabs--left > .el-tabs__header .el-tabs__item:last-child, .el-tabs--top .el-tabs--right > .el-tabs__header .el-tabs__item:last-child, .el-tabs--top.el-tabs--border-card > .el-tabs__header .el-tabs__item:last-child, .el-tabs--top.el-tabs--card > .el-tabs__header .el-tabs__item:last-child {
441
+        padding: 0 10px;
442
+    }
443
+
444
+    .el-tabs--card > .el-tabs__header .el-tabs__item.is-active.is-closable {
445
+        padding: 0 10px;
446
+    }
447
+
448
+    }
449
+    .centerRight {
450
+
451
+    .el-tabs__nav-scroll {
452
+        display: flex;
453
+    }
454
+
455
+    .el-tabs__nav {
456
+        margin: 0 auto;
457
+    }
458
+
459
+    .el-table th .cell, .el-table td .cell {
460
+        padding: 0 2px;
461
+    }
462
+
463
+    }
464
+    .preTabs {
465
+
466
+    .el-tabs__content {
467
+
468
+    }
469
+
470
+    }
471
+    .rightTabs {
472
+        height: 100%;
473
+
474
+
475
+    .el-tabs__content {
476
+
477
+    }
478
+
479
+    }
480
+    .centerDialog {
481
+
482
+    .el-dialog__body {
483
+        max-height: calc(100vh - 100px) !important;
484
+        padding: 0 20px;
485
+    }
486
+
487
+    }
488
+</style>

Файловите разлики са ограничени, защото са твърде много
+ 1997 - 0
src/xt_pages/outpatientDoctorStation/prescriptionTemplatedetail.vue


+ 8 - 3
src/xt_pages/outpatientDoctorStation/print.vue Целия файл

@@ -13,7 +13,8 @@
13 13
       </template>
14 14
             
15 15
     <div class='dialysisPage' style="padding-top:40px;">
16
-      <printOne v-bind:childResponse="childResponse" :advicePrint="advicePrint" :ids="ids" :patient="patient" :hisPatient="hisPatient" :doctorPorject="doctorPorject" :patient_id="patient_id" :record_date="record_date" :prescription_id="prescription_id"></printOne>
16
+      <printOne v-if="org_id != 10088" v-bind:childResponse="childResponse" :advicePrint="advicePrint" :ids="ids" :patient="patient" :hisPatient="hisPatient" :doctorPorject="doctorPorject" :patient_id="patient_id" :record_date="record_date" :prescription_id="prescription_id"></printOne>
17
+      <printFour v-else v-bind:childResponse="childResponse" :advicePrint="advicePrint" :ids="ids" :patient="patient" :hisPatient="hisPatient" :doctorPorject="doctorPorject" :patient_id="patient_id" :record_date="record_date" :prescription_id="prescription_id"></printFour>
17 18
     </div>
18 19
   </div>
19 20
 </template>
@@ -29,12 +30,14 @@ import { jsGetAge, uParseTime } from "@/utils/tools";
29 30
 import BreadCrumb from "@/xt_pages/components/bread-crumb";
30 31
 import print from "print-js";
31 32
 import printOne from "./template/printOne"
33
+import printFour from "./template/printFour"
32 34
 import { getAllDoctorList,getAllHisPatientList,getPrescriptionPrint } from "@/api/project/project"
33 35
 export default {
34 36
   name: "dialysisPrintOrder",
35 37
   components: {
36 38
     BreadCrumb,
37
-    printOne
39
+    printOne,
40
+    printFour
38 41
   },
39 42
   props:{
40 43
     paramsObj:Object
@@ -56,7 +59,8 @@ export default {
56 59
        patient_id:"",
57 60
        prescription_id:"",
58 61
        ids:'',
59
-       paramsObj:{}
62
+       paramsObj:{},
63
+       org_id:''
60 64
     };
61 65
   },
62 66
   methods:{
@@ -154,6 +158,7 @@ export default {
154 158
   },
155 159
 
156 160
   created() {
161
+    this.org_id = this.$store.getters.xt_user.org_id
157 162
     this.getAllDoctorList()
158 163
     var record_date = this.paramsObj.record
159 164
     this.record_date = record_date

+ 330 - 0
src/xt_pages/outpatientDoctorStation/template/printFour.vue Целия файл

@@ -0,0 +1,330 @@
1
+<template>
2
+  <div id='prescriptionPrint'>
3
+    <div v-for="(item,index) in advicePrint" :key="index">
4
+      <div id='prescription-print' class="prescription-print" style="page-break-after: always;">
5
+          <div class="printTitle">{{orgname}}处方笺</div>
6
+          <div class="infoTitle">
7
+              <p>姓名:{{item.patient.name?item.patient.name:""}}</p>
8
+              <p>性别:
9
+                <span v-if="item.patient.gender == 1">男</span>
10
+                <span v-if="item.patient.gender == 2">女</span>
11
+              </p>
12
+              <p>年龄:{{item.patient.age?item.patient.age:""}}岁</p>
13
+          </div>
14
+          <div class="infoMain">
15
+              <div style="margin-bottom: 10px;">门诊号:{{hisPatient.number?hisPatient.number:""}}</div>
16
+              <div style="margin-bottom: 10px;">科室:{{item.info?getDepart(item.info.departments):''}}</div>
17
+              <div style="margin-bottom: 10px;">医保卡号:{{item.hisPatient.number?item.hisPatient.number:""}}</div>
18
+              <div style="margin-bottom: 10px;">电话:{{item.patient.phone}}</div>
19
+              <div>地址:{{item.patient.home_address}}</div>
20
+              <div style="display:flex;width:50%;">临床诊断:{{getDiagnosis(item.info.diagnosis)}}</div>
21
+          </div>
22
+          <div class="prescriptionBox">
23
+              <div class="Rp">Rp:</div>
24
+              <div class="drugsBox" v-for="(it,index) in item.advices" :key="index">
25
+                  <!-- <div class="drugsOne"><span style="font-weight:bold;">{{ index+1 + '.' }}</span>{{it.advice_name?it.advice_name:""}}&nbsp;&nbsp;{{it.single_dose}}{{it.single_dose_unit}}&nbsp;×&nbsp; {{it.prescribing_number}}{{it.prescribing_number_unit}}</div> -->
26
+                  <div class="drugsOne"><span style="font-weight:bold;">{{ index+1 + '.' }}</span>{{it.advice_name?it.advice_name:""}}&nbsp;&nbsp;<span>用法:{{it.single_dose}}{{it.single_dose_unit}}</span>&nbsp;&nbsp;<span>{{it.execution_frequency}}&nbsp;{{it.delivery_way}}&nbsp;</span>&nbsp;&nbsp;<span>{{it.advice_desc}}</span></div>
27
+                  <div style="margin-left:100px;"><span>{{it.drug.drug_spec}}&nbsp;×&nbsp; {{it.prescribing_number}}{{it.prescribing_number_unit}}</span></div>
28
+              </div>
29
+              <div class="drugsBox" v-for="(it,i) in item.additionalcharge" :key="i">
30
+                <div class="drugsOne">{{it.item_name?it.item_name:""}}:&nbsp;{{it.price}}元/{{it.count}}次</div>
31
+               </div>
32
+               
33
+              <div class="drugsBox" v-for="(it,index) in item.project" :key="index">
34
+                  <div class="drugsOne"><span style="font-weight:bold;">{{ index+1 + '.' }}</span>{{getProjectName(it.project_id)?getProjectName(it.project_id):""}}&nbsp;&nbsp;<span>用法:{{it.single_dose}}{{it.single_dose_unit}}</span>&nbsp;&nbsp;<span>{{it.delivery_way}}</span>&nbsp;&nbsp;<span>{{it.advice_desc}}</span></div>
35
+                  <div style="margin-left:100px;"><span>{{it.single_dose}}{{it.single_dose_unit}}&nbsp;×&nbsp; {{it.count}}{{unit}}</span></div>
36
+              </div>
37
+              <div class="drugsBox" v-for="(it,i) in item.additionalcharge" :key="i">
38
+                <div class="drugsOne">{{it.project_id?it.project_id:""}}:&nbsp;{{it.price}}元/{{it.count}}次</div>
39
+               </div>
40
+               <div style="text-align:center;" >(以下空白)</div>
41
+
42
+          </div>
43
+          <div class="doctorBox">
44
+              <p>医师:{{item.doctor?item.doctor:""}}</p>
45
+              <p>日期:{{getTime(item.ctime)?getTime(item.ctime):""}}</p>
46
+          </div>
47
+          <div class="actionBar">
48
+                 <!-- <p>审核:{{getDoctor(item.advices[0].checker)?getDoctor(item.advices[0].checker):""}}</p>
49
+                 <p>配对:</p>
50
+                 <p>核对:{{getDoctor(item.advices[0].checker)?getDoctor(item.advices[0].checker):""}}</p>
51
+                 <p>发药:{{getDoctor(item.advices[0].execution_staff)?getDoctor(item.advices[0].execution_staff):""}}</p>
52
+                 <p>药费:{{getTotalOne(item.id)?getTotalOne(item.id):0}}元</p> -->
53
+
54
+                 <p>审核:</p>
55
+                 <p>配对:</p>
56
+                 <p>核对:</p>
57
+                 <p>发药:</p>
58
+                 <p>药费:{{getTotalOne(item.id).toFixed(2)?getTotalOne(item.id).toFixed(2):0}}元</p>
59
+          </div>
60
+          <div style="page-break-after:always"></div>
61
+      </div>
62
+    </div>
63
+    
64
+  </div>
65
+
66
+    
67
+</template>
68
+<script>
69
+import { jsGetAge, uParseTime } from '@/utils/tools'
70
+import {getAllDoctorList,getPrescriptionPrint,getHisPatientDetail} from "@/api/project/project"
71
+import {getInitData} from "@/api/his/his"
72
+export default {
73
+    props:{
74
+      patient_id:Number,
75
+      record_date:String,
76
+      prescription_id:Number,
77
+      ids:String
78
+    }, 
79
+    data(){
80
+      return {
81
+        doctorList:[],
82
+        advicePrint:{},
83
+        patient:{},
84
+        tableData:[],
85
+        prescriptionInfo:[],
86
+        hisPatient:{},
87
+        department:[],
88
+        prescriptions:[],
89
+        projectList:[],
90
+        orgname:"",
91
+        diagnoses:[],
92
+      }
93
+    },
94
+   methods:{
95
+     
96
+     getAllDoctorList(){
97
+      getAllDoctorList().then(response=>{
98
+        if(response.data.state == 1){
99
+               var doctor =  response.data.data.doctor
100
+               
101
+               this.doctorList = doctor
102
+             }
103
+         })   
104
+     },
105
+
106
+      getDoctor(id){
107
+        var name = ""
108
+        for(let i=0;i<this.doctorList.length;i++){
109
+          if(id == this.doctorList[i].admin_user_id){
110
+              name = this.doctorList[i].user_name
111
+          }
112
+        }
113
+        return name
114
+      },
115
+      getTime(value, temp) {
116
+        if (value != undefined) {
117
+            return uParseTime(value, temp)
118
+        }
119
+        return ''
120
+     },
121
+       getPrescriptionPrint(){
122
+         var params = {
123
+          // patient_id:this.patient_id,
124
+          // record_date:this.record_date,
125
+          // prescription_id:this.prescription_id,
126
+          patient_id:this.patient_id,
127
+          record_date:this.record_date,
128
+          prescription_id:this.prescription_id,
129
+          ids:this.ids
130
+        }
131
+        console.log("params",params)
132
+       getPrescriptionPrint(params).then(response=>{
133
+         if(response.data.state == 1){
134
+            var advicePrint =  response.data.data.advicePrint
135
+            console.log("adviceprint9999",advicePrint)
136
+            this.advicePrint = advicePrint
137
+            this.prescriptions = advicePrint
138
+            console.log("处方222222",this.prescriptions)
139
+            var hisPatient = response.data.data.hisPatient
140
+            console.log("hisPatient",hisPatient)
141
+            this.hisPatient = hisPatient
142
+            var projectlist =  response.data.data.projectlist
143
+            console.log("所有项目列表",projectlist)
144
+            this.projectList = projectlist
145
+          }
146
+       })
147
+     },
148
+     getHisPatientDetail(){
149
+          const params = {
150
+              patient_id:this.patient_id
151
+          }
152
+       getHisPatientDetail(params).then(response=>{
153
+          if(response.data.state == 1){
154
+             var hisPatient =  response.data.data.hisPatient
155
+             console.log("挂号病人",hisPatient)
156
+             this.hisPatient = hisPatient
157
+          }
158
+       })
159
+     },
160
+     getInitData(){
161
+       getInitData().then(response=>{
162
+          if(response.data.state == 1){
163
+            this.department = response.data.data.department
164
+            this.diagnoses = response.data.data.diagnose
165
+            console.log("争端",this.diagnoses)
166
+          }
167
+       })
168
+     },
169
+     getDepart(id){
170
+         var name = ""
171
+       for(let i=0;i<this.department.length;i++){
172
+           if(id == this.department[i].id){
173
+               name = this.department[i].name
174
+           }
175
+       }
176
+       return name
177
+     },
178
+    getTotalOne(id) {
179
+
180
+        var total = 0
181
+        var addtotal = 0
182
+        for (let i = 0; i < this.prescriptions.length; i++) {
183
+          if(id == this.prescriptions[i].id){
184
+            if (this.prescriptions[i].project != null) {
185
+              for (let a = 0; a < this.prescriptions[i].project.length; a++) {
186
+                total = total + this.prescriptions[i].project[a].price * this.prescriptions[i].project[a].count
187
+              }
188
+            }
189
+
190
+            if (this.prescriptions[i].additionalcharge != null) {
191
+              for (let a = 0; a < this.prescriptions[i].additionalcharge.length; a++) {
192
+                addtotal = addtotal + this.prescriptions[i].additionalcharge[a].price * this.prescriptions[i].additionalcharge[a].count
193
+              }
194
+            }
195
+              addtotal =  Math.floor(addtotal * 100) / 100
196
+        }
197
+       
198
+       }
199
+
200
+      for (let i = 0; i < this.prescriptions.length; i++) {
201
+          if(id == this.prescriptions[i].id){
202
+            if (this.prescriptions[i].advices != null) {
203
+              for (let a = 0; a < this.prescriptions[i].advices.length; a++) {
204
+                total = total + this.prescriptions[i].advices[a].price * this.prescriptions[i].advices[a].prescribing_number
205
+              }
206
+            }
207
+          
208
+            if (this.prescriptions[i].additionalcharge != null) {
209
+              for (let a = 0; a < this.prescriptions[i].additionalcharge.length; a++) {
210
+                addtotal = addtotal + this.prescriptions[i].additionalcharge[a].price * this.prescriptions[i].additionalcharge[a].count
211
+              }
212
+            }
213
+              addtotal =  Math.floor(addtotal * 100) / 100
214
+        }
215
+       }
216
+
217
+        return total + addtotal
218
+      },
219
+      
220
+     getProjectName(id){
221
+        var project_name = ""
222
+        for(let i=0;i<this.projectList.length;i++){
223
+           if(id == this.projectList[i].id){
224
+               project_name = this.projectList[i].project_name
225
+           }
226
+        }
227
+        return project_name
228
+     },
229
+
230
+     getDiagnosis(id){
231
+        var name = ""
232
+        for(let i=0;i<this.diagnoses.length;i++){
233
+          if(id == this.diagnoses[i].id){
234
+             name = this.diagnoses[i].class_name
235
+          }
236
+        }
237
+        return name
238
+     }
239
+
240
+   },
241
+   created(){
242
+      this.getAllDoctorList()
243
+      this.getInitData()
244
+      this.getPrescriptionPrint()
245
+      this.getHisPatientDetail()
246
+      var xtuser = this.$store.getters.xt_user;
247
+      this.orgname = xtuser.org.org_name;
248
+     
249
+   },
250
+   watch:{
251
+     ids:function(val){
252
+      this.ids = val
253
+      this.getPrescriptionPrint()
254
+    }
255
+   }
256
+}
257
+</script>
258
+
259
+
260
+<style lang="scss" scoped>
261
+.prescription-print{
262
+  -webkit-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 60px rgba(0, 0, 0, 0.06) inset;
263
+    -moz-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 40px rgba(0, 0, 0, 0.06) inset; 
264
+    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 40px rgba(0, 0, 0, 0.06) inset;
265
+    margin-bottom: 20px;
266
+    padding:20px 10px;
267
+}
268
+.printTitle{
269
+    font-size: 22px;
270
+    text-align: center;
271
+    font-weight: bold;
272
+}
273
+.infoTitle{
274
+    display: flex;
275
+    border-bottom: 2px solid #000;
276
+    margin-top:10px;
277
+    line-height: 24px;
278
+    padding:0 10px;
279
+}
280
+.infoTitle p{
281
+    width: 200px;
282
+}
283
+.infoMain{
284
+    display: flex;
285
+    flex-wrap: wrap;
286
+    border-bottom: 2px solid #000;
287
+    padding:0 10px;
288
+}
289
+.infoMain div{
290
+    width: 50%;
291
+    line-height: 24px;
292
+}
293
+.prescriptionBox{
294
+    padding:0 10px;
295
+    min-height:450px;
296
+}
297
+.Rp{
298
+    font-size: 22px;
299
+    font-weight: bold;
300
+}
301
+.drugsBox{
302
+    padding-left: 40px;
303
+    margin-bottom: 10px;
304
+}
305
+.drugsBox div{
306
+    line-height: 20px;
307
+}
308
+.drugsOne{
309
+    line-height: 24px;
310
+}
311
+.drugsOne span{
312
+    margin-right: 20px;
313
+}
314
+.doctorBox{
315
+    display: flex;
316
+    justify-content: space-between;
317
+    padding:0 10px;
318
+    line-height: 24px;
319
+    border-bottom: 2px solid #000;
320
+}
321
+.actionBar{
322
+    display: flex;
323
+    justify-content: space-between; 
324
+    line-height: 24px;
325
+    padding:0 10px;
326
+}
327
+.actionBar p{
328
+    width:150px;
329
+}
330
+</style>

+ 14 - 14
src/xt_pages/outpatientDoctorStation/template/printOne.vue Целия файл

@@ -29,9 +29,9 @@
29 29
               <div class="drugsBox" v-for="(it,i) in item.additionalcharge" :key="i">
30 30
                 <div class="drugsOne">{{it.item_name?it.item_name:""}}:&nbsp;{{it.price}}元/{{it.count}}次</div>
31 31
                </div>
32
-               
32
+
33 33
               <div class="drugsBox" v-for="(it,index) in item.project" :key="index">
34
-                  <div class="drugsOne"><span style="font-weight:bold;">{{ index+1 + '.' }}</span>{{getProjectName(it.project_id)?getProjectName(it.project_id):""}}&nbsp;&nbsp;{{it.single_dose}}{{it.single_dose_unit}}&nbsp;×&nbsp; {{it.count}}{{unit}}</div>
34
+                  <div class="drugsOne"><span style="font-weight:bold;">{{ index+1 + '.' }}</span>{{it.type == 2?getProjectName(it.project_id)?getProjectName(it.project_id):"":it.good_info.good_name}}&nbsp;&nbsp;{{it.single_dose}}{{it.single_dose_unit}}&nbsp;×&nbsp; {{it.count}}{{unit}}</div>
35 35
                   <div style="margin-left:100px;"><span>用法:{{it.single_dose}}{{it.single_dose_unit}}</span>&nbsp;&nbsp;<span>{{it.delivery_way}}</span>&nbsp;&nbsp;<span>{{it.advice_desc}}</span></div>
36 36
               </div>
37 37
               <div class="drugsBox" v-for="(it,i) in item.additionalcharge" :key="i">
@@ -60,10 +60,10 @@
60 60
           <div style="page-break-after:always"></div>
61 61
       </div>
62 62
     </div>
63
-    
63
+
64 64
   </div>
65 65
 
66
-    
66
+
67 67
 </template>
68 68
 <script>
69 69
 import { jsGetAge, uParseTime } from '@/utils/tools'
@@ -75,7 +75,7 @@ export default {
75 75
       record_date:String,
76 76
       prescription_id:Number,
77 77
       ids:String
78
-    }, 
78
+    },
79 79
     data(){
80 80
       return {
81 81
         doctorList:[],
@@ -92,15 +92,15 @@ export default {
92 92
       }
93 93
     },
94 94
    methods:{
95
-     
95
+
96 96
      getAllDoctorList(){
97 97
       getAllDoctorList().then(response=>{
98 98
         if(response.data.state == 1){
99 99
                var doctor =  response.data.data.doctor
100
-               
100
+
101 101
                this.doctorList = doctor
102 102
              }
103
-         })   
103
+         })
104 104
      },
105 105
 
106 106
       getDoctor(id){
@@ -194,7 +194,7 @@ export default {
194 194
             }
195 195
               addtotal =  Math.floor(addtotal * 100) / 100
196 196
         }
197
-       
197
+
198 198
        }
199 199
 
200 200
       for (let i = 0; i < this.prescriptions.length; i++) {
@@ -204,7 +204,7 @@ export default {
204 204
                 total = total + this.prescriptions[i].advices[a].price * this.prescriptions[i].advices[a].prescribing_number
205 205
               }
206 206
             }
207
-          
207
+
208 208
             if (this.prescriptions[i].additionalcharge != null) {
209 209
               for (let a = 0; a < this.prescriptions[i].additionalcharge.length; a++) {
210 210
                 addtotal = addtotal + this.prescriptions[i].additionalcharge[a].price * this.prescriptions[i].additionalcharge[a].count
@@ -216,7 +216,7 @@ export default {
216 216
 
217 217
         return total + addtotal
218 218
       },
219
-      
219
+
220 220
      getProjectName(id){
221 221
         var project_name = ""
222 222
         for(let i=0;i<this.projectList.length;i++){
@@ -245,7 +245,7 @@ export default {
245 245
       this.getHisPatientDetail()
246 246
       var xtuser = this.$store.getters.xt_user;
247 247
       this.orgname = xtuser.org.org_name;
248
-     
248
+
249 249
    },
250 250
    watch:{
251 251
      ids:function(val){
@@ -260,7 +260,7 @@ export default {
260 260
 <style lang="scss" scoped>
261 261
 .prescription-print{
262 262
   -webkit-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 60px rgba(0, 0, 0, 0.06) inset;
263
-    -moz-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 40px rgba(0, 0, 0, 0.06) inset; 
263
+    -moz-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 40px rgba(0, 0, 0, 0.06) inset;
264 264
     box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 40px rgba(0, 0, 0, 0.06) inset;
265 265
     margin-bottom: 20px;
266 266
     padding:20px 10px;
@@ -320,7 +320,7 @@ export default {
320 320
 }
321 321
 .actionBar{
322 322
     display: flex;
323
-    justify-content: space-between; 
323
+    justify-content: space-between;
324 324
     line-height: 24px;
325 325
     padding:0 10px;
326 326
 }

+ 2 - 2
src/xt_pages/outpatientDoctorStation/treatTemplate/printOne.vue Целия файл

@@ -50,7 +50,7 @@
50 50
                 </tr>
51 51
                 <tr v-for="(it,index) in item.project" :key="index">
52 52
                     <td>{{index+1}}</td>
53
-                    <td>{{getProjectName(it.project_id)}}</td>
53
+                    <td>{{it.type == 2 ?getProjectName(it.project_id):it.good_info.good_name}}</td>
54 54
                     <td>{{it.single_dose}}</td>
55 55
                     <td>{{getUnit(it.unit)}}</td>
56 56
                     <td>{{it.price}}</td>
@@ -481,4 +481,4 @@ export default {
481 481
 .actionBar div{
482 482
     width:150px;
483 483
 }
484
-</style>
484
+</style>

+ 0 - 0
src/xt_pages/outpatientRegistration/index.vue Целия файл


Някои файлове не бяха показани, защото твърде много файлове са промени