yq1 10 months ago
parent
commit
f721272577

+ 10 - 4
src/xt_pages/Pharmacy/PatientDispensing.vue View File

@@ -321,7 +321,7 @@ export default {
321 321
       ],
322 322
       tableHeight: 400,
323 323
       start_time: moment(new Date()).add("year", 0).format("YYYY-MM-DD"),
324
-      start_time2: moment(new Date()).add("year", 0).format("YYYY-MM-DD hh:mm"),
324
+      start_time2: moment(new Date()).add("year", 0).format("YYYY-MM-DD HH:mm"),
325 325
       state: 1, //1待发药,2已发药
326 326
       waitmount: 0, //待发药人数
327 327
       waitmount_data: [],
@@ -349,7 +349,9 @@ export default {
349 349
       baseList:[],
350 350
       org_id:'',
351 351
       patients:{},
352
-      doctors:[]
352
+      doctors:[],
353
+      diagnosearr:[],
354
+      diagnosis:'',
353 355
     };
354 356
   },
355 357
   watch: {},
@@ -565,6 +567,8 @@ export default {
565 567
            this.baseList =[]
566 568
           this.baseList = res.data.data.baseList
567 569
           this.doctors = res.data.data.doctors
570
+          this.diagnosearr = res.data.data.diagnose
571
+          this.diagnosis = res.data.data.prescription.diagnosis
568 572
           const obj={
569 573
             age:res.data.data.patients.age,
570 574
             gender: res.data.data.patients.gender,
@@ -611,10 +615,12 @@ export default {
611 615
             this.tableData,
612 616
             this.currentRow,
613 617
             this.state,
614
-            this.start_time2,
618
+            this.start_time,
615 619
             this.baseList,
616 620
             this.patients,
617
-            this.doctors
621
+            this.doctors,
622
+            this.diagnosearr,
623
+            this.diagnosis
618 624
           )
619 625
         }
620 626
       }

+ 30 - 7
src/xt_pages/Pharmacy/print/patientPrintTwo.vue View File

@@ -6,7 +6,7 @@
6 6
     :close-on-press-escape="isClose"
7 7
   >
8 8
     <el-button type="primary" @click="print" class="print_style"
9
-      >打印23</el-button
9
+      >打印</el-button
10 10
     >
11 11
     <div id="dialysis-print-box-1" class="dialysis-print-box-1">
12 12
       <div class="list_title" style="border-bottom:none;">
@@ -25,7 +25,8 @@
25 25
         <span>性别:{{ patients.gender==1 ?'男':'女'}}</span>&nbsp;&nbsp;
26 26
         <span>年龄:{{patients.age}}</span>&nbsp;&nbsp;
27 27
         <span>住院科室:肾内科</span>&nbsp;&nbsp;
28
-        <span>入院诊断:{{patients.diagnose}}</span>
28
+        <!-- <span>入院诊断:{{patients.diagnose}}</span> -->
29
+        <span>入院诊断:{{ getdiagnosis(diagnosis) }}</span>
29 30
       </div>
30 31
       <div>
31 32
         <table class="table" border="1" 
@@ -102,7 +103,9 @@ export default {
102 103
       Doctor:'',
103 104
       patients:{},
104 105
       doctors:[],
105
-      Price_zong:0
106
+      Price_zong:0,
107
+      diagnosearr:[],
108
+      diagnosis:'',
106 109
     };
107 110
   },
108 111
   props: {
@@ -137,7 +140,7 @@ export default {
137 140
         }
138 141
       }
139 142
     },
140
-    show: function (val,data,state,times,base,patients,doctors) {
143
+    show: function (val,data,state,times,base,patients,doctors,arr,diagnosis) {
141 144
       this.times = times
142 145
       this.visibility = true;
143 146
       console.log("val",val)
@@ -148,6 +151,8 @@ export default {
148 151
       this.baseList = base
149 152
       this.patients = patients
150 153
       this.doctors = doctors
154
+      this.diagnosearr = arr
155
+      this.diagnosis = diagnosis
151 156
       if (state == 1){
152 157
         this.state = "待发药"
153 158
       }
@@ -160,7 +165,25 @@ export default {
160 165
         }
161 166
       }
162 167
     },
163
-
168
+    getdiagnosis(val){
169
+      const diagnosis = val.split(',')
170
+      console.log('diagnosis',diagnosis)
171
+      const diagn = []
172
+      // const dia_id =[]
173
+      const arr = this.diagnosearr
174
+      if(diagnosis.length>0 && arr.length>0){
175
+        for(let i in arr){
176
+          for(let j in diagnosis){
177
+            if(arr[i].id ==diagnosis[j]){
178
+              diagn.push(arr[i].class_name)
179
+            }
180
+          }
181
+          var arr2 = diagn.join()
182
+          console.log('arr2',arr2);
183
+        }
184
+      }
185
+      return arr2
186
+    },
164 187
     comfirm: function (formName) {
165 188
       this.goodInfo = [];
166 189
       this.goodInfoTableData = [];
@@ -301,8 +324,8 @@ export default {
301 324
 .table tr td{
302 325
  border:1px solid black;
303 326
  padding: 5px 0;
304
-//  border-left: none;
305
-//  border-right: none;
327
+ border-left: none;
328
+ border-right: none;
306 329
 }
307 330
 </style>
308 331