Browse Source

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

csx 3 years ago
parent
commit
4c58f30391
61 changed files with 6247 additions and 512 deletions
  1. 9 0
      src/api/drug/drug_stock.js
  2. 53 0
      src/api/schedule.js
  3. 9 1
      src/api/stock.js
  4. 11 0
      src/router/modules/dialysis.js
  5. 22 11
      src/router/modules/workforce.js
  6. 1 1
      src/views/layout/Layout.vue
  7. 1 1
      src/views/layout/components/Sidebar/index.vue
  8. 8 8
      src/xt_pages/dialysis/batch_print/batch_print_order_fifteen.vue
  9. 2 0
      src/xt_pages/dialysis/batch_print/batch_print_order_thirty.vue
  10. 1 1
      src/xt_pages/dialysis/components/dialysisDrugs.vue
  11. 1 1
      src/xt_pages/dialysis/details/BasicInfor.vue
  12. 18 2
      src/xt_pages/dialysis/details/DialysisPrescription.vue
  13. 11 1
      src/xt_pages/dialysis/details/acceptsAssessment.vue
  14. 33 3
      src/xt_pages/dialysis/details/assessmentAfter.vue
  15. 64 9
      src/xt_pages/dialysis/details/dialog/AssessmentAfterDislysis.vue
  16. 17 1
      src/xt_pages/dialysis/details/dialog/acceptsTreatmentDialog.vue
  17. 6 0
      src/xt_pages/dialysis/details/dialog/assessmentBeforeDislysisDialog.vue
  18. 31 4
      src/xt_pages/dialysis/details/dialog/dialysisPrescriptionDialog.vue
  19. 26 9
      src/xt_pages/dialysis/details/dialog/doubleCheckDialog.vue
  20. 6 2
      src/xt_pages/dialysis/details/dialog/monitor_dialog.vue
  21. 4 4
      src/xt_pages/dialysis/details/dialysisMonitoring.vue
  22. 49 3
      src/xt_pages/dialysis/dialysisDoctorAdvice.vue
  23. 24 0
      src/xt_pages/dialysis/dialysisPrintOrder.vue
  24. 692 0
      src/xt_pages/dialysis/signPrint.vue
  25. 23 9
      src/xt_pages/dialysis/template/DialysisPrintOrderThirtyEight.vue
  26. 1438 0
      src/xt_pages/dialysis/template/DialysisPrintOrderThirtyNine.vue
  27. 16 2
      src/xt_pages/dialysis/template/DialysisPrintOrderTwentyFour.vue
  28. 2 1
      src/xt_pages/dialysis/template/DialysisPrintOrderTwentySeven.vue
  29. 10 5
      src/xt_pages/outpatientCharges/invoicePrint.vue
  30. 221 0
      src/xt_pages/outpatientCharges/invoiceTemplate/printTwo.vue
  31. 1 1
      src/xt_pages/outpatientCharges/listPrint.vue
  32. 77 4
      src/xt_pages/outpatientCharges/summary.vue
  33. 6 3
      src/xt_pages/outpatientDoctorStation/components/deskPrescription.vue
  34. 939 0
      src/xt_pages/outpatientDoctorStation/components/dialysisIndex.vue
  35. 3 1
      src/xt_pages/outpatientDoctorStation/components/inquiriesDetail.vue
  36. 14 10
      src/xt_pages/outpatientDoctorStation/components/prescriptionTable.vue
  37. 3 8
      src/xt_pages/outpatientRegistration/index.vue
  38. 10 10
      src/xt_pages/qcd/basicInformationAnalysis.vue
  39. 19 10
      src/xt_pages/stock/detail/print.vue
  40. 54 27
      src/xt_pages/stock/detail/stockInDetail.vue
  41. 4 5
      src/xt_pages/stock/detail/stockOutDetail.vue
  42. 9 3
      src/xt_pages/stock/drugs/components/drugOutDetail.vue
  43. 2 2
      src/xt_pages/stock/drugs/drugCancelDetailPrint.vue
  44. 2 2
      src/xt_pages/stock/drugs/drugCancelOurderPrint.vue
  45. 2 1
      src/xt_pages/stock/drugs/drugOutOrderPrint.vue
  46. 2 2
      src/xt_pages/stock/drugs/drugQueryPrint.vue
  47. 15 11
      src/xt_pages/stock/drugs/drugStockInOrderDetailPrint.vue
  48. 59 9
      src/xt_pages/stock/drugs/drugStockOutOrderDetailPrint.vue
  49. 1 1
      src/xt_pages/stock/drugs/query.vue
  50. 2 2
      src/xt_pages/stock/stockOutOrderDetail.vue
  51. 59 6
      src/xt_pages/stock/stockOutOrderDetailPrint.vue
  52. 4 3
      src/xt_pages/stock/stockPrint.vue
  53. 3 1
      src/xt_pages/stock/stockQuery.vue
  54. 26 29
      src/xt_pages/workforce/appointment.vue
  55. 171 34
      src/xt_pages/workforce/components/nextTableWeeks.vue
  56. 263 41
      src/xt_pages/workforce/components/tableData.vue
  57. 212 83
      src/xt_pages/workforce/components/tableWeeks.vue
  58. 114 37
      src/xt_pages/workforce/next_remind_print.vue
  59. 128 85
      src/xt_pages/workforce/remind_print.vue
  60. 378 2
      src/xt_pages/workforce/remind_print_setting.vue
  61. 856 0
      src/xt_pages/workforce/scheduleTablePrint.vue

+ 9 - 0
src/api/drug/drug_stock.js View File

@@ -428,6 +428,15 @@ export function getDrugAutoMaticList(params){
428 428
 }
429 429
 
430 430
 
431
+export function getDrugWarehouseOrderInfo(params){
432
+   
433
+  return request({
434
+    url:"/api/drugstock/getdrugwarehouseorderinfo",
435
+    method:"get",
436
+    params:params
437
+  })
438
+}
439
+
431 440
 
432 441
 
433 442
 

+ 53 - 0
src/api/schedule.js View File

@@ -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',
@@ -167,4 +184,40 @@ export function getRemindPrintList(params){
167 184
     method:"get",
168 185
     params:params
169 186
   })
187
+}
188
+
189
+export function getScheduleList(params){
190
+  
191
+  return request({
192
+    url:"/api/schedule/getbloodschedulelist",
193
+    method:"get",
194
+    params:params,
195
+  })
196
+}
197
+
198
+export function getPrintList(params){
199
+   
200
+  return request({
201
+    url:"/api/schedule/getprintlist",
202
+    method:"Get",
203
+    params:params,
204
+  })
205
+}
206
+
207
+export function getAllZoneList(params){
208
+  
209
+  return request({
210
+    url:"/api/schedule/getallzonelist",
211
+    method:"get",
212
+    params:params
213
+  })
214
+}
215
+
216
+export function getPatientSheduleCount(params){
217
+   
218
+  return request({
219
+    url:"/api/schedule/getpatientschedulecount",
220
+    method:"get",
221
+    params:params
222
+  })
170 223
 }

+ 9 - 1
src/api/stock.js View File

@@ -610,4 +610,12 @@ export function getInitializtion(params){
610 610
     method:"get",
611 611
     params:params
612 612
   })
613
-}
613
+}
614
+
615
+export function getWarehouseOrderInfoList(params){
616
+   return request({
617
+      url:"/api/good/getwarehouseorderinfolist",
618
+      method:"get",
619
+      params:params
620
+   })
621
+} 

+ 11 - 0
src/router/modules/dialysis.js View File

@@ -58,6 +58,17 @@ export default {
58 58
         noCache: true
59 59
       }
60 60
     },
61
+    {
62
+      path: '/dialysis/signPrint',
63
+      component: () => import('@/xt_pages/dialysis/signPrint'),
64
+      name: '标签打印',
65
+      hidden: true,
66
+      is_menu: false,
67
+      meta: {
68
+        title: '标签打印',
69
+        noCache: true
70
+      }
71
+    },
61 72
     {
62 73
       path: '/dialysis/consumableDrugs',
63 74
       component: () => import('@/xt_pages/dialysis/consumableDrugs'),

+ 22 - 11
src/router/modules/workforce.js View File

@@ -82,16 +82,27 @@ export default {
82 82
         noCache: true
83 83
       }
84 84
     },
85
-    // {
86
-    //   path: '/schedule/remind/print/setting',
87
-    //   component: () => import('@/xt_pages/workforce/remind_print_setting'),
88
-    //   name: 'remind_print_setting',
89
-    //   hidden: true,
90
-    //   is_menu: false,
91
-    //   meta: {
92
-    //     title: 'remind_print_setting',
93
-    //     noCache: true
94
-    //   }
95
-    // },
85
+    {
86
+      path: '/schedule/remind/print/setting',
87
+      component: () => import('@/xt_pages/workforce/remind_print_setting'),
88
+      name: 'remind_print_setting',
89
+      hidden: true,
90
+      is_menu: false,
91
+      meta: {
92
+        title: 'remind_print_setting',
93
+        noCache: true
94
+      }
95
+    },
96
+    {
97
+      path: '/scheduleTablePrint',
98
+      component: () => import('@/xt_pages/workforce/scheduleTablePrint'),
99
+      name: 'scheduleTablePrint',
100
+      hidden: true,
101
+      is_menu: false,
102
+      meta: {
103
+        title: 'scheduleTablePrint',
104
+        noCache: true
105
+      }
106
+    },
96 107
   ]
97 108
 }

+ 1 - 1
src/views/layout/Layout.vue View File

@@ -123,7 +123,7 @@ export default {
123 123
   },
124 124
   created(){
125 125
     console.log('permission_routers',this.permission_routers);
126
-    let menzhen = ['outpatientRegistration','outpatientDoctorStation','outpatientCharges','outpatientPharmacy','outpatientRecord','hospitalStation'];
126
+    let menzhen = ['hospitalStation','outpatientRegistration','outpatientDoctorStation','outpatientCharges','outpatientPharmacy','outpatientRecord',];
127 127
     let bingli = ['User','createPatient'];
128 128
     let touxi = ['home','workforce', 'dialysisrecord', 'dialysis', 'medicalScheduling', 'signIndex', 'qcd', 'device', 'quality_control'];
129 129
     let kucun = ['stockManage','stockDrugs','selfPreparedMedicine','otherManagement'];

+ 1 - 1
src/views/layout/components/Sidebar/index.vue View File

@@ -69,7 +69,7 @@ export default {
69 69
     navTitle:{
70 70
       handler(newVal,oldVal){
71 71
         if(newVal == '门诊管理'){
72
-          let nameArr = ['outpatientRegistration','outpatientDoctorStation','outpatientCharges','outpatientPharmacy','outpatientRecord','hospitalStation'];
72
+          let nameArr = ['hospitalStation','outpatientRegistration','outpatientDoctorStation','outpatientCharges','outpatientPharmacy','outpatientRecord',];
73 73
           // console.log('permission_routers',this.permission_routers)
74 74
           let routerArr = [];
75 75
           this.permission_routers.map(item => {

+ 8 - 8
src/xt_pages/dialysis/batch_print/batch_print_order_fifteen.vue View File

@@ -56,7 +56,7 @@
56 56
                                     <label-box showValue="住院" :isChecked="record.receive_assessment.condition == 1 ? true : false"></label-box>
57 57
                                 </td>
58 58
                                 <td style="padding-left:5px;width:25%;text-align:left;border-left:none;border-right:none;">其他</td>
59
-                                
59
+
60 60
                             </tr>
61 61
                         </table>
62 62
                         <table class="table-box" border="1" style="border:none;border-color:#000;border-collapse: collapse;">
@@ -221,8 +221,8 @@
221 221
                                     </span>
222 222
                                 </span>
223 223
                             <!-- </span> -->
224
-                            
225
-                            
224
+
225
+
226 226
                         </span>
227 227
                     </td>
228 228
                     <td>
@@ -282,7 +282,7 @@
282 282
                         <p style="height:20px;line-height:20px">电导率</p>
283 283
                         <p style="height:20px;line-height:20px">ms/cm</p>
284 284
                     </th>
285
-                    
285
+
286 286
                     <th style="min-width:60px">
287 287
                         <p style="height:20px;line-height:20px">温度</p>
288 288
                         <p style="height:20px;line-height:20px">℃</p>
@@ -332,7 +332,7 @@
332 332
                         </span>
333 333
                     </td>
334 334
 
335
-                    
335
+
336 336
                     </tr>
337 337
                 </table>
338 338
                 <table class="print-table" border="1">
@@ -444,9 +444,9 @@
444 444
                     </tr>
445 445
                     </tbody>
446 446
                 </table>
447
-                
447
+
448 448
                 <table class="print-table" border="1">
449
-                    
449
+
450 450
                 </table>
451 451
 
452 452
 
@@ -575,7 +575,7 @@ export default {
575 575
     this.precaution_arr = getDataConfig('hemodialysis', 'precaution')
576 576
   },
577 577
   mounted() {
578
-    console.log(this.records)
578
+    // console.log(this.records)
579 579
     this.loading = true
580 580
     var ids = this.$store.getters.temp_params.batch_print_dialysis_record_ids
581 581
     if (ids.length == 0) {

+ 2 - 0
src/xt_pages/dialysis/batch_print/batch_print_order_thirty.vue View File

@@ -154,6 +154,8 @@
154 154
                                         &nbsp;
155 155
                                         <label-box :isChecked="isBbloodAccessParOperaCheck(record.assessment_before_dislysis, '人造血管')" showValue="人造血管"></label-box>
156 156
                                         &nbsp;
157
+                                         <label-box :isChecked="isBbloodAccessParOperaCheck(record.assessment_before_dislysis, '扣眼')" showValue="扣眼"></label-box>
158
+                                        &nbsp;
157 159
                                     </div>
158 160
                                 </td>
159 161
                                 <td width='20'></td>

+ 1 - 1
src/xt_pages/dialysis/components/dialysisDrugs.vue View File

@@ -510,7 +510,7 @@ export default {
510 510
                 }
511 511
             })
512 512
             this.indexInfoList = newArr
513
-            console.log("过年9999999999",this.scheduleMap)
513
+           
514 514
            }
515 515
          
516 516
   

+ 1 - 1
src/xt_pages/dialysis/details/BasicInfor.vue View File

@@ -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>

+ 18 - 2
src/xt_pages/dialysis/details/DialysisPrescription.vue View File

@@ -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.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.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.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>
111 111
         </li>
112 112
         <li v-if="isShow('葡萄糖')">
113 113
           <label>葡萄糖 : </label>
@@ -323,6 +323,22 @@
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
+
326 342
       </ul>
327 343
     </div>
328 344
     <div style="color:#34495e;margin: 12px 100px 0 100px;">备注: <span style="color:#409eff;">{{ note }}</span></div>

+ 11 - 1
src/xt_pages/dialysis/details/acceptsAssessment.vue View File

@@ -83,6 +83,9 @@
83 83
           <span class="content">{{sickCondition}} </span>
84 84
         </li>
85 85
 
86
+
87
+       
88
+
86 89
         <li v-if="isShow('风险程度')">
87 90
           <label>风险程度:</label>
88 91
           <span class="content">{{ dangerLevel }}</span>
@@ -103,7 +106,14 @@
103 106
             this.record.psychological_assessment_other
104 107
           }}</span>
105 108
         </li>
106
-
109
+        
110
+       <li v-if="isShow('是否跌倒')">
111
+          <label>是否跌倒:</label>
112
+          <span class="content">
113
+            <span v-if="this.record.tumble == 1">是</span>
114
+            <span v-if="this.record.tumble == 2">否</span>
115
+          </span>
116
+        </li>
107 117
 
108 118
       </ul>
109 119
 

+ 33 - 3
src/xt_pages/dialysis/details/assessmentAfter.vue View File

@@ -17,8 +17,8 @@
17 17
           <span class="content" v-if="actual_ultrafiltration != '0'">{{
18 18
             actual_ultrafiltration
19 19
           }}</span>
20
-          <span class="unit" v-if=" actual_ultrafiltration != '0' && (this.$store.getters.xt_user.template_info.template_id == 6 || this.$store.getters.xt_user.template_info.template_id == 9 || this.$store.getters.xt_user.template_info.template_id == 17 || 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.org_id == 9555) " >ml</span>
21
-          <span class="unit" v-if=" actual_ultrafiltration != '0' && this.$store.getters.xt_user.template_info.template_id != 6 && this.$store.getters.xt_user.template_info.template_id != 9 && this.$store.getters.xt_user.template_info.template_id != 17 && 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.org_id == 9555 " >L</span>
20
+          <span class="unit" v-if=" actual_ultrafiltration != '0' && (this.$store.getters.xt_user.template_info.template_id == 6 || this.$store.getters.xt_user.template_info.template_id == 9 || this.$store.getters.xt_user.template_info.template_id == 17 || 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) " >ml</span>
21
+          <span class="unit" v-if=" actual_ultrafiltration != '0' && this.$store.getters.xt_user.template_info.template_id != 6 && this.$store.getters.xt_user.template_info.template_id != 9 && this.$store.getters.xt_user.template_info.template_id != 17 && 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 " >L</span>
22 22
         </li>
23 23
         <li v-if="isShow('导管')">
24 24
           <label>导管 : </label>
@@ -300,6 +300,14 @@
300 300
           <label>KT/V: </label>
301 301
           <span class="content" >{{ this.record.ktv ? this.record.ktv : ""  }}</span>
302 302
         </li>
303
+        <li v-if="isShow('意识')">
304
+          <label>意识: </label>
305
+          <span class="content" >{{ getConsciousness(this.record.consciousness)}}</span>
306
+        </li>
307
+        <li v-if="isShow('跌倒风险')">
308
+          <label>跌倒风险: </label>
309
+          <span class="content" >{{ getFallrisk(this.record.fallrisk)}}</span>
310
+        </li>
303 311
       </ul>
304 312
     </div>
305 313
     <div class="note">
@@ -640,7 +648,8 @@ export default {
640 648
         return ''
641 649
       }
642 650
       return this.record.in_advance_reason_other
643
-    }
651
+    },
652
+   
644 653
   },
645 654
   methods: {
646 655
     getInternal: function() {
@@ -775,6 +784,27 @@ export default {
775 784
         }
776 785
       }
777 786
       return false
787
+    },
788
+     getConsciousness:function(id){
789
+       var consciousnessList = getDataConfig("hemodialysis","consciousness")
790
+     
791
+       var name = ""
792
+       for(let i=0;i<consciousnessList.length;i++){
793
+         if(id == consciousnessList[i].id){
794
+           name= consciousnessList[i].name
795
+         }
796
+      }
797
+      return name
798
+    },
799
+    getFallrisk:function(id){
800
+      var fallriskList = getDataConfig("hemodialysis","fallrisk")
801
+      var name = ""
802
+      for(let i=0;i<fallriskList.length;i++){
803
+        if(id == fallriskList[i].id){
804
+           name = fallriskList[i].name
805
+        }
806
+      }
807
+      return name
778 808
     }
779 809
   }
780 810
 }

+ 64 - 9
src/xt_pages/dialysis/details/dialog/AssessmentAfterDislysis.vue View File

@@ -28,7 +28,7 @@
28 28
           <el-col :span="8" v-if="isShow('实际超滤量')">
29 29
             <el-form-item
30 30
               label="实际超滤量(ml): "
31
-              v-if=" this.template_id == 6 || this.template_id == 9 || this.template_id == 10 || this.template_id == 11  || this.template_id == 17 || this.template_id == 20 || this.template_id == 21 || this.template_id == 22 || this.template_id == 23 || this.template_id == 24 || this.template_id == 26 || this.template_id == 28 || this.template_id == 27 || this.template_id == 29 || this.template_id == 30 || this.template_id == 31 || this.template_id == 32 || this.template_id == 34 || this.template_id == 36 || this.$store.getters.xt_user.template_info.org_id == 9555 "  >
31
+              v-if=" this.template_id == 6 || this.template_id == 9 || this.template_id == 10 || this.template_id == 11  || this.template_id == 17 || this.template_id == 20 || this.template_id == 21 || this.template_id == 22 || this.template_id == 23 || this.template_id == 24 || this.template_id == 26 || this.template_id == 28 || this.template_id == 27 || this.template_id == 29 || this.template_id == 30 || this.template_id == 31 || this.template_id == 32 || this.template_id == 34 || this.template_id == 36 || this.template_id == 38 || this.$store.getters.xt_user.template_info.org_id == 9555 "  >
32 32
               <el-input v-model="form.actual_ultrafiltration"></el-input>
33 33
             </el-form-item>
34 34
             <el-form-item label="实际超滤量(L): " v-else>
@@ -588,7 +588,7 @@
588 588
               <el-input v-model="form.dosage_of_anticoagulants"></el-input>
589 589
           </el-form-item>
590 590
         </el-col>
591
-        
591
+
592 592
 
593 593
         <el-col :span="8" v-if="isShow('并发症其他')">
594 594
           <el-form-item label="并发症其他: ">
@@ -603,21 +603,23 @@
603 603
         </el-col>
604 604
         <el-col :span="8" v-if="isShow('透析相关高血压')">
605 605
             <el-form-item label="透析相关高血压:">
606
+
606 607
              <el-select v-model="form.hypertenison">
608
+              <el-option :key="0" label="请选择" :value="0"></el-option>
607 609
               <el-option
608 610
                 v-for="item in option"
609 611
                 :label="item.name"
610 612
                 :value="item.id"
611 613
                 :key="item.id"
612 614
               ></el-option>
613
-             </el-select>
615
+            </el-select>
614 616
             </el-form-item>
615 617
         </el-col>
616 618
          <el-col :span="8" v-if="isShow('透析相关低血压')">
617 619
             <el-form-item label="透析相关低血压">
618 620
              <el-select v-model="form.hypopiesia">
619 621
               <el-option
620
-                v-for="item in option"
622
+                v-for="item in optionOne"
621 623
                 :label="item.name"
622 624
                 :value="item.id"
623 625
                 :key="item.id"
@@ -649,13 +651,37 @@
649 651
              </el-select>
650 652
             </el-form-item>
651 653
         </el-col>
654
+        <el-col :span="8" v-if="isShow('意识')">
655
+            <el-form-item label="意识">
656
+             <el-select v-model="form.consciousness">
657
+              <el-option
658
+                v-for="item in consciousnessList"
659
+                :label="item.name"
660
+                :value="item.id"
661
+                :key="item.id"
662
+              ></el-option>
663
+             </el-select>
664
+            </el-form-item>
665
+        </el-col>
666
+        <el-col :span="8" v-if="isShow('跌倒风险')">
667
+            <el-form-item label="跌倒风险">
668
+             <el-select v-model="form.fallrisk">
669
+              <el-option
670
+                v-for="item in fallriskList"
671
+                :label="item.name"
672
+                :value="item.id"
673
+                :key="item.id"
674
+              ></el-option>
675
+             </el-select>
676
+            </el-form-item>
677
+        </el-col>
652 678
         <el-col :span="24" v-if="isShow('KT/V')">
653 679
             <el-form-item label="KT/V:">
654 680
               <el-input type="textarea" :rows="4" v-model="form.ktv"></el-input>
655 681
             </el-form-item>
656 682
         </el-col>
657 683
       </el-form>
658
-         
684
+
659 685
 
660 686
       <span slot="footer" class="dialog-footer">
661 687
         <el-button @click="hide">取 消</el-button>
@@ -739,7 +765,10 @@ export default {
739 765
       dialogCruorTitle: '凝血',
740 766
       sealing_fluid_special_name: '',
741 767
       option:[
742
-        {id:0,name:"请选择"},
768
+        {id:"1",name:"有"},
769
+        {id:"2",name:"无"},
770
+      ],
771
+       optionOne:[
743 772
         {id:"1",name:"有"},
744 773
         {id:"2",name:"无"},
745 774
       ],
@@ -814,9 +843,17 @@ export default {
814 843
         other_complication:'',
815 844
         ktv:"",
816 845
         urr:"",
846
+        hypertenison:"",
847
+        hypopiesia:"",
848
+        leave_office_method:"",
849
+        lapse:"",
850
+        consciousness:"",
851
+        fallrisk:"",
817 852
       },
818 853
       lapseList:[],
819
-      leaveOfficeMethod:[]
854
+      leaveOfficeMethod:[],
855
+      consciousnessList:[],
856
+      fallriskList:[]
820 857
     }
821 858
   },
822 859
   watch: {
@@ -1025,6 +1062,8 @@ export default {
1025 1062
       data["hypopiesia"] = parseInt(this.form.hypopiesia)
1026 1063
       data["leave_office_method"] = this.form.leave_office_method
1027 1064
       data["lapse"] = this.form.lapse
1065
+      data["consciousness"] = this.form.consciousness
1066
+      data["fallrisk"] = this.form.fallrisk
1028 1067
       console.log("Paramsquery",data)
1029 1068
       postAssessmentAfterDislysis(ParamsQuery, data)
1030 1069
         .then(response => {
@@ -1170,13 +1209,26 @@ export default {
1170 1209
 
1171 1210
     // 数据开始
1172 1211
     show(predialysis,last_after) {
1212
+      console.log("predialysis",predialysis)
1173 1213
       this.isVisibility = true
1174 1214
       this.predialysis = predialysis
1175 1215
       this.form.observation_content = predialysis.observation_content
1176 1216
       this.form.inpatient_department = predialysis.inpatient_department
1177 1217
       this.form.observation_content_other = predialysis.observation_content_other
1178
-      this.form.hypertenison = predialysis.hypertenison.toString()
1179
-      this.form.hypopiesia = predialysis.hypopiesia.toString()
1218
+      if(predialysis.id > 0){
1219
+        this.form.hypertenison = predialysis.hypertenison.toString()
1220
+      }
1221
+      if(predialysis.id > 0){
1222
+        this.form.hypopiesia = predialysis.hypopiesia.toString()
1223
+      }
1224
+      if(predialysis.id > 0){
1225
+         this.form.hypertenison = predialysis.hypertenison.toString()
1226
+      }
1227
+      if(predialysis.id > 0){
1228
+        this.form.hypopiesia = predialysis.hypopiesia.toString()
1229
+      }
1230
+
1231
+
1180 1232
       this.form.leave_office_method = predialysis.leave_office_method
1181 1233
       this.form.lapse = predialysis.lapse
1182 1234
       // console.log("透后", predialysis);
@@ -1292,11 +1344,14 @@ export default {
1292 1344
     this.sealingFluidDisposeOptions = getDataConfig('hemodialysis', 'sealing_fluid_dispose')
1293 1345
     this.lapseList = getDataConfig('hemodialysis', 'lapse')
1294 1346
     this.leaveOfficeMethod = getDataConfig('hemodialysis','leave_office_method')
1347
+    this.consciousnessList = getDataConfig("hemodialysis","consciousness")
1348
+    this.fallriskList = getDataConfig("hemodialysis","fallrisk")
1295 1349
     this.internalFistulaTremorAcOptions = this.$store.getters.internal_fistula_tremor_ac
1296 1350
     this.patientGoseOptions = this.$store.getters.patient_gose
1297 1351
     this.observationContentOptions = this.$store.getters.observation_content
1298 1352
     this.template_id = this.$store.getters.xt_user.template_info.template_id
1299 1353
     this.channels = this.$store.getters.channels
1354
+
1300 1355
     var date = this.$route.query && this.$route.query.date
1301 1356
     this.record_date = uParseTime(date, '{y}-{m}-{d}')
1302 1357
   },

+ 17 - 1
src/xt_pages/dialysis/details/dialog/acceptsTreatmentDialog.vue View File

@@ -229,6 +229,17 @@
229 229
           v-model="receiveTreatmentAsses.psychological_other"
230 230
         ></el-input>
231 231
       </el-form-item>
232
+        <el-form-item label="是否跌倒: " v-if="isShow('是否跌倒')">
233
+        <el-radio
234
+          v-model="receiveTreatmentAsses.tumble"
235
+          label="1"
236
+          >是</el-radio>
237
+        <el-radio
238
+          v-model="receiveTreatmentAsses.tumble"
239
+          label="2"
240
+          >否
241
+        </el-radio>
242
+      </el-form-item>
232 243
     </el-form>
233 244
     <div slot="footer" class="dialog-footer">
234 245
       <el-button @click="handleCancle">取 消</el-button>
@@ -281,7 +292,8 @@ export default {
281 292
         precaution: "",
282 293
         precaution_other: "",
283 294
         admission_number: "",
284
-        diacrisis:""
295
+        diacrisis:"",
296
+        tumble:"",
285 297
       },
286 298
       precautionTwo: []
287 299
     };
@@ -301,6 +313,10 @@ export default {
301 313
       return false;
302 314
     },
303 315
     show(accepts) {
316
+      console.log("accepts333333",accepts)
317
+      if(accepts.id > 0){
318
+        accepts.tumble = accepts.tumble.toString()
319
+      }
304 320
       this.accepts = accepts;
305 321
       // console.log("accepts", accepts);
306 322
       var arr = [];

+ 6 - 0
src/xt_pages/dialysis/details/dialog/assessmentBeforeDislysisDialog.vue View File

@@ -828,6 +828,12 @@
828 828
           if (this.lastPredialysisEvaluation.is_infect == 2) {
829 829
             this.lastPredialysisEvaluation.is_infect = "2"
830 830
           }
831
+          if(this.lastPredialysisEvaluation.period == 1){
832
+             this.lastPredialysisEvaluation.period = "1"
833
+          }
834
+          if(this.lastPredialysisEvaluation.period == 2){
835
+             this.lastPredialysisEvaluation.period = "2"
836
+          }
831 837
         }
832 838
 
833 839
 

+ 31 - 4
src/xt_pages/dialysis/details/dialog/dialysisPrescriptionDialog.vue View File

@@ -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.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.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.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.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> -->
@@ -325,14 +340,14 @@
325 340
             </el-form-item>
326 341
           </el-col>
327 342
 
328
-          <el-col :span="8" v-if="isShows('葡萄糖')">
343
+          <!-- <el-col :span="8" v-if="isShows('葡萄糖')">
329 344
             <el-form-item label="葡萄糖(mmol/L):">
330 345
               <el-input
331 346
                 type="number"
332 347
                 v-model="dialysisPrescription.glucose"
333 348
               ></el-input>
334 349
             </el-form-item>
335
-          </el-col>
350
+          </el-col> -->
336 351
           <el-col :span="8" v-if="isShows('透析液流量')">
337 352
             <el-form-item label="透析液流量(ml/min):">
338 353
               <el-input
@@ -547,6 +562,15 @@
547 562
              </el-form-item>
548 563
           </el-col>
549 564
 
565
+         
566
+
567
+
568
+          <el-col :span="8" v-if="isShows('置换流量')">
569
+             <el-form-item label="置换流量(L/h):">
570
+                <el-input v-model="dialysisPrescription.replacement_flow"></el-input>
571
+             </el-form-item>
572
+          </el-col>
573
+
550 574
         </el-row>
551 575
 
552 576
         <el-row :gutter="20">
@@ -1042,6 +1066,9 @@
1042 1066
           displace_speed:"",
1043 1067
           illness:"",
1044 1068
           amylaceum:"",
1069
+          single_time:"",
1070
+          single_water:"",
1071
+          replacement_flow:"",
1045 1072
         },
1046 1073
 
1047 1074
         anticoagulant: {

+ 26 - 9
src/xt_pages/dialysis/details/dialog/doubleCheckDialog.vue View File

@@ -2,7 +2,8 @@
2 2
   <el-dialog title="双人核对"
3 3
              :visible.sync="isVisibility"
4 4
              :modal-append-to-body="false"
5
-             width="854px">
5
+             width="854px"
6
+            >
6 7
 
7 8
     <el-form :inline="true" class="demo-form-inline newInline" :model="doubleReview" label-width="105px">
8 9
       
@@ -202,9 +203,9 @@
202 203
         blood_access_part_opera_id:"通路类型:"
203 204
       }
204 205
     }, methods: {
206
+      
205 207
       show() {
206
-        console.log(this.double_check)
207
-
208
+        
208 209
         this.isVisibility = true
209 210
         if (this.double_check.id > 0) {
210 211
 
@@ -252,9 +253,11 @@
252 253
         }
253 254
       },
254 255
       hide() {
256
+      
255 257
         this.isVisibility = false
256 258
       },
257 259
       handleCancle: function() {
260
+      
258 261
         this.isVisibility = false
259 262
 
260 263
       }, 
@@ -776,6 +779,7 @@
776 779
       GetDialysateFormulationById(val) {
777 780
          this.dialysate_formulation_options = getDataConfig('hemodialysis','dialysate_formulation')
778 781
          console.log("透析液配方",this.dialysate_formulation_options)
782
+        
779 783
         let name = ''
780 784
         let dfl = this.dialysate_formulation_options.length
781 785
         for (let index = 0; index < dfl; index++) {
@@ -924,24 +928,37 @@
924 928
     },
925 929
     watch: {
926 930
       isVisibility(val) {
927
-      
931
+        
928 932
         if(this.prescription!=null && this.prescription.id!=0){
933
+
929 934
           this.diazes = this.diazes + this.prescription.dialyzer_perfusion_apparatus
935
+          this.prescription.dialyzer_perfusion_apparatus = ""
930 936
           this.dialysate_formulation = this.dialysate_formulation + this.GetDialysateFormulationById(this.prescription.dialysate_formulation)
931
-         
937
+          // this.prescription.dialysate_formulation = ""
932 938
           this.kalium = this.kalium + (this.prescription.kalium?this.prescription.kalium:"")
933
-         
939
+          this.prescription.kalium = ""
934 940
           this.calcium = this.calcium + (this.prescription.calcium?this.prescription.calcium:"")
941
+          this.prescription.calcium = ""
935 942
           this.dialys_mode = this.dialys_mode + this.getMode(this.prescription.mode_id)
936
-          this.long_time = this.long_time + (this.prescription.dialysis_duration?this.prescription.dialysate_formulation:"")
943
+          this.prescription.mode_id= ""
944
+          this.long_time = this.long_time + (this.prescription.dialysis_duration?this.prescription.dialysis_duration:"")
945
+          this.prescription.dialysis_duration=""
937 946
           this.target_ultrafiltration = this.target_ultrafiltration + (this.prescription.target_ultrafiltration?this.prescription.target_ultrafiltration:"")
947
+          this.prescription.target_ultrafiltration = ""
938 948
           this.anticoagulant = this.anticoagulant + this.getAnticoagulant(this.prescription.anticoagulant)
949
+          this.prescription.anticoagulant=""
939 950
           this.anticoagulant_shouji = this.anticoagulant_shouji + (this.prescription.anticoagulant_shouji?this.prescription.anticoagulant_shouji:"")
951
+          this.prescription.anticoagulant_shouji = ""
940 952
           this.anticoagulant_weichi = this.anticoagulant_weichi + (this.prescription.anticoagulant_weichi?this.prescription.anticoagulant_weichi:"")
941
-          this.anticoagulant_zongliang = this.anticoagulant_zongliang+(this.prescription.anticoagulant_zongliang?this.prescription.anticoagulant_zongliang:"")
942
-          this.displace_liqui_part = this.displace_liqui_part + (this.prescription.displace_liqui_part?this.prescription.displace_liqui_part:"")
953
+         this.prescription.anticoagulant_weichi=""
954
+         this.anticoagulant_zongliang = this.anticoagulant_zongliang+(this.prescription.anticoagulant_zongliang?this.prescription.anticoagulant_zongliang:"")
955
+         this.prescription.anticoagulant_zongliang = ""
956
+         this.displace_liqui_part = this.displace_liqui_part + (this.prescription.displace_liqui_part?this.prescription.displace_liqui_part:"")
957
+          this.prescription.displace_liqui_part
943 958
           this.replacement_total = this.replacement_total + (this.prescription.replacement_total?this.prescription.replacement_total:"")
959
+          this.prescription.replacement_total= ""
944 960
           this.dialysate_flow = this.dialysate_flow + (this.prescription.dialysate_flow?this.prescription.dialysate_flow:"")
961
+          this.prescription.dialysate_flow= ""
945 962
         }
946 963
         if(this.predialysis_evaluation!=null && this.predialysis_evaluation.id!=0){
947 964
           this.puncture_needle = this.puncture_needle + this.predialysis_evaluation.puncture_needle

+ 6 - 2
src/xt_pages/dialysis/details/dialog/monitor_dialog.vue View File

@@ -165,6 +165,8 @@
165 165
                   template_id == 34 ||
166 166
                   template_id == 35 ||
167 167
                   template_id == 36 ||
168
+                  template_id == 38 ||
169
+                  template_id == 39 ||
168 170
                   org_id == 9555)
169 171
             "
170 172
           >
@@ -206,6 +208,8 @@
206 208
                 template_id != 34 &&
207 209
                 template_id != 35 &&
208 210
                 template_id != 36 &&
211
+                template_id != 38 &&
212
+                template_id != 39 &&
209 213
                 org_id!=9555
210 214
             "
211 215
           >
@@ -223,7 +227,7 @@
223 227
             align="center"
224 228
             label="超滤率(ml/h)"
225 229
             width="100"
226
-            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) "
230
+            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) "
227 231
           >
228 232
             <template slot-scope="scope">
229 233
               {{ scope.row.ultrafiltration_rate ? scope.row.ultrafiltration_rate : ""  }}
@@ -234,7 +238,7 @@
234 238
             align="center"
235 239
             label="超滤率(L/h)"
236 240
             width="100"
237
-            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"
241
+            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"
238 242
           >
239 243
             <template slot-scope="scope">
240 244
               {{ scope.row.ultrafiltration_rate ? scope.row.ultrafiltration_rate : ""  }}

+ 4 - 4
src/xt_pages/dialysis/details/dialysisMonitoring.vue View File

@@ -14,10 +14,10 @@
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 || 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 && this.$store.getters.xt_user.template_info.org_id != 9555"  width="76px"> 超滤量(L) </th>
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)" width="50px"> 超滤率 <br />(ml/h) </th>
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" width="50px"> 超滤率 <br />(L/h) </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 || 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 && this.$store.getters.xt_user.template_info.org_id != 9555"  width="76px"> 超滤量(L) </th>
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
+          <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>
22 22
           <th v-if="isShow('透析液温度')" width="92px">透析液温度(℃)</th>
23 23
           <th v-if=" isShow('置换率') && (template_id == 6 || template_id == 10 || template_id == 11 || template_id == 20 || template_id == 26 || template_id == 29) " width="92px" > 置换率(ml/min) </th>

+ 49 - 3
src/xt_pages/dialysis/dialysisDoctorAdvice.vue View File

@@ -2,13 +2,24 @@
2 2
   <div class="main-contain">
3 3
     <div class="position">
4 4
       <bread-crumb :crumbs="crumbs"></bread-crumb>
5
+       <el-button
6
+          size="small"
7
+          icon="el-icon-printer"
8
+          :disabled="selecting_schs.length == 0"
9
+          @click="signPrintAction"
10
+          type="primary"
11
+          style="float:right"
12
+        >标签打印
13
+      </el-button>
5 14
       <el-button
6 15
           size="small"
7 16
           icon="el-icon-printer"
8 17
           :disabled="selecting_schs.length == 0"
9 18
           @click="batchPrintAction"
10 19
           type="primary"
11
-          >打印</el-button>
20
+          >医嘱打印
21
+      </el-button>
22
+   
12 23
     </div>
13 24
     <div class="app-container">
14 25
       <!-- <div class="filter-container">
@@ -111,6 +122,11 @@
111 122
             <span v-if="scope.row.mode_id == 14">(腹水回输)</span>
112 123
           </template>
113 124
         </el-table-column>
125
+        <el-table-column  label="分区床位" width="100">
126
+          <template slot-scope="scope" >
127
+              {{scope.row.zone_name}}/{{scope.row.number}}
128
+          </template>
129
+        </el-table-column>
114 130
         <el-table-column prop="date" label="透析器" align="center" min-width="26px">
115 131
           <template slot-scope="scope">
116 132
             <span>{{ scope.row.dialyzer_perfusion_apparatus }}</span>
@@ -513,6 +529,8 @@ export default {
513 529
                     it.zoneId = item.device_number.zone.id
514 530
                     it.dialysis_no = item.patient.dialysis_no
515 531
                     it.mode_id = item.mode_id
532
+                    it.number = item.device_number.number
533
+                    it.zone_name = item.device_number.zone.name
516 534
                     arr.push(it)
517 535
                 })
518 536
             })
@@ -575,6 +593,8 @@ export default {
575 593
                     it.zoneId = item.device_number.zone.id
576 594
                     it.dialysis_no = item.patient.dialysis_no
577 595
                     it.mode_id = item.mode_id
596
+                    it.number = item.device_number.number
597
+                    it.zone_name = item.device_number.zone.name
578 598
                     arr.push(it)
579 599
                 })
580 600
             })
@@ -662,7 +682,7 @@ export default {
662 682
       for (let index = 0; index < this.selecting_schs.length; index++) {
663 683
         sch_ids.push(this.selecting_schs[index].patient_id);
664 684
       }
665
-    //   console.log("sch_ids",sch_ids)
685
+  
666 686
       this.$store.dispatch("SetAdviceIDs", sch_ids);
667 687
        var name = ""
668 688
         for(let i=0;i<this.deliveryWay.length;i++){
@@ -675,6 +695,31 @@ export default {
675 695
        }
676 696
       this.$router.push({ path: "/dialysis/doctorAdvicePrint",query:{time: new Date(this.time).getTime(),delivery_way:name} });
677 697
 
698
+    },
699
+    signPrintAction:function(){
700
+      if (this.selecting_schs.length === 0) {
701
+        this.$message.error("请至少选择一条需要打印的内容");
702
+        return false;
703
+      }
704
+      // 模板ID为6
705
+      var sch_ids = [];
706
+
707
+      for (let index = 0; index < this.selecting_schs.length; index++) {
708
+        sch_ids.push(this.selecting_schs[index].patient_id);
709
+      }
710
+  
711
+      this.$store.dispatch("SetAdviceIDs", sch_ids);
712
+       var name = ""
713
+        for(let i=0;i<this.deliveryWay.length;i++){
714
+            if(this.delivery_way == this.deliveryWay[i].id){
715
+              name = this.deliveryWay[i].name
716
+            }
717
+        }
718
+        if(name == '全部'){
719
+          name = ""
720
+       }
721
+      this.$router.push({ path: "/dialysis/signPrint",query:{time: new Date(this.time).getTime(),delivery_way:name} });
722
+
678 723
     },
679 724
     batchPrintActionOne: function() {
680 725
       if (this.selecting_schs.length === 0) {
@@ -868,7 +913,8 @@ export default {
868 913
     handleSelectionChange(val){
869 914
         // console.log('val',val)
870 915
         this.selecting_schs = val;
871
-    }
916
+    },
917
+    
872 918
   },
873 919
   components: {
874 920
     BreadCrumb

+ 24 - 0
src/xt_pages/dialysis/dialysisPrintOrder.vue View File

@@ -543,6 +543,16 @@
543 543
           >打印</el-button
544 544
         >
545 545
       </template>
546
+      <template v-if="org_template_info.template_id == 39">
547
+        <el-button
548
+          :loading="loading"
549
+          size="small"
550
+          icon="el-icon-printer"
551
+          @click="printThisPage"
552
+          type="primary"
553
+          >打印</el-button
554
+        >
555
+      </template>
546 556
     </div>
547 557
     <div class="app-container" style="min-height:0;">
548 558
       <!--<div class="order-print-btn"-->
@@ -813,6 +823,11 @@
813 823
             v-if="org_template_info.template_id == 38"
814 824
           >
815 825
           </DialysisPrintOrderThirtyEight>
826
+          <DialysisPrintOrderThirtyNine
827
+            v-bind:childResponse="childResponse"
828
+            v-if="org_template_info.template_id == 39"
829
+          >
830
+          </DialysisPrintOrderThirtyNine>
816 831
         </div>
817 832
       </el-container>
818 833
     </div>
@@ -870,9 +885,11 @@ import DialysisPrintOrderThirtyFive from "./template/DialysisPrintOrderThirtyFiv
870 885
 import DialysisPrintOrderThirtySix from "./template/DialysisPrintOrderThirtySix";
871 886
 import DialysisPrintOrderThirtySeven from "./template/DialysisPrintOrderThirtySeven";
872 887
 import DialysisPrintOrderThirtyEight from "./template/DialysisPrintOrderThirtyEight";
888
+import DialysisPrintOrderThirtyNine from "./template/DialysisPrintOrderThirtyNine";
873 889
 export default {
874 890
   name: "dialysisPrintOrder",
875 891
   components: {
892
+    DialysisPrintOrderThirtyNine,
876 893
     DialysisPrintOrderThirtyEight,
877 894
     DialysisPrintOrderThirtySeven,
878 895
     DialysisPrintOrderThirtySix,
@@ -1342,6 +1359,13 @@ export default {
1342 1359
           style: style8,
1343 1360
           scanStyles: false
1344 1361
         });
1362
+      } else if (this.org_template_info.template_id == 39) {
1363
+        printJS({
1364
+          printable: "dialysis-print-box",
1365
+          type: "html",
1366
+          style: style3,
1367
+          scanStyles: false
1368
+        });
1345 1369
       }
1346 1370
     },
1347 1371
     printThisOnePage() {

+ 692 - 0
src/xt_pages/dialysis/signPrint.vue View File

@@ -0,0 +1,692 @@
1
+<template>
2
+    <div class="main-contain">
3
+        <div class="position">
4
+        <bread-crumb :crumbs="crumbs"></bread-crumb>
5
+        <el-row style="float:right;">
6
+            <el-col :span="24">
7
+            <el-button size="small" icon="el-icon-printer" type="primary" @click="printAction">打印</el-button>
8
+            </el-col>
9
+        </el-row>
10
+        </div>
11
+        <div class="app-container" style="background-color: white;" v-show="show">
12
+            <div id="dialysisTable">
13
+                <div v-for="(item, index) in list" :key="index">
14
+                    <div class="signPrint" v-for="it in item.doctor_advice" style="page-break-after: always;">
15
+                        <div>分区/床位号:{{item.device_number.zone.name}}/{{item.device_number.number}}</div>  
16
+                        <div>姓名:{{item.patient.name}}</div>  
17
+                        <div>医嘱内容:{{ it.advice_name }}</div>  
18
+                        <div>给药途径:{{it.execution_frequency}}</div>  
19
+                        <div>执行频率:{{it.delivery_way}}</div>  
20
+                        <div>打印时间:{{time}}</div>   
21
+                    </div>  
22
+                </div>
23
+            </div>
24
+        </div>
25
+
26
+          <div class="app-container" style="background-color: white;" v-show="showOne">
27
+            <div id="dialysisTable">
28
+                <div v-for="(item, index) in list" :key="index">
29
+                    <div class="signPrint" v-for="it in item.doctor_advice" style="page-break-after: always;">
30
+                        <div>分区/床位号:{{item.device_number.zone.name}}/{{item.device_number.number}}</div>  
31
+                        <div>姓名:{{item.patient.name}}</div>  
32
+                        <div>医嘱内容:{{getAdvice(item.doctor_advice)}}</div>  
33
+                        <div>给药途径:{{item.doctor_advice[0].execution_frequency}}</div>  
34
+                        <div>执行频率:{{item.doctor_advice[0].delivery_way}}</div>  
35
+                        <div>打印时间:{{time}}</div>   
36
+                    </div>  
37
+                  
38
+                </div>
39
+            </div>
40
+        </div>
41
+    </div>
42
+</template>
43
+
44
+<script>
45
+import BreadCrumb from '@/xt_pages/components/bread-crumb'
46
+import { getSchedualDoctors } from '@/api/advice'
47
+import { parseTime } from '@/utils'
48
+import print from 'print-js'
49
+const moment = require('moment')
50
+export default {
51
+    components:{
52
+        BreadCrumb
53
+    },
54
+    data(){
55
+        return{
56
+            crumbs: [
57
+                { path: false, name: '耗材药品' },
58
+                { path: false, name: '打印' }
59
+            ],
60
+            tableData:[],
61
+            start_time:"",
62
+            end_time:"",
63
+            print_time:moment(new Date()).add('year', 0).format('YYYY-MM-DD'),
64
+
65
+            zone_selected: 0,
66
+            scheduleMap:[],
67
+            time:'',
68
+            show:true,
69
+            showOne:false,
70
+            delivery_way:"",
71
+            list:[]
72
+        }
73
+    },
74
+    methods:{
75
+        printAction: function() {
76
+            const style = '@media print { .dialysisTable{width:960px;margin: 0 auto;text-align: center;border-collapse: collapse;}.order_title_panl {text-align: center;.main_title {font-size: 18px;line-height: 40px;font-weight: 500;}}.dialysisTable tr{padding: 10px 0;}.dialysisTable th {color: #000;padding: 0;margin: 0;height: 30px;}.dialysisTable tr td {padding: 12px 0;}.subadvice_content {text-align: left;padding-left: 25px !important;padding-right: 5px !important;}.advice_content {text-align: left;padding-left: 5px !important;padding-right: 5px !important;padding: 15px 5px !important;} }'
77
+
78
+            printJS({
79
+            printable: 'dialysisTable',
80
+            type: 'html',
81
+            documentTitle: '  ',
82
+            style: style,
83
+            scanStyles: false
84
+            })
85
+        },
86
+        requestSchedualDoctors (time) {
87
+            let newTime =  moment(time).format('YYYY-MM-DD')
88
+            getSchedualDoctors({
89
+            date: newTime,
90
+            patient_type: 0,
91
+            advice_type: 2,
92
+            delivery_way:this.delivery_way,
93
+            }).then(rs => {
94
+                var resp = rs.data
95
+                if (resp.state == 1) {
96
+                this.admin_user = resp.data.adminUser
97
+                var config = resp.data.config
98
+                if(config.is_open == 0 || config.is_open == 2){
99
+                
100
+                   var schedulesArr = resp.data.scheduals
101
+                   let schedules = []
102
+                   var ids = this.$store.getters.temp_params.advice_ids
103
+                   console.log('ids',ids)
104
+                   schedulesArr.map(item => {
105
+                   if(ids.indexOf(item.patient_id) > -1){
106
+                        schedules.push(item)
107
+                    }
108
+                    
109
+                })
110
+               
111
+                for (let i = 0; i < schedules.length; i++) {
112
+                    schedules[i].dialysis_no = schedules[i].patient.dialysis_no
113
+                }
114
+           
115
+
116
+                var arr = []
117
+                for (let j = 0; j < schedules.length; j++) {
118
+                    arr.push(schedules[j].dialysis_no)
119
+                }
120
+                arr.sort(function (a, b) {
121
+                    return a - b
122
+                })
123
+               
124
+
125
+                var arrTwo = []
126
+                for (let i = 0; i < arr.length; i++) {
127
+                    for (let j = 0; j < schedules.length; j++) {
128
+                    if (arr[i] == schedules[j].dialysis_no) {
129
+                        arrTwo.push(schedules[j])
130
+                    }
131
+                    }
132
+                }
133
+
134
+                arrTwo.map((item, index) => {
135
+                  
136
+                    item.doctor_advice.sort(this.compare('start_time'))
137
+                })
138
+                
139
+
140
+                const res = new Map()
141
+                let a = arrTwo.filter(
142
+                    a => !res.has(a.dialysis_no) && res.set(a.dialysis_no, 1)
143
+                )
144
+
145
+               
146
+
147
+                schedules = a
148
+                var zoneMap = {}
149
+                var scheduleMap = {}
150
+                for (let index = 0; index < schedules.length; index++) {
151
+                    const schedule = schedules[index]
152
+                    if (schedule.doctor_advice.length == 0) {
153
+                    continue
154
+                    }
155
+                    if (scheduleMap[schedule.device_number.zone.name] == null) {
156
+                    scheduleMap[schedule.device_number.zone.name] = []
157
+                    }
158
+                    scheduleMap[schedule.device_number.zone.name].push(schedule)
159
+                    if (zoneMap[schedule.device_number.zone.name] == null) {
160
+                    zoneMap[schedule.device_number.zone.name] =schedule.device_number.zone}
161
+                }
162
+
163
+                var zones = []
164
+                zones.push({ value: 0, text: '全部分区' })
165
+                for (var zoneName in zoneMap) {
166
+                    zones.push({ value: zoneMap[zoneName].id, text: zoneName })
167
+                }
168
+
169
+                zones = zones.sort(function (a, b) {
170
+                    return a.value > b.value
171
+                })
172
+                this.zones = zones
173
+                for (var key in scheduleMap) {
174
+                    let mapArr = scheduleMap[key]
175
+                    for (let i = 0; i < mapArr.length; i++) {
176
+                    mapArr[i]['new_advice'] = []
177
+                    }
178
+                }
179
+
180
+                for (var key in scheduleMap) {
181
+                    let mapArr = scheduleMap[key]
182
+                    for (let i = 0; i < mapArr.length; i++) {
183
+                    var maps = mapArr[i]
184
+                    var resp_advices = maps.doctor_advice
185
+                    if (resp_advices.length > 0) {
186
+                        var newGroupObject = function () {
187
+                        return Object.assign(
188
+                            {},
189
+                            {
190
+                            group_no: 0,
191
+                            advices: []
192
+                            }
193
+                        )
194
+                        }
195
+                        var initGroupBlock = function (group, advice) {
196
+                        group.group_no = advice.groupno
197
+                        }
198
+
199
+                        var advice_groups = []
200
+                        var group = newGroupObject()
201
+                        for (let index = 0; index < resp_advices.length; index++) {
202
+                        const advice = resp_advices[index]
203
+                        if (advice.groupno == 0) {
204
+                            // 老版本的医嘱
205
+                            if (advice.parent_id > 0) {
206
+                            if (advice_groups.length > 0) {
207
+                                var parent_group = advice_groups[advice_groups.length - 1]
208
+                                if (parent_group.advices.length > 0) {
209
+                                if (parent_group.advices[0].id == advice.parent_id) {
210
+                                    parent_group.advices.push(advice)
211
+                                }
212
+                                }
213
+                            }
214
+                            continue
215
+                            } else {
216
+                            if (group.group_no > 0) {
217
+                                advice_groups.push(group)
218
+                                group = newGroupObject()
219
+                            }
220
+
221
+                            initGroupBlock(group, advice)
222
+                            group.advices.push(advice)
223
+                            advice_groups.push(group)
224
+                            group = newGroupObject()
225
+                            continue
226
+                            }
227
+                        } else {
228
+                            if (group.group_no > 0 && group.group_no != advice.groupno) {
229
+                            advice_groups.push(group)
230
+                            group = newGroupObject()
231
+                            }
232
+                            if (group.group_no == 0) {
233
+                            initGroupBlock(group, advice)
234
+                            }
235
+                            if (group.group_no == advice.groupno) {
236
+                            group.advices.push(advice)
237
+                            }
238
+                        }
239
+                        }
240
+                        if (group.group_no > 0) {
241
+                        // 上述的算法会导致最后一组没有加到advice_groups,这里要手动加
242
+                        advice_groups.push(group)
243
+                        }
244
+                        advice_groups = advice_groups
245
+                    } else {
246
+                        advice_groups = []
247
+                    }
248
+                    maps.new_advice = advice_groups
249
+                    }
250
+                 }
251
+                console.log("scheduleMap999999999999",schedules)
252
+                  this.list = schedules
253
+                }
254
+               
255
+                 if(config.is_open == 1){
256
+                   var schedulesArr = resp.data.hisAdvices
257
+                   let schedules = []
258
+                   var ids = this.$store.getters.temp_params.advice_ids
259
+                   console.log('ids',ids)
260
+                   schedulesArr.map(item => {
261
+                    if(ids.indexOf(item.patient_id) > -1){
262
+                        schedules.push(item)
263
+                    }
264
+                    
265
+                })
266
+               
267
+                for (let i = 0; i < schedules.length; i++) {
268
+                    schedules[i].dialysis_no = schedules[i].patient.dialysis_no
269
+                }
270
+           
271
+
272
+                var arr = []
273
+                for (let j = 0; j < schedules.length; j++) {
274
+                    arr.push(schedules[j].dialysis_no)
275
+                }
276
+                arr.sort(function (a, b) {
277
+                    return a - b
278
+                })
279
+               
280
+
281
+                var arrTwo = []
282
+                for (let i = 0; i < arr.length; i++) {
283
+                    for (let j = 0; j < schedules.length; j++) {
284
+                    if (arr[i] == schedules[j].dialysis_no) {
285
+                        arrTwo.push(schedules[j])
286
+                    }
287
+                    }
288
+                }
289
+
290
+                arrTwo.map((item, index) => {
291
+                  
292
+                    item.doctor_advice.sort(this.compare('start_time'))
293
+                })
294
+                
295
+
296
+                const res = new Map()
297
+                let a = arrTwo.filter(
298
+                    a => !res.has(a.dialysis_no) && res.set(a.dialysis_no, 1)
299
+                )
300
+
301
+               
302
+
303
+                schedules = a
304
+                var zoneMap = {}
305
+                var scheduleMap = {}
306
+                for (let index = 0; index < schedules.length; index++) {
307
+                    const schedule = schedules[index]
308
+                    if (schedule.doctor_advice.length == 0) {
309
+                    continue
310
+                    }
311
+                    if (scheduleMap[schedule.device_number.zone.name] == null) {
312
+                    scheduleMap[schedule.device_number.zone.name] = []
313
+                    }
314
+                    scheduleMap[schedule.device_number.zone.name].push(schedule)
315
+                    if (zoneMap[schedule.device_number.zone.name] == null) {
316
+                    zoneMap[schedule.device_number.zone.name] =
317
+                        schedule.device_number.zone
318
+                    }
319
+                }
320
+             
321
+                var zones = []
322
+                zones.push({ value: 0, text: '全部分区' })
323
+                for (var zoneName in zoneMap) {
324
+                    zones.push({ value: zoneMap[zoneName].id, text: zoneName })
325
+                }
326
+
327
+                zones = zones.sort(function (a, b) {
328
+                    return a.value > b.value
329
+                })
330
+                this.zones = zones
331
+                for (var key in scheduleMap) {
332
+                    let mapArr = scheduleMap[key]
333
+                    for (let i = 0; i < mapArr.length; i++) {
334
+                    mapArr[i]['new_advice'] = []
335
+                    }
336
+                }
337
+
338
+                for (var key in scheduleMap) {
339
+                    let mapArr = scheduleMap[key]
340
+                    for (let i = 0; i < mapArr.length; i++) {
341
+                    var maps = mapArr[i]
342
+                    var resp_advices = maps.doctor_advice
343
+                    if (resp_advices.length > 0) {
344
+                        var newGroupObject = function () {
345
+                        return Object.assign(
346
+                            {},
347
+                            {
348
+                            group_no: 0,
349
+                            advices: []
350
+                            }
351
+                        )
352
+                        }
353
+                        var initGroupBlock = function (group, advice) {
354
+                        group.group_no = advice.groupno
355
+                        }
356
+
357
+                        var advice_groups = []
358
+                        var group = newGroupObject()
359
+                        for (let index = 0; index < resp_advices.length; index++) {
360
+                        const advice = resp_advices[index]
361
+                        if (advice.groupno == 0) {
362
+                            // 老版本的医嘱
363
+                            if (advice.parent_id > 0) {
364
+                            if (advice_groups.length > 0) {
365
+                                var parent_group = advice_groups[advice_groups.length - 1]
366
+                                if (parent_group.advices.length > 0) {
367
+                                if (parent_group.advices[0].id == advice.parent_id) {
368
+                                    parent_group.advices.push(advice)
369
+                                }
370
+                                }
371
+                            }
372
+                            continue
373
+                            } else {
374
+                            if (group.group_no > 0) {
375
+                                advice_groups.push(group)
376
+                                group = newGroupObject()
377
+                            }
378
+
379
+                            initGroupBlock(group, advice)
380
+                            group.advices.push(advice)
381
+                            advice_groups.push(group)
382
+                            group = newGroupObject()
383
+                            continue
384
+                            }
385
+                        } else {
386
+                            if (group.group_no > 0 && group.group_no != advice.groupno) {
387
+                            advice_groups.push(group)
388
+                            group = newGroupObject()
389
+                            }
390
+                            if (group.group_no == 0) {
391
+                            initGroupBlock(group, advice)
392
+                            }
393
+                            if (group.group_no == advice.groupno) {
394
+                            group.advices.push(advice)
395
+                            }
396
+                        }
397
+                        }
398
+                        if (group.group_no > 0) {
399
+                        // 上述的算法会导致最后一组没有加到advice_groups,这里要手动加
400
+                        advice_groups.push(group)
401
+                        }
402
+                        advice_groups = advice_groups
403
+                    } else {
404
+                        advice_groups = []
405
+                    }
406
+                    maps.new_advice = advice_groups
407
+                    }
408
+                 }
409
+                
410
+                     this.list = schedules
411
+                     this.scheduleMap = scheduleMap  
412
+                 }
413
+                console.log("this.list",this.list)
414
+                
415
+                }
416
+            })
417
+        },
418
+        compare (property) {
419
+            return function (a, b) {
420
+                var value1 = a[property]
421
+                var value2 = b[property]
422
+                return value1 - value2
423
+            }
424
+        },
425
+        parseTime: function (time, layout) {
426
+            if (time == 0) {
427
+                return ''
428
+            }
429
+            return parseTime(time, layout)
430
+        },
431
+        getName (val) {
432
+            for (let i = 0; i < this.admin_user.length; i++) {
433
+                if (this.admin_user[i].id == val) {
434
+                    return this.admin_user[i].name
435
+                }
436
+            }
437
+        },
438
+        getAdvice: function(doctor_advice) {
439
+          if (doctor_advice.length > 0) {
440
+            let name = "";
441
+            for (let i = 0; i < doctor_advice.length; i++) {
442
+            let prescribing_number = "";
443
+            let single_dose = "";
444
+            let drug_spec = "";
445
+
446
+            if (doctor_advice[i].prescribing_number > 0) {
447
+                prescribing_number =
448
+                doctor_advice[i].prescribing_number +
449
+                doctor_advice[i].prescribing_number_unit;
450
+            }
451
+            if (doctor_advice[i].single_dose > 0) {
452
+                single_dose =
453
+                " 单次用量 " +
454
+                doctor_advice[i].single_dose +
455
+                doctor_advice[i].single_dose_unit;
456
+            }
457
+
458
+            if (doctor_advice[i].drug_spec > 0) {
459
+                drug_spec =
460
+                doctor_advice[i].drug_spec + doctor_advice[i].drug_spec_unit;
461
+            }
462
+
463
+            name =
464
+                name +
465
+                doctor_advice[i].advice_name +
466
+                " " +
467
+                drug_spec +
468
+                " " +
469
+                prescribing_number +
470
+                " " +
471
+                single_dose +
472
+                " " +
473
+                doctor_advice[i].delivery_way +
474
+                " " +
475
+                doctor_advice[i].execution_frequency +
476
+                " " +
477
+                doctor_advice[i].remark +
478
+                "\n";
479
+
480
+            // if (doctor_advice[i].child.length > 0) {
481
+            //     for (let a = 0; a < doctor_advice[i].child.length; a++) {
482
+            //     if (doctor_advice[i].child[a].prescribing_number > 0) {
483
+            //         doctor_advice[i].child[a]["presc"] =
484
+            //         doctor_advice[i].child[a].prescribing_number +
485
+            //         doctor_advice[i].child[a].prescribing_number_unit;
486
+            //     } else {
487
+            //         doctor_advice[i].child[a]["presc"] = "";
488
+            //     }
489
+
490
+            //     if (doctor_advice[i].child[a].single_dose > 0) {
491
+            //         doctor_advice[i].child[a]["single"] =
492
+            //         " " +
493
+            //         " 单次用量 " +
494
+            //         " " +
495
+            //         doctor_advice[i].child[a].single_dose +
496
+            //         doctor_advice[i].child[a].single_dose_unit;
497
+            //     } else {
498
+            //         doctor_advice[i].child[a]["single"] = "";
499
+            //     }
500
+
501
+            //     name =
502
+            //         name +
503
+            //         "▲" +
504
+            //         doctor_advice[i].child[a].advice_name +
505
+            //         "" +
506
+            //         doctor_advice[i].child[a].advice_desc +
507
+            //         doctor_advice[i].child[a].drug_spec_unit +
508
+            //         doctor_advice[i].child[a].presc +
509
+            //         doctor_advice[i].child[a].single +
510
+            //         "\n";
511
+            //     }
512
+            // }
513
+        }
514
+        return name;
515
+      }else{
516
+        return ""
517
+      }
518
+    },
519
+    },
520
+    computed: {
521
+    filtedScheduals: function () {
522
+        var scheduleMap = new Object()
523
+        if (this.zone_selected == 0) {
524
+            for (const key in this.scheduleMap) {
525
+            scheduleMap[key] = this.scheduleMap[key]
526
+            }
527
+        } else {
528
+            var zone_name = this.zones[this.zone_selected].text
529
+            scheduleMap[zone_name] = this.scheduleMap[zone_name]
530
+        }
531
+
532
+        if (this.schedule_type_selected != 0) {
533
+            var _scheduleMap = {}
534
+            for (const key in scheduleMap) {
535
+            var origin_schedules = scheduleMap[key]
536
+            var schedules = []
537
+            for (let index = 0; index < origin_schedules.length; index++) {
538
+                const schedule = origin_schedules[index]
539
+                if (schedule.schedule_type == this.schedule_type_selected) {
540
+                schedules.push(schedule)
541
+                }
542
+            }
543
+            if (schedules.length > 0) {
544
+                _scheduleMap[key] = schedules
545
+            }
546
+            }
547
+
548
+            scheduleMap = _scheduleMap
549
+        }
550
+        for (var key in scheduleMap) {
551
+            let mapArr = scheduleMap[key]
552
+            for (let i = 0; i < mapArr.length; i++) {
553
+            mapArr[i]['new_advice'] = []
554
+            }
555
+        }
556
+
557
+        for (var key in scheduleMap) {
558
+            let mapArr = scheduleMap[key]
559
+            for (let i = 0; i < mapArr.length; i++) {
560
+            var maps = mapArr[i]
561
+            var resp_advices = maps.doctor_advice
562
+            if (resp_advices.length > 0) {
563
+                var newGroupObject = function () {
564
+                return Object.assign(
565
+                    {},
566
+                    {
567
+                    group_no: 0,
568
+                    advices: []
569
+                    }
570
+                )
571
+                }
572
+                var initGroupBlock = function (group, advice) {
573
+                group.group_no = advice.groupno
574
+                }
575
+
576
+                var advice_groups = []
577
+                var group = newGroupObject()
578
+                for (let index = 0; index < resp_advices.length; index++) {
579
+                const advice = resp_advices[index]
580
+                if (advice.groupno == 0) {
581
+                    // 老版本的医嘱
582
+                    if (advice.parent_id > 0) {
583
+                    if (advice_groups.length > 0) {
584
+                        var parent_group = advice_groups[advice_groups.length - 1]
585
+                        if (parent_group.advices.length > 0) {
586
+                        if (parent_group.advices[0].id == advice.parent_id) {
587
+                            parent_group.advices.push(advice)
588
+                        }
589
+                        }
590
+                    }
591
+                    continue
592
+                    } else {
593
+                    if (group.group_no > 0) {
594
+                        advice_groups.push(group)
595
+                        group = newGroupObject()
596
+                    }
597
+
598
+                    initGroupBlock(group, advice)
599
+                    group.advices.push(advice)
600
+                    advice_groups.push(group)
601
+                    group = newGroupObject()
602
+                    continue
603
+                    }
604
+                } else {
605
+                    if (group.group_no > 0 && group.group_no != advice.groupno) {
606
+                    advice_groups.push(group)
607
+                    group = newGroupObject()
608
+                    }
609
+                    if (group.group_no == 0) {
610
+                    initGroupBlock(group, advice)
611
+                    }
612
+                    if (group.group_no == advice.groupno) {
613
+                    group.advices.push(advice)
614
+                    }
615
+                }
616
+                }
617
+                if (group.group_no > 0) {
618
+                // 上述的算法会导致最后一组没有加到advice_groups,这里要手动加
619
+                advice_groups.push(group)
620
+                }
621
+                advice_groups = advice_groups
622
+            } else {
623
+                advice_groups = []
624
+            }
625
+            maps.new_advice = advice_groups
626
+            }
627
+        }
628
+        console.log("222222",scheduleMap)
629
+        return scheduleMap
630
+        },
631
+    
632
+    },
633
+    created(){
634
+      var time = this.$route.query.time
635
+      var delivery_way = this.$route.query.delivery_way
636
+      console.log("delivery_Way",delivery_way)
637
+      this.delivery_way = delivery_way
638
+      this.time = moment(time).format('YYYY-MM-DD')
639
+      console.log(11,this.$route.query)
640
+      this.requestSchedualDoctors(time)
641
+    }
642
+}
643
+</script>
644
+
645
+
646
+<style rel="stylesheet/scss" lang="scss" scoped>
647
+.signPrint{
648
+    -webkit-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 60px rgba(0, 0, 0, 0.06) inset;
649
+    -moz-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 40px rgba(0, 0, 0, 0.06) inset;
650
+    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 40px rgba(0, 0, 0, 0.06) inset;
651
+    margin-bottom: 20px;
652
+    padding: 20px 10px;
653
+}
654
+.dialysisTable{
655
+    width:960px;
656
+    margin: 0 auto;
657
+    text-align: center;
658
+    border-collapse: collapse;
659
+}
660
+.order_title_panl {
661
+    text-align: center;
662
+
663
+    .main_title {
664
+      font-size: 18px;
665
+      line-height: 40px;
666
+      font-weight: 500;
667
+    }
668
+}
669
+.dialysisTable tr{
670
+    padding: 10px 0;
671
+}
672
+.dialysisTable th {
673
+    color: #000;
674
+    padding: 0;
675
+    margin: 0;
676
+    height: 30px;
677
+}
678
+.dialysisTable tr td {
679
+    padding: 12px 0;
680
+}
681
+.subadvice_content {
682
+    text-align: left;
683
+    padding-left: 25px !important;
684
+    padding-right: 5px !important;
685
+}
686
+.advice_content {
687
+    text-align: left;
688
+    padding-left: 5px !important;
689
+    padding-right: 5px !important;
690
+    padding: 15px 5px !important;
691
+}
692
+</style>

+ 23 - 9
src/xt_pages/dialysis/template/DialysisPrintOrderThirtyEight.vue View File

@@ -35,7 +35,7 @@
35 35
         <span v-else>出血部位:无</span>
36 36
       </div>
37 37
       <div class="lineHeight">
38
-          <div class="widthLength25">是否跌倒:暂无</div>
38
+          <div class="widthLength25">是否跌倒:{{ receiverTreatmentAccess.tumble == 1 ? '是' : '否' }}</div>
39 39
           <div class="widthLength25">跌倒预防措施:{{ receiverTreatmentAccess.precaution ? receiverTreatmentAccess.precaution : '/' }}</div>
40 40
           <div class="widthLength25">跌倒风险:
41 41
               <span v-if="receiverTreatmentAccess.danger_level == 1">无</span>
@@ -69,7 +69,7 @@
69 69
       </div>
70 70
       <div class="lineHeight">
71 71
           <div class="widthLength25">T:{{ predialysis.temperature ? predialysis.temperature : '' }} ℃</div>
72
-          <div class="widthLength25">P:{{ predialysis.pulse_frequency ? predialysis.pulse_frequency : '' }}</div>
72
+          <div class="widthLength25">P:{{ predialysis.pulse_frequency ? predialysis.pulse_frequency : '' }} 次/分</div>
73 73
           <div class="widthLength25">意识:
74 74
             <span v-for="(item, index) in consciousness_arr" :key="index">
75 75
               <span v-if="receiverTreatmentAccess.consciousness == item.id">{{ item.name }}</span>
@@ -95,11 +95,18 @@
95 95
           <div class="widthLength25">BP:{{ afterdialysis.systolic_blood_pressure ? afterdialysis.systolic_blood_pressure : "" }}/
96 96
             {{ afterdialysis.diastolic_blood_pressure ? afterdialysis.diastolic_blood_pressure : "" }} mmHg
97 97
           </div>
98
-          <div class="widthLength25">T:{{ afterdialysis.temperature ? afterdialysis.temperature : '' }}</div>
98
+          <div class="widthLength25">T:{{ afterdialysis.temperature ? afterdialysis.temperature : '' }}</div>
99 99
           <div class="widthLength25">意识:
100
-
100
+            <span v-for="(item, index) in consciousness_arr" :key="index">
101
+              <span v-if="afterdialysis.consciousness == item.id">{{ item.name }}</span>
102
+            </span>
103
+          </div>
104
+          <div class="widthLength25">跌倒风险:
105
+            <span v-if="afterdialysis.fallrisk == 1">无</span>
106
+            <span v-if="afterdialysis.fallrisk == 2">低风险</span>
107
+            <span v-if="afterdialysis.fallrisk == 3">中度风险</span>
108
+            <span v-if="afterdialysis.fallrisk == 4">高风险</span>
101 109
           </div>
102
-          <div class="widthLength25">跌倒风险:</div>
103 110
       </div>
104 111
       <div class="lineHeight">
105 112
           <div class="widthLength25">实际进食量:{{ afterdialysis.dialysis_during ? afterdialysis.dialysis_during : '' }} g</div>
@@ -133,19 +140,21 @@
133 140
           <div class="widthLength25">治疗总时长:{{ prescription.dialysis_duration_hour ? prescription.dialysis_duration_hour : 0 }}小时
134 141
             {{ prescription.dialysis_duration_minute ? prescription.dialysis_duration_minute : 0 }}分钟
135 142
           </div>
136
-          <div class="widthLength25">透析器:{{ prescription.dialysis_dialyszers ? prescription.dialysis_dialyszers : '' }}</div>
143
+          <div class="widthLength25">透析器:{{ prescription.dialysis_dialyszers ? prescription.dialysis_dialyszers : '' }} 
144
+            <span v-if="prescription.dialysis_irrigation!=''">/{{prescription.dialysis_irrigation}}</span>
145
+          </div>
137 146
       </div>
138 147
       <div class="lineHeight">
139 148
           <div class="widthLength25">血流量:{{ prescription.blood_flow_volume ? prescription.blood_flow_volume : "" }} ml/min</div>
140
-          <div class="widthLength25">设定UF量:{{ prescription.target_ultrafiltration ? prescription.target_ultrafiltration : "" }} L</div>
141
-          <div class="widthLength25">实际UF量:{{ afterdialysis.actual_ultrafiltration ? afterdialysis.actual_ultrafiltration : "" }} L</div>
149
+          <div class="widthLength25">设定UF量:{{ prescription.target_ultrafiltration ? prescription.target_ultrafiltration : "" }} ml</div>
150
+          <div class="widthLength25">实际UF量:{{ afterdialysis.actual_ultrafiltration ? afterdialysis.actual_ultrafiltration : "" }} ml</div>
142 151
           <div class="widthLength25">分区:{{ patientInfo.DialysisSchedule.device_zone.name }}</div>
143 152
       </div>
144 153
       <div class="lineHeight">
145 154
           <div class="widthLength25">透析液温度:{{ prescription.dialysate_temperature ? prescription.dialysate_temperature : "" }} ℃</div>
146 155
           <div class="widthLength25">透析液流量:{{ prescription.dialysate_flow ? prescription.dialysate_flow : "" }} ml/min</div>
147 156
           <div class="widthLength25">碳酸氢根:{{ prescription.bicarbonate ? prescription.bicarbonate : "" }} mmol/L</div>
148
-          <div class="widthLength25">血管通路:{{ predialysis.blood_access_part_opera_name ? predialysis.blood_access_part_opera_name : '' }}</div>
157
+          <div class="widthLength25">血管通路:{{ prescription.blood_access_part_opera_name ? prescription.blood_access_part_opera_name : '' }}</div>
149 158
       </div>
150 159
       <div class="lineHeight">
151 160
           透析液浓度(mmol/L):Ca: {{ prescription.calcium ? prescription.calcium : "" }}  &nbsp; Na: {{ prescription.sodium ? prescription.sodium : "" }} &nbsp;  K: {{ prescription.kalium ? prescription.kalium : "" }} &nbsp; 葡萄糖:{{ prescription.amylaceum ? prescription.amylaceum : "" }}
@@ -714,9 +723,11 @@ export default {
714 723
           this.predialysis.blood_access_part_opera_name = this.bloodAccessParOperaName(
715 724
             this.predialysis.blood_access_part_opera_id
716 725
           );
726
+          
717 727
           this.assessmentafter = response.data.data.assessmentAfterDislysis;
718 728
           console.log("上次透后体重", this.assessmentafter);
719 729
           var doctorAdevieInfo = response.data.data.doctorAdevieInfo;
730
+          var doctorAdevieInfo = response.data.data.advices;
720 731
           var tableAdvice = doctorAdevieInfo;
721 732
           console.log("医生", tableAdvice);
722 733
           if (tableAdvice.length === 0) {
@@ -979,6 +990,9 @@ export default {
979 990
           this.prescription.dialysate_formulation_name = this.dialysateFormulationName(
980 991
             this.prescription.dialysate_formulation
981 992
           );
993
+          this.prescription.blood_access_part_opera_name = this.bloodAccessParOperaName(
994
+            this.prescription.blood_access
995
+          );
982 996
 
983 997
           var paLen = this.perfusionApparatus.length;
984 998
           this.prescription.perfusion_apparatus_name = "";

File diff suppressed because it is too large
+ 1438 - 0
src/xt_pages/dialysis/template/DialysisPrintOrderThirtyNine.vue


+ 16 - 2
src/xt_pages/dialysis/template/DialysisPrintOrderTwentyFour.vue View File

@@ -1267,7 +1267,8 @@
1267 1267
             <td style="line-height:20px;" width="40">钠<br />浓<br />度<br /><span style="font-size:10px; !important">mmol/L</span></td>
1268 1268
             <td style="line-height:20px;" width="40">电<br />导<br />度<br /><span style="font-size:10px; !important">ms/cm</span></td>
1269 1269
             
1270
-            <td style="line-height:20px;" width="60">透析液<br />温度<br /><span style="font-size:10px; !important">ml</span></td>
1270
+            <td style="line-height:20px;" width="60">透析液<br />温度<br /><span style="font-size:10px; !important">℃</span></td>
1271
+            <td style="line-height:20px;" width="100">抗凝剂</td>
1271 1272
             <td style="line-height:20px;" width="">病情变化及处理</td>
1272 1273
             <td style="line-height:20px;" width="60">签名</td>
1273 1274
           </tr>
@@ -1305,11 +1306,24 @@
1305 1306
             <td>
1306 1307
               &nbsp;{{ monitor.transmembrane_pressure ? monitor.transmembrane_pressure : "" }}
1307 1308
             </td>
1308
-            <td>&nbsp;{{ monitor.ultrafiltration_rate ? monitor.ultrafiltration_rate : "" }}</td>
1309
+            <td>&nbsp;<span v-if="getTime(monitor.operate_time, '{h}:{i}')">{{ monitor.ultrafiltration_rate ? monitor.ultrafiltration_rate : "0" }}</span></td>
1309 1310
             <td>&nbsp;{{ monitor.sodium_concentration ? monitor.sodium_concentration : "" }}</td>
1310 1311
             <td>&nbsp;{{ monitor.conductivity ? monitor.conductivity : "" }}</td>
1311 1312
 
1312 1313
             <td>&nbsp;{{ monitor.dialysate_temperature ? monitor.dialysate_temperature : '' }}</td>
1314
+            <td>&nbsp;
1315
+              <span v-if="monitor.monitor_anticoagulant == 0"></span>
1316
+              <span v-if="monitor.monitor_anticoagulant == 1">无肝素</span>
1317
+              <span v-if="monitor.monitor_anticoagulant == 2">普通肝素</span>
1318
+              <span v-if="monitor.monitor_anticoagulant == 3">低分子肝素</span>
1319
+              <span v-if="monitor.monitor_anticoagulant == 4">阿加曲班</span>
1320
+              <span v-if="monitor.monitor_anticoagulant == 5">枸橼酸钠</span>
1321
+              <span v-if="monitor.monitor_anticoagulant == 6">低分子肝素钙</span>
1322
+              <span v-if="monitor.monitor_anticoagulant == 7">低分子肝素钠</span>
1323
+              <span v-if="monitor.monitor_anticoagulant == 8">依诺肝素</span>
1324
+              <span v-if="monitor.monitor_anticoagulant == 9">达肝素</span>
1325
+              <span v-if="monitor.monitor_anticoagulant_value!=undefined && monitor.monitor_anticoagulant_value!='' ">({{monitor.monitor_anticoagulant_value}})</span>
1326
+            </td>
1313 1327
             <td style="text-align:left;line-height:20px;">
1314 1328
               &nbsp;{{ monitor.symptom }} &nbsp;{{ monitor.dispose }} &nbsp;{{ monitor.result }}
1315 1329
             </td>

+ 2 - 1
src/xt_pages/dialysis/template/DialysisPrintOrderTwentySeven.vue View File

@@ -176,7 +176,8 @@
176 176
                     <td width="100">体液过多症状:</td>
177 177
                     <td width="50">
178 178
                       <div>
179
-                        <label-box :isChecked="predialysis.humor_excessive_symptom ? getHumorExcessiveSymptom(predialysis.humor_excessive_symptom).indexOf('无') > -1 : false" showValue="无"></label-box>
179
+                         <label-box :isChecked="prescription.body_fluid == 1 ? true : false" showValue="无"></label-box>
180
+                        <!-- <label-box :isChecked="predialysis.humor_excessive_symptom ? getHumorExcessiveSymptom(predialysis.humor_excessive_symptom).indexOf('无') > -1 : false" showValue="无"></label-box> -->
180 181
                       </div>
181 182
                     </td>
182 183
                     <td width="180">

+ 10 - 5
src/xt_pages/outpatientCharges/invoicePrint.vue View File

@@ -13,7 +13,8 @@
13 13
     </template>
14 14
     <div class="app-container" style="padding-top:40px;">
15 15
         <div class='dialysisPage'>
16
-            <printOne :paramsObj="invoiceParams"></printOne>
16
+            <printOne v-if="org_id != 10106" :paramsObj="invoiceParams"></printOne>
17
+            <printTwo v-if="org_id == 10106" :paramsObj="invoiceParams"></printTwo>
17 18
         </div>
18 19
     </div>
19 20
   </div>
@@ -21,10 +22,12 @@
21 22
 
22 23
 <script>
23 24
 import printOne from './invoiceTemplate/printOne'
25
+import printTwo from './invoiceTemplate/printTwo'
24 26
 export default {
25 27
   name: "invoicePrint",
26 28
   components: {
27
-    printOne
29
+    printOne,
30
+    printTwo
28 31
   },
29 32
   props:{
30 33
     invoiceParams:Object
@@ -32,7 +35,8 @@ export default {
32 35
   data() {
33 36
     return {
34 37
       childResponse: {},
35
-    //   invoiceParams:{}
38
+    //   invoiceParams:{},
39
+     org_id:''
36 40
       
37 41
 
38 42
     };
@@ -61,8 +65,7 @@ export default {
61 65
       return "";
62 66
     },
63 67
     printThisPage() {
64
-
65
-      const style =
68
+        const style =
66 69
         '@media print {#invoice-print{font-size:12px;}.printTitle{font-size: 22px;text-align: center;font-weight: bold;}.infoMain{display: flex;flex-wrap: wrap;padding:0 10px;margin-top:10px;}.infoMain .infoP{width: 33%;}.chargeBox{border: 1px solid #000;}.chargeUl{display:flex;justify-content: space-between;text-align: center;}.chargeUl p{line-height: 1px;}.chargeP{line-height: 1px;padding-bottom:16px;}.moneyBox{display: flex;justify-content: space-between;padding: 0 10px;background: #eeeeee;-webkit-print-color-adjust:exact;-moz-print-color-adjust:exact;-ms-print-color-adjust:exact;print-color-adjust:exact;height: 40px;align-items: center;border:1px solid #000; border-top:none}.actionBar{display: flex;justify-content: space-between; line-height: 24px;padding:0 10px;}.actionBar div{width:150px;}}';
67 70
         printJS({
68 71
             printable: "invoice-print",
@@ -70,6 +73,7 @@ export default {
70 73
             style: style,
71 74
             scanStyles: false
72 75
         });
76
+      
73 77
 
74 78
       // if (this.org_template_info.template_id == 1) {
75 79
       //   printJS({
@@ -83,6 +87,7 @@ export default {
83 87
   },
84 88
   created() {
85 89
       console.log('this.invoiceParams',this.invoiceParams)
90
+      this.org_id = this.$store.getters.xt_user.org_id
86 91
   },
87 92
   watch:{
88 93
     paramsObj:{//深度监听,可监听到对象、数组的变化

+ 221 - 0
src/xt_pages/outpatientCharges/invoiceTemplate/printTwo.vue View File

@@ -0,0 +1,221 @@
1
+<template>
2
+    <div id='invoice-print'>
3
+        <div style="display:flex;">
4
+            <div style="position: absolute;top:30px;left:70px;">{{ list.order_number }}</div>
5
+            <!-- <div>{{ list.id_card_no }}</div> -->
6
+        </div>
7
+        <div style="display:flex;justify-content: space-between;">
8
+            <!-- <div>{{ list.department_name }}</div> -->
9
+            <div  style="position: absolute;top:40px;left:300px">{{ list.number }}</div>
10
+            <div></div>
11
+            <div>
12
+                <span style="position: absolute;left:590px;top:40px;">{{ printDate.slice(0,4) }}</span>
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>
15
+            </div>
16
+        </div>
17
+        <div style="display:flex;justify-content: space-between;">
18
+            <div style="position: absolute;top:60px;left:120px;"> {{ paramsObj.name }}</div>
19
+            <div style="position: absolute;top:60px;left:210px;">√</div>
20
+            <!-- <div>{{ list.pay_way }}</div> -->
21
+            <div style="position: absolute;top:60px;left:460px;">{{ paramsObj.setl_time.split(' ')[0] }}</div>
22
+            <div style="position: absolute;top:60px;left:640px;">{{ paramsObj.setl_time.split(' ')[0] }}</div>
23
+        </div>
24
+        <div style="display:flex;justify-content: space-between;">
25
+            <!-- <div>{{ paramsObj.gend == 1 ? '男' : '女' }}</div> -->
26
+            <div style="position: absolute;top:90px;left:290px;">{{ (totalPrice - list.psn_cash_money).toFixed(2) }}</div>
27
+            <div style="position: absolute;top:90px;left:460px;">{{ list.psn_cash_money }}</div>
28
+            <div style="position: absolute;top:90px;left:640px;">门慢结算</div>
29
+        </div>
30
+        <div style="display:flex;justify-content: space-between;">
31
+            <div style="position: absolute;top:140px;left:40px">西药</div>
32
+            <div style="position: absolute;top:140px;left:110px">{{ list.westernMedicineCostTotal }}</div>
33
+            <div style="position: absolute;top:140px;left:200px">检查费</div>
34
+            <div style="position: absolute;top:140px;left:280px">{{ list.checkCostTotal }}</div>
35
+            <div style="position: absolute;top:140px;left:380px">治疗费</div>
36
+            <div style="position: absolute;top:140px;left:460px">{{ list.treatCostTotal }}</div>
37
+            <div style="position: absolute;top:140px;left:560px">床位费</div>
38
+            <div style="position: absolute;top:140px;left:640px">{{ list.bedCostTotal }}</div>
39
+        </div>
40
+        <div style="display:flex;justify-content: space-between;">
41
+            <div style="position: absolute;top:170px;left:40px">中成药</div>
42
+            <div style="position: absolute;top:170px;left:110px">{{ list.chineseTraditionalMedicineCostTotal }}</div>
43
+            <div style="position: absolute;top:170px;left:200px">化验费</div>
44
+            <div style="position: absolute;top:170px;left:280px">{{ list.laboratoryCostTotal }}</div>
45
+            <div style="position: absolute;top:170px;left:380px">手术费</div>
46
+            <div style="position: absolute;top:170px;left:460px">{{ list.operationCostTotal }}</div>
47
+            <div style="position: absolute;top:170px;left:560px">其他费</div>
48
+            <div style="position: absolute;top:170px;left:640px">{{ list.otherCostTotal }}</div>
49
+        </div>
50
+        <div style="display:flex;justify-content: space-between;">
51
+            <div style="position: absolute;top:200px;left:40px"></div>
52
+            <div style="position: absolute;top:200px;left:110px"></div>
53
+            <div style="position: absolute;top:200px;left:200px"></div>
54
+            <div style="position: absolute;top:200px;left:280px"></div>
55
+            <div style="position: absolute;top:200px;left:380px">材料费</div>
56
+            <div style="position: absolute;top:200px;left:460px">{{ list.materialCostTotal }}</div>
57
+            <div style="position: absolute;top:200px;left:560px"></div>
58
+            <div style="position: absolute;top:200px;left:640px"></div>
59
+        </div>
60
+        <div>
61
+            <span>
62
+            <span style="position: absolute;top:250px;left:200px">
63
+                <span v-if="zhongwen.indexOf('万') > -1">
64
+                    {{ zhongwen.substring(zhongwen.indexOf('万') - 1,zhongwen.indexOf('万')) }}
65
+                </span>
66
+                <span v-else>零</span>
67
+            </span>
68
+            <span style="position: absolute;top:250px;left:260px">
69
+                <span v-if="zhongwen.indexOf('仟') > -1">
70
+                    {{ zhongwen.substring(zhongwen.indexOf('仟') - 1,zhongwen.indexOf('仟')) }}
71
+                </span>
72
+                <span v-else>零</span>
73
+            </span>
74
+            <span style="position: absolute;top:250px;left:320px">
75
+                <span v-if="zhongwen.indexOf('佰') > -1">
76
+                    {{ zhongwen.substring(zhongwen.indexOf('佰') - 1,zhongwen.indexOf('佰')) }}
77
+                </span>
78
+                <span v-else>零</span>
79
+            </span>
80
+            <span style="position: absolute;top:250px;left:380px">
81
+                <span v-if="zhongwen.indexOf('拾') > -1">
82
+                    {{ zhongwen.substring(zhongwen.indexOf('拾') - 1,zhongwen.indexOf('拾')) }}
83
+                </span>
84
+                <span v-else>零</span>
85
+            </span>
86
+            <span style="position: absolute;top:250px;left:440px">
87
+                <span v-if="zhongwen.indexOf('元') > -1 && zhongwen.substring(zhongwen.indexOf('元') - 1,zhongwen.indexOf('元')) != '拾'">
88
+                    {{ zhongwen.substring(zhongwen.indexOf('元') - 1,zhongwen.indexOf('元')) }}
89
+                </span>
90
+                <span v-else>零</span>
91
+            </span>
92
+            <span style="position: absolute;top:250px;left:500px">
93
+                <span v-if="zhongwen.indexOf('角') > -1">
94
+                    {{ zhongwen.substring(zhongwen.indexOf('角') - 1,zhongwen.indexOf('角')) }}
95
+                </span>
96
+                <span v-else>零</span>
97
+            </span>
98
+            <span style="position: absolute;top:250px;left:560px">
99
+                <span v-if="zhongwen.indexOf('分') > -1">
100
+                    {{ zhongwen.substring(zhongwen.indexOf('分') - 1,zhongwen.indexOf('分')) }}
101
+                </span>
102
+                <span v-else>零</span>
103
+            </span>
104
+            </span>
105
+            <span style="position: absolute;top:250px;left:610px">{{ totalPrice.toFixed(2) }}</span>
106
+        </div>
107
+        <div style="position: absolute;top:280px;left:460px">现金:{{ list.psn_cash_money }}</div>
108
+        <div>
109
+            <div style="position: absolute;top:320px;left:120px">{{ org_name }}</div>
110
+            <div v-if="org_id == 10106" style="position: absolute;top:320px;left:460px">林美华</div>
111
+        </div>
112
+    </div>
113
+</template>
114
+
115
+
116
+<script>
117
+import { getInvoice } from '@/api/project/project'
118
+export default {
119
+    props:{
120
+        paramsObj:Object
121
+    },
122
+    data(){
123
+        return{
124
+            list:{},
125
+            printDate:'',
126
+            zhongwen:'',
127
+            totalPrice:0.0,
128
+            org_id:'',
129
+            org_name:''
130
+        }
131
+    },
132
+    created(){
133
+        console.log('paramsObj',this.paramsObj)
134
+        let params = {
135
+            order_id: this.paramsObj.order_id,
136
+            patient_id: this.paramsObj.patient_id,
137
+        }
138
+        this.getInvoice(params)
139
+        // var data = new Date();
140
+        // var month =data.getMonth() < 9 ? "0" + (data.getMonth() + 1) : data.getMonth() + 1;
141
+        // var date = data.getDate() <= 9 ? "0" + data.getDate() : data.getDate();
142
+        // this.printDate = data.getFullYear() + "-" + month + "-" + date;
143
+        // this.smalltoBIG(982732.21)
144
+        this.org_id = this.$store.getters.xt_user.org_id
145
+        this.org_name = this.$store.getters.xt_user.org.org_name
146
+    },
147
+    methods:{
148
+        getInvoice(params){
149
+            getInvoice(params).then((res) => {
150
+                console.log('res',res)
151
+                this.list = res.data.data
152
+                this.totalPrice = this.list.westernMedicineCostTotal + this.list.checkCostTotal + this.list.treatCostTotal + this.list.bedCostTotal + this.list.chineseTraditionalMedicineCostTotal +
153
+                                    this.list.laboratoryCostTotal + this.list.operationCostTotal + this.list.otherCostTotal + this.list.materialCostTotal
154
+                this.smalltoBIG(this.totalPrice)
155
+                var data = new Date(res.data.data.date * 1000);
156
+                var month =data.getMonth() < 9 ? "0" + (data.getMonth() + 1) : data.getMonth() + 1;
157
+                var date = data.getDate() <= 9 ? "0" + data.getDate() : data.getDate();
158
+                this.printDate = data.getFullYear() + "-" + month + "-" + date;
159
+            })
160
+        },
161
+        smalltoBIG(n) {
162
+            // let fraction = ['角', '分'];
163
+            // let digit = ['零', '壹', '贰', '叁', '肆', '伍', '陆', '柒', '捌', '玖'];
164
+            // let unit = [['元.', '万,', '亿,'], ["元",'拾', '佰', '仟']];
165
+            // let head = price < 0 ? '欠' : '';
166
+            // price = Math.abs(price);
167
+            // let upper = '';
168
+            // for (let i = 0; i < fraction.length; i++) {
169
+            // upper += (digit[Math.floor(price * 10 * Math.pow(10, i)) % 10] + fraction[i]).replace(/零./, '');
170
+            // }
171
+            // upper = upper || '整';
172
+            // price = Math.floor(price);
173
+            // for (let i = 0; i < unit[0].length && price > 0; i++) {
174
+            // let p = '';
175
+            // for (let j = 0; j < unit[1].length && price > 0; j++) {
176
+            //     p = digit[price % 10] + unit[1][j] + p;
177
+            //     price = Math.floor(price / 10);
178
+            // }
179
+            // upper = p.replace(/(零.)*零$/, '').replace(/^$/, '零') + unit[0][i] + upper;
180
+            // }
181
+            // this.zhongwen = head + upper.replace(/(零.)*零圆/, '圆').replace(/(零.)+/g, '零').replace(/^整$/, '零圆整')
182
+            // console.log('6666',head + upper.replace(/(零.)*零圆/, '圆').replace(/(零.)+/g, '零').replace(/^整$/, '零圆整'))
183
+            if (!/^(0|[1-9]\d*)(\.\d+)?$/.test(n)){
184
+                return "数据非法";  //判断数据是否大于0
185
+            }
186
+
187
+            var unit = "仟佰拾亿仟佰拾万仟佰拾元角分", str = "";
188
+            n += "00";  
189
+
190
+            var indexpoint = n.indexOf('.');  // 如果是小数,截取小数点前面的位数
191
+
192
+            if (indexpoint >= 0){
193
+
194
+                n = n.substring(0, indexpoint) + n.substr(indexpoint+1, 2);   // 若为小数,截取需要使用的unit单位
195
+            }
196
+
197
+            unit = unit.substr(unit.length - n.length);  // 若为整数,截取需要使用的unit单位
198
+            for (var i=0; i < n.length; i++){
199
+                str += "零壹贰叁肆伍陆柒捌玖".charAt(n.charAt(i)) + unit.charAt(i);  //遍历转化为大写的数字
200
+            }
201
+
202
+            this.zhongwen =  str.replace(/零(仟|佰|拾|角)/g, "零").replace(/(零)+/g, "零").replace(/零(万|亿|元)/g, "$1").replace(/(亿)万|壹(拾)/g, "$1$2").replace(/^元零?|零分/g, "").replace(/元$/g, "元整");
203
+            console.log(this.zhongwen)
204
+        },
205
+
206
+    },
207
+    watch:{
208
+        paramsObj:{//深度监听,可监听到对象、数组的变化
209
+            handler(val, oldVal){
210
+                let params = {
211
+                    order_id: val.order_id,
212
+                    patient_id: val.patient_id,
213
+                }
214
+                this.getInvoice(params)
215
+
216
+            },
217
+            deep:true
218
+        }
219
+    }
220
+}
221
+</script>

+ 1 - 1
src/xt_pages/outpatientCharges/listPrint.vue View File

@@ -464,4 +464,4 @@
464 464
   .newContainer::-webkit-scrollbar {
465 465
     height: 15px !important;
466 466
   }
467
-</style>
467
+</style>

+ 77 - 4
src/xt_pages/outpatientCharges/summary.vue View File

@@ -85,7 +85,9 @@
85 85
           <template slot-scope="scope">{{scope.row.department_name}}</template>
86 86
         </el-table-column>
87 87
         <el-table-column align="center" prop="name" label="收费日期">
88
-          <template slot-scope="scope"> {{scope.row.setl_time?scope.row.setl_time:getTimes(scope.row.settle_accounts_date)}}</template>
88
+          <template slot-scope="scope">
89
+            {{scope.row.setl_time?scope.row.setl_time:getTimes(scope.row.settle_accounts_date)}}
90
+          </template>
89 91
         </el-table-column>
90 92
         <el-table-column align="center" prop="name" label="收费员">
91 93
           <template slot-scope="scope">{{ getName(scope.row.creator) }}</template>
@@ -104,6 +106,10 @@
104 106
                        v-if="(scope.row.order_status == 2 && $store.getters.xt_user.org_id == 9504) || (scope.row.order_status == 2 && $store.getters.xt_user.org_id == 9919) ||  ($store.getters.xt_user.org_id == 10106) ||  (scope.row.order_status == 2 && $store.getters.xt_user.org_id == 4) || (scope.row.order_status == 2 && $store.getters.xt_user.org_id == 9990)">
105 107
               结算单
106 108
             </el-button>
109
+            <el-button size="mini" type="primary" @click="uploadInfo(scope.row)"
110
+                       v-if="scope.row.order_status == 2&& scope.row.result.id == 0">
111
+              上传结算清单
112
+            </el-button>
107 113
             <el-button size="mini" type="primary"
108 114
                        v-if="scope.row.order_status == 2 && $store.getters.xt_user.org_id == 10106"
109 115
                        @click="settlementPrint(scope.row)">结算单
@@ -235,6 +241,40 @@
235 241
       }
236 242
     },
237 243
     methods: {
244
+      uploadInfo(row) {
245
+        var that = this;
246
+        axios.get('http://127.0.0.1:9532/api/settlelist/get', {
247
+          params: {
248
+            order_id: row.id,
249
+            admin_user_id: this.$store.getters.xt_user.user.id
250
+          }
251
+        }).then(function (response) {
252
+          if (response.data.state == 0) {
253
+            that.$message.error(response.data.msg);
254
+            return false
255
+          } else {
256
+
257
+            if (response.data.data.failed_code == -10) {
258
+              // that.$message.error(response.data.data.msg)
259
+              that.$confirm(response.data.data.msg, '医保错误信息', {
260
+                confirmButtonText: '确 定',
261
+                type: 'warning'
262
+              }).then(() => {
263
+
264
+              }).catch(() => {
265
+              })
266
+
267
+            } else {
268
+              that.$message.success("上传成功");
269
+              row.result.id = response.data.data.result.id
270
+            }
271
+
272
+
273
+          }
274
+        }).catch(function (error) {
275
+        })
276
+      },
277
+
238 278
       fetchAllAdminUsers() {
239 279
         fetchAllAdminUsers().then(response => {
240 280
           if (response.data.state == 1) {
@@ -431,6 +471,38 @@
431 471
                 time = this.getTimes(order.settle_accounts_date)
432 472
               }
433 473
 
474
+              var hifmi_pay = 0.00;
475
+
476
+              if(order.setl_detail.length > 0){
477
+                var jsonObj = JSON.parse(order.setl_detail);
478
+                for (let i = 0; i < jsonObj.length; i++) {
479
+                  if (order.insutype == '310') {
480
+                    if (jsonObj[i].fund_pay_type == '310300') {
481
+                      hifmi_pay = jsonObj[i].fund_payamt
482
+                    }
483
+
484
+                  } else if (order.insutype == '390')
485
+                    if (order.fund_pay_type == '390200') {
486
+                      hifmi_pay = jsonObj[i].fund_payamt
487
+                    }
488
+                }
489
+              }
490
+              var hifmi_pay = 0.00;
491
+
492
+              if(order.setl_detail.length > 0){
493
+                var jsonObj = JSON.parse(order.setl_detail);
494
+                for (let i = 0; i < jsonObj.length; i++) {
495
+                  if (order.insutype == '310') {
496
+                    if (jsonObj[i].fund_pay_type == '310300') {
497
+                      hifmi_pay = jsonObj[i].fund_payamt
498
+                    }
499
+                  }
500
+                  if (order.insutype == '390')
501
+                    if (jsonObj[i].fund_pay_type == '390200') {
502
+                      hifmi_pay = jsonObj[i].fund_payamt
503
+                    }
504
+                }
505
+              }
434 506
 
435 507
               let obj = {
436 508
                 '就诊号': order.mdtrt_id,
@@ -441,7 +513,7 @@
441 513
                 '实收金额': order.medfee_sumamt,
442 514
                 '医保统筹金额': order.hifp_pay,
443 515
                 '大额基金金额': order.hifob_pay,
444
-                '大病基金金额': order.hifmi_pay,
516
+                '大病基金金额': hifmi_pay,
445 517
                 '补充保险基金金额': order.hifes_pay,
446 518
                 '医疗救助基金金额': order.maf_pay,
447 519
                 '公务员基金': order.cvlserv_pay,
@@ -461,11 +533,12 @@
461 533
                 '收费状态': order_status,
462 534
                 '退费日期': ''
463 535
               };
536
+
464 537
               list.push(obj)
465 538
             }
466 539
             import('@/vendor/Export2Excel').then(excel => {
467
-              const tHeader = ['就诊号', '患者姓名', '开处时间','险种类型', '应收金额', '实收金额', '医保统筹金额', '大额基金金额', '大病基金金额', '补充保险基金金额', '医疗救助基金金额', '公务员基金', '个人支付基金', '个人账户支付金额', '科室', '医生姓名', '收费类别', '收费者姓名', '总金额', '现金支付', '账户支付', '支付宝支付', '微信支付', '其他支付', '收费时间', '收费状态', '退费日期'];
468
-              const filterVal = ['就诊号', '患者姓名','开处时间','险种类型', '应收金额', '实收金额', '医保统筹金额', '大额基金金额', '大病基金金额', '补充保险基金金额', '医疗救助基金金额', '公务员基金', '个人支付基金', '个人账户支付金额', '科室', '医生姓名', '收费类别', '收费者姓名', '总金额', '现金支付', '账户支付', '支付宝支付', '微信支付', '其他支付', '收费时间', '收费状态', '退费日期'];
540
+              const tHeader = ['就诊号', '患者姓名', '开处时间', '险种类型', '应收金额', '实收金额', '医保统筹金额', '大额基金金额', '大病基金金额', '补充保险基金金额', '医疗救助基金金额', '公务员基金', '个人支付基金', '个人账户支付金额', '科室', '医生姓名', '收费类别', '收费者姓名', '总金额', '现金支付', '账户支付', '支付宝支付', '微信支付', '其他支付', '收费时间', '收费状态', '退费日期'];
541
+              const filterVal = ['就诊号', '患者姓名', '开处时间', '险种类型', '应收金额', '实收金额', '医保统筹金额', '大额基金金额', '大病基金金额', '补充保险基金金额', '医疗救助基金金额', '公务员基金', '个人支付基金', '个人账户支付金额', '科室', '医生姓名', '收费类别', '收费者姓名', '总金额', '现金支付', '账户支付', '支付宝支付', '微信支付', '其他支付', '收费时间', '收费状态', '退费日期'];
469 542
               const data = this.formatJson(filterVal, list);
470 543
               excel.export_json_to_excel({
471 544
                 header: tHeader,

+ 6 - 3
src/xt_pages/outpatientDoctorStation/components/deskPrescription.vue View File

@@ -361,7 +361,7 @@
361 361
               </el-tab-pane>
362 362
               <el-tab-pane label="项目组套" name="2">
363 363
                 <div style="width: 100%;flex:1;overflow-y: auto;">
364
-                  <el-table :data="tabPrjectTeam" border
364
+                  <el-table :data="tabPrjectTeam" border ref="tabProjectTeam"
365 365
                             :height="multipleTableHeight != '' ? multipleTableHeight : '200'"
366 366
                             :row-style="{ color: '#303133' }"
367 367
                             :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}"
@@ -2092,7 +2092,6 @@
2092 2092
           '-' +
2093 2093
           (nowDay < 10 ? '0' + nowDay : nowDay) + ' ' + (hours < 10 ? '0' + hours : hours) +
2094 2094
           ':' + (min < 10 ? '0' + min : min);
2095
-
2096 2095
         this.prescriptions.push({
2097 2096
           id: 0,
2098 2097
           name: newTabName,
@@ -2100,7 +2099,8 @@
2100 2099
           advices: [],
2101 2100
           project: [],
2102 2101
           addition: [],
2103
-          pre_time: nowTime
2102
+          pre_time: this.prescriptions[0].pre_time
2103
+          // pre_time: nowTime
2104 2104
 
2105 2105
         });
2106 2106
         this.editableTabsValue = newTabName;
@@ -2589,6 +2589,9 @@
2589 2589
              this.hisList = hisprojectlist
2590 2590
           }
2591 2591
         })
2592
+      },
2593
+      clearSelection(){
2594
+        this.$refs.tabProjectTeam.clearSelection()
2592 2595
       }
2593 2596
     }, mounted() {
2594 2597
       this.request_record_date = this.record_date

+ 939 - 0
src/xt_pages/outpatientDoctorStation/components/dialysisIndex.vue View File

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

+ 3 - 1
src/xt_pages/outpatientDoctorStation/components/inquiriesDetail.vue View File

@@ -111,7 +111,7 @@
111 111
       append-to-body>
112 112
 
113 113
       <print v-if="activeName == 'first'" :paramsObj='paramsObj'></print>
114
-      <recordPrint v-if="activeName == 'second'" :patientid="patientid"></recordPrint>
114
+      <recordPrint v-if="activeName == 'second'" ref="recordPrint" :patientid="patientid"></recordPrint>
115 115
     </el-dialog>
116 116
   </el-dialog>
117 117
 </div>
@@ -192,6 +192,7 @@
192 192
           var record_date = this.format(this.case_history.sick_date)
193 193
           this.patientid = this.patientInfo.id
194 194
           this.innerVisible = true
195
+          this.$refs.recordPrint.show(this.patientid)
195 196
           // this.$router.push("/outpatientDoctorStation/recordPrint?record="+record_date+"&patient_id="+this.case_history.patient_id)
196 197
         }
197 198
       },
@@ -241,6 +242,7 @@
241 242
         let params={
242 243
           id:id,
243 244
         }
245
+        console.log(id)
244 246
         getHisPrescriptionInfo(params).then(response => {
245 247
           if (response.data.state == 0) {
246 248
             this.$message.error(response.data.msg)

+ 14 - 10
src/xt_pages/outpatientDoctorStation/components/prescriptionTable.vue View File

@@ -41,11 +41,11 @@
41 41
       </el-table-column>
42 42
 
43 43
 
44
-      <el-table-column align="center" prop="day" width="50" label="天数">
44
+      <el-table-column align="center" prop="day" width="70" label="天数">
45 45
         <template slot-scope="scope">
46
-          <el-input v-model="scope.row.day" @input="getDay(scope)" placeholder=""></el-input>
47
-          <div>{{'天'}}</div>
48
-
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 49
         </template>
50 50
       </el-table-column>
51 51
 
@@ -57,10 +57,12 @@
57 57
           </div>
58 58
         </template>
59 59
       </el-table-column>
60
-      <el-table-column align="center" prop="retail_price" width="60" label="单价">
60
+      <el-table-column align="center" prop="retail_price" width="80" label="单价">
61 61
         <template slot-scope="scope">
62
-          <el-input v-model="scope.row.retail_price" placeholder="" readonly></el-input>
63
-          <div>{{'元'}}</div>
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>
64 66
 
65 67
         </template>
66 68
       </el-table-column>
@@ -108,10 +110,12 @@
108 110
           <el-input v-model="scope.row.execution_frequency" placeholder=""></el-input>
109 111
         </template>
110 112
       </el-table-column>
111
-      <el-table-column align="center" prop="number_days" width="50" label="天数">
113
+      <el-table-column align="center" prop="number_days" width="70" label="天数">
112 114
         <template slot-scope="scope">
113
-          <el-input v-model="scope.row.number_days" @input="getProjectDay(scope)" placeholder=""></el-input>
114
-          <div>{{'天'}}</div>
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>
115 119
         </template>
116 120
       </el-table-column>
117 121
       <el-table-column align="center" prop="total" width="70" label="总量">

+ 3 - 8
src/xt_pages/outpatientRegistration/index.vue View File

@@ -315,7 +315,7 @@
315 315
             <div class="nameTitle">患者挂号信息:</div>
316 316
             <div class="formMain">
317 317
                 <el-form class="basicForm" :model="form" :rules="rules" ref="form" label-width="100px">
318
-                    <el-form-item label="挂号类型:" prop="register" :validate-event="is_Name">
318
+                    <el-form-item label="挂号类型:" >
319 319
                         <el-select v-model="form.register" placeholder="请选择">
320 320
                             <el-option
321 321
                                     v-for="item in his_registers"
@@ -611,7 +611,6 @@
611 611
           name: [{ required: true, message: '患者姓名不能为空', trigger: 'blur' }],
612 612
           sex: [{ required: true, message: '患者性别不能为空', trigger: 'blur' }],
613 613
           idCard: [{ required: true, message: '证件号码不能为空', trigger: 'blur' }],
614
-          register: [{ required: true, message: '请选择挂号类型', trigger: 'blur' }],
615 614
           doctor: [{ required: true, message: '请选择医生', trigger: 'blur' }],
616 615
           department: [{ required: true, message: '请填写科室', trigger: 'blur' }],
617 616
           age: [{ required: true, message: '患者年龄不能为空', trigger: 'blur' }],
@@ -1121,12 +1120,6 @@
1121 1120
           this.$message.error('患者性别不能为空')
1122 1121
         }
1123 1122
 
1124
-        if (this.form.register == '') {
1125
-          this.$message.error('挂号类型不能为空');
1126
-          this.is_Name = true;
1127
-          return
1128
-        }
1129
-
1130 1123
         if (this.form.doctor == '') {
1131 1124
           this.$message.error('医生不能为空');
1132 1125
           this.is_Name = true;
@@ -1461,7 +1454,9 @@
1461 1454
         this.form.certificates = 2;
1462 1455
         this.form.id_card_type = 1
1463 1456
       }else{
1457
+        this.form.settlementValue = 1;
1464 1458
         this.form.registrationFee = 0;
1459
+        this.form.medicalExpenses = 0;
1465 1460
         this.form.certificates = 1;
1466 1461
         this.form.id_card_type = 2
1467 1462
       }

+ 10 - 10
src/xt_pages/qcd/basicInformationAnalysis.vue View File

@@ -256,7 +256,7 @@
256 256
                 </span>
257 257
                 <span v-if="lapsetoType == 0 || lapsetoType == 2"><p>转出:{{outTotal}}人({{(outTotal/patientCount*100).toFixed(1)}}%)</p>
258 258
                  <el-progress :percentage="(outTotal/patientCount*100).toFixed(1)"></el-progress>
259
-                </span> 
259
+                </span>
260 260
               </div>
261 261
             </div>
262 262
             <div class="infoOne">
@@ -709,7 +709,7 @@ export default {
709 709
       //获取本月当前机构的透析模式
710 710
       const startDate = moment().subtract('month', 0).format('YYYY-MM') + '-01'
711 711
       const endDate = moment(new Date()).format('YYYY-MM-DD')
712
-     
712
+
713 713
       var now = new Date()
714 714
       var nowMonth = now.getMonth(); //当前月
715 715
       var nowYear = now.getFullYear(); //当前年
@@ -720,7 +720,7 @@ export default {
720 720
       //本月的结束时间
721 721
       var monthEndDate = new Date(nowYear, nowMonth+1, 0);
722 722
       var timeEnd=Date.parse(monthEndDate)/1000-1;//s
723
-     // console.log("本月最后一天",timeEnd)
723
+      // console.log("本月最后一天",timeEnd)
724 724
       //本月
725 725
       if(state == 0){
726 726
        //统计透析总量
@@ -745,7 +745,7 @@ export default {
745 745
         this.listQuery.start_time = ""
746 746
         this.listQuery.end_time = ""
747 747
         const startDate = moment().subtract('month', 3).format('YYYY-MM-DD')
748
-       
748
+
749 749
         var startunitx = Date.parse(startDate)/1000
750 750
         // console.log("开始时间搓",startunitx)
751 751
         const endDate = moment(new Date()).format('YYYY-MM-DD')
@@ -929,7 +929,7 @@ export default {
929 929
     },
930 930
     //统计转归
931 931
     getTotalLapseCount(startDate,endDate,lapsetoType,sourceType ){
932
-   
932
+
933 933
        this.modesDataTwo.series = []
934 934
        this.modesDataTwo.xAxis = []
935 935
       getTotalLapseCount(startDate,endDate,lapsetoType,sourceType).then(response=>{
@@ -939,7 +939,7 @@ export default {
939 939
              {name:"转出",count:0}
940 940
            ]
941 941
           var patients =  response.data.data.patients
942
-      
942
+
943 943
           this.rollOutTotal = patients.length
944 944
 
945 945
           var patienttwo = response.data.data.patienttwo
@@ -948,7 +948,7 @@ export default {
948 948
           this.patientCount = count
949 949
 
950 950
           var rollout = response.data.data.rollout
951
-        
951
+
952 952
 
953 953
           for(let i=0;i<arr.length;i++){
954 954
             arr[0].count = this.rollOutTotal
@@ -1000,7 +1000,7 @@ export default {
1000 1000
       getTotalAgeCount(timeStar,timeEnd,lapsetoType,sourceType).then(response=>{
1001 1001
          if(response.data.state == 1){
1002 1002
           var ageCount =  response.data.data.ageCount
1003
-        
1003
+
1004 1004
           var arr = []
1005 1005
           arr =  ageCount.sort(this.compare('age'))
1006 1006
           this.ageCount = arr
@@ -1022,7 +1022,7 @@ export default {
1022 1022
       getTotalDialysisCount(timeStar,timeEnd,lapsetoType,sourceType).then(response=>{
1023 1023
          if(response.data.state == 1){
1024 1024
            var dataage =  response.data.data.dataage
1025
-          
1025
+
1026 1026
            this.dialysisAge = dataage
1027 1027
 
1028 1028
          }
@@ -1153,7 +1153,7 @@ export default {
1153 1153
           start_time:this.start,
1154 1154
           end_time:this.end,
1155 1155
           mode_id:this.mode_id,
1156
-          
1156
+
1157 1157
         }
1158 1158
         this.modesData.series = []
1159 1159
         this.modesData.xAxis = []

+ 19 - 10
src/xt_pages/stock/detail/print.vue View File

@@ -81,7 +81,8 @@
81 81
               <td width="633" style="line-height: 50px">合计</td>
82 82
               <td width="80" style="line-height: 50px">
83 83
                 <span v-if="type == 1">{{calTotalPrice()}}</span>
84
-                <span v-if="type == 3">{{getTotalPrice().toFixed(2)}}</span>
84
+                <span v-if="type == 3 && org_id!=10090">{{getTotalPrice().toFixed(2)}}</span>
85
+                <span v-if="type == 3 && org_id==10090">{{getTotalPriceOne().toFixed(2)}}</span>
85 86
               </td>
86 87
               <td></td>
87 88
             </tr>
@@ -186,18 +187,18 @@
186 187
         getPrintStockGood(this.queryParams).then(response => {
187 188
           if (response.data.state == 1) {
188 189
             var stockTotal = response.data.data.stockTotal
189
-            console.log("stocktOTl",stockTotal)
190
+          
190 191
             this.stockTotal = stockTotal
191
-            console.log("导出数据",response.data.data.list)
192
+           
192 193
             var info = response.data.data.info
193
-            console.log("infor2222222",info)
194
+           
194 195
             this.wareOutInfo = info
195 196
             var org_id = response.data.data.orgid
196
-            console.log("org_id",org_id)
197
+          
197 198
             this.org_id = org_id
198 199
 
199 200
             var informationlist = response.data.data.infomationList
200
-            console.log('数据列表',informationlist)
201
+           
201 202
             this.informationList = informationlist
202 203
             this.stockDatas = []
203 204
             for (let i = 0; i < response.data.data.list.length; i++) {
@@ -205,7 +206,7 @@
205 206
                 if (response.data.data.list[i].query_warehousing_info.length > 0) {
206 207
                   this.stockDatas.push(response.data.data.list[i])
207 208
                 }
208
-
209
+                console.log("入库打印数据源",this.stockDatas)
209 210
               } else if (this.type == 2) {
210 211
                 if (response.data.data.list[i].query_sales_return_info.length > 0) {
211 212
                   this.stockDatas.push(response.data.data.list[i])
@@ -218,6 +219,7 @@
218 219
                 }
219 220
                
220 221
                 console.log("出库打印数据源",this.stockDatas)
222
+
221 223
                 
222 224
               } else if (this.type == 4) {
223 225
                 if (response.data.data.list[i].query_cancel_stock_info.length > 0) {
@@ -373,14 +375,14 @@
373 375
        for(let i=0;i<this.informationList.length;i++){
374 376
         for(let j=0;j<this.wareOutInfo.length;j++){
375 377
            if(this.informationList[i].id == this.wareOutInfo[j].good_id){
376
-             this.wareOutInfo[j].retail_price =  this.informationList[i].retail_price 
378
+             this.wareOutInfo[j].buy_price =  this.informationList[i].buy_price 
377 379
            }
378 380
         }
379 381
        }
380 382
       
381 383
        for(let j=0;j<this.wareOutInfo.length;j++){
382 384
          if(id == this.wareOutInfo[j].good_id){
383
-            sum += (this.wareOutInfo[j].retail_price * this.wareOutInfo[j].count).toFixed(2)
385
+            sum += (this.wareOutInfo[j].buy_price * this.wareOutInfo[j].count).toFixed(2)
384 386
          }
385 387
        }
386 388
        
@@ -391,7 +393,7 @@
391 393
        var price = 0
392 394
        for(let i=0;i<this.informationList.length;i++){
393 395
           if(id == this.informationList[i].id){
394
-             price = this.informationList[i].retail_price
396
+             price = this.informationList[i].buy_price
395 397
           }
396 398
        }
397 399
        return price
@@ -403,6 +405,13 @@
403 405
        }
404 406
        return total_price
405 407
      },
408
+     getTotalPriceOne(){
409
+       var total_price = 0
410
+       for(let i=0;i<this.stockDatas.length;i++){
411
+         total_price +=(this.getWareOut(this.stockDatas[i].id) * this.getReailPrice(this.stockDatas[i].id))
412
+       }
413
+       return total_price
414
+     },
406 415
      unique(arr) {
407 416
         const res = new Map();
408 417
         return arr.filter((arr) => !res.has(arr.id) && res.set(arr.id, 1));

+ 54 - 27
src/xt_pages/stock/detail/stockInDetail.vue View File

@@ -235,6 +235,8 @@ export default {
235 235
     this.goodUnit = this.$store.getters.good_unit
236 236
 
237 237
     this.getPrintStockGood()
238
+    this.org_id = this.$store.getters.xt_user.template_info.org_id
239
+    console.log("机构ID",this.org_id)
238 240
   },
239 241
   data() {
240 242
     return {
@@ -268,7 +270,8 @@ export default {
268 270
       dealer: [],
269 271
       tableList:[],
270 272
       goodUnit:[],
271
-      stockTotal:[]
273
+      stockTotal:[],
274
+      org_id:0,
272 275
     };
273 276
   },
274 277
   methods: {
@@ -389,13 +392,10 @@ export default {
389 392
           return false;
390 393
         } else {
391 394
           this.total = response.data.data.total;
392
-          console.log("数据源头list2222222",response.data.data.list)
393
-
394 395
           for (let i = 0; i < response.data.data.list.length; i++) {
395 396
             var obj = response.data.data.list[i];
396 397
             obj["is_total"] = 0;
397 398
             this.cancelStockDate.push(obj);
398
-            // this.tableList.push(obj)
399 399
           }
400 400
           this.cancelStockDate.push({
401 401
             warehousing_order: "合计",
@@ -439,7 +439,7 @@ export default {
439 439
           var alen = this.adminUserOptions.length;
440 440
           for (let index = 0; index < alen; index++) {
441 441
             if (this.adminUserOptions[index].user_type == 2) {
442
-              // this.doctorOptions.push(this.adminUserOptions[index]);
442
+            
443 443
             }
444 444
           }
445 445
         }
@@ -642,9 +642,10 @@ export default {
642 642
        end_time:this.end_time,
643 643
        type:1,
644 644
      }
645
-   
645
+     
646 646
      getPrintStockGood(params).then(response=>{
647 647
         if(response.data.state == 1){
648
+          this.tableList = []
648 649
           var stockTotal =  response.data.data.stockTotal
649 650
         
650 651
           this.stockTotal = stockTotal
@@ -655,9 +656,7 @@ export default {
655 656
                this.tableList.push(list[i])
656 657
              }
657 658
           }
658
-         
659
-       
660
-       
659
+          console.log("数据源头2222222222",this.tableList)
661 660
         }
662 661
      })
663 662
    },
@@ -727,6 +726,11 @@ export default {
727 726
         const res = new Map();
728 727
         return arr.filter((arr) => !res.has(arr.specification_name) && res.set(arr.specification_name, 1));
729 728
       },
729
+      uniqueOne(arr) {
730
+        const res = new Map();
731
+        return arr.filter((arr) => !res.has(arr.id) && res.set(arr.id, 1));
732
+      },
733
+      
730 734
       exportList(){
731 735
         var obj = {index:"合计",total:0}
732 736
         obj.total = this.calTotalPrice()
@@ -740,25 +744,48 @@ export default {
740 744
           this.tableList[i].remark = this.tableList[i].query_warehousing_info[0].remark
741 745
 
742 746
         }
743
-        var arr = this.unique(this.tableList)
744
-        console.log("arrrr",arr)
745
-        this.tableList = arr
746
-        this.tableList.push(obj)
747
-        console.log("数据222222",this.tableList)
748
-      
749
-        import('@/vendor/Export2Excel').then(excel => {
750
-        const tHeader = ['序号','耗材名称', '规格型号', '单位','数量','出货价','总价','备注']
751
-        const filterVal = ['index','good_name', 'specification_name', 'min_unit','count','price','total','remark']
747
+        console.log("总共条数",this.tableList)
748
+        if(this.org_id == 10024){
749
+          var arr = this.uniqueOne(this.tableList)
750
+          this.tableList = arr
751
+          this.tableList.push(obj)
752
+          console.log("去重后条数",this.tableList)
752 753
         
753
-        const data = this.formatJson(filterVal, this.tableList)
754
-        
755
-          excel.export_json_to_excel({
756
-            header: tHeader,
757
-            data,
758
-            filename: '耗材入库明细'
759
-          })
760
-            this.downloadLoading = false
761
-          })
754
+          import('@/vendor/Export2Excel').then(excel => {
755
+          const tHeader = ['序号','耗材名称', '规格型号', '单位','数量','出货价','总价','备注']
756
+          const filterVal = ['index','good_name', 'specification_name', 'min_unit','count','price','total','remark']
757
+          
758
+          const data = this.formatJson(filterVal, this.tableList)
759
+          console.log("data222222222",data)
760
+            excel.export_json_to_excel({
761
+              header: tHeader,
762
+              data,
763
+              filename: '耗材入库明细'
764
+            })
765
+              this.downloadLoading = false
766
+            })
767
+        }
768
+        if(this.org_id !=10024){
769
+           var arr = this.unique(this.tableList)
770
+            this.tableList = arr
771
+            this.tableList.push(obj)
772
+            console.log("去重后条数",this.tableList)
773
+          
774
+            import('@/vendor/Export2Excel').then(excel => {
775
+            const tHeader = ['序号','耗材名称', '规格型号', '单位','数量','出货价','总价','备注']
776
+            const filterVal = ['index','good_name', 'specification_name', 'min_unit','count','price','total','remark']
777
+            
778
+            const data = this.formatJson(filterVal, this.tableList)
779
+            console.log("data222222222",data)
780
+              excel.export_json_to_excel({
781
+                header: tHeader,
782
+                data,
783
+                filename: '耗材入库明细'
784
+              })
785
+                this.downloadLoading = false
786
+              })
787
+        }
788
+     
762 789
         },
763 790
      formatJson(filterVal, jsonData) {
764 791
         return jsonData.map(v => filterVal.map(j => v[j]));

+ 4 - 5
src/xt_pages/stock/detail/stockOutDetail.vue View File

@@ -743,12 +743,11 @@ export default {
743 743
       },
744 744
 
745 745
      exportList(){
746
-      console.log("数据22222",this.tableList)
747
-      console.log("数据3333",this.goodInfoData)
746
+      
748 747
       for(let i=0;i<this.tableList.length;i++){
749 748
          for(let j=0;j<this.goodInfoData.length;j++){
750 749
             if(this.tableList[i].id === this.goodInfoData[j].id){
751
-               this.tableList[i].retail_price = this.goodInfoData[j].retail_price
750
+               this.tableList[i].buy_price = this.goodInfoData[j].buy_price
752 751
             }
753 752
          }
754 753
       }
@@ -760,7 +759,7 @@ export default {
760 759
         this.tableList[i].min_unit = this.getUnit(this.tableList[i].good_unit)
761 760
         this.tableList[i].count = this.getStockCount(this.tableList[i].id)
762 761
         // this.tableList[i].price = this.tableList[i].query_warehouseout_info[0].buy_price
763
-        this.tableList[i].total = (this.getStockCount(this.tableList[i].id) * this.tableList[i].retail_price).toFixed(2)
762
+        this.tableList[i].total = (this.getStockCount(this.tableList[i].id) * this.tableList[i].buy_price).toFixed(2)
764 763
         this.tableList[i].remark = this.tableList[i].query_warehouseout_info[0].remark
765 764
        }
766 765
        var arr = this.unique(this.tableList)
@@ -769,7 +768,7 @@ export default {
769 768
        this.tableList.push(obj)
770 769
        import('@/vendor/Export2Excel').then(excel => {
771 770
        const tHeader = ['序号','耗材名称', '规格型号', '单位','数量','出货价','总价','备注']
772
-       const filterVal = ['index','good_name', 'specification_name', 'min_unit','count','retail_price','total','remark']
771
+       const filterVal = ['index','good_name', 'specification_name', 'min_unit','count','buy_price','total','remark']
773 772
 
774 773
        const data = this.formatJson(filterVal, this.tableList)
775 774
        console.log("data",data)

+ 9 - 3
src/xt_pages/stock/drugs/components/drugOutDetail.vue View File

@@ -456,17 +456,23 @@ export default {
456 456
         for(let i=0;i<this.tableList.length;i++){
457 457
           for(let j=0;j<this.drugList.length;j++){
458 458
              if(this.tableList[i].drug_id == this.drugList[j].id){
459
-               this.tableList[i].retail_price = this.drugList[j].retail_price
459
+               this.tableList[i].last_price = this.drugList[j].last_price
460
+               
460 461
              }
461 462
           }
462 463
           this.tableList[i].index = i+1
463 464
         }
465
+        for(let i=0;i<this.tableList.length;i++){
466
+           this.tableList[i].total_price = this.tableList[i].last_price * this.tableList[i].count
467
+        }
468
+       console.log("列表数据333333333",this.tableList)
469
+      
464 470
        import('@/vendor/Export2Excel').then(excel => {
465 471
        const tHeader = ['序号','药品名称', '规格型号', '单位','数量','单价','总价','备注']
466
-       const filterVal = ['index','drug_name', 'drug_spec', 'min_unit','count','retail_price','total_price','remark']
472
+       const filterVal = ['index','drug_name', 'drug_spec', 'min_unit','count','last_price','total_price','remark']
467 473
        let obj = {'index':'合计','total_price':0}
468 474
        for(let i=0;i<this.tableList.length;i++){
469
-         obj.total_price += this.tableList[i].retail_price * this.tableList[i].count
475
+         obj.total_price += (this.tableList[i].last_price * this.tableList[i].count)
470 476
        }
471 477
        for(let j=0;j<this.tableList.length;j++){
472 478
           this.tableList[j].total_price = this.tableList[j].total_price.toFixed(2)

+ 2 - 2
src/xt_pages/stock/drugs/drugCancelDetailPrint.vue View File

@@ -56,7 +56,7 @@
56 56
             <tbody>
57 57
             <tr>
58 58
               <td width="633" style="line-height: 50px">合计</td>
59
-              <td width="80" style="line-height: 50px">{{getTotal()}}</td>
59
+              <td width="80" style="line-height: 50px">{{getTotal().toFixed(2)}}</td>
60 60
               <td></td>
61 61
             </tr>
62 62
 
@@ -172,7 +172,7 @@
172 172
       getTotal(){
173 173
          var total = 0
174 174
          for(let i=0;i<this.cancelStockDate.length;i++){
175
-            total += this.cancelStockDate[i].price
175
+            total += this.cancelStockDate[i].price*this.cancelStockDate[i].count 
176 176
          }
177 177
          return total
178 178
       }

+ 2 - 2
src/xt_pages/stock/drugs/drugCancelOurderPrint.vue View File

@@ -55,7 +55,7 @@
55 55
             <tbody>
56 56
             <tr>
57 57
               <td width="633" style="line-height: 50px">合计</td>
58
-              <td width="80" style="line-height: 50px">{{getTotal()}}</td>
58
+              <td width="80" style="line-height: 50px">{{getTotal().toFixed(2)}}</td>
59 59
               <td></td>
60 60
             </tr>
61 61
 
@@ -171,7 +171,7 @@
171 171
       getTotal(){
172 172
          var total = 0
173 173
          for(let i=0;i<this.cancelStockDate.length;i++){
174
-            total += this.cancelStockDate[i].price
174
+            total += this.cancelStockDate[i].price*this.cancelStockDate[i].count
175 175
          }
176 176
          return total
177 177
       }

+ 2 - 1
src/xt_pages/stock/drugs/drugOutOrderPrint.vue View File

@@ -168,6 +168,7 @@
168 168
         limit:this.limit,
169 169
         page:this.page,
170 170
        }
171
+       console.log("出库数据22222",params)
171 172
       getDrugOutDetail(params).then(response=>{
172 173
         if(response.data.state == 1){
173 174
           var drugInOrder = response.data.data.order
@@ -249,7 +250,7 @@
249 250
         var price = 0
250 251
         for(let i=0;i<this.drugList.length;i++){
251 252
           if(id == this.drugList[i].id){
252
-             price = this.drugList[i].retail_price
253
+             price = this.drugList[i].last_price
253 254
           }
254 255
         }
255 256
         return price

+ 2 - 2
src/xt_pages/stock/drugs/drugQueryPrint.vue View File

@@ -93,8 +93,8 @@
93 93
         signAndWeighBoxPatients: 'sign-and-weigh-box-patients',
94 94
         start_time: '',
95 95
         end_time: '',
96
-        page: 1,
97
-        limit: 10000,
96
+        page: this.$route.query.page,
97
+        limit: this.$route.query.limit,
98 98
         goodType: [],
99 99
         goodInfo: [],
100 100
         tempArr: [],

+ 15 - 11
src/xt_pages/stock/drugs/drugStockInOrderDetailPrint.vue View File

@@ -10,7 +10,7 @@
10 10
         <div class="dialysis-print-order">
11 11
           <div style="font-size:22px;font-weight:bold;text-align:center;">{{ orgName }}</div>
12 12
           <div class="order-title" style="font-size:18px;padding-top:0;">药品入库登记表</div>
13
-         
13
+
14 14
           <div style="float: right;margin-bottom: 1px;">{{getDateTwo()}}</div>
15 15
 
16 16
           <table class="print-table" border="1">
@@ -22,7 +22,7 @@
22 22
               <td style="line-height:18px;" width="80">生产<br>厂商</td>
23 23
               <td style="line-height:18px;" width="80">单位</td>
24 24
               <td style="line-height:18px;" width="80">进货价</td>
25
-              <td style="line-height:18px;" width="80">入库<br>数量</td> 
25
+              <td style="line-height:18px;" width="80">入库<br>数量</td>
26 26
               <td style="line-height:18px;" width="60">总价</td>
27 27
               <td style="line-height:18px;" width="80">批号</td>
28 28
               <td style="line-height:18px;" width="120">生产日期</td>
@@ -50,7 +50,7 @@
50 50
               <td style="line-height: 18px">
51 51
                    <span>{{ item.warehousing_count }}</span>
52 52
               </td>
53
-              
53
+
54 54
               <td style="line-height:18px">
55 55
                   <span>{{(item.warehousing_count * item.price).toFixed(2)}}</span>
56 56
               </td>
@@ -66,15 +66,19 @@
66 66
             </tr>
67 67
             </tbody>
68 68
           </table>
69
-        
70 69
 
71
-          <div style="display:flex;margin-top:1px;float:right;">
70
+          <div style="display:flex;margin-top:1px;float:right;" v-if="orgId == 10024">
72 71
             <div style="width:50px;">审批:</div><div style="width:100px;"></div>
73
-            <div style="width:80px;">药材主任:</div><div style="width:100px;"></div>
74 72
             <div style="width:50px;">会计:</div><div style="width:100px;"><span v-if='orgId == 10024'>徐立琼</span></div>
75 73
             <div style="width:50px;">审核:</div><div style="width:100px;"><span v-if='orgId == 10024'>徐立琼</span></div>
76 74
             <div style="width:70px;">制单人:</div><div style="width:100px;">{{ getXuserName(this.WarehouseInfo.warehouse.creater) }}</div>
77 75
           </div>
76
+          <div style="display:flex;margin-top:1px;float:right;" v-if="orgId !=10024">
77
+            <div style="width:50px;">审批:</div><div style="width:100px;"></div>
78
+            <div style="width:80px;">药材主任:</div><div style="width:100px;"></div>
79
+            <div style="width:50px;">会计:</div><div style="width:100px;"></div>
80
+            <div style="width:70px;">制单人:</div><div style="width:100px;">{{ getXuserName(this.WarehouseInfo.warehouse.creater) }}</div>
81
+          </div>
78 82
         </div>
79 83
 
80 84
       </div>
@@ -165,7 +169,7 @@
165 169
         }
166 170
         return ''
167 171
       },
168
-     
172
+
169 173
       printThisPage() {
170 174
         var ptime = Math.round(new Date().getTime() / 1000)
171 175
         this.print_time = uParseTime(ptime, '{y}-{m}-{d} {h}:{i}')
@@ -177,7 +181,7 @@
177 181
           scanStyles: false
178 182
         })
179 183
       },
180
-   
184
+
181 185
       getUnit(id){
182 186
         var name = ""
183 187
         for(let i=0;i<this.goodUnit.length;i++){
@@ -229,13 +233,13 @@
229 233
             for (let i = 0; i < response.data.data.list.length; i++) {
230 234
               this.list.push(response.data.data.list[i])
231 235
             }
232
-           
236
+
233 237
             for(let j=0;j<this.list.length;j++){
234 238
               this.list[j].manufacturer_name = ""
235 239
             }
236 240
 
237 241
             for(let i=0;i<this.list.length;i++){
238
-           
242
+
239 243
               for(let j=0;j<this.manufacturer.length;j++){
240 244
                  if(this.list[i].manufacturer == this.manufacturer[j].id){
241 245
                     this.list[i].manufacturer_name = this.manufacturer[j].manufacturer_name
@@ -331,7 +335,7 @@
331 335
       const order_id = this.$route.query.id;
332 336
       this.GetOrderDetail(order_id);
333 337
       this.getList()
334
-      
338
+
335 339
     }
336 340
 
337 341
   }

+ 59 - 9
src/xt_pages/stock/drugs/drugStockOutOrderDetailPrint.vue View File

@@ -9,7 +9,9 @@
9 9
       <div id="dialysis-print-box">
10 10
         <div class="dialysis-print-order">
11 11
          <div class="order-yy-name" style="font-weight:bold;">{{orgName}}</div>
12
-          <div class="order-title" style="font-weight:none;">药品出库登记表</div>
12
+          <div class="order-title" style="font-weight:normal;">药品出库登记表</div>
13
+         <div class="order-yy-name" style="font-size:22px;font-weight:bold;letter-spacing:0px;">{{orgName}}</div>
14
+          <div class="order-title" style="font-weight:500;font-size:18px;">药品出库登记表</div>
13 15
 
14 16
           <div style="float: right;margin-bottom: 1px;">{{getDateTwo()}}</div>
15 17
 
@@ -22,7 +24,7 @@
22 24
               <td style="line-height: 50px" width="80">出货数量</td>
23 25
               <td style="line-height:50px" width="80">出库价格</td>
24 26
               <td style="line-height: 50px" width="">总价</td>
25
-              <td style="line-height: 50px" width="">批</td>
27
+              <td style="line-height: 50px" width="">批</td>
26 28
               <td style="line-height: 50px" width="">生产日期</td>
27 29
               <td style="line-height: 50px" width="">有效日期</td>
28 30
             </tr>
@@ -47,9 +49,9 @@
47 49
              <td  style="line-height:50px">
48 50
                 {{(item.count * item.price).toFixed(2)}}
49 51
              </td>
50
-             <td></td>
51
-             <td></td>
52
-             <td></td>
52
+             <td>{{getNumber(item.drug_id)}}</td>
53
+             <td>{{getProductDate(item.drug_id)}}</td>
54
+             <td>{{getExpiryDate(item.drug_id)}}</td>
53 55
             </tr>
54 56
              <tr>
55 57
                <td style="line-height:50px">合计</td>
@@ -68,8 +70,8 @@
68 70
             <div style="width:70px;">制单人:</div><div style="width:100px;"></div>
69 71
           </div>
70 72
           <div v-if="orgId == 10024" style="display:flex;margin-top:1px;float:right;">
71
-            <div style="width:70px;">科室:</div><div style="width:100px;"></div>
72
-            <div style="width:70px;">领料人:</div><div style="width:100px;"></div>
73
+            <div style="width:50px;">科室:</div><div style="width:60px;"></div>
74
+            <div style="width:70px;">领料人:</div><div style="width:60px;"></div>
73 75
             <div style="width:80px;">审批:</div><div style="width:100px;"></div>
74 76
             <div style="width:50px;">会计:</div><div style="width:100px;">徐立琼</div>
75 77
             <div style="width:50px;">审核:</div><div style="width:100px;">徐立琼</div>
@@ -90,7 +92,7 @@
90 92
   import { jsGetAge, uParseTime } from '@/utils/tools'
91 93
   import BreadCrumb from '@/xt_pages/components/bread-crumb'
92 94
   import print from 'print-js'
93
-  import {  getDrugWarehouseOutInfo } from '@/api/drug/drug_stock'
95
+  import {  getDrugWarehouseOutInfo,getDrugWarehouseOrderInfo } from '@/api/drug/drug_stock'
94 96
   import {getBaseDrugLibList} from '@/api/data'
95 97
   export default {
96 98
     name: 'dialysisPrintOrder',
@@ -128,7 +130,8 @@
128 130
         limit:10000,
129 131
         keywords:"",
130 132
         orgId:'',
131
-        orgName:""
133
+        orgName:"",
134
+        drugOrderList:[]
132 135
       }
133 136
     },
134 137
     methods: {
@@ -256,6 +259,52 @@
256 259
         });
257 260
         this.sameRowArr = sameRowArr
258 261
       },
262
+      getDrugWarehouseOrderInfo(){
263
+        getDrugWarehouseOrderInfo().then(response=>{
264
+           if(response.data.state == 1){
265
+             var list =  response.data.data.list
266
+             console.log("入库单详情",list)
267
+             this.drugOrderList = list
268
+           }
269
+        })
270
+      },
271
+      getNumber(id){
272
+        var number = ""
273
+        for(let i=0;i<this.drugOrderList.length;i++){
274
+          if(id == this.drugOrderList[i].drug_id){
275
+              number = this.drugOrderList[i].number
276
+          }
277
+        }
278
+        return number
279
+      },
280
+      getProductDate(id){
281
+        var product_date = ""
282
+        for(let i=0;i<this.drugOrderList.length;i++){
283
+           if(id == this.drugOrderList[i].drug_id){
284
+             product_date = this.drugOrderList[i].product_date
285
+           }
286
+        }
287
+        return this.getTime(product_date)
288
+      },
289
+      getExpiryDate(id){
290
+         var expiry_date = ""
291
+         for(let i=0;i<this.drugOrderList.length;i++){
292
+           if(id == this.drugOrderList[i].drug_id){
293
+             expiry_date = this.drugOrderList[i].expiry_date
294
+           }
295
+        }
296
+        return this.getTime(expiry_date)
297
+      },
298
+      getTime(val) {
299
+         if(val < 0){
300
+           return ""
301
+         }
302
+         if(val == ""){
303
+          return ""
304
+         }else {
305
+          return uParseTime(val, '{y}-{m}-{d}')
306
+         }
307
+      },
259 308
     },
260 309
     created() {
261 310
       this.orgName = this.$store.getters.xt_user.org.org_name;
@@ -263,6 +312,7 @@
263 312
       this.orgId = this.$store.getters.xt_user.org.id;
264 313
       this.GetOrderDetail(order_id);
265 314
       this.getList()
315
+      this.getDrugWarehouseOrderInfo()
266 316
     }
267 317
 
268 318
   }

+ 1 - 1
src/xt_pages/stock/drugs/query.vue View File

@@ -455,7 +455,7 @@
455 455
       printOrder(){
456 456
         this.$router.push({
457 457
           name: "drugQueryPrint",
458
-          query: {drug_category:this.drug_category,keyword:this.keywords,start_time:this.start_time,end_time:this.end_time}
458
+          query: {drug_category:this.drug_category,keyword:this.keywords,start_time:this.start_time,end_time:this.end_time,page:this.page,limit:this.limit}
459 459
         });
460 460
       }
461 461
     }

+ 2 - 2
src/xt_pages/stock/stockOutOrderDetail.vue View File

@@ -124,7 +124,7 @@
124 124
     created() {
125 125
       const order_id = this.$route.query.id
126 126
       const warehouse_out_time = this.$route.query.warehouse_out_time
127
-      console.log("时间搓",warehouse_out_time)
127
+     
128 128
       this.GetConfigInfo()
129 129
       this.GetOrderDetail(order_id)
130 130
       this.GetTotalCount(warehouse_out_time)
@@ -234,7 +234,7 @@
234 234
             }
235 235
             this.warehousingOutInfo.info = response.data.data.info
236 236
           
237
-            console.log("数据源头9999999999",this.warehousingOutInfo.warehousingOutData)
237
+          
238 238
             this.handleSpanTempArr()
239 239
           }
240 240
         })

+ 59 - 6
src/xt_pages/stock/stockOutOrderDetailPrint.vue View File

@@ -41,9 +41,9 @@
41 41
                                     <td>{{getOutStockCount(item.good_id) + getWarehouseOutInfoCount(item.warehouse_out_id,item.good_id)}}</td>
42 42
                                     <td>{{item.price}}</td>
43 43
                                     <td>{{((getOutStockCount(item.good_id) +getWarehouseOutInfoCount(item.warehouse_out_id,item.good_id))*item.price).toFixed(2)}}</td>
44
-                                    <td></td>
45
-                                    <td></td>
46
-                                    <td></td>
44
+                                    <td>{{getNumber(item.good_id)}}</td>
45
+                                    <td>{{getProductDate(item.good_id)}}</td>
46
+                                    <td>{{getExpiryDate(item.good_id)}}</td>
47 47
                                 </tr>
48 48
                                 <tr>
49 49
                                   <td>合计</td>
@@ -63,7 +63,7 @@
63 63
                         <div v-if="orgId == 10024" style="display:flex;margin-top:1px;float:right;">
64 64
                           <div style="width:50px;">科室:</div><div style="width:60px;"></div>
65 65
                           <div style="width:70px;">领料人:</div><div style="width:60px;"></div>
66
-                          <div style="width:80px;">审批:</div><div style="width:100px;"></div>
66
+                          <div style="width:80px;">审批:</div><div style="width:100px;">肖庆娥</div>
67 67
                           <div style="width:50px;">会计:</div><div style="width:100px;">徐立琼</div>
68 68
                           <div style="width:50px;">审核:</div><div style="width:100px;">徐立琼</div>
69 69
                           <div style="width:70px;">制单人:</div><div style="width:100px;">徐立琼</div>
@@ -77,9 +77,10 @@
77 77
 
78 78
 <script>
79 79
 import BreadCrumb from '@/xt_pages/components/bread-crumb'
80
-import { GetAllConfig,getWarehouseOutInfo,GetOutStockTotalCount,getGoodInfoList } from "@/api/stock";
80
+import { GetAllConfig,getWarehouseOutInfo,GetOutStockTotalCount,getGoodInfoList,getWarehouseOrderInfoList } from "@/api/stock";
81 81
 import print from 'print-js'
82 82
 const moment = require('moment');
83
+import { uParseTime } from '@/utils/tools'
83 84
 export default {
84 85
     components:{
85 86
         BreadCrumb
@@ -117,6 +118,7 @@ export default {
117 118
             wareoutList:[],
118 119
             orgId:'',
119 120
             orgName:'',
121
+            orderInList:[]
120 122
         }
121 123
     },
122 124
     methods:{
@@ -272,7 +274,56 @@ export default {
272 274
             }
273 275
          }
274 276
         return count
275
-      }
277
+      },
278
+
279
+      getWarehouseOrderInfoList(){
280
+         getWarehouseOrderInfoList().then(response=>{
281
+             if(response.data.state == 1){
282
+               var list = response.data.data.list
283
+               console.log("入库单详情",list)
284
+               this.orderInList = list
285
+             }
286
+         })
287
+      },
288
+      getNumber(id){
289
+        var name = ""
290
+        for(let i=0;i<this.orderInList.length;i++){
291
+           if(id == this.orderInList[i].good_id){
292
+               name = this.orderInList[i].number
293
+           }
294
+        }
295
+        return name
296
+      },
297
+      getProductDate(id){
298
+        var product_date = ""
299
+         for(let i=0;i<this.orderInList.length;i++){
300
+           if(id == this.orderInList[i].good_id){
301
+               product_date =  this.orderInList[i].product_date
302
+           }
303
+         }
304
+         return this.getTime(product_date)
305
+      },
306
+
307
+      getExpiryDate(id){
308
+         var expiry_date = ""
309
+         for(let i=0;i<this.orderInList.length;i++){
310
+           if(id == this.orderInList[i].good_id){
311
+              expiry_date = this.orderInList[i].expiry_date
312
+           }
313
+         }
314
+         return this.getTime(expiry_date)
315
+      },
316
+      getTime(val) {
317
+         if(val < 0){
318
+           return ""
319
+         }
320
+         if(val == ""){
321
+          return ""
322
+         }else {
323
+          return uParseTime(val, '{y}-{m}-{d}')
324
+         }
325
+      },
326
+
276 327
 
277 328
     },
278 329
     created(){
@@ -284,6 +335,8 @@ export default {
284 335
       this.GetOrderDetail(order_id);
285 336
       this.GetTotalCount(warehouse_out_time);
286 337
       this.getList()
338
+      //获取所有入库单
339
+      this.getWarehouseOrderInfoList()
287 340
     }
288 341
 }
289 342
 </script>

+ 4 - 3
src/xt_pages/stock/stockPrint.vue View File

@@ -83,8 +83,8 @@ export default {
83 83
           tableData:[],
84 84
           time_now:moment(new Date()).add('year',0).format("YYYY-MM-DD"),
85 85
           type_name:"",
86
-          limit:20,
87
-          page:1,
86
+          limit:"",
87
+          page:"",
88 88
           WarehouseInfo: {
89 89
           loading: false,
90 90
           warehouseInfoDate: []
@@ -173,7 +173,8 @@ export default {
173 173
       this.type_name = type_name
174 174
       var keyword = this.$route.query.keyword
175 175
       this.keyword = keyword
176
-
176
+      this.page = this.$route.query.page
177
+      this.limit = this.$route.query.limit
177 178
       this.getlist()
178 179
     }
179 180
 }

+ 3 - 1
src/xt_pages/stock/stockQuery.vue View File

@@ -332,6 +332,7 @@ export default {
332 332
         this.$message.error("开始时间不能大于结束时间");
333 333
         this.start_time = "";
334 334
       } else {
335
+        this.start_time = val
335 336
         this.GetAllStockQuery();
336 337
       }
337 338
     },
@@ -341,6 +342,7 @@ export default {
341 342
         this.$message.error("结束时间不能小于开始时间");
342 343
         this.end_time = "";
343 344
       } else {
345
+        this.end_time = val
344 346
         this.GetAllStockQuery();
345 347
       }
346 348
      
@@ -405,7 +407,7 @@ export default {
405 407
        this.GetAllStockQuery()
406 408
       },
407 409
       toPrint(){
408
-        this.$router.push("/stock/stockprint?start_time="+this.start_time+"&end_time="+this.end_time+"&keyword="+this.keywords+"&type_name="+this.type_name)
410
+        this.$router.push("/stock/stockprint?start_time="+this.start_time+"&end_time="+this.end_time+"&keyword="+this.keywords+"&type_name="+this.type_name+"&page="+this.page+"&limit="+this.limit)
409 411
         
410 412
       },
411 413
 

+ 26 - 29
src/xt_pages/workforce/appointment.vue View File

@@ -69,6 +69,7 @@
69 69
       <bread-crumb :crumbs="crumbs"></bread-crumb>
70 70
         <div style="display:flex;align-items:center">
71 71
           <schedule-upload-excel style="margin-right:10px;" :on-success='handleSuccess' ></schedule-upload-excel>
72
+           <el-button @click="printTable" type="primary" size="small">打印排班</el-button>
72 73
           <el-button v-if="isShow()" type="primary" size="small" @click="export_file()" :loading="downloadLoading">
73 74
             导出模版
74 75
           </el-button>
@@ -121,7 +122,7 @@
121 122
       <!-- </el-col>
122 123
     </el-row> -->
123 124
 
124
-      <table-data :week-time="activeName" :partitions-prop="partitions" :schedule-zone-row-prop="scheduleZoneRow"
125
+      <table-data ref="tableData" :week-time="activeName" :partitions-prop="partitions" :schedule-zone-row-prop="scheduleZoneRow"
125 126
                   :schedule-zone-prop="scheduleZone" title="" @event1="changePartition" @event2="changeSchedule"></table-data>
126 127
 
127 128
 
@@ -226,7 +227,9 @@
226 227
       UploadExcel
227 228
     },
228 229
     methods: {
229
-
230
+      printTable(){
231
+        this.$router.push({path: '/scheduleTablePrint?partition_id='+this.partition_id+"&weekTime="+this.activeName})
232
+      },
230 233
       generateTxt: function(log) {
231 234
         var content = ''
232 235
         var errlog = log.err_logs
@@ -287,7 +290,7 @@
287 290
             return false
288 291
           }
289 292
           var partitions = response.data.data.partitions
290
-          console.log("分区",partitions)
293
+          // console.log("分区",partitions)
291 294
           this.theWeek.thisWeek = response.data.data.theWeek
292 295
           this.theWeek.lastWeek = this.theWeek.thisWeek - 1
293 296
           this.theWeek.nextWeek = this.theWeek.thisWeek + 1
@@ -507,14 +510,13 @@
507 510
             }
508 511
             i++
509 512
           }
510
-          console.log("listw22222222",list)
511 513
             var data = []
512 514
 
513 515
           this.tableList.map(item=>{
514 516
             data.push(Object.values(item))
515 517
 
516 518
           })
517
-          console.log("data",data)
519
+        
518 520
           
519 521
           const filename = '排班模版'
520 522
         
@@ -529,8 +531,6 @@
529 531
           }
530 532
           
531 533
           if(this.export_type == 1){
532
-
533
-            console.log("44444444",this.tableList)
534 534
             //  const multiHeader = [['区号', '机号', '周一'+"("+this.newDay[0]+")" , '', '', '周二'+"("+this.newDay[1]+")", '', '', '周三'+"("+this.newDay[2]+")" , '', '', '周四'+"("+this.newDay[3]+")" , '', '', '周五'+"("+this.newDay[4]+")" , '', '', '周六'+"("+this.newDay[5]+")" , '', '', '周日'+"("+this.newDay[6]+")" , '', '', '周一'+"("+this.days[7]+")" , '', '', '周二'+"("+this.days[8]+")" , '', '', '周三'+"("+this.days[9]+")" , '', '', '周四'+"("+this.days[10]+")" , '', '', '周五'+"("+this.days[11]+")" , '', '', '周六'+"("+this.days[12]+")" , '', '', '周日'+"("+this.days[13]+")", '', '', '周一'+"("+this.days[14]+")", '', '', '周二'+"("+this.days[15]+")", '', '', '周三'+"("+this.days[16]+")", '', '', '周四'+"("+this.days[17]+")", '', '', '周五'+"("+this.days[18]+")", '', '', '周六'+"("+this.days[19]+")", '', '', '周日'+"("+this.days[20]+")", '', '']]
535 535
             //  const header = ['', '', '上午', '下午', '晚上', '上午', '下午', '晚上', '上午', '下午', '晚上', '上午', '下午', '晚上', '上午', '下午', '晚上', '上午', '下午', '晚上', '上午', '下午', '晚上', '上午', '下午', '晚上', '上午', '下午', '晚上', '上午', '下午', '晚上', '上午', '下午', '晚上', '上午', '下午', '晚上', '上午', '下午', '晚上', '上午', '下午', '晚上', '上午', '下午', '晚上', '上午', '下午', '晚上', '上午', '下午', '晚上', '上午', '下午', '晚上', '上午', '下午', '晚上', '上午', '下午', '晚上', '上午', '下午', '晚上']
536 536
             //  const merges = ['A1:A2', 'B1:B2', 'C1:E1', 'F1:H1', 'I1:K1', 'L1:N1', 'O1:Q1', 'R1:T1', 'U1:W1', 'X1:Z1', 'AA1:AC1', 'AD1:AF1', 'AG1:AI1', 'AJ1:AL1', 'AM1:AO1', 'AP1:AR1', 'AS1:AU1', 'AV1:AX1', 'AY1:BA1', 'BB1:BD1', 'BE1:BG1', 'BH1:BJ1', 'BK1:BM1']
@@ -566,7 +566,7 @@
566 566
               data.push(Object.values(item))
567 567
 
568 568
             })
569
-            console.log("data",data)
569
+            // console.log("data",data)
570 570
             
571 571
             const filename = '排班模版'
572 572
            
@@ -593,7 +593,7 @@
593 593
           const merges = ['A1:A2', 'B1:B2', 'C1:E1', 'F1:H1', 'I1:K1', 'L1:N1', 'O1:Q1', 'R1:T1', 'U1:W1', 'X1:Z1', 'AA1:AC1', 'AD1:AF1', 'AG1:AI1', 'AJ1:AL1', 'AM1:AO1', 'AP1:AR1', 'AS1:AU1', 'AV1:AX1', 'AY1:BA1', 'BB1:BD1', 'BE1:BG1', 'BH1:BJ1', 'BK1:BM1']
594 594
 
595 595
           var data = []
596
-          console.log("33333",this.tableList)
596
+          // console.log("33333",this.tableList)
597 597
          
598 598
          this.tableList.map(item=>{
599 599
            data.push(Object.values(item))
@@ -618,10 +618,7 @@
618 618
       formatJson(filterVal, jsonData) {
619 619
         return jsonData.map(v =>
620 620
           filterVal.map(j => {
621
-            console.log(v)
622
-            console.log(j)
623
-            console.log(v[j])
624
-
621
+        
625 622
             if (j === 'timestamp') {
626 623
               return parseTime(v[j])
627 624
             } else {
@@ -2130,11 +2127,11 @@
2130 2127
               partition_id:this.partition_id,
2131 2128
               schedule_type:this.schedule_type
2132 2129
             }
2133
-           console.log("params2222",params)
2130
+          //  console.log("params2222",params)
2134 2131
          getThreeWeekList(params).then(response=>{
2135 2132
            if(response.data.state == 1){
2136 2133
              var partitions =  response.data.data.partitions
2137
-             console.log("数据22222",this.partitions)
2134
+            //  console.log("数据22222",this.partitions)
2138 2135
 
2139 2136
              const merges = ['A1:A2', 'B1:B2', 'C1:E1', 'F1:H1', 'I1:K1', 'L1:N1', 'O1:Q1', 'R1:T1', 'U1:W1', 'X1:Z1', 'AA1:AC1', 'AD1:AF1', 'AG1:AI1', 'AJ1:AL1', 'AM1:AO1', 'AP1:AR1', 'AS1:AU1', 'AV1:AX1', 'AY1:BA1', 'BB1:BD1', 'BE1:BG1', 'BH1:BJ1', 'BK1:BM1']
2140 2137
               var list = []
@@ -2302,16 +2299,16 @@
2302 2299
               var lastWeek = []
2303 2300
               var next_start = this.getNextWeekOne(1)
2304 2301
               var nextstart = this.getTimestamp(next_start) - 28800
2305
-              console.log("下周开始时间",nextstart)
2302
+              // console.log("下周开始时间",nextstart)
2306 2303
               var next_end = this.getNextWeek(1)
2307 2304
               var nextend = this.getTimestamp(next_end) - 28800
2308
-              console.log("下周结束时间",nextend)
2305
+              // console.log("下周结束时间",nextend)
2309 2306
               var last_start = this.getNextWeekOne(2)
2310 2307
               var last_end = this.getNextWeek(2)
2311 2308
               var laststart = this.getTimestamp(last_start) - 28800
2312
-              console.log("下下周数据时间",laststart)
2309
+              // console.log("下下周数据时间",laststart)
2313 2310
               var lastend = this.getTimestamp(last_end) - 28800
2314
-              console.log("下下周数据时间",lastend)
2311
+              // console.log("下下周数据时间",lastend)
2315 2312
                
2316 2313
               if(this.export_type == 0){
2317 2314
                 for(let i = 0;i<scheduleList.length;i++){
@@ -2428,7 +2425,7 @@
2428 2425
               }
2429 2426
              }
2430 2427
 
2431
-             console.log("list5555555555",list)
2428
+            //  console.log("list5555555555",list)
2432 2429
 
2433 2430
              if(nextWeek.length > 0 ){
2434 2431
                for(let i=0;i<list.length;i++){
@@ -2531,7 +2528,7 @@
2531 2528
               }
2532 2529
              }
2533 2530
 
2534
-             console.log("nextWeek",nextWeek)
2531
+            //  console.log("nextWeek",nextWeek)
2535 2532
 
2536 2533
              if(lastWeek.length > 0 ){
2537 2534
                for(let i=0;i<list.length;i++){
@@ -2692,7 +2689,7 @@
2692 2689
       
2693 2690
      
2694 2691
 
2695
-         console.log("33333333",this.newDay)
2692
+        //  console.log("33333333",this.newDay)
2696 2693
          this.export_type = 1
2697 2694
          this.getThreeWeekList()
2698 2695
        },
@@ -2770,16 +2767,16 @@
2770 2767
                 let weekOfday = parseInt(moment().format('d')) 
2771 2768
                 start_time =  this.getTimestamp(moment().subtract(weekOfday + 6, 'days').format('YYYY-MM-DD')) -28800
2772 2769
                 end_time =  this.getTimestamp(moment().subtract(weekOfday, 'days').format('YYYY-MM-DD')) -28800
2773
-                console.log("start",start_time)
2774
-                console.log("end",end_time)
2770
+                // console.log("start",start_time)
2771
+                // console.log("end",end_time)
2775 2772
              }
2776 2773
             
2777 2774
             //本周
2778 2775
              if(this.form.lastweek == "2"){
2779 2776
                 start_time = this.getTimestamp(this.weekDayArr[0])
2780 2777
                 end_time = this.getTimestamp(this.weekDayArr[6])
2781
-                console.log("start",start_time)
2782
-                console.log("end",end_time)
2778
+                // console.log("start",start_time)
2779
+                // console.log("end",end_time)
2783 2780
              }
2784 2781
 
2785 2782
             var label = ""
@@ -2798,7 +2795,7 @@
2798 2795
               copy_startime:copy_startime,
2799 2796
               copy_endtime:copy_endtime,
2800 2797
             }
2801
-           console.log("时间",params)
2798
+         
2802 2799
          
2803 2800
            this.$refs[formName].validate(valid=>{
2804 2801
               if(valid){
@@ -2817,11 +2814,11 @@
2817 2814
     },
2818 2815
     created() {
2819 2816
      var start_time = moment().weekday(1).format('YYYY-MM-DD');
2820
-     console.log("开始时间",start_time)
2817
+   
2821 2818
      this.start_time = start_time
2822 2819
 
2823 2820
      var end_time = this.getNextWeek(2)
2824
-     console.log("结束时间222222",end_time)
2821
+   
2825 2822
      this.end_time = end_time
2826 2823
       this.getWeekPanels()
2827 2824
       this.getInitDate()

+ 171 - 34
src/xt_pages/workforce/components/nextTableWeeks.vue View File

@@ -25,7 +25,8 @@
25 25
           </li>
26 26
         </ul>
27 27
       </div>
28
-      
28
+    </div>
29
+    <div class="cell clearfix">
29 30
       <div  class="title"><span class="name">班 次</span> :</div>
30 31
       <div class="time">
31 32
         <ul class>
@@ -40,6 +41,36 @@
40 41
         </ul>
41 42
       </div>
42 43
     </div>
44
+    <div class="cell clearfix">
45
+      <div  class="title"><span class="name">处方状态</span> :</div>
46
+      <div class="time">
47
+        <ul class>
48
+          <li
49
+            :class="item.id == pre_status ? 'active' : ''"
50
+            @click="selectPreList(item.id)"
51
+            v-for="item in preStatusList"
52
+            :key="item.id"
53
+          >
54
+            {{ item.name }}
55
+          </li>
56
+        </ul>
57
+      </div>
58
+    </div>
59
+    <div class="cell clearfix">
60
+      <div  class="title"><span class="name">分区</span> :</div>
61
+      <div class="time">
62
+        <ul class>
63
+          <li
64
+            :class="item.id == zone ? 'active' : ''"
65
+            @click="selectZoneList(item.id)"
66
+            v-for="item in zoneList"
67
+            :key="item.id"
68
+          >
69
+            {{ item.name }}
70
+          </li>
71
+        </ul>
72
+      </div>
73
+    </div>
43 74
     <el-table
44 75
       :row-style="{ color: '#303133' }"
45 76
       :data="scheduleData"
@@ -50,6 +81,23 @@
50 81
       }"
51 82
       style="width: 100%"
52 83
     >
84
+      <el-table-column label="透析处方" min-width="100" align="center">
85
+        <template slot-scope="scope">
86
+          <span v-if="scope.row.prescription.id > 0">已确认</span>
87
+          <span v-if="scope.row.prescription.id == 0">未确认</span>
88
+        </template>
89
+      </el-table-column>
90
+      <el-table-column label="星期" min-width="100" align="center">
91
+        <template slot-scope="scope">
92
+           <span v-if="scope.row.schedule_week == 0">周日</span>
93
+           <span v-if="scope.row.schedule_week == 1">周一</span>
94
+           <span v-if="scope.row.schedule_week == 2">周二</span>
95
+           <span v-if="scope.row.schedule_week == 3">周三</span>
96
+           <span v-if="scope.row.schedule_week == 4">周四</span>
97
+           <span v-if="scope.row.schedule_week == 5">周五</span>
98
+           <span v-if="scope.row.schedule_week == 6">周六</span>
99
+        </template>
100
+      </el-table-column>
53 101
       <el-table-column label="姓名" min-width="100" align="center">
54 102
         <template slot-scope="scope">
55 103
           {{ scope.row.patient }}
@@ -87,27 +135,18 @@
87 135
           <span v-if="scope.row.prescription.dialysis_irrigation!=''">{{scope.row.prescription.dialysis_irrigation}}</span>
88 136
         </template>
89 137
       </el-table-column>
90
-      <el-table-column label="抗凝剂" min-width="100" align="center">
138
+      <el-table-column label="抗凝剂(商品名称)" min-width="100" align="center">
91 139
         <template slot-scope="scope">
92 140
           <span v-if="scope.row.prescription.anticoagulant === 1">无肝素</span>
93
-          <span v-if="scope.row.prescription.anticoagulant === 2"
94
-            >普通肝素</span
95
-          >
96
-          <span v-if="scope.row.prescription.anticoagulant === 3"
97
-            >低分子肝素</span
98
-          >
99
-          <span v-if="scope.row.prescription.anticoagulant === 4"
100
-            >阿加曲班</span
101
-          >
102
-          <span v-if="scope.row.prescription.anticoagulant === 5"
103
-            >枸橼酸钠</span
104
-          >
105
-          <span v-if="scope.row.prescription.anticoagulant === 6"
106
-            >低分子肝素钙</span
107
-          >
108
-          <span v-if="scope.row.prescription.anticoagulant === 7"
109
-            >低分子肝素钠</span
110
-          >
141
+          <span v-if="scope.row.prescription.anticoagulant === 2">普通肝素</span>
142
+          <span v-if="scope.row.prescription.anticoagulant === 3" >低分子肝素</span>
143
+          <span v-if="scope.row.prescription.anticoagulant === 4">阿加曲班</span>
144
+          <span v-if="scope.row.prescription.anticoagulant === 5">枸橼酸钠</span>
145
+          <span v-if="scope.row.prescription.anticoagulant === 6">低分子肝素钙</span>
146
+          <span v-if="scope.row.prescription.anticoagulant === 7">低分子肝素钠</span>
147
+         <span v-if="scope.row.prescription.antioxidant_commodity_name!=''">
148
+             (<span>{{scope.row.prescription.antioxidant_commodity_name}}</span>)
149
+          </span>
111 150
         </template>
112 151
       </el-table-column>
113 152
       <el-table-column label="总量" min-width="100" align="center">
@@ -152,9 +191,8 @@
152 191
 
153 192
       <el-table-column label="长期医嘱" min-width="440" align="center">
154 193
         <template slot-scope="scope">
155
-          <span style="white-space: pre">{{
156
-            getAdvice(scope.row.doctor_advice)
157
-          }}</span>
194
+          <span style="white-space: pre" v-if="scope.row.doctoradvice.length>0">{{getAdvice(scope.row.doctoradvice)}}</span>
195
+          <span style="white-space: pre" v-if="scope.row.hisdoctoradviceinfo.length>0">{{getAdviceOne(scope.row.hisdoctoradviceinfo)}}</span>
158 196
         </template>
159 197
       </el-table-column>
160 198
     </el-table>
@@ -162,7 +200,7 @@
162 200
 </template>
163 201
 
164 202
 <script>
165
-import { getNextScheduleWeekDay } from "@/api/schedule";
203
+import { getNextScheduleWeekDay,getAllZoneList } from "@/api/schedule";
166 204
 import WeekItem from "./WeekItem";
167 205
 const moment = require('moment')
168 206
 export default {
@@ -177,6 +215,7 @@ export default {
177 215
   data() {
178 216
     return {
179 217
       weekArr: [
218
+        { id: 0, name: "全部" },
180 219
         { id: 1, name: "周一" },
181 220
         { id: 2, name: "周二" },
182 221
         { id: 3, name: "周三" },
@@ -207,7 +246,15 @@ export default {
207 246
       },
208 247
       scheduleData: [],
209 248
       modeOptions: null,
210
-       org_id:0
249
+      org_id:0,
250
+      pre_status:0,
251
+      preStatusList:[
252
+        {id:0,name:"全部"},
253
+        {id:1,name:"已确认"},
254
+        {id:2,name:"未确认"},
255
+      ],
256
+      zone:"",
257
+      zoneList:[{id:0,name:"全部"}],
211 258
     };
212 259
   },
213 260
   watch: {
@@ -222,7 +269,7 @@ export default {
222 269
   methods: {
223 270
     printAction() {
224 271
       this.$router.push({
225
-        path: "/schedule/remind/print/next?week_type=" + this.week_type+"&week_time="+this.week_time
272
+        path: "/schedule/remind/print/next?week_type=" + this.week_type+"&week_time="+this.week_time+"&zone="+this.zone+"&prestatus="+this.pre_status
226 273
       });
227 274
     },
228 275
    compare(property) {
@@ -242,6 +289,7 @@ export default {
242 289
           end_time:moment().week(moment().week() + 1).endOf('week').unix(),
243 290
           week_type:this.week_type,
244 291
           week_time:this.week_time,
292
+          zone:this.zone,
245 293
         }
246 294
         // const params = {
247 295
         //   start_time:1609603200,
@@ -254,12 +302,37 @@ export default {
254 302
         this.scheduleData = [];
255 303
         if (response.data.state == 1) {
256 304
           var scheduleData = response.data.data.schedule;
257
-          for(let i=0;i<scheduleData.length;i++){
258
-             scheduleData[i].sort = scheduleData[i].number.sort
259
-           }
260
-          var arr =   scheduleData.sort(this.compare('sort'))
261
-           console.log("元旦快乐",arr)
262
-          this.scheduleData = arr
305
+          if(this.pre_status == 0){
306
+              for(let i=0;i<scheduleData.length;i++){
307
+              scheduleData[i].sort = scheduleData[i].number.sort
308
+            }
309
+            var arr =   scheduleData.sort(this.compare('sort'))
310
+            console.log("元旦快乐",arr)
311
+            this.scheduleData = arr
312
+          }
313
+          if(this.pre_status == 1){
314
+            var newList = []
315
+            for(let i=0;i<scheduleData.length;i++){
316
+              if(scheduleData.prescription.id > 0){
317
+                 newList.push(scheduleData[i])
318
+              } 
319
+            }
320
+            var arr =   newList.sort(this.compare('sort'))
321
+            console.log("元旦快乐",arr)
322
+            this.scheduleData = arr
323
+          }
324
+
325
+          if(this.pre_status == 2){
326
+            var newList = []
327
+            for(let i=0;i<scheduleData.length;i++){
328
+              if(scheduleData.prescription.id == 0){
329
+                 newList.push(scheduleData[i])
330
+              } 
331
+            }
332
+            var arr =   newList.sort(this.compare('sort'))
333
+            console.log("元旦快乐",arr)
334
+            this.scheduleData = arr
335
+          }
263 336
         
264 337
          
265 338
         } else {
@@ -313,7 +386,14 @@ export default {
313 386
        this.week_time = type
314 387
        this.getNextScheduleWeekDay()
315 388
     },
316
-
389
+    selectPreList(type){
390
+      this.pre_status = type
391
+      this.getNextScheduleWeekDay()
392
+    },
393
+    selectZoneList(type){
394
+       this.zone = type
395
+       this.getNextScheduleWeekDay()
396
+    },
317 397
     getSchedulesType: function(type) {
318 398
       let type_name = "";
319 399
       switch (type) {
@@ -407,6 +487,62 @@ export default {
407 487
         }
408 488
         return name;
409 489
       }
490
+    },
491
+      getAdviceOne: function(doctor_advice) {
492
+      if (doctor_advice != null) {
493
+        let name = "";
494
+        for (let i = 0; i < doctor_advice.length; i++) {
495
+          let prescribing_number = "";
496
+          let single_dose = "";
497
+          let drug_spec = "";
498
+
499
+          if (doctor_advice[i].prescribing_number > 0) {
500
+            prescribing_number =
501
+              doctor_advice[i].prescribing_number +
502
+              doctor_advice[i].prescribing_number_unit;
503
+          }
504
+          if (doctor_advice[i].single_dose > 0) {
505
+            single_dose =
506
+              " 单次用量 " +
507
+              doctor_advice[i].single_dose +
508
+              doctor_advice[i].single_dose_unit;
509
+          }
510
+
511
+          if (doctor_advice[i].drug_spec > 0) {
512
+            drug_spec =
513
+              doctor_advice[i].drug_spec + doctor_advice[i].drug_spec_unit;
514
+          }
515
+
516
+          name =
517
+            name +
518
+            doctor_advice[i].advice_name +
519
+            " " +
520
+            drug_spec +
521
+            " " +
522
+            prescribing_number +
523
+            " " +
524
+            single_dose +
525
+            " " +
526
+            doctor_advice[i].delivery_way +
527
+            " " +
528
+            doctor_advice[i].execution_frequency +
529
+            " " +
530
+            doctor_advice[i].remark +
531
+            "\n";
532
+
533
+          
534
+        }
535
+        return name;
536
+      }
537
+    },
538
+    getAllZoneList(){
539
+      getAllZoneList().then(response=>{
540
+         if(response.data.state == 1){
541
+            var zonelist = response.data.data.zoneList
542
+            this.zoneList.push(...zonelist)
543
+           
544
+         }
545
+      })
410 546
     }
411 547
   },
412 548
   components: {
@@ -415,13 +551,14 @@ export default {
415 551
   created() {
416 552
     this.modeOptions = this.$store.getters.treatment_mode;
417 553
     this.anticoagulants_confit = this.$store.getters.anticoagulants_confit;
418
-    console.log("抗凝机", this.anticoagulants_confit);
419 554
     this.week_type = new Date().getDay();
420 555
     if (this.week_type == 0) {
421 556
       this.week_type = 7;
422 557
     }
558
+    this.getAllZoneList()
423 559
     this.getNextScheduleWeekDay();
424 560
     this.org_id = this.$store.getters.xt_user.org.id
561
+   
425 562
   }
426 563
 };
427 564
 </script>

+ 263 - 41
src/xt_pages/workforce/components/tableData.vue View File

@@ -1,8 +1,8 @@
1 1
 <template>
2 2
   <div id="table_data">
3
-    <!-- <div style="margin-bottom:-30px">
3
+    <div style="margin-bottom:-30px;margin-left:300px">
4 4
       <span>分区:</span>
5
-       <el-select v-model="partition_id" placeholder="请选择" @change="changePartiton">
5
+       <el-select v-model="partition_id" multiple placeholder="请选择" @change="changePartiton">
6 6
         <el-option
7 7
           v-for="item in this.zones"
8 8
           :key="item.id"
@@ -10,7 +10,8 @@
10 10
           :value="item.id">
11 11
          </el-option>
12 12
         </el-select>
13
-       <span style="margin-left:100px">班次:</span>
13
+      
14
+       <!-- <span style="margin-left:100px">班次:</span>
14 15
        <el-select v-model="schedule_type" placeholder="请选择" @change="changeSchedule_type">
15 16
         <el-option
16 17
           v-for="item in options"
@@ -18,8 +19,8 @@
18 19
           :label="item.name"
19 20
           :value="item.id">
20 21
          </el-option>
21
-       </el-select>
22
-    </div> -->
22
+       </el-select> -->
23
+    </div>
23 24
    
24 25
     <div class="cell clearfix" v-if="weekTime == 'thisWeek' || weekTime == 'nextWeek'  || weekTime == 'nextTwoWeek' ">
25 26
       <el-input
@@ -129,7 +130,6 @@
129 130
       :height="tableContainHeight"
130 131
       ref="table"
131 132
       style="width: 100%;cursor: pointer;"
132
-      
133 133
     >
134 134
       <el-table-column
135 135
         prop="area"
@@ -617,16 +617,17 @@
617 617
 
618 618
 <script>
619 619
 import { uParseTime } from "@/utils/tools";
620
+import print from 'print-js'
620 621
 
621 622
 import {
622 623
   CancelSchedule,
623 624
   ChangeSchedule,
624 625
   CreateSchedule,
625 626
   getSchedulePatients,
626
-  getSchedules,
627
+  getSchedulesOne,
627 628
   getSearchResult,
628 629
   getUrgentScheduleInitData,
629
-  getWeekPanels,
630
+  getWeekPanelsOne,
630 631
   getAllZones,
631 632
 } from "@/api/schedule";
632 633
 import ScheduleItem from "./ScheduleItem";
@@ -643,10 +644,10 @@ export default {
643 644
       type: Array,
644 645
       dafault: []
645 646
     },
646
-    scheduleZoneProp: {
647
-      type: Array,
648
-      dafault: []
649
-    },
647
+    // scheduleZoneProp: {
648
+    //   type: Array,
649
+    //   dafault: []
650
+    // },
650 651
     partitionsProp: {
651 652
       type: Object,
652 653
       dafault: {}
@@ -688,7 +689,7 @@ export default {
688 689
       tzDialogVisible: false,
689 690
       msDialogVisible: false,
690 691
       jhDialogVisible: false,
691
-      scheduleZone: this.scheduleZoneProp,
692
+     // scheduleZone: this.scheduleZoneProp,
692 693
       scheduleZoneRow: -1,
693 694
       partitions: [],
694 695
       jihaos: [],
@@ -758,17 +759,26 @@ export default {
758 759
         {id:2,name:"下午"},
759 760
         {id:3,name:"晚上"},
760 761
       ],
761
-      partition_id:"",
762
+      partition_id:0,
762 763
       schedule_type:"",
763
-      zones:[{id:0,name:"全部"}],
764
-      theType:""
764
+      zones:[],
765
+      theType:"",
766
+      scheduleZone:[],
767
+      theWeek: {
768
+        lastWeek: 0,
769
+        thisWeek: 0,
770
+        nextWeek: 0,
771
+        nextTwoWeek: 0
772
+      },
773
+      zoneIdList:[],
774
+      strArr:""
765 775
     };
766 776
   },
767 777
 
768 778
   watch: {
769 779
     weekTime: function() {
770 780
       var theType = this.weekType(this.weekTime);
771
-      console.log("999999999",theType)
781
+      // console.log("999999999",theType)
772 782
       this.theType = theType
773 783
       this.getSchedules();
774 784
     },
@@ -789,6 +799,205 @@ export default {
789 799
     }
790 800
   },
791 801
   methods: {
802
+       getWeekPanels() {
803
+         this.scheduleZone=[]
804
+         var partionStr = this.partition_id
805
+         var arr = this.zoneIdList.join(',')
806
+         
807
+         var str = ""
808
+         if(partionStr == 0){
809
+            str = arr
810
+         }
811
+         if(partionStr != 0){
812
+            str = partionStr.join(',')
813
+         }
814
+       
815
+      
816
+        getWeekPanelsOne(1,str).then(response => {
817
+          if (response.data.state == 0) {
818
+            return false
819
+          }
820
+          var partitions = response.data.data.partitions
821
+        
822
+          this.theWeek.thisWeek = response.data.data.theWeek
823
+          this.theWeek.lastWeek = this.theWeek.thisWeek - 1
824
+          this.theWeek.nextWeek = this.theWeek.thisWeek + 1
825
+          this.theWeek.nextTwoWeek = this.theWeek.thisWeek + 2
826
+          var that = this
827
+          if (partitions.length > 0) {
828
+            partitions.forEach(function(partition) {
829
+              if (partition.jihaos.length == 0) {
830
+                return false
831
+              }
832
+              that.scheduleZoneRow.push(partition.jihaos.length)
833
+
834
+              that.partitions[partition.id] = partition
835
+                
836
+              partition.jihaos.forEach(function(jihao) {
837
+                var thisPa = {
838
+                  area: partition.name,
839
+                  zone_id: partition.id,
840
+                  zone_type: partition.type,
841
+                  cut: jihao.number,
842
+                  jihao_id: jihao.id,
843
+                  Mon_M: {
844
+                    schedule_id: 0,
845
+                    mode_id: 0,
846
+                    mode_name: '',
847
+                    patient_id: 0,
848
+                    patient: ''
849
+                  },
850
+                  Mon_A: {
851
+                    schedule_id: 0,
852
+                    mode_id: 0,
853
+                    mode_name: '',
854
+                    patient_id: 0,
855
+                    patient: ''
856
+                  },
857
+                  Mon_N: {
858
+                    schedule_id: 0,
859
+                    mode_id: 0,
860
+                    mode_name: '',
861
+                    patient_id: 0,
862
+                    patient: ''
863
+                  },
864
+                  Tue_M: {
865
+                    schedule_id: 0,
866
+                    mode_id: 0,
867
+                    mode_name: '',
868
+                    patient_id: 0,
869
+                    patient: ''
870
+                  },
871
+                  Tue_A: {
872
+                    schedule_id: 0,
873
+                    mode_id: 0,
874
+                    mode_name: '',
875
+                    patient_id: 0,
876
+                    patient: ''
877
+                  },
878
+                  Tue_N: {
879
+                    schedule_id: 0,
880
+                    mode_id: 0,
881
+                    mode_name: '',
882
+                    patient_id: 0,
883
+                    patient: ''
884
+                  },
885
+                  Wed_M: {
886
+                    schedule_id: 0,
887
+                    mode_id: 0,
888
+                    mode_name: '',
889
+                    patient_id: 0,
890
+                    patient: ''
891
+                  },
892
+                  Wed_A: {
893
+                    schedule_id: 0,
894
+                    mode_id: 0,
895
+                    mode_name: '',
896
+                    patient_id: 0,
897
+                    patient: ''
898
+                  },
899
+                  Wed_N: {
900
+                    schedule_id: 0,
901
+                    mode_id: 0,
902
+                    mode_name: '',
903
+                    patient_id: 0,
904
+                    patient: ''
905
+                  },
906
+                  Thurs_M: {
907
+                    schedule_id: 0,
908
+                    mode_id: 0,
909
+                    mode_name: '',
910
+                    patient_id: 0,
911
+                    patient: ''
912
+                  },
913
+                  Thurs_A: {
914
+                    schedule_id: 0,
915
+                    mode_id: 0,
916
+                    mode_name: '',
917
+                    patient_id: 0,
918
+                    patient: ''
919
+                  },
920
+                  Thurs_N: {
921
+                    schedule_id: 0,
922
+                    mode_id: 0,
923
+                    mode_name: '',
924
+                    patient_id: 0,
925
+                    patient: ''
926
+                  },
927
+                  Fri_M: {
928
+                    schedule_id: 0,
929
+                    mode_id: 0,
930
+                    mode_name: '',
931
+                    patient_id: 0,
932
+                    patient: ''
933
+                  },
934
+                  Fri_A: {
935
+                    schedule_id: 0,
936
+                    mode_id: 0,
937
+                    mode_name: '',
938
+                    patient_id: 0,
939
+                    patient: ''
940
+                  },
941
+                  Fri_N: {
942
+                    schedule_id: 0,
943
+                    mode_id: 0,
944
+                    mode_name: '',
945
+                    patient_id: 0,
946
+                    patient: ''
947
+                  },
948
+                  Sat_M: {
949
+                    schedule_id: 0,
950
+                    mode_id: 0,
951
+                    mode_name: '',
952
+                    patient_id: 0,
953
+                    patient: ''
954
+                  },
955
+                  Sat_A: {
956
+                    schedule_id: 0,
957
+                    mode_id: 0,
958
+                    mode_name: '',
959
+                    patient_id: 0,
960
+                    patient: ''
961
+                  },
962
+                  Sat_N: {
963
+                    schedule_id: 0,
964
+                    mode_id: 0,
965
+                    mode_name: '',
966
+                    patient_id: 0,
967
+                    patient: ''
968
+                  },
969
+                  Sun_A: {
970
+                    schedule_id: 0,
971
+                    mode_id: 0,
972
+                    mode_name: '',
973
+                    patient_id: 0,
974
+                    patient: ''
975
+                  },
976
+                  Sun_N: {
977
+                    schedule_id: 0,
978
+                    mode_id: 0,
979
+                    mode_name: '',
980
+                    patient_id: 0,
981
+                    patient: ''
982
+                  },
983
+                  Sun_M: {
984
+                    schedule_id: 0,
985
+                    mode_id: 0,
986
+                    mode_name: '',
987
+                    patient_id: 0,
988
+                    patient: ''
989
+                  },
990
+                  total: 0
991
+                }
992
+               
993
+                that.scheduleZone.push(thisPa)
994
+               
995
+              })
996
+            })
997
+          }
998
+            console.log("34455555566666",this.scheduleZone)
999
+        })
1000
+     },
792 1001
     cellClass({ row, column, rowIndex, columnIndex }) {
793 1002
       if (columnIndex == 0 || columnIndex == 1 || columnIndex == 23) {
794 1003
         return "";
@@ -861,6 +1070,7 @@ export default {
861 1070
       return sums;
862 1071
     },
863 1072
     objectSpanMethod({ row, column, rowIndex, columnIndex }) {
1073
+    
864 1074
       var that = this;
865 1075
       var rowNum = 0;
866 1076
       rowNumber = 0;
@@ -905,21 +1115,30 @@ export default {
905 1115
       this.currentData.patient_id = 0;
906 1116
     },
907 1117
     getSchedules() {
1118
+         var partionStr = this.partition_id
1119
+         var arr = this.zoneIdList.join(',')
1120
+         var str = ""
1121
+         if(partionStr == 0){
1122
+            str = arr
1123
+         }
1124
+         if(partionStr != 0){
1125
+            str = partionStr.join(',')
1126
+         }
908 1127
         const params = {
909 1128
           weekTime:this.theType,
910
-          partition_id:this.partition_id,
1129
+          patitionid:str,
911 1130
           schedule_type:this.schedule_type,
912 1131
         }
913
-      getSchedules(params).then(response => {
1132
+     
1133
+      getSchedulesOne(params).then(response => {
914 1134
         if (response.data.state == 1) {
915 1135
           this.weekTitle = response.data.data.weekTitle;
916 1136
           this.weekDays = response.data.data.days;
917 1137
           this.toDay = response.data.data.today;
918 1138
           var theSchedules = response.data.data.schdules;
919 1139
           
920
-        
921
-        
922 1140
           var that = this;
1141
+          
923 1142
           this.scheduleZone.forEach(function(zone, index) {
924 1143
            
925 1144
             that.scheduleZone[index].Mon_M = {
@@ -1054,14 +1273,14 @@ export default {
1054 1273
               theSchedules.forEach(function(schedule, sindex) {
1055 1274
 
1056 1275
                 if (zone.jihao_id == schedule.bed_id) {
1057
-                  // if(zone.zone_id == schedule.partition_id && zone.jihao_id == schedule.bed_id) {
1276
+                
1058 1277
                   var weekPath = that.weekPath(
1059 1278
                     schedule.schedule_week,
1060 1279
                     schedule.schedule_type
1061 1280
                   );
1062 1281
 
1063 1282
                   if (weekPath.length == 2) {
1064
-                    console.log(schedule);
1283
+                   
1065 1284
 
1066 1285
                     var weekPathKey = weekPath[0] + "_" + weekPath[1];
1067 1286
                     that.scheduleZone[index][weekPathKey] = {
@@ -1077,12 +1296,14 @@ export default {
1077 1296
                           : that.modeOptions[schedule.mode_id].name
1078 1297
                     };
1079 1298
                     that.scheduleZone[index].total += 1;
1299
+                    
1080 1300
                   }
1081 1301
                 }
1082 1302
               });
1083 1303
             }
1084 1304
 
1085 1305
           });
1306
+          
1086 1307
         } else {
1087 1308
           this.$message.error("网络错误");
1088 1309
           return false;
@@ -1265,9 +1486,8 @@ export default {
1265 1486
     },
1266 1487
     clickThis(row, column, cell, event) {
1267 1488
       // debugger
1268
-      console.log("aaa",column.property);
1269 1489
       var week = this.weekDay(column.property);
1270
-      console.log("week",week);
1490
+  
1271 1491
 
1272 1492
       if (week[0] == -1 || week[1] == -1) {
1273 1493
         return false;
@@ -1288,7 +1508,6 @@ export default {
1288 1508
       this.currentData.bed_name = row.cut;
1289 1509
       this.currentData.partition_type = row.zone_type;
1290 1510
 
1291
-      console.log(this.currentData);
1292 1511
 
1293 1512
       if (row[column.property].schedule_id > 0) {
1294 1513
         this.currentData.mode_id = row[column.property].mode_id;
@@ -1329,8 +1548,6 @@ export default {
1329 1548
             }
1330 1549
           }
1331 1550
 
1332
-          // console.log(this.scheduleZone)
1333
-
1334 1551
           this.changeSchedule.change_action = "change_device";
1335 1552
           this.changeScheduleActon(formName);
1336 1553
 
@@ -1518,7 +1735,7 @@ export default {
1518 1735
               this.current_devices = this.zone_device_map[this.zone_name];
1519 1736
               this.device_id = this.current_devices[0].id;
1520 1737
             }
1521
-            console.log(this.current_devices);
1738
+         
1522 1739
 
1523 1740
             this.zone_device_options = [
1524 1741
               { values: this.zone_names },
@@ -1526,7 +1743,6 @@ export default {
1526 1743
               { values: this.current_devices }
1527 1744
             ];
1528 1745
 
1529
-            console.log(this.current_devices);
1530 1746
           } else {
1531 1747
           }
1532 1748
         })
@@ -1604,9 +1820,6 @@ export default {
1604 1820
                   if (this.zone_names.length > 0) {
1605 1821
                     this.zone_name = this.zone_names[0];
1606 1822
                     this.current_devices = this.zone_device_map[this.zone_name];
1607
-
1608
-                    console.log(this.zone_device_map[this.zone_name]);
1609
-
1610 1823
                     this.device_id = this.current_devices[0].id;
1611 1824
                   }
1612 1825
                   this.zone_device_options = [
@@ -1998,30 +2211,37 @@ export default {
1998 2211
       getAllZones().then(response=>{
1999 2212
          if(response.data.state == 1){
2000 2213
            var zones = response.data.data.zones
2001
-           this.zones.push(...zones)
2002
-           
2214
+           for(let i=0;i<zones.length;i++){
2215
+              this.zoneIdList.push(zones[i].id)
2216
+           }
2217
+          this.zones.push(...zones)
2218
+          var strArr =  this.zoneIdList.join(",")
2219
+         
2220
+          this.strArr = strArr
2221
+          this.getWeekPanels()
2003 2222
          }
2004 2223
       })
2005 2224
     },
2006 2225
     changePartiton(val){
2007 2226
      this.$emit('event1', val)
2008 2227
       this.partition_id = val
2228
+      this.getWeekPanels()
2009 2229
       this.getSchedules()
2230
+    
2010 2231
     },
2011 2232
     changeSchedule_type(val){
2012 2233
      this.$emit('event2', val)
2013 2234
      this.schedule_type = val
2014 2235
      this.getSchedules()
2015
-    }
2236
+    },
2016 2237
   },
2017 2238
   components: {
2018 2239
     ScheduleItem
2019 2240
   },
2020 2241
   mounted() {
2021
-    console.log('this.tableContainHeight,',this.$refs.table.$el.offsetTop);
2022
-    this.tableContainHeight =
2023
-      window.innerHeight - this.$refs.table.$el.offsetTop - 120;
2024
-    console.log(this.tableContainHeight);
2242
+  
2243
+    this.tableContainHeight = window.innerHeight - this.$refs.table.$el.offsetTop - 120;
2244
+   
2025 2245
     // var theType = this.weekType(this.weekTime);
2026 2246
     // this.getSchedules(theType);
2027 2247
     const that = this;
@@ -2040,6 +2260,8 @@ export default {
2040 2260
   //    this.tableContainHeight = window.innerHeight - this.$refs.table.$el.offsetTop - 160
2041 2261
   // },
2042 2262
   created() {
2263
+    this.getAllZones()
2264
+ 
2043 2265
     this.changeScheduleType(1)
2044 2266
     rowNumber = 0;
2045 2267
     this.modeOptions = this.$store.getters.treatment_mode;
@@ -2064,7 +2286,7 @@ export default {
2064 2286
     if (this.weekday == 0) {
2065 2287
       this.weekday = 7;
2066 2288
     }
2067
-    this.getAllZones()
2289
+   
2068 2290
   }
2069 2291
 };
2070 2292
 </script>

+ 212 - 83
src/xt_pages/workforce/components/tableWeeks.vue View File

@@ -1,6 +1,14 @@
1 1
 <template>
2 2
   <div>
3 3
     <div class="cell clearfix" style="float: right">
4
+      <el-button
5
+        style="float: right"
6
+        size="small"
7
+        icon="el-icon-printer"
8
+        @click="signPrint()"
9
+        type="primary"
10
+        >标签打印
11
+      </el-button>
4 12
       <el-button
5 13
         style="float: right"
6 14
         size="small"
@@ -10,14 +18,14 @@
10 18
         >打印
11 19
       </el-button>
12 20
 
13
-      <!-- <el-button
21
+      <el-button
14 22
        style="float: right"
15 23
        size="small"
16 24
        icon="el-icon-printer"
17 25
        @click="printActionSetting()"
18 26
        type="primary">
19 27
         打印设置
20
-      </el-button> -->
28
+      </el-button>
21 29
     </div>
22 30
 
23 31
     <div class="cell clearfix">
@@ -50,6 +58,36 @@
50 58
         </ul>
51 59
       </div>
52 60
     </div>
61
+    <div  class="cell clearfix">
62
+     <div  class="title"><span class="name">处方状态</span> :</div>
63
+      <div class="time">
64
+        <ul class>
65
+          <li
66
+            :class="item.id == pre_status ? 'active' : ''"
67
+            @click="selectPreStatus(item.id)"
68
+            v-for="item in preStatus"
69
+            :key="item.id"
70
+          >
71
+            {{ item.name }}
72
+          </li>
73
+        </ul>
74
+      </div>
75
+    </div>
76
+    <div class="cell clearfix">
77
+      <div  class="title"><span class="name">分区</span> :</div>
78
+      <div class="time">
79
+        <ul class>
80
+          <li
81
+            :class="item.id == zone ? 'active' : ''"
82
+            @click="selectZoneList(item.id)"
83
+            v-for="item in zoneList"
84
+            :key="item.id"
85
+          >
86
+            {{ item.name }}
87
+          </li>
88
+        </ul>
89
+      </div>
90
+    </div>
53 91
     <el-table
54 92
       :row-style="{ color: '#303133' }"
55 93
       :data="scheduleData"
@@ -60,9 +98,26 @@
60 98
       }"
61 99
       style="width: 100%"
62 100
     >
101
+     <el-table-column label="透析处方" min-width="100" align="center">
102
+        <template slot-scope="scope">
103
+           <span v-if="scope.row.prescription.id>0">已确定</span>
104
+           <span v-if="scope.row.prescription.id == 0">未确定</span>
105
+        </template>
106
+      </el-table-column>
107
+      <el-table-column label="星期" min-width="100" align="center">
108
+        <template slot-scope="scope">
109
+           <span v-if="scope.row.schedule_week == 0">周日</span>
110
+           <span v-if="scope.row.schedule_week == 1">周一</span>
111
+           <span v-if="scope.row.schedule_week == 2">周二</span>
112
+           <span v-if="scope.row.schedule_week == 3">周三</span>
113
+           <span v-if="scope.row.schedule_week == 4">周四</span>
114
+           <span v-if="scope.row.schedule_week == 5">周五</span>
115
+           <span v-if="scope.row.schedule_week == 6">周六</span>
116
+        </template>
117
+      </el-table-column>
63 118
       <el-table-column label="姓名" min-width="100" align="center">
64 119
         <template slot-scope="scope">
65
-          {{ scope.row.patient }}
120
+          {{ scope.row.patient.name }}
66 121
         </template>
67 122
       </el-table-column>
68 123
       <el-table-column label="分区" min-width="70" align="center">
@@ -98,27 +153,18 @@
98 153
         </template>
99 154
       </el-table-column>
100 155
 
101
-      <el-table-column label="抗凝剂" min-width="100" align="center">
156
+      <el-table-column label="抗凝剂(商品名称)" min-width="70" align="center">
102 157
         <template slot-scope="scope">
103 158
           <span v-if="scope.row.prescription.anticoagulant === 1">无肝素</span>
104
-          <span v-if="scope.row.prescription.anticoagulant === 2"
105
-            >普通肝素</span
106
-          >
107
-          <span v-if="scope.row.prescription.anticoagulant === 3"
108
-            >低分子肝素</span
109
-          >
110
-          <span v-if="scope.row.prescription.anticoagulant === 4"
111
-            >阿加曲班</span
112
-          >
113
-          <span v-if="scope.row.prescription.anticoagulant === 5"
114
-            >枸橼酸钠</span
115
-          >
116
-          <span v-if="scope.row.prescription.anticoagulant === 6"
117
-            >低分子肝素钙</span
118
-          >
119
-          <span v-if="scope.row.prescription.anticoagulant === 7"
120
-            >低分子肝素钠</span
121
-          >
159
+          <span v-if="scope.row.prescription.anticoagulant === 2">普通肝素</span>
160
+          <span v-if="scope.row.prescription.anticoagulant === 3">低分子肝素</span>
161
+          <span v-if="scope.row.prescription.anticoagulant === 4">阿加曲班</span>
162
+          <span v-if="scope.row.prescription.anticoagulant === 5">枸橼酸钠</span>
163
+          <span v-if="scope.row.prescription.anticoagulant === 6">低分子肝素钙</span>
164
+          <span v-if="scope.row.prescription.anticoagulant === 7">低分子肝素钠</span>
165
+          <span v-if="scope.row.prescription.antioxidant_commodity_name!=''">
166
+             (<span>{{scope.row.prescription.antioxidant_commodity_name}}</span>)
167
+          </span>
122 168
         </template>
123 169
       </el-table-column>
124 170
       <el-table-column label="总量" min-width="100" align="center">
@@ -158,14 +204,16 @@
158 204
               ? scope.row.prescription.anticoagulant_zongliang + "iu"
159 205
               : ""
160 206
           }}</span>
207
+        
161 208
         </template>
162 209
       </el-table-column>
163 210
 
164 211
       <el-table-column label="长期医嘱" min-width="440" align="center">
165 212
         <template slot-scope="scope">
166
-          <span style="white-space: pre">{{
167
-            getAdvice(scope.row.doctor_advice)
168
-          }}</span>
213
+          <span style="white-space: pre">
214
+             <span v-if="scope.row.doctoradvice.length >0">{{ getAdvice(scope.row.doctoradvice)}}</span>
215
+             <span v-if="scope.row.hisdoctoradviceinfo.length>0">{{ getAdviceOne(scope.row.hisdoctoradviceinfo)}}</span>
216
+          </span>
169 217
         </template>
170 218
       </el-table-column>
171 219
     </el-table>
@@ -227,7 +275,7 @@
227 275
 </template>
228 276
 
229 277
 <script>
230
-import { getSchedules, getScheduleWeekDay,saveRemindPrint,getRemindPrintList } from "@/api/schedule";
278
+import { getSchedules, getScheduleWeekDay,saveRemindPrint,getRemindPrintList,getScheduleList,getAllZoneList } from "@/api/schedule";
231 279
 import WeekItem from "./WeekItem";
232 280
 
233 281
 export default {
@@ -255,12 +303,18 @@ export default {
255 303
 
256 304
       week_type: "1",
257 305
       week_time:0,
306
+      pre_status:0,
258 307
       weekTimes:[
259 308
         {id:0,name:"全部"},
260 309
         {id:1,name:"上午"},
261 310
         {id:2,name:"下午"},
262 311
         {id:3,name:"晚上"},
263 312
       ],
313
+      preStatus:[
314
+        {id:0,name:"全部"},
315
+        {id:1,name:"已确认"},
316
+        {id:2,name:"未确认"}
317
+      ],
264 318
       weekTitle: ["", "", "", "", "", "", ""],
265 319
       weekData: {
266 320
         Monday: [],
@@ -301,7 +355,9 @@ export default {
301 355
         anticoagulant:"",
302 356
         anticoagulant_zongliang:"",
303 357
         doctor_advice:"",
304
-      }
358
+      },
359
+      zone:0,
360
+      zoneList:[{id:0,name:"全部"}]
305 361
     };
306 362
   },
307 363
   watch: {
@@ -315,9 +371,14 @@ export default {
315 371
   methods: {
316 372
     printAction() {
317 373
       this.$router.push({
318
-        path: "/schedule/remind/print?week_type=" + this.week_type+"&week_time="+this.week_time
374
+        path: "/schedule/remind/print?week_type=" + this.week_type+"&week_time="+this.week_time+"&zone="+this.zone
319 375
       });
320 376
     },
377
+    signPrint(){
378
+      this.$router.push({
379
+        path:"/schedule/remind/print/setting?week_type=" + this.week_type+"&week_time="+this.week_time+"&zone="+this.zone+"&prestatus="+this.pre_status
380
+      })
381
+    },
321 382
     compare(property) {
322 383
        return function (a, b) {
323 384
           var value1 = a[property];
@@ -331,7 +392,6 @@ export default {
331 392
         week_type:this.week_type,
332 393
         week_time:this.week_time,
333 394
        }
334
-      console.log("param22222",params)
335 395
       getScheduleWeekDay(params).then(response => {
336 396
         this.scheduleData = [];
337 397
         if (response.data.state == 1) {
@@ -342,7 +402,7 @@ export default {
342 402
           var arr = scheduleData.sort(this.compare('sort'))
343 403
 
344 404
           var arr =   scheduleData.sort(this.compare('sort'))
345
-        //  console.log("元旦快乐",arr)
405
+       
346 406
           this.scheduleData = arr
347 407
         } else {
348 408
           this.$message.error("网络错误");
@@ -351,47 +411,54 @@ export default {
351 411
       });
352 412
     },
353 413
 
354
-    // getSchedules(weekType) {
355
-    //   getSchedules(weekType).then(response => {
356
-    //     this.scheduleData = []
357
-    //     if (response.data.state == 1) {
358
-    //       this.weekTitle = response.data.data.weekTitle
359
-    //       var theSchedules = response.data.data.schdules
360
-    //       var that = this
361
-    //       theSchedules.forEach(function(schedule) {
362
-    //         schedule['mode_name'] = typeof (that.modeOptions[schedule.mode_id]) == 'undefined' ? '' : that.modeOptions[schedule.mode_id].name
363
-    //         var weekPath = that.weekPath(schedule.schedule_week)
364
-    //         if (weekPath.length > 0) {
365
-    //           that.weekData[weekPath].push(schedule)
366
-    //         }
367
-    //       })
368
-    //       var rowNum = 0
369
-    //       console.log(that.weekData)
370
-    //       for (var index in that.weekData) {
371
-    //         var thisLen = that.weekData[index].length
372
-    //         rowNum = rowNum >= thisLen ? rowNum : thisLen
373
-    //       }
374
-    //       console.log(rowNum)
375
-    //       for (let index = 0; index < rowNum; index++) {
376
-    //         var dataItem = {}
377
-    //         for (var weekIndex in that.weekData) {
378
-    //           var weekItem = that.weekData[weekIndex].shift()
379
-    //           console.log('weekItem', weekItem)
380
-    //           if (typeof (weekItem) != 'undefined') {
381
-    //             dataItem[weekIndex] = weekItem
382
-    //           }
383
-    //         }
384
-    //         that.scheduleData.push(dataItem)
385
-    //       }
386
-    //
387
-    //       console.log(that.scheduleData)
388
-    //
389
-    //     } else {
390
-    //       this.$message.error('网络错误')
391
-    //       return false
392
-    //     }
393
-    //   })
394
-    // },
414
+    getScheduleList(){
415
+        const params = {
416
+          week_type:this.week_type,
417
+          week_time:this.week_time,
418
+          zone:this.zone,
419
+        }
420
+       
421
+       getScheduleList(params).then(response=>{
422
+         if(response.data.state ==1){
423
+           console.log("22333333333",this.pre_status)
424
+           var list = response.data.data.list
425
+           if(this.pre_status == 0){
426
+             
427
+            for(let i=0;i<list.length;i++){
428
+                list[i].sort = list[i].number.sort
429
+            }
430
+
431
+            var arr = list.sort(this.compare('sort'))
432
+              console.log("list2222999999999",list)
433
+            this.scheduleData = arr
434
+           }
435
+           if(this.pre_status == 1){
436
+              var newList = []
437
+              for(let i=0;i<list.length;i++){
438
+                if(list[i].prescription.id > 0){
439
+                   newList.push(list[i])
440
+                }
441
+              }
442
+              var arr = newList.sort(this.compare('sort'))
443
+              this.scheduleData = arr
444
+           }
445
+
446
+           if(this.pre_status == 2){
447
+              var newList = []
448
+              for(let i=0;i<list.length;i++){
449
+                if(list[i].prescription.id ==0){
450
+                   newList.push(list[i])
451
+                }
452
+              }
453
+              var arr = newList.sort(this.compare('sort'))
454
+              this.scheduleData = arr
455
+           }
456
+         
457
+          }
458
+       })
459
+    },
460
+
461
+   
395 462
     weekType(weekTime) {
396 463
       var theType = 2;
397 464
       switch (weekTime) {
@@ -430,16 +497,21 @@ export default {
430 497
     },
431 498
     selectWeekType(type) {
432 499
       this.week_type = type;
433
-      // let params = {
434
-      //   week_type: this.week_type
435
-      // };
436
-      this.getScheduleWeekDay();
500
+      this.getScheduleList()
437 501
     },
502
+
438 503
     selectWeekTime(type){
439 504
        this.week_time = type
440
-       this.getScheduleWeekDay()
505
+      this.getScheduleList()
506
+    },
507
+    selectPreStatus(type){
508
+       this.pre_status = type
509
+       this.getScheduleList()
510
+    },
511
+   selectZoneList(type){
512
+       this.zone = type
513
+       this.getScheduleList()
441 514
     },
442
-
443 515
     getSchedulesType: function(type) {
444 516
       let type_name = "";
445 517
       switch (type) {
@@ -456,7 +528,8 @@ export default {
456 528
       return type_name;
457 529
     },
458 530
     getAdvice: function(doctor_advice) {
459
-      if (doctor_advice != null) {
531
+     
532
+      if (doctor_advice.length > 0) {
460 533
         let name = "";
461 534
         for (let i = 0; i < doctor_advice.length; i++) {
462 535
           let prescribing_number = "";
@@ -532,6 +605,56 @@ export default {
532 605
           }
533 606
         }
534 607
         return name;
608
+      }else{
609
+        return ""
610
+      }
611
+    },
612
+    getAdviceOne: function(doctor_advice) {
613
+     
614
+      if (doctor_advice.length > 0) {
615
+        let name = "";
616
+        for (let i = 0; i < doctor_advice.length; i++) {
617
+          let prescribing_number = "";
618
+          let single_dose = "";
619
+          let drug_spec = "";
620
+
621
+          if (doctor_advice[i].prescribing_number > 0) {
622
+            prescribing_number =
623
+              doctor_advice[i].prescribing_number +
624
+              doctor_advice[i].prescribing_number_unit;
625
+          }
626
+          if (doctor_advice[i].single_dose > 0) {
627
+            single_dose =
628
+              " 单次用量 " +
629
+              doctor_advice[i].single_dose +
630
+              doctor_advice[i].single_dose_unit;
631
+          }
632
+
633
+          if (doctor_advice[i].drug_spec > 0) {
634
+            drug_spec =
635
+              doctor_advice[i].drug_spec + doctor_advice[i].drug_spec_unit;
636
+          }
637
+
638
+          name =
639
+            name +
640
+            doctor_advice[i].advice_name +
641
+            " " +
642
+            drug_spec +
643
+            " " +
644
+            prescribing_number +
645
+            " " +
646
+            single_dose +
647
+            " " +
648
+            doctor_advice[i].delivery_way +
649
+            " " +
650
+            doctor_advice[i].execution_frequency +
651
+            " " +
652
+            doctor_advice[i].remark +
653
+            "\n";
654
+        }
655
+        return name;
656
+      }else{
657
+        return ""
535 658
       }
536 659
     },
537 660
     printActionSetting(){
@@ -723,6 +846,15 @@ export default {
723 846
             this.form.id = list.id
724 847
          }
725 848
       })
849
+    },
850
+    getAllZoneList(){
851
+      getAllZoneList().then(response=>{
852
+         if(response.data.state == 1){
853
+            var zonelist = response.data.data.zoneList
854
+            this.zoneList.push(...zonelist)
855
+           
856
+         }
857
+      })
726 858
     }
727 859
   },
728 860
   components: {
@@ -735,12 +867,9 @@ export default {
735 867
     if (this.week_type == 0) {
736 868
       this.week_type = 7;
737 869
     }
738
-    // let params = {
739
-    //   week_type: this.week_type
740
-    // };
741
-    this.getScheduleWeekDay();
742 870
     this.org_id = this.$store.getters.xt_user.org.id
743
-    // this.getlist()
871
+    this.getScheduleList()
872
+     this.getAllZoneList()
744 873
   }
745 874
 };
746 875
 </script>

+ 114 - 37
src/xt_pages/workforce/next_remind_print.vue View File

@@ -25,52 +25,55 @@
25 25
             <table class="table">
26 26
               <thead>
27 27
                 <tr>
28
-                  <!-- <td :width="td_1_width">姓名</td>
29
-                  <td :width="td_1_width">分区</td>
30
-                  <td :width="td_1_width">班次</td>
31
-                  <td :width="td_1_width">机号</td>
32
-                  <td :width="td_1_width">透析模式</td>
33
-                  <td :width="td_2_width">透析器</td>
34
-                  <td :width="td_2_width">抗凝剂</td>
35
-                  <td :width="td_2_width">低分子肝素</td>
36
-                  <td :width="td_4_width">长期医嘱</td> -->
37
-                  <td width="100">姓名</td>
38
-                  <td width="70">分区</td>
39
-                  <td width="70">班次</td>
40
-                  <td width="70">机号</td>
41
-                  <td width="120">透析模式</td>
42
-                  <td width="100">透析器/灌流器</td>
43
-                  <td width="120">抗凝剂</td>
44
-                  <td width="100">总量</td>
45
-                  <td width="300">长期医嘱</td>
28
+                  <td width="100" v-if="printObj.week == 1">星期</td>
29
+                  <td width="100" v-if="printObj.name == 1">姓名</td>
30
+                  <td width="70" v-if="printObj.zone == 1">分区</td>
31
+                  <td width="70" v-if="printObj.classes == 1">班次</td>
32
+                  <td width="70" v-if="printObj.number == 1">机号</td>
33
+                  <td width="120" v-if="printObj.prescription_status == 1">透析模式</td>
34
+                  <td width="100" v-if="printObj.dialyzers == 1 && printObj.perfusion_apparatus == 1">透析器/灌流器</td>
35
+                  <td width="120" v-if="printObj.anticoagulant==1">抗凝剂(商品名称)</td>
36
+                  <td width="100" v-if="printObj.anticoagulant_zongliang == 1">总量</td>
37
+                  <td width="300" v-if="printObj.doctor_advice == 1">长期医嘱</td>
46 38
                 </tr>
47 39
               </thead>
48 40
               <tbody>
49 41
               <tr v-for="(main_collection, index) in scheduleData" :key="index">
50
-                <td :width="td_1_width">{{ main_collection.patient}}</td>
51
-                <td :width="td_1_width">{{ main_collection.zone.name }}</td>
52
-                <td :width="td_1_width">
42
+                <td :width="td_1_width" v-if="printObj.week == 1">
43
+                  <span v-if="main_collection.schedule_week == 0">周日</span>
44
+                  <span v-if="main_collection.schedule_week == 1">周一</span>
45
+                  <span v-if="main_collection.schedule_week == 2">周二</span>
46
+                  <span v-if="main_collection.schedule_week == 3">周三</span>
47
+                  <span v-if="main_collection.schedule_week == 4">周四</span>
48
+                  <span v-if="main_collection.schedule_week == 5">周五</span>
49
+                  <span v-if="main_collection.schedule_week == 6">周六</span>
50
+                </td>
51
+                <td :width="td_1_width" v-if="printObj.name == 1">{{ main_collection.patient}}</td>
52
+                <td :width="td_1_width" v-if="printObj.zone == 1">{{ main_collection.zone.name }}</td>
53
+                <td :width="td_1_width" v-if="printObj.classes == 1">
53 54
                   {{getSchedulesType(main_collection.schedule_type)}}
54 55
                 </td>
55
-                <td :width="td_1_width">
56
+                <td :width="td_1_width" v-if="printObj.number == 1">
56 57
                   {{main_collection.number.number}}
57 58
 
58 59
                 </td>
59
-                <td :width="td_1_width">
60
+                <td :width="td_1_width"  v-if="printObj.prescription_status == 1">
60 61
                   {{modeOptions[main_collection.mode_id].name}}
61 62
                 </td>
62
-                <td :width="td_1_width">
63
+                <td :width="td_1_width" v-if="printObj.dialyzers == 1 && printObj.perfusion_apparatus == 1">
63 64
                   <span v-if="org_id!=9987">{{main_collection.prescription.dialyzer_perfusion_apparatus}}</span> 
64 65
                   {{main_collection.prescription.dialysis_dialyszers}} 
65 66
                   <span v-if="main_collection.prescription.dialysis_dialyszers!='' && main_collection.prescription.dialysis_irrigation!=''">/</span>
66 67
                   <span v-if="main_collection.prescription.dialysis_irrigation!=''"> {{main_collection.prescription.dialysis_irrigation}}</span>
67 68
 
68 69
                 </td>
69
-                <td :width="td_1_width">
70
+                <td :width="td_1_width" v-if="printObj.anticoagulant==1">
70 71
                   {{ main_collection.prescription.anticoagulant ? anticoagulants_confit[main_collection.prescription.anticoagulant].name : ''}}
71
-
72
+                  <span v-if="main_collection.prescription.antioxidant_commodity_name!=''">
73
+                    (<span>{{main_collection.prescription.antioxidant_commodity_name}}</span>)
74
+                  </span>
72 75
                 </td>
73
-                <td :width="td_1_width">
76
+                <td :width="td_1_width"  v-if="printObj.anticoagulant_zongliang == 1">
74 77
                   <span v-if="main_collection.prescription.anticoagulant == 1">{{main_collection.prescription.anticoagulant_zongliang?main_collection.prescription.anticoagulant_zongliang+'mg':''}}</span>
75 78
                   <span v-if="main_collection.prescription.anticoagulant == 2">{{main_collection.prescription.anticoagulant_zongliang?main_collection.prescription.anticoagulant_zongliang+'iu':''}}</span>
76 79
                   <span v-if="main_collection.prescription.anticoagulant == 3">{{main_collection.prescription.anticoagulant_zongliang?main_collection.prescription.anticoagulant_zongliang+'iu':''}}</span>
@@ -79,8 +82,9 @@
79 82
                   <span v-if="main_collection.prescription.anticoagulant == 6">{{main_collection.prescription.anticoagulant_zongliang?main_collection.prescription.anticoagulant_zongliang+'iu':''}}</span>
80 83
                   <span v-if="main_collection.prescription.anticoagulant == 7">{{main_collection.prescription.anticoagulant_zongliang?main_collection.prescription.anticoagulant_zongliang+'iu':''}}</span>
81 84
                 </td>
82
-                <td :width="td_4_width" style="text-align:left" >
83
-                  <span style="white-space: pre">{{getAdvice(main_collection.doctor_advice)}}</span>
85
+                <td :width="td_4_width" style="text-align:left"  v-if="printObj.doctor_advice == 1">
86
+                  <span style="white-space: pre" v-if="main_collection.doctor_advice.length>0">{{getAdvice(main_collection.doctor_advice)}}</span>
87
+                  <span style="white-space: pre" v-if="main_collection.hisdoctoradviceinfo.length>0">{{getAdviceOne(main_collection.hisdoctoradviceinfo)}}</span>
84 88
                 </td>
85 89
               </tr>
86 90
               </tbody>
@@ -93,7 +97,7 @@
93 97
 </template>
94 98
 
95 99
 <script>
96
-  import { getNextScheduleWeekDay } from '@/api/schedule'
100
+  import { getNextScheduleWeekDay,getPrintList } from '@/api/schedule'
97 101
   import { parseTime } from '@/utils'
98 102
   import { uParseTime } from '@/utils/tools'
99 103
   import BreadCrumb from '@/xt_pages/components/bread-crumb'
@@ -120,13 +124,17 @@
120 124
         start_time:moment().week(moment().week() + 1).startOf('week').unix(),
121 125
         end_time:moment().week(moment().week() + 1).endOf('week').unix(),
122 126
         org_id:0,
123
-        now_time:0
127
+        now_time:0,
128
+        zone:"",
129
+        pre_status:0,
130
+        printObj:{}
124 131
       }
125 132
     },
126 133
     components: {
127 134
       BreadCrumb
128 135
     },
129 136
     created() {
137
+     this.getPrintList()
130 138
      this.org_id = this.$store.getters.xt_user.org.id
131 139
      this.currentDate = this.getCurrentDate()
132 140
    
@@ -134,12 +142,14 @@
134 142
       this.anticoagulants_confit = this.$store.getters.anticoagulants_confit
135 143
       this.week_type = this.$route.query.week_type
136 144
       this.week_time  = this.$route.query.week_time
137
-      
145
+      this.zone = this.$route.query.zone
146
+      this.pre_status = this.$route.query.prestatus
138 147
       const params = {
139 148
           week_type:this.week_type,
140 149
           week_time:this.week_time,
141 150
           start_time:this.start_time,
142 151
           end_time:this.end_time,
152
+          zone:this.zone,
143 153
         }
144 154
 
145 155
         //  const params = {
@@ -157,12 +167,37 @@
157 167
         if (resp.state == 1) {
158 168
          var scheduleData = resp.data.schedule
159 169
 
160
-         for(let i=0;i<scheduleData.length;i++){
161
-             scheduleData[i].sort = scheduleData[i].number.sort
170
+          if(this.pre_status == 0){
171
+              for(let i=0;i<scheduleData.length;i++){
172
+              scheduleData[i].sort = scheduleData[i].number.sort
173
+            }
174
+            var arr =   scheduleData.sort(this.compare('sort'))
175
+            console.log("打印",arr)
176
+            this.scheduleData = arr
177
+          }
178
+          if(this.pre_status == 1){
179
+            var newList = []
180
+            for(let i=0;i<scheduleData.length;i++){
181
+              if(scheduleData.prescription.id > 0){
182
+                 newList.push(scheduleData[i])
183
+              } 
184
+            }
185
+            var arr =   newList.sort(this.compare('sort'))
186
+            console.log("打印",arr)
187
+            this.scheduleData = arr
188
+          }
189
+
190
+          if(this.pre_status == 2){
191
+            var newList = []
192
+            for(let i=0;i<scheduleData.length;i++){
193
+              if(scheduleData.prescription.id == 0){
194
+                 newList.push(scheduleData[i])
195
+              } 
196
+            }
197
+            var arr =   newList.sort(this.compare('sort'))
198
+            console.log("打印",arr)
199
+            this.scheduleData = arr
162 200
           }
163
-          var arr = scheduleData.sort(this.compare('sort'))
164
-          console.log("打印数据",arr)
165
-          this.scheduleData = arr
166 201
         } else {
167 202
           this.$message.error(resp.msg)
168 203
         }
@@ -229,6 +264,39 @@
229 264
         }
230 265
 
231 266
       },
267
+
268
+      getAdviceOne:function(doctor_advice) {
269
+        if (doctor_advice != null) {
270
+
271
+        let name = ""
272
+        for (let i = 0; i< doctor_advice.length; i++) {
273
+
274
+          let prescribing_number = ''
275
+          let single_dose = ''
276
+          let drug_spec = ''
277
+
278
+          if (doctor_advice[i].prescribing_number > 0) {
279
+            prescribing_number = doctor_advice[i].prescribing_number + doctor_advice[i].prescribing_number_unit
280
+          }
281
+          if (doctor_advice[i].single_dose > 0) {
282
+            single_dose = ' 单次用量 ' + doctor_advice[i].single_dose + doctor_advice[i].single_dose_unit
283
+          }
284
+
285
+          if (doctor_advice[i].drug_spec > 0) {
286
+            drug_spec = doctor_advice[i].drug_spec + doctor_advice[i].drug_spec_unit
287
+          }
288
+
289
+          name = name + doctor_advice[i].advice_name + " " + drug_spec + " " + prescribing_number + " " + single_dose + " " + doctor_advice[i].delivery_way + " " + doctor_advice[i].execution_frequency + " " + doctor_advice[i].remark + "\n"
290
+
291
+       
292
+        }
293
+          return name
294
+
295
+
296
+        }
297
+
298
+      },
299
+
232 300
       printAction: function() {
233 301
         const style = '@media print { .print_main_content { background-color: white; width:960px;  margin:0 auto; padding: 0 0 20px 0; } .order_title_panl { text-align: center; } .main_title { font-size: 18px; line-height: 40px; font-weight: 500; } .table_panel { } .table { width: 100%; border: 1px solid; border-collapse: collapse; padding: 2px; } thead tr td { border: 1px solid; text-align: center; font-size: 20px; padding: 15px 5px; } tbody tr td { border: 1px solid; text-align: center; font-size: 18px; padding: 10px 5px; } .proj { padding: 5px 0; text-align: left; } .proj_title { font-size: 16px; font-weight: 500; line-height: 25px; } .proj_item { font-size: 15px; line-height: 20px; } .zone_name { font-weight: 500; } }'
234 302
 
@@ -318,6 +386,15 @@
318 386
           return uParseTime(val, '{y}-{m}-{d}')
319 387
          }
320 388
       },
389
+     getPrintList(){
390
+      getPrintList().then(response=>{
391
+         if(response.data.state == 1){
392
+           var list = response.data.data.list
393
+           console.log("list222222222",list)
394
+           this.printObj = list
395
+         }
396
+      })
397
+     }
321 398
     }
322 399
   }
323 400
 </script>

+ 128 - 85
src/xt_pages/workforce/remind_print.vue View File

@@ -24,52 +24,55 @@
24 24
             <table class="table">
25 25
               <thead>
26 26
                 <tr>
27
-                  <!-- <td :width="td_1_width">姓名</td>
28
-                  <td :width="td_1_width">分区</td>
29
-                  <td :width="td_1_width">班次</td>
30
-                  <td :width="td_1_width">机号</td>
31
-                  <td :width="td_1_width">透析模式</td>
32
-                  <td :width="td_2_width">透析器</td>
33
-                  <td :width="td_2_width">抗凝剂</td>
34
-                  <td :width="td_2_width">低分子肝素</td>
35
-                  <td :width="td_4_width">长期医嘱</td> -->
36
-                  <td width="100">姓名</td>
37
-                  <td width="70">分区</td>
38
-                  <td width="70">班次</td>
39
-                  <td width="70">机号</td>
40
-                  <td width="120">透析模式</td>
41
-                  <td width="100">透析器/灌流器</td>
42
-                  <td width="120">抗凝剂</td>
43
-                  <td width="100">总量</td>
44
-                  <td width="300">长期医嘱</td>
27
+                  <td width="100" v-if="printObj.week == 1">星期</td>
28
+                  <td width="100" v-if="printObj.name == 1">姓名</td>
29
+                  <td width="70" v-if="printObj.zone == 1">分区</td>
30
+                  <td width="70" v-if="printObj.classes == 1">班次</td>
31
+                  <td width="70" v-if="printObj.number == 1">机号</td>
32
+                  <td width="120" v-if="printObj.prescription_status == 1">透析模式</td>
33
+                  <td width="100" v-if="printObj.dialyzers == 1 && printObj.perfusion_apparatus == 1">透析器/灌流器</td>
34
+                  <td width="120" v-if="printObj.anticoagulant==1">抗凝剂(商品名称)</td>
35
+                  <td width="100" v-if="printObj.anticoagulant_zongliang == 1">总量</td>
36
+                  <td width="300" v-if="printObj.doctor_advice == 1">长期医嘱</td>
45 37
                 </tr>
46 38
               </thead>
47 39
               <tbody>
48 40
               <tr v-for="(main_collection, index) in scheduleData" :key="index">
49
-                <td :width="td_1_width">{{ main_collection.patient}}</td>
50
-                <td :width="td_1_width">{{ main_collection.zone.name }}</td>
51
-                <td :width="td_1_width">
41
+                <td :width="td_1_width" v-if="printObj.week == 1">
42
+                  <span v-if="main_collection.schedule_week == 0">周日</span>
43
+                  <span v-if="main_collection.schedule_week == 1">周一</span>
44
+                  <span v-if="main_collection.schedule_week == 2">周二</span>
45
+                  <span v-if="main_collection.schedule_week == 3">周三</span>
46
+                  <span v-if="main_collection.schedule_week == 4">周四</span>
47
+                  <span v-if="main_collection.schedule_week == 5">周五</span>
48
+                  <span v-if="main_collection.schedule_week == 6">周六</span>
49
+                </td>
50
+                <td :width="td_1_width" v-if="printObj.name == 1">{{ main_collection.patient.name}}</td>
51
+                <td :width="td_1_width" v-if="printObj.zone == 1">{{ main_collection.zone.name }}</td>
52
+                <td :width="td_1_width" v-if="printObj.classes == 1">
52 53
                   {{getSchedulesType(main_collection.schedule_type)}}
53 54
                 </td>
54
-                <td :width="td_1_width">
55
+                <td :width="td_1_width" v-if="printObj.number == 1">
55 56
                   {{main_collection.number.number}}
56 57
 
57 58
                 </td>
58
-                <td :width="td_1_width">
59
+                <td :width="td_1_width" v-if="printObj.prescription_status == 1">
59 60
                   {{modeOptions[main_collection.mode_id].name}}
60 61
                 </td>
61
-                <td :width="td_1_width">
62
+                <td :width="td_1_width" v-if="printObj.dialyzers == 1 && printObj.perfusion_apparatus ==1">
62 63
                   <span v-if="org_id!=9987">{{main_collection.prescription.dialyzer_perfusion_apparatus}}</span>
63 64
                   {{main_collection.prescription.dialysis_dialyszers}}
64 65
                   <span v-if="main_collection.prescription.dialysis_dialyszers!=''&& main_collection.prescription.dialysis_irrigation!='' ">/</span>
65 66
                   <span v-if="main_collection.prescription.dialysis_irrigation!=''">{{main_collection.prescription.dialysis_irrigation}}</span>
66 67
 
67 68
                 </td>
68
-                <td :width="td_1_width">
69
+                <td :width="td_1_width" v-if="printObj.anticoagulant == 1">
69 70
                   {{ main_collection.prescription.anticoagulant ? anticoagulants_confit[main_collection.prescription.anticoagulant].name : ''}}
70
-
71
+                  <span v-if="main_collection.prescription.antioxidant_commodity_name!=''">
72
+                    (<span>{{main_collection.prescription.antioxidant_commodity_name}}</span>)
73
+                  </span>
71 74
                 </td>
72
-                <td :width="td_1_width">
75
+                <td :width="td_1_width" v-if="printObj.anticoagulant_zongliang == 1">
73 76
                   <span v-if="main_collection.prescription.anticoagulant == 1">{{main_collection.prescription.anticoagulant_zongliang?main_collection.prescription.anticoagulant_zongliang+'mg':''}}</span>
74 77
                   <span v-if="main_collection.prescription.anticoagulant == 2">{{main_collection.prescription.anticoagulant_zongliang?main_collection.prescription.anticoagulant_zongliang+'iu':''}}</span>
75 78
                   <span v-if="main_collection.prescription.anticoagulant == 3">{{main_collection.prescription.anticoagulant_zongliang?main_collection.prescription.anticoagulant_zongliang+'iu':''}}</span>
@@ -78,8 +81,9 @@
78 81
                   <span v-if="main_collection.prescription.anticoagulant == 6">{{main_collection.prescription.anticoagulant_zongliang?main_collection.prescription.anticoagulant_zongliang+'iu':''}}</span>
79 82
                   <span v-if="main_collection.prescription.anticoagulant == 7">{{main_collection.prescription.anticoagulant_zongliang?main_collection.prescription.anticoagulant_zongliang+'iu':''}}</span>
80 83
                 </td>
81
-                <td :width="td_4_width" style="text-align:left" >
82
-                  <span style="white-space: pre">{{getAdvice(main_collection.doctor_advice)}}</span>
84
+                <td :width="td_4_width" style="text-align:left"  v-if="printObj.doctor_advice == 1">
85
+                  <span style="white-space: pre" v-if="main_collection.doctoradvice.length>0">{{getAdvice(main_collection.doctoradvice)}}</span>
86
+                   <span style="white-space: pre" v-if="main_collection.hisdoctoradviceinfo.length>0">{{ getAdviceOne(main_collection.hisdoctoradviceinfo)}}</span>
83 87
                 </td>
84 88
               </tr>
85 89
               </tbody>
@@ -92,7 +96,7 @@
92 96
 </template>
93 97
 
94 98
 <script>
95
-  import { getScheduleWeekDay } from '@/api/schedule'
99
+  import { getScheduleList,getPrintList } from '@/api/schedule'
96 100
   import { parseTime } from '@/utils'
97 101
   import BreadCrumb from '@/xt_pages/components/bread-crumb'
98 102
   import print from 'print-js'
@@ -115,76 +119,76 @@
115 119
         modeOptions: null,
116 120
         anticoagulants_confit:null,
117 121
         currentDate:'',
118
-        org_id:0
122
+        org_id:0,
123
+        printObj:{},
124
+        week_time:0,
125
+        zone:0,
119 126
       }
120 127
     },
121 128
     components: {
122 129
       BreadCrumb
123 130
     },
124 131
     created() {
125
-     this.org_id = this.$store.getters.xt_user.org.id
132
+      this.getPrintList()
133
+      this.org_id = this.$store.getters.xt_user.org.id
126 134
     //  this.currentDate = this.getCurrentDate()
127 135
       this.modeOptions = this.$store.getters.treatment_mode
128 136
       this.anticoagulants_confit = this.$store.getters.anticoagulants_confit
129 137
       this.week_type = this.$route.query.week_type
130 138
       this.week_time  = this.$route.query.week_time
131
-
139
+      this.zone = this.$route.query.zone
132 140
       const params = {
133 141
           week_type:this.week_type,
134 142
           week_time:this.week_time,
143
+          zone:this.zone,
135 144
         }
136 145
        console.log("params",params)
137
-      getScheduleWeekDay(params).then(rs => {
138
-        var resp = rs.data
139
-        console.log(resp)
140
-        
141
-        if (resp.state == 1) {
142
-          var scheduleData = resp.data.schdules
143
-          let a = resp.data.day
144
-          console.log("a",a)
145
-          var myDate = new Date(a);
146
-          var year = myDate.getFullYear(); //年
147
-          var month = myDate.getMonth() + 1; //月
148
-          var day = myDate.getDate(); //日
149
-          var days = myDate.getDay();
150
-          switch(days) {
151
-          case 1:
152
-            days = '星期一';
153
-            break;
154
-          case 2:
155
-            days = '星期二';
156
-            break;
157
-          case 3:
158
-            days = '星期三';
159
-            break;
160
-          case 4:
161
-            days = '星期四';
162
-            break;
163
-          case 5:
164
-            days = '星期五';
165
-            break;
166
-          case 6:
167
-            days = '星期六';
168
-            break;
169
-          case 0:
170
-            days = '星期日';
171
-            break;
172
-        }
173
-        var str = year + "年" + month + "月" + day + "日  " + days;
174
-        this.currentDate = str
175
-           console.log("树",scheduleData)
176
-          for(let i=0;i<scheduleData.length;i++){
177
-             scheduleData[i].sort = scheduleData[i].number.sort
146
+       getScheduleList(params).then(response=>{
147
+         if(response.data.state ==1){
148
+           var list = response.data.data.list
149
+           for(let i=0;i<list.length;i++){
150
+              list[i].sort = list[i].number.sort
151
+           }
152
+           var arr = list.sort(this.compare('sort'))
153
+            
154
+             this.scheduleData = arr
155
+            
156
+             let a = response.data.data.day
157
+              console.log("a",a)
158
+              var myDate = new Date(a);
159
+              var year = myDate.getFullYear(); //年
160
+              var month = myDate.getMonth() + 1; //月
161
+              var day = myDate.getDate(); //日
162
+              var days = myDate.getDay();
163
+              switch(days) {
164
+              case 1:
165
+                days = '星期一';
166
+                break;
167
+              case 2:
168
+                days = '星期二';
169
+                break;
170
+              case 3:
171
+                days = '星期三';
172
+                break;
173
+              case 4:
174
+                days = '星期四';
175
+                break;
176
+              case 5:
177
+                days = '星期五';
178
+                break;
179
+              case 6:
180
+                days = '星期六';
181
+                break;
182
+              case 0:
183
+                days = '星期日';
184
+                break;
178 185
           }
179
-          var arr = scheduleData.sort(this.compare('sort'))
180
-          console.log("打印数据",arr)
181
-          this.scheduleData = arr
182
-        } else {
183
-          this.$message.error(resp.msg)
184
-        }
185
-      }).catch(err => {
186
-        this.$message.error(err)
187
-      })
186
+          var str = year + "年" + month + "月" + day + "日  " + days;
187
+          this.currentDate = str
188
+          }
189
+       })
190
+       
191
+      
188 192
     },
189 193
     methods: {
190 194
       getAdvice:function(doctor_advice) {
@@ -241,6 +245,38 @@
241 245
         }
242 246
 
243 247
       },
248
+      getAdviceOne:function(doctor_advice) {
249
+        if (doctor_advice != null) {
250
+
251
+        let name = ""
252
+        for (let i = 0; i< doctor_advice.length; i++) {
253
+
254
+          let prescribing_number = ''
255
+          let single_dose = ''
256
+          let drug_spec = ''
257
+
258
+          if (doctor_advice[i].prescribing_number > 0) {
259
+            prescribing_number = doctor_advice[i].prescribing_number + doctor_advice[i].prescribing_number_unit
260
+          }
261
+          if (doctor_advice[i].single_dose > 0) {
262
+            single_dose = ' 单次用量 ' + doctor_advice[i].single_dose + doctor_advice[i].single_dose_unit
263
+          }
264
+
265
+          if (doctor_advice[i].drug_spec > 0) {
266
+            drug_spec = doctor_advice[i].drug_spec + doctor_advice[i].drug_spec_unit
267
+          }
268
+
269
+          name = name + doctor_advice[i].advice_name + " " + drug_spec + " " + prescribing_number + " " + single_dose + " " + doctor_advice[i].delivery_way + " " + doctor_advice[i].execution_frequency + " " + doctor_advice[i].remark + "\n"
270
+
271
+        
272
+        }
273
+          return name
274
+
275
+
276
+        }
277
+
278
+      },
279
+     
244 280
       printAction: function() {
245 281
         const style = '@media print { .print_main_content { background-color: white; width:960px;  margin:0 auto; padding: 0 0 20px 0; } .order_title_panl { text-align: center; } .main_title { font-size: 18px; line-height: 40px; font-weight: 500; } .table_panel { } .table { width: 100%; border: 1px solid; border-collapse: collapse; padding: 2px; } thead tr td { border: 1px solid; text-align: center; font-size: 20px; padding: 15px 5px; } tbody tr td { border: 1px solid; text-align: center; font-size: 18px; padding: 10px 5px; } .proj { padding: 5px 0; text-align: left; } .proj_title { font-size: 16px; font-weight: 500; line-height: 25px; } .proj_item { font-size: 15px; line-height: 20px; } .zone_name { font-weight: 500; } }'
246 282
 
@@ -320,8 +356,15 @@
320 356
             return value1 - value2;
321 357
         }
322 358
       },
323
-    }
324
-
359
+     getPrintList(){
360
+      getPrintList().then(response=>{
361
+         if(response.data.state == 1){
362
+           var list = response.data.data.list
363
+           this.printObj = list
364
+         }
365
+      })
366
+     }
367
+    },
325 368
   }
326 369
 </script>
327 370
 

+ 378 - 2
src/xt_pages/workforce/remind_print_setting.vue View File

@@ -1,3 +1,379 @@
1
-<div class="main-contain">
1
+<template>
2
+  <div class="main-contain">
3
+    <div class="position">
4
+      <bread-crumb :crumbs="crumbs"></bread-crumb>
5
+      <el-row style="float:right;">
6
+        <el-col :span="24">
7
+          <el-button
8
+            size="small"
9
+            icon="el-icon-printer"
10
+            type="primary"
11
+            @click="printAction"
12
+            >打印</el-button
13
+          >
14
+        </el-col>
15
+      </el-row>
16
+    </div>
17
+    <div class="app-container" style="background-color: white;">
18
+      <div id="print_content">
19
+        <div class="print_main_content">
20
+          <div class="table_panel">
21
+            <div v-for="(main_collection,index) in scheduleData" :key="index" style="page-break-after: always;">
22
+              <div class="signPrint">
23
+                <div>分区/床位号:{{main_collection.zone.name}}/{{main_collection.number.number}}</div> 
24
+                <div>姓名:{{main_collection.patient.name}}</div> 
25
+                <div>抗凝剂: {{ main_collection.prescription.anticoagulant ? anticoagulants_confit[main_collection.prescription.anticoagulant].name : ''}} </div> 
26
+                <div>总量:  
27
+                  <span v-if="main_collection.prescription.anticoagulant == 1">{{main_collection.prescription.anticoagulant_zongliang?main_collection.prescription.anticoagulant_zongliang+'mg':''}}</span>
28
+                  <span v-if="main_collection.prescription.anticoagulant == 2">{{main_collection.prescription.anticoagulant_zongliang?main_collection.prescription.anticoagulant_zongliang+'iu':''}}</span>
29
+                  <span v-if="main_collection.prescription.anticoagulant == 3">{{main_collection.prescription.anticoagulant_zongliang?main_collection.prescription.anticoagulant_zongliang+'iu':''}}</span>
30
+                  <span v-if="main_collection.prescription.anticoagulant == 4">{{main_collection.prescription.anticoagulant_zongliang?main_collection.prescription.anticoagulant_zongliang+'mg':''}}</span>
31
+                  <span v-if="main_collection.prescription.anticoagulant == 5">{{main_collection.prescription.anticoagulant_zongliang?main_collection.prescription.anticoagulant_zongliang+'mg':''}}</span>
32
+                  <span v-if="main_collection.prescription.anticoagulant == 6">{{main_collection.prescription.anticoagulant_zongliang?main_collection.prescription.anticoagulant_zongliang+'iu':''}}</span>
33
+                  <span v-if="main_collection.prescription.anticoagulant == 7">{{main_collection.prescription.anticoagulant_zongliang?main_collection.prescription.anticoagulant_zongliang+'iu':''}}</span>
34
+                </div> 
35
+                <div>用法:透析备用</div> 
36
+                <div>打印时间:{{currentDate}}</div>
37
+              </div>
38
+           </div>
39
+          </div>
40
+        </div>
41
+      </div>
42
+    </div>
43
+  </div>
44
+</template>
45
+
46
+<script>
47
+  import { getScheduleList,getPrintList } from '@/api/schedule'
48
+  import { parseTime } from '@/utils'
49
+  import { uParseTime } from '@/utils/tools'
50
+  import BreadCrumb from '@/xt_pages/components/bread-crumb'
51
+  import print from 'print-js'
52
+  const moment = require('moment') 
53
+  export default {
54
+    name: 'SchedulePrint',
55
+    data() {
56
+      return {
57
+        crumbs: [
58
+          { path: false, name: '排班提醒' },
59
+          { path: false, name: '排班提醒打印' }
60
+        ],
61
+        scheduleData:[],
62
+        week_type: 0,
63
+        day:'',
64
+        td_1_width: '10%',
65
+        td_2_width: '10%',
66
+        td_3_width: '25%',
67
+        td_4_width: '45%',
68
+        modeOptions: null,
69
+        anticoagulants_confit:null,
70
+        currentDate:'',
71
+        start_time:moment().week(moment().week() + 1).startOf('week').unix(),
72
+        end_time:moment().week(moment().week() + 1).endOf('week').unix(),
73
+        org_id:0,
74
+        now_time:0,
75
+        zone:"",
76
+        pre_status:0,
77
+        printObj:{}
78
+      }
79
+    },
80
+    components: {
81
+      BreadCrumb
82
+    },
83
+    created() {
84
+     this.getPrintList()
85
+     this.org_id = this.$store.getters.xt_user.org.id
86
+     this.currentDate = this.getCurrentDate()
2 87
    
3
-</div>
88
+      this.modeOptions = this.$store.getters.treatment_mode
89
+      this.anticoagulants_confit = this.$store.getters.anticoagulants_confit
90
+      this.week_type = this.$route.query.week_type
91
+      this.week_time  = this.$route.query.week_time
92
+      this.zone = this.$route.query.zone
93
+      this.pre_status = this.$route.query.prestatus
94
+     const params = {
95
+          week_type:this.week_type,
96
+          week_time:this.week_time,
97
+          zone:this.zone,
98
+        }
99
+       console.log("params",params)
100
+       getScheduleList(params).then(response=>{
101
+         if(response.data.state ==1){
102
+           var list = response.data.data.list
103
+           for(let i=0;i<list.length;i++){
104
+              list[i].sort = list[i].number.sort
105
+           }
106
+           var arr = list.sort(this.compare('sort'))
107
+            
108
+             this.scheduleData = arr
109
+            
110
+             let a = response.data.data.day
111
+              console.log("a",a)
112
+              var myDate = new Date(a);
113
+              var year = myDate.getFullYear(); //年
114
+              var month = myDate.getMonth() + 1; //月
115
+              var day = myDate.getDate(); //日
116
+              var days = myDate.getDay();
117
+              switch(days) {
118
+              case 1:
119
+                days = '星期一';
120
+                break;
121
+              case 2:
122
+                days = '星期二';
123
+                break;
124
+              case 3:
125
+                days = '星期三';
126
+                break;
127
+              case 4:
128
+                days = '星期四';
129
+                break;
130
+              case 5:
131
+                days = '星期五';
132
+                break;
133
+              case 6:
134
+                days = '星期六';
135
+                break;
136
+              case 0:
137
+                days = '星期日';
138
+                break;
139
+          }
140
+          var str = year + "年" + month + "月" + day + "日  " + days;
141
+          this.currentDate = str
142
+          }
143
+       })
144
+
145
+      var now_time = parseInt(this.week_type) * 86400 + this.start_time
146
+      console.log("now",now_time)
147
+      this.now_time = now_time
148
+    },
149
+    methods: {
150
+      getAdvice:function(doctor_advice) {
151
+        if (doctor_advice != null) {
152
+
153
+        let name = ""
154
+        for (let i = 0; i< doctor_advice.length; i++) {
155
+
156
+          let prescribing_number = ''
157
+          let single_dose = ''
158
+          let drug_spec = ''
159
+
160
+          if (doctor_advice[i].prescribing_number > 0) {
161
+            prescribing_number = doctor_advice[i].prescribing_number + doctor_advice[i].prescribing_number_unit
162
+          }
163
+          if (doctor_advice[i].single_dose > 0) {
164
+            single_dose = ' 单次用量 ' + doctor_advice[i].single_dose + doctor_advice[i].single_dose_unit
165
+          }
166
+
167
+          if (doctor_advice[i].drug_spec > 0) {
168
+            drug_spec = doctor_advice[i].drug_spec + doctor_advice[i].drug_spec_unit
169
+          }
170
+
171
+          name = name + doctor_advice[i].advice_name + " " + drug_spec + " " + prescribing_number + " " + single_dose + " " + doctor_advice[i].delivery_way + " " + doctor_advice[i].execution_frequency + " " + doctor_advice[i].remark + "\n"
172
+
173
+          if (doctor_advice[i].child.length > 0) {
174
+
175
+            for (let a = 0; a < doctor_advice[i].child.length; a++) {
176
+
177
+              if (doctor_advice[i].child[a].prescribing_number > 0) {
178
+                doctor_advice[i].child[a]['presc'] = doctor_advice[i].child[a].prescribing_number + doctor_advice[i].child[a].prescribing_number_unit
179
+              } else {
180
+                doctor_advice[i].child[a]['presc'] = ''
181
+              }
182
+
183
+              if (doctor_advice[i].child[a].single_dose > 0) {
184
+                doctor_advice[i].child[a]['single'] = " " + ' 单次用量 ' + " " + doctor_advice[i].child[a].single_dose + doctor_advice[i].child[a].single_dose_unit
185
+              } else {
186
+                doctor_advice[i].child[a]['single'] = ''
187
+              }
188
+
189
+              name = name + "▲" + doctor_advice[i].child[a].advice_name + ""
190
+                + doctor_advice[i].child[a].advice_desc
191
+                + doctor_advice[i].child[a].drug_spec_unit
192
+                + doctor_advice[i].child[a].presc
193
+                + doctor_advice[i].child[a].single + "\n"
194
+            }
195
+
196
+          }
197
+        }
198
+          return name
199
+
200
+
201
+        }
202
+
203
+      },
204
+      printAction: function() {
205
+        const style = '@media print { .print_main_content { background-color: white; width:960px;  margin:0 auto; padding: 0 0 20px 0; } .order_title_panl { text-align: center; } .main_title { font-size: 18px; line-height: 40px; font-weight: 500; } .table_panel { } .table { width: 100%; border: 1px solid; border-collapse: collapse; padding: 2px; } thead tr td { border: 1px solid; text-align: center; font-size: 20px; padding: 15px 5px; } tbody tr td { border: 1px solid; text-align: center; font-size: 18px; padding: 10px 5px; } .proj { padding: 5px 0; text-align: left; } .proj_title { font-size: 16px; font-weight: 500; line-height: 25px; } .proj_item { font-size: 15px; line-height: 20px; } .zone_name { font-weight: 500; } }'
206
+
207
+        printJS({
208
+          printable: 'print_content',
209
+          type: 'html',
210
+          documentTitle: '  ',
211
+          style: style,
212
+          scanStyles: false
213
+        })
214
+      }, getSchedulesType: function(type) {
215
+        let type_name = ''
216
+        switch (type) {
217
+          case 1:
218
+            type_name = '上午'
219
+            break
220
+          case 2:
221
+            type_name = '下午'
222
+            break
223
+          case 3:
224
+            type_name = '晚上'
225
+            break
226
+        }
227
+        return type_name
228
+      },
229
+      getCurrentDate: function () {
230
+        console.log(this.$route.query.week_type)
231
+        var myDate = new Date();
232
+        var year = myDate.getFullYear(); //年
233
+        var month = myDate.getMonth() + 1; //月
234
+        var day = myDate.getDate() + 7; //日
235
+        var newday = myDate.getDay();
236
+        var days = parseInt(this.$route.query.week_type);
237
+        var dayNum = parseInt(this.$route.query.week_type);
238
+        switch(days) {
239
+          case 1:
240
+            days = '星期一';
241
+            break;
242
+          case 2:
243
+            days = '星期二';
244
+            break;
245
+          case 3:
246
+            days = '星期三';
247
+            break;
248
+          case 4:
249
+            days = '星期四';
250
+            break;
251
+          case 5:
252
+            days = '星期五';
253
+            break;
254
+          case 6:
255
+            days = '星期六';
256
+            break;
257
+          case 7:
258
+            days = '星期日';
259
+            break;
260
+        }
261
+        if(newday > dayNum){
262
+          let lastDay = day - (newday - dayNum)
263
+          console.log("lastDay1",lastDay)
264
+          var str = year + "年" + month + "月" + lastDay + "日  " + days;
265
+          return str;
266
+        }else if(newday < dayNum){
267
+          let lastDay = day + (dayNum - newday)
268
+          console.log("lastDay2",lastDay)
269
+          var str = year + "年" + month + "月" + lastDay + "日  " + days;
270
+          return str;
271
+        }else{
272
+          var str = year + "年" + month + "月" + day + "日  " + days;
273
+          return str;
274
+        }
275
+        
276
+        
277
+      },
278
+
279
+       compare(property) {
280
+       return function (a, b) {
281
+          var value1 = a[property];
282
+          var value2 = b[property];
283
+          return value1 - value2;
284
+      }
285
+     },
286
+     getTime(val) {
287
+         if(val == ""){
288
+          return ""
289
+         }else {
290
+          return uParseTime(val, '{y}-{m}-{d}')
291
+         }
292
+      },
293
+     getPrintList(){
294
+      getPrintList().then(response=>{
295
+         if(response.data.state == 1){
296
+           var list = response.data.data.list
297
+           console.log("list222222222",list)
298
+           this.printObj = list
299
+         }
300
+      })
301
+     }
302
+    }
303
+  }
304
+</script>
305
+
306
+<style rel="stylesheet/scss" lang="scss" scoped>
307
+.print_main_content {
308
+  background-color: white;
309
+  max-width: 1500px;
310
+  margin: 0 auto;
311
+  padding: 0 0 20px 0;
312
+
313
+  .order_title_panl {
314
+    text-align: center;
315
+
316
+    .main_title {
317
+      font-size: 18px;
318
+      line-height: 40px;
319
+      font-weight: 500;
320
+    }
321
+  }
322
+  .table_panel {
323
+    .table {
324
+      width: 100%;
325
+      border: 1px solid;
326
+      border-collapse: collapse;
327
+      padding: 2px;
328
+
329
+      thead {
330
+        tr {
331
+          td {
332
+            border: 1px solid;
333
+            text-align: center;
334
+            font-size: 20px;
335
+            padding: 15px 5px;
336
+          }
337
+        }
338
+      }
339
+      tbody {
340
+        tr {
341
+          td {
342
+            border: 1px solid;
343
+            text-align: center;
344
+            font-size: 18px;
345
+            padding: 10px 5px;
346
+
347
+            .proj {
348
+              padding: 5px 0;
349
+              text-align: left;
350
+
351
+              .proj_title {
352
+                font-size: 16px;
353
+                font-weight: 500;
354
+                line-height: 25px;
355
+              }
356
+
357
+              .proj_item {
358
+                font-size: 15px;
359
+                line-height: 20px;
360
+
361
+                .zone_name {
362
+                  font-weight: 500;
363
+                }
364
+              }
365
+            }
366
+          }
367
+        }
368
+      }
369
+    }
370
+  }
371
+}
372
+.signPrint{
373
+  -webkit-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 60px rgba(0, 0, 0, 0.06) inset;
374
+  -moz-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 40px rgba(0, 0, 0, 0.06) inset;
375
+  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 40px rgba(0, 0, 0, 0.06) inset;
376
+  margin-bottom: 20px;
377
+  padding: 20px 10px;
378
+}
379
+</style>

+ 856 - 0
src/xt_pages/workforce/scheduleTablePrint.vue View File

@@ -0,0 +1,856 @@
1
+<template>
2
+    <div>
3
+        <el-button type="primary" @click="printAction">打印</el-button>
4
+        <table id="scheduleTable" class="scheduleTable" border="1" cellspacing="0">
5
+            <tr>
6
+                <td rowspan="2">分区</td>
7
+                <td rowspan="2">机号</td>
8
+                <td colspan="3">周一({{ weekTitle[0] }})</td>
9
+                <td colspan="3">周二({{ weekTitle[1] }})</td>
10
+                <td colspan="3">周三({{ weekTitle[2] }})</td>
11
+                <td colspan="3">周四({{ weekTitle[3] }})</td>
12
+                <td colspan="3">周五({{ weekTitle[4] }})</td>
13
+                <td colspan="3">周六({{ weekTitle[5] }})</td>
14
+                <td colspan="3">周日({{ weekTitle[6] }})</td>
15
+                <td colspan="3">总数</td>
16
+            </tr>
17
+            <tr>
18
+                <td>上午</td>
19
+                <td>下午</td>
20
+                <td>晚上</td>
21
+                <td>上午</td>
22
+                <td>下午</td>
23
+                <td>晚上</td>
24
+                <td>上午</td>
25
+                <td>下午</td>
26
+                <td>晚上</td>
27
+                <td>上午</td>
28
+                <td>下午</td>
29
+                <td>晚上</td>
30
+                <td>上午</td>
31
+                <td>下午</td>
32
+                <td>晚上</td>
33
+                <td>上午</td>
34
+                <td>下午</td>
35
+                <td>晚上</td>
36
+                <td>上午</td>
37
+                <td>下午</td>
38
+                <td>晚上</td>
39
+            </tr>
40
+            <tr v-for="(item,index) in scheduleZone" :key="index">
41
+                <td style="min-width:50px;">{{ item.area }}</td>
42
+                <td style="min-width:50px;">{{ item.cut }}</td>
43
+                <td style="min-width:50px;">
44
+                    <span v-if="item.Mon_M.patient_id">
45
+                        <div>{{ item.Mon_M.patient }}</div>
46
+                        <div v-if="item.Mon_M.mode_name != 'HD'">{{ item.Mon_M.mode_name }}</div>
47
+                    </span>
48
+                </td>
49
+                <td style="min-width:50px;">
50
+                    <span v-if="item.Mon_A.patient_id">
51
+                        <div>{{ item.Mon_A.patient }}</div>
52
+                        <div v-if="item.Mon_A.mode_name != 'HD'">{{ item.Mon_A.mode_name }}</div>
53
+                    </span>
54
+                </td>
55
+                <td style="min-width:50px;">
56
+                    <span v-if="item.Mon_N.patient_id">
57
+                        <div>{{ item.Mon_N.patient }}</div>
58
+                        <div v-if="item.Mon_N.mode_name != 'HD'">{{ item.Mon_N.mode_name }}</div>
59
+                    </span>
60
+                </td>
61
+                <td style="min-width:50px;">
62
+                    <span v-if="item.Tue_M.patient_id">
63
+                        <div>{{ item.Tue_M.patient }}</div>
64
+                        <div v-if="item.Tue_M.mode_name != 'HD'">{{ item.Tue_M.mode_name }}</div>
65
+                    </span>
66
+                </td>
67
+                <td style="min-width:50px;">
68
+                    <span v-if="item.Tue_A.patient_id">
69
+                        <div>{{ item.Tue_A.patient }}</div>
70
+                        <div v-if="item.Tue_A.mode_name != 'HD'">{{ item.Tue_A.mode_name }}</div>
71
+                    </span>
72
+                </td>
73
+                <td style="min-width:50px;">
74
+                    <span v-if="item.Tue_N.patient_id">
75
+                        <div>{{ item.Tue_N.patient }}</div>
76
+                        <div v-if="item.Tue_N.mode_name != 'HD'">{{ item.Tue_N.mode_name }}</div>
77
+                    </span>
78
+                </td>
79
+                <td style="min-width:50px;">
80
+                    <span v-if="item.Wed_M.patient_id">
81
+                        <div>{{ item.Wed_M.patient }}</div>
82
+                        <div v-if="item.Wed_M.mode_name != 'HD'">{{ item.Wed_M.mode_name }}</div>
83
+                    </span>
84
+                </td>
85
+                <td style="min-width:50px;">
86
+                    <span v-if="item.Wed_A.patient_id">
87
+                        <div>{{ item.Wed_A.patient }}</div>
88
+                        <div v-if="item.Wed_A.mode_name != 'HD'">{{ item.Wed_A.mode_name }}</div>
89
+                    </span>
90
+                </td>
91
+                <td style="min-width:50px;"> 
92
+                    <span v-if="item.Wed_N.patient_id">
93
+                        <div>{{ item.Wed_N.patient }}</div>
94
+                        <div v-if="item.Wed_N.mode_name != 'HD'">{{ item.Wed_N.mode_name }}</div>
95
+                    </span>
96
+                </td>
97
+                <td style="min-width:50px;">
98
+                    <span v-if="item.Thurs_M.patient_id">
99
+                        <div>{{ item.Thurs_M.patient }}</div>
100
+                        <div v-if="item.Thurs_M.mode_name != 'HD'">{{ item.Thurs_M.mode_name }}</div>
101
+                    </span>
102
+                </td>
103
+                <td style="min-width:50px;">
104
+                    <span v-if="item.Thurs_A.patient_id">
105
+                        <div>{{ item.Thurs_A.patient }}</div>
106
+                        <div v-if="item.Thurs_A.mode_name != 'HD'">{{ item.Thurs_A.mode_name }}</div>
107
+                    </span>
108
+                </td>
109
+                <td style="min-width:50px;">
110
+                    <span v-if="item.Thurs_N.patient_id">
111
+                        <div>{{ item.Thurs_N.patient }}</div>
112
+                        <div v-if="item.Thurs_N.mode_name != 'HD'">{{ item.Thurs_N.mode_name }}</div>
113
+                    </span>
114
+                </td>
115
+                <td style="min-width:50px;">
116
+                    <span v-if="item.Fri_M.patient_id">
117
+                        <div>{{ item.Fri_M.patient }}</div>
118
+                        <div v-if="item.Fri_M.mode_name != 'HD'">{{ item.Fri_M.mode_name }}</div>
119
+                    </span>
120
+                </td>
121
+                <td style="min-width:50px;">
122
+                    <span v-if="item.Fri_A.patient_id">
123
+                        <div>{{ item.Fri_A.patient }}</div>
124
+                        <div v-if="item.Fri_A.mode_name != 'HD'">{{ item.Fri_A.mode_name }}</div>
125
+                    </span>
126
+                </td>
127
+                <td style="min-width:50px;">
128
+                    <span v-if="item.Fri_N.patient_id">
129
+                        <div>{{ item.Fri_N.patient }}</div>
130
+                        <div v-if="item.Sat_M.mode_name != 'HD'">{{ item.Sat_M.mode_name }}</div>
131
+                    </span>
132
+                </td>
133
+                <td style="min-width:50px;">
134
+                    <span v-if="item.Sat_M.patient_id">
135
+                        <div>{{ item.Sat_M.patient }}</div>
136
+                        <div v-if="item.Sat_M.mode_name != 'HD'">{{ item.Sat_M.mode_name }}</div>
137
+                    </span>
138
+                </td>
139
+                <td style="min-width:50px;">
140
+                    <span v-if="item.Sat_A.patient_id">
141
+                        <div>{{ item.Sat_A.patient }}</div>
142
+                        <div v-if="item.Sat_A.mode_name != 'HD'">{{ item.Sat_A.mode_name }}</div>
143
+                    </span>
144
+                </td>
145
+                <td style="min-width:50px;">
146
+                    <span v-if="item.Sat_N.patient_id">
147
+                        <div>{{ item.Sat_N.patient }}</div>
148
+                        <div v-if="item.Sat_N.mode_name != 'HD'">{{ item.Sat_N.mode_name }}</div>
149
+                    </span>
150
+                </td>
151
+                <td style="min-width:50px;">
152
+                    <span v-if="item.Sun_M.patient_id">
153
+                        <div>{{ item.Sun_M.patient }}</div>
154
+                        <div v-if="item.Sun_M.mode_name != 'HD'">{{ item.Sun_M.mode_name }}</div>
155
+                    </span>
156
+                </td>
157
+                <td style="min-width:50px;">
158
+                    <span v-if="item.Sun_A.patient_id">
159
+                        <div>{{ item.Sun_A.patient }}</div>
160
+                        <div v-if="item.Sun_A.mode_name != 'HD'">{{ item.Sun_A.mode_name }}</div>
161
+                    </span>
162
+                </td>
163
+                <td style="min-width:50px;">
164
+                    <span v-if="item.Sun_N.patient_id">
165
+                        <div>{{ item.Sun_N.patient }}</div>
166
+                        <div v-if="item.Sun_N.mode_name != 'HD'">{{ item.Sun_N.mode_name }}</div>
167
+                    </span>
168
+                </td>
169
+                <td>{{item.total}}</td>
170
+            </tr>
171
+        </table>
172
+    </div>
173
+</template>
174
+
175
+
176
+
177
+<script>
178
+import {getSchedulesOne,getWeekPanelsOne,getPatientSheduleCount,getAllZones} from "@/api/schedule";
179
+import print from 'print-js'
180
+export default {
181
+    props:{
182
+        scheduleZoneProp: {
183
+            type: Array,
184
+            dafault: []
185
+        },
186
+    },
187
+    data(){
188
+        return{
189
+            schedule_type:'',
190
+            partition_id:'',
191
+            theType:2,
192
+            scheduleZone:[],
193
+            weekTitle:[],
194
+            scheduleZoneRow: [],
195
+            partitions: {},
196
+            theWeek: {
197
+              lastWeek: 0,
198
+              thisWeek: 0,
199
+              nextWeek: 0,
200
+              nextTwoWeek: 0
201
+           },
202
+           scheduleCountList:[],
203
+           total:0,
204
+           zones:[],
205
+           zoneIdList:[],
206
+           strArr:""
207
+        }
208
+    },
209
+    created(){
210
+        this.getAllZones()
211
+        this.modeOptions = this.$store.getters.treatment_mode;
212
+        this.partition_id = this.$route.query.partition_id
213
+       
214
+        
215
+    },
216
+    methods:{
217
+         getAllZones(){
218
+           getAllZones().then(response=>{
219
+             if(response.data.state == 1){
220
+                var zones = response.data.data.zones
221
+               for(let i=0;i<zones.length;i++){
222
+                    this.zoneIdList.push(zones[i].id)
223
+                }
224
+                this.zones.push(...zones)
225
+                var strArr =  this.zoneIdList.join(",")
226
+                
227
+                this.strArr = strArr
228
+                this.getWeekPanels()
229
+                //统计患者排班数量
230
+                this.getPatientSheduleCount()
231
+            }
232
+          })
233
+        },
234
+        getWeekPanels() {
235
+             this.scheduleZone = []
236
+              var partionStr = this.partition_id
237
+              var arr = this.zoneIdList.join(',')
238
+               var str = ""
239
+                if(partionStr == 0){
240
+                    str = arr
241
+                }
242
+                if(partionStr != 0){
243
+                    str = partionStr
244
+                }
245
+            getWeekPanelsOne(1,str).then(response => {
246
+                if (response.data.state == 0) {
247
+                    return false
248
+                }
249
+                var partitions = response.data.data.partitions
250
+                console.log("分区",partitions)
251
+                this.theWeek.thisWeek = response.data.data.theWeek
252
+                this.theWeek.lastWeek = this.theWeek.thisWeek - 1
253
+                this.theWeek.nextWeek = this.theWeek.thisWeek + 1
254
+                this.theWeek.nextTwoWeek = this.theWeek.thisWeek + 2
255
+                var that = this
256
+                if (partitions.length > 0) {
257
+                    partitions.forEach(function(partition) {
258
+                        if (partition.jihaos.length == 0) {
259
+                            return false
260
+                        }
261
+                        that.scheduleZoneRow.push(partition.jihaos.length)
262
+                        that.partitions[partition.id] = partition
263
+                        partition.jihaos.forEach(function(jihao) {
264
+                            var thisPa = {
265
+                            area: partition.name,
266
+                            zone_id: partition.id,
267
+                            zone_type: partition.type,
268
+                            cut: jihao.number,
269
+                            jihao_id: jihao.id,
270
+                            Mon_M: {
271
+                                schedule_id: 0,
272
+                                mode_id: 0,
273
+                                mode_name: '',
274
+                                patient_id: 0,
275
+                                patient: ''
276
+                            },
277
+                            Mon_A: {
278
+                                schedule_id: 0,
279
+                                mode_id: 0,
280
+                                mode_name: '',
281
+                                patient_id: 0,
282
+                                patient: ''
283
+                            },
284
+                            Mon_N: {
285
+                                schedule_id: 0,
286
+                                mode_id: 0,
287
+                                mode_name: '',
288
+                                patient_id: 0,
289
+                                patient: ''
290
+                            },
291
+                            Tue_M: {
292
+                                schedule_id: 0,
293
+                                mode_id: 0,
294
+                                mode_name: '',
295
+                                patient_id: 0,
296
+                                patient: ''
297
+                            },
298
+                            Tue_A: {
299
+                                schedule_id: 0,
300
+                                mode_id: 0,
301
+                                mode_name: '',
302
+                                patient_id: 0,
303
+                                patient: ''
304
+                            },
305
+                            Tue_N: {
306
+                                schedule_id: 0,
307
+                                mode_id: 0,
308
+                                mode_name: '',
309
+                                patient_id: 0,
310
+                                patient: ''
311
+                            },
312
+                            Wed_M: {
313
+                                schedule_id: 0,
314
+                                mode_id: 0,
315
+                                mode_name: '',
316
+                                patient_id: 0,
317
+                                patient: ''
318
+                            },
319
+                            Wed_A: {
320
+                                schedule_id: 0,
321
+                                mode_id: 0,
322
+                                mode_name: '',
323
+                                patient_id: 0,
324
+                                patient: ''
325
+                            },
326
+                            Wed_N: {
327
+                                schedule_id: 0,
328
+                                mode_id: 0,
329
+                                mode_name: '',
330
+                                patient_id: 0,
331
+                                patient: ''
332
+                            },
333
+                            Thurs_M: {
334
+                                schedule_id: 0,
335
+                                mode_id: 0,
336
+                                mode_name: '',
337
+                                patient_id: 0,
338
+                                patient: ''
339
+                            },
340
+                            Thurs_A: {
341
+                                schedule_id: 0,
342
+                                mode_id: 0,
343
+                                mode_name: '',
344
+                                patient_id: 0,
345
+                                patient: ''
346
+                            },
347
+                            Thurs_N: {
348
+                                schedule_id: 0,
349
+                                mode_id: 0,
350
+                                mode_name: '',
351
+                                patient_id: 0,
352
+                                patient: ''
353
+                            },
354
+                            Fri_M: {
355
+                                schedule_id: 0,
356
+                                mode_id: 0,
357
+                                mode_name: '',
358
+                                patient_id: 0,
359
+                                patient: ''
360
+                            },
361
+                            Fri_A: {
362
+                                schedule_id: 0,
363
+                                mode_id: 0,
364
+                                mode_name: '',
365
+                                patient_id: 0,
366
+                                patient: ''
367
+                            },
368
+                            Fri_N: {
369
+                                schedule_id: 0,
370
+                                mode_id: 0,
371
+                                mode_name: '',
372
+                                patient_id: 0,
373
+                                patient: ''
374
+                            },
375
+                            Sat_M: {
376
+                                schedule_id: 0,
377
+                                mode_id: 0,
378
+                                mode_name: '',
379
+                                patient_id: 0,
380
+                                patient: ''
381
+                            },
382
+                            Sat_A: {
383
+                                schedule_id: 0,
384
+                                mode_id: 0,
385
+                                mode_name: '',
386
+                                patient_id: 0,
387
+                                patient: ''
388
+                            },
389
+                            Sat_N: {
390
+                                schedule_id: 0,
391
+                                mode_id: 0,
392
+                                mode_name: '',
393
+                                patient_id: 0,
394
+                                patient: ''
395
+                            },
396
+                            Sun_A: {
397
+                                schedule_id: 0,
398
+                                mode_id: 0,
399
+                                mode_name: '',
400
+                                patient_id: 0,
401
+                                patient: ''
402
+                            },
403
+                            Sun_N: {
404
+                                schedule_id: 0,
405
+                                mode_id: 0,
406
+                                mode_name: '',
407
+                                patient_id: 0,
408
+                                patient: ''
409
+                            },
410
+                            Sun_M: {
411
+                                schedule_id: 0,
412
+                                mode_id: 0,
413
+                                mode_name: '',
414
+                                patient_id: 0,
415
+                                patient: ''
416
+                            },
417
+                            total: 0
418
+                            }
419
+                            that.scheduleZone.push(thisPa)
420
+
421
+                        })
422
+                    })
423
+                }
424
+                this.getSchedules()
425
+            })
426
+        },
427
+        getSchedules() {
428
+            var theType = 2;
429
+            if(this.$route.query.weekTime == "lastWeek"){
430
+               theType = 1
431
+            }
432
+           if(this.$route.query.weekTime == "thisWeek"){
433
+               theType = 2
434
+            }
435
+            if(this.$route.query.weekTime == "nextWeek"){
436
+               theType = 3
437
+            }
438
+           if(this.$route.query.weekTime == "nextTwoWeek"){
439
+               theType = 4
440
+            }
441
+            var partionStr = this.partition_id
442
+            var arr = this.zoneIdList.join(',')
443
+            var str = ""
444
+            if(partionStr == 0){
445
+                str = arr
446
+            }
447
+            if(partionStr != 0){
448
+                str = partionStr
449
+            }
450
+            const params = {
451
+                weekTime:theType,
452
+                patitionid:str,
453
+                schedule_type:this.schedule_type,
454
+            }
455
+            getSchedulesOne(params).then(response => {
456
+                if (response.data.state == 1) {
457
+                    this.weekTitle = response.data.data.weekTitle;
458
+                    this.weekDays = response.data.data.days;
459
+                    this.toDay = response.data.data.today;
460
+                    var theSchedules = response.data.data.schdules;
461
+                    var that = this;
462
+                    that.scheduleZone.forEach(function(zone, index) {
463
+                        
464
+                        that.scheduleZone[index].Mon_M = {
465
+                            mode_id: 0,
466
+                            mode_name: "",
467
+                            patient_id: 0,
468
+                            patient: ""
469
+                        };
470
+                        that.scheduleZone[index].Mon_A = {
471
+                            mode_id: 0,
472
+                            mode_name: "",
473
+                            patient_id: 0,
474
+                            patient: ""
475
+                        };
476
+                        that.scheduleZone[index].Mon_N = {
477
+                            mode_id: 0,
478
+                            mode_name: "",
479
+                            patient_id: 0,
480
+                            patient: ""
481
+                        };
482
+                        that.scheduleZone[index].Tue_M = {
483
+                            mode_id: 0,
484
+                            mode_name: "",
485
+                            patient_id: 0,
486
+                            patient: ""
487
+                        };
488
+                        that.scheduleZone[index].Tue_A = {
489
+                            mode_id: 0,
490
+                            mode_name: "",
491
+                            patient_id: 0,
492
+                            patient: ""
493
+                        };
494
+                        that.scheduleZone[index].Tue_N = {
495
+                            mode_id: 0,
496
+                            mode_name: "",
497
+                            patient_id: 0,
498
+                            patient: ""
499
+                        };
500
+                        that.scheduleZone[index].Wed_M = {
501
+                            mode_id: 0,
502
+                            mode_name: "",
503
+                            patient_id: 0,
504
+                            patient: ""
505
+                        };
506
+                        that.scheduleZone[index].Wed_A = {
507
+                            mode_id: 0,
508
+                            mode_name: "",
509
+                            patient_id: 0,
510
+                            patient: ""
511
+                        };
512
+                        that.scheduleZone[index].Wed_N = {
513
+                            mode_id: 0,
514
+                            mode_name: "",
515
+                            patient_id: 0,
516
+                            patient: ""
517
+                        };
518
+                        that.scheduleZone[index].Thurs_M = {
519
+                            mode_id: 0,
520
+                            mode_name: "",
521
+                            patient_id: 0,
522
+                            patient: ""
523
+                        };
524
+                        that.scheduleZone[index].Thurs_A = {
525
+                            mode_id: 0,
526
+                            mode_name: "",
527
+                            patient_id: 0,
528
+                            patient: ""
529
+                        };
530
+                        that.scheduleZone[index].Thurs_N = {
531
+                            mode_id: 0,
532
+                            mode_name: "",
533
+                            patient_id: 0,
534
+                            patient: ""
535
+                        };
536
+                        that.scheduleZone[index].Fri_M = {
537
+                            mode_id: 0,
538
+                            mode_name: "",
539
+                            patient_id: 0,
540
+                            patient: ""
541
+                        };
542
+                        that.scheduleZone[index].Fri_A = {
543
+                            mode_id: 0,
544
+                            mode_name: "",
545
+                            patient_id: 0,
546
+                            patient: ""
547
+                        };
548
+                        that.scheduleZone[index].Fri_N = {
549
+                            mode_id: 0,
550
+                            mode_name: "",
551
+                            patient_id: 0,
552
+                            patient: ""
553
+                        };
554
+                        that.scheduleZone[index].Sat_M = {
555
+                            mode_id: 0,
556
+                            mode_name: "",
557
+                            patient_id: 0,
558
+                            patient: ""
559
+                        };
560
+                        that.scheduleZone[index].Sat_A = {
561
+                            mode_id: 0,
562
+                            mode_name: "",
563
+                            patient_id: 0,
564
+                            patient: ""
565
+                        };
566
+                        that.scheduleZone[index].Sat_N = {
567
+                            mode_id: 0,
568
+                            mode_name: "",
569
+                            patient_id: 0,
570
+                            patient: ""
571
+                        };
572
+                        that.scheduleZone[index].Sun_A = {
573
+                            mode_id: 0,
574
+                            mode_name: "",
575
+                            patient_id: 0,
576
+                            patient: ""
577
+                        };
578
+                        that.scheduleZone[index].Sun_N = {
579
+                            mode_id: 0,
580
+                            mode_name: "",
581
+                            patient_id: 0,
582
+                            patient: ""
583
+                        };
584
+                        that.scheduleZone[index].Sun_M = {
585
+                            mode_id: 0,
586
+                            mode_name: "",
587
+                            patient_id: 0,
588
+                            patient: ""
589
+                        };
590
+                        that.scheduleZone[index].total = 0;
591
+                        
592
+                        if (response.data.data.schdules.length > 0) {
593
+                            theSchedules.forEach(function(schedule, sindex) {
594
+
595
+                                if (zone.jihao_id == schedule.bed_id) {
596
+                                    // if(zone.zone_id == schedule.partition_id && zone.jihao_id == schedule.bed_id) {
597
+                                    var weekPath = that.weekPath(
598
+                                        schedule.schedule_week,
599
+                                        schedule.schedule_type
600
+                                    );
601
+
602
+                                    if (weekPath.length == 2) {
603
+                                        // console.log(schedule);
604
+
605
+                                        var weekPathKey = weekPath[0] + "_" + weekPath[1];
606
+                                        that.scheduleZone[index][weekPathKey] = {
607
+                                        schedule_id: schedule.id,
608
+                                        mode_id: schedule.mode_id,
609
+                                        patient_id: schedule.patient_id,
610
+                                        patient: schedule.patient,
611
+                                        patient_contagions: schedule.patient_contagions,
612
+                                        mode_name:
613
+                                            typeof that.modeOptions[schedule.mode_id] ===
614
+                                            "undefined"
615
+                                            ? ""
616
+                                            : that.modeOptions[schedule.mode_id].name
617
+                                        };
618
+                                        that.scheduleZone[index].total += 1;
619
+                                        
620
+                                    }
621
+                                    
622
+                                }
623
+                                
624
+                            });
625
+                        }
626
+                       
627
+                    });
628
+                    var newArr= [{"area":"总数","cut":0,"Fri_A":{mode_id:0,mode_name:"",patient:"0",patient_id:"1"},"Fri_M":{mode_id:0,mode_name:"",patient:"0",patient_id:"1"},"Fri_N":{mode_id:0,mode_name:"",patient:"0",patient_id:"1"},"Mon_A":{mode_id:0,mode_name:"",patient:"",patient_id:"1"},"Mon_M":{mode_id:0,mode_name:"",patient:"0",patient_id:"1"},"Mon_N":{mode_id:0,mode_name:"",patient:"0",patient_id:"1"},"Sat_A":{mode_id:0,mode_name:"",patient:"0",patient_id:"1"},"Sat_M":{mode_id:0,mode_name:"",patient:"0",patient_id:"1"},"Sat_N":{mode_id:0,mode_name:"",patient:"0",patient_id:"1"},"Sun_A":{mode_id:0,mode_name:"",patient:"0",patient_id:"1"},"Sun_M":{mode_id:0,mode_name:"",patient:"0",patient_id:"1"},"Sun_N":{mode_id:0,mode_name:"",patient:"0",patient_id:"1"},"Thurs_A":{mode_id:0,mode_name:"",patient:"0",patient_id:"1"},"Thurs_M":{mode_id:0,mode_name:"",patient:"0",patient_id:"1"},"Thurs_N":{mode_id:0,mode_name:"",patient:"0",patient_id:"1"},"Tue_A":{mode_id:0,mode_name:"",patient:"0",patient_id:"1"},"Tue_M":{mode_id:0,mode_name:"",patient:"0",patient_id:"1"},"Tue_N":{mode_id:0,mode_name:"",patient:"0",patient_id:"1"},"Wed_A":{mode_id:0,mode_name:"",patient:"0",patient_id:"1"},"Wed_M":{mode_id:0,mode_name:"",patient:"0",patient_id:"1"},"Wed_N":{mode_id:0,mode_name:"",patient:"0",patient_id:"1"},"jihao_id":"","total":"","zone_id":"","zone_type":""}]
629
+                     
630
+                     
631
+                     for(let i=0;i<newArr.length;i++){
632
+                       for(let j=0;j<this.scheduleCountList.length;j++){
633
+                            newArr[i].cut = this.total
634
+                         //礼拜一上午
635
+                          if(this.scheduleCountList[j].schedule_week == 1 && this.scheduleCountList[j].schedule_type == 1){
636
+                            
637
+                              newArr[i].Mon_M.patient = this.scheduleCountList[j].Count
638
+                          } 
639
+                        //礼拜一下午
640
+                         if(this.scheduleCountList[j].schedule_week == 1 && this.scheduleCountList[j].schedule_type == 2){
641
+                           
642
+                              newArr[i].Mon_A.patient = this.scheduleCountList[j].Count
643
+                          } 
644
+
645
+                         //礼拜一晚上
646
+                         if(this.scheduleCountList[j].schedule_week == 1 && this.scheduleCountList[j].schedule_type == 3){
647
+                            
648
+                              newArr[i].Mon_N.patient = this.scheduleCountList[j].Count
649
+                          } 
650
+                         
651
+                        //礼拜二上午
652
+                         if(this.scheduleCountList[j].schedule_week == 2 && this.scheduleCountList[j].schedule_type == 1){
653
+                            
654
+                              newArr[i].Tue_M.patient = this.scheduleCountList[j].Count
655
+                          } 
656
+                         //礼拜二下午
657
+                         if(this.scheduleCountList[j].schedule_week == 2 && this.scheduleCountList[j].schedule_type == 2){
658
+                            
659
+                              newArr[i].Tue_A.patient = this.scheduleCountList[j].Count
660
+                          } 
661
+                        
662
+                         //礼拜二晚上
663
+                         if(this.scheduleCountList[j].schedule_week == 2 && this.scheduleCountList[j].schedule_type == 3){
664
+                            
665
+                              newArr[i].Tue_N.patient = this.scheduleCountList[j].Count
666
+                          } 
667
+
668
+                         //礼拜三上午
669
+                         if(this.scheduleCountList[j].schedule_week == 3 && this.scheduleCountList[j].schedule_type == 1){
670
+                            
671
+                              newArr[i].Wed_M.patient = this.scheduleCountList[j].Count
672
+                          } 
673
+
674
+                         //礼拜三下午
675
+                         if(this.scheduleCountList[j].schedule_week == 3 && this.scheduleCountList[j].schedule_type == 2){
676
+                            
677
+                              newArr[i].Wed_A.patient = this.scheduleCountList[j].Count
678
+                          }
679
+
680
+                         //礼拜三晚上
681
+                         if(this.scheduleCountList[j].schedule_week == 3 && this.scheduleCountList[j].schedule_type == 2){
682
+                            
683
+                              newArr[i].Wed_N.patient = this.scheduleCountList[j].Count
684
+                          }
685
+
686
+
687
+
688
+                        //礼拜四上午
689
+                         if(this.scheduleCountList[j].schedule_week == 3 && this.scheduleCountList[j].schedule_type == 1){
690
+                            
691
+                              newArr[i].Thurs_A.patient = this.scheduleCountList[j].Count
692
+                          } 
693
+
694
+                         //礼拜四下午
695
+                         if(this.scheduleCountList[j].schedule_week == 3 && this.scheduleCountList[j].schedule_type == 2){
696
+                            
697
+                              newArr[i].Thurs_M.patient = this.scheduleCountList[j].Count
698
+                          }
699
+
700
+                         //礼拜四晚上
701
+                         if(this.scheduleCountList[j].schedule_week == 3 && this.scheduleCountList[j].schedule_type == 2){
702
+                            
703
+                              newArr[i].Thurs_N.patient = this.scheduleCountList[j].Count
704
+                          }
705
+
706
+
707
+                        //礼拜五上午
708
+                         if(this.scheduleCountList[j].schedule_week == 3 && this.scheduleCountList[j].schedule_type == 1){
709
+                            
710
+                              newArr[i].Fri_A.patient = this.scheduleCountList[j].Count
711
+                          } 
712
+
713
+                         //礼拜五下午
714
+                         if(this.scheduleCountList[j].schedule_week == 3 && this.scheduleCountList[j].schedule_type == 2){
715
+                            
716
+                              newArr[i].Fri_M.patient = this.scheduleCountList[j].Count
717
+                          }
718
+
719
+                         //礼拜五晚上
720
+                         if(this.scheduleCountList[j].schedule_week == 3 && this.scheduleCountList[j].schedule_type == 2){
721
+                            
722
+                              newArr[i].Fri_N.patient = this.scheduleCountList[j].Count
723
+                          }
724
+
725
+
726
+                        //礼拜六上午
727
+                         if(this.scheduleCountList[j].schedule_week == 3 && this.scheduleCountList[j].schedule_type == 1){
728
+                            
729
+                              newArr[i].Sat_A.patient = this.scheduleCountList[j].Count
730
+                          } 
731
+
732
+                         //礼拜六下午
733
+                         if(this.scheduleCountList[j].schedule_week == 3 && this.scheduleCountList[j].schedule_type == 2){
734
+                            
735
+                              newArr[i].Sat_M.patient = this.scheduleCountList[j].Count
736
+                          }
737
+
738
+                         //礼拜六晚上
739
+                         if(this.scheduleCountList[j].schedule_week == 3 && this.scheduleCountList[j].schedule_type == 2){
740
+                            
741
+                              newArr[i].Sat_N.patient = this.scheduleCountList[j].Count
742
+                          }
743
+                         
744
+
745
+                          //礼拜日上午
746
+                         if(this.scheduleCountList[j].schedule_week == 3 && this.scheduleCountList[j].schedule_type == 1){
747
+                            
748
+                              newArr[i].Sun_A.patient = this.scheduleCountList[j].Count
749
+                          } 
750
+
751
+                         //礼拜日下午
752
+                         if(this.scheduleCountList[j].schedule_week == 3 && this.scheduleCountList[j].schedule_type == 2){
753
+                            
754
+                              newArr[i].Sun_M.patient = this.scheduleCountList[j].Count
755
+                          }
756
+
757
+                         //礼拜日晚上
758
+                         if(this.scheduleCountList[j].schedule_week == 3 && this.scheduleCountList[j].schedule_type == 2){
759
+                            
760
+                              newArr[i].Sun_N.patient = this.scheduleCountList[j].Count
761
+                          }
762
+
763
+
764
+                       }
765
+                     }
766
+                    console.log("newArr222222222",newArr)
767
+                    that.scheduleZone.push(...newArr)
768
+                    console.log('总数据77777777777',that.scheduleZone)
769
+                    
770
+                } else {
771
+                    this.$message.error("网络错误");
772
+                    return false;
773
+                }
774
+            });
775
+        },
776
+        weekPath(week, schedule_type) {
777
+            var weekArr = {
778
+                1: "Mon",
779
+                2: "Tue",
780
+                3: "Wed",
781
+                4: "Thurs",
782
+                5: "Fri",
783
+                6: "Sat",
784
+                7: "Sun"
785
+            };
786
+            var typeArr = { 1: "M", 2: "A", 3: "N" };
787
+            if (
788
+                typeof weekArr[week] === "undefined" ||
789
+                typeof typeArr[schedule_type] === "undefined"
790
+            ) {
791
+                return [];
792
+            }
793
+            return [weekArr[week], typeArr[schedule_type]];
794
+        },
795
+        printAction: function() {
796
+            const style = '@media print {#scheduleTable{font-size:14px;} .scheduleTable tr td{text-align: center;padding: 5px;}}'
797
+
798
+            printJS({
799
+            printable: 'scheduleTable',
800
+            type: 'html',
801
+            documentTitle: '  ',
802
+            style: style,
803
+            scanStyles: false
804
+            })
805
+        },
806
+        getPatientSheduleCount(){
807
+            var theType = 2;
808
+            if(this.$route.query.weekTime == "lastWeek"){
809
+               theType = 1
810
+            }
811
+           if(this.$route.query.weekTime == "thisWeek"){
812
+               theType = 2
813
+            }
814
+            if(this.$route.query.weekTime == "nextWeek"){
815
+               theType = 3
816
+            }
817
+           if(this.$route.query.weekTime == "nextTwoWeek"){
818
+               theType = 4
819
+            }
820
+           var partionStr = this.partition_id
821
+            var arr = this.zoneIdList.join(',')
822
+            var str = ""
823
+            if(partionStr == 0){
824
+                str = arr
825
+            }
826
+            if(partionStr != 0){
827
+                str = partionStr.join(',')
828
+            }
829
+            var params = {
830
+             weekTime:theType,
831
+             partition_id:str,
832
+
833
+            }
834
+           getPatientSheduleCount(params).then(response=>{
835
+               if(response.data.state == 1){
836
+                  var list = response.data.data.list
837
+                  console.log("list22222",list)
838
+                  
839
+                  this.scheduleCountList = list
840
+                  var total = response.data.data.total
841
+                  console.log("totalw222",total)
842
+                  this.total = total
843
+               }
844
+           }) 
845
+        }
846
+    }
847
+}
848
+</script>
849
+
850
+
851
+<style lang="scss">
852
+td{
853
+    text-align: center;
854
+    padding: 5px;
855
+}
856
+</style>