Procházet zdrojové kódy

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

XMLWAN před 4 roky
rodič
revize
422a5adde7

+ 10 - 9
src/xt_pages/outpatientDoctorStation/template/printOne.vue Zobrazit soubor

@@ -2,7 +2,7 @@
2 2
   <div id='prescriptionPrint'>
3 3
     <div v-for="(item,index) in advicePrint" :key="index">
4 4
       <div id='prescription-print' class="prescription-print" style="page-break-after: always;">
5
-          <div class="printTitle">{{orgname}} &nbsp;&nbsp; 血液透析中心处方笺</div>
5
+          <div class="printTitle">血液透析中心处方笺</div>
6 6
           <div class="infoTitle">
7 7
               <p>姓名:{{item.patient.name?item.patient.name:""}}</p>
8 8
               <p>性别:
@@ -69,8 +69,8 @@ export default {
69 69
         prescriptionInfo:[],
70 70
         hisPatient:{},
71 71
         department:[],
72
-        prescriptions:[],
73
-        orgname:""
72
+        prescriptions:[]
73
+
74 74
       }
75 75
     },
76 76
    methods:{
@@ -150,6 +150,7 @@ export default {
150 150
        return name
151 151
      },
152 152
      getTotalOne(id) {
153
+        console.log("处方数据",this.prescriptions)
153 154
         var total = 0
154 155
         var addtotal = 0
155 156
         for (let i = 0; i < this.prescriptions.length; i++) {
@@ -161,14 +162,15 @@ export default {
161 162
             }
162 163
           
163 164
             if (this.prescriptions[i].additionalcharge != null) {
164
-              for (let b = 0; b < this.prescriptions[i].additionalcharge.length; b++) {
165
-                addtotal = addtotal + this.prescriptions[i].additionalcharge[b].price * this.prescriptions[i].additionalcharge[b].count
165
+              for (let a = 0; a < this.prescriptions[i].additionalcharge.length; a++) {
166
+                addtotal = addtotal + this.prescriptions[i].additionalcharge[a].price * this.prescriptions[i].additionalcharge[a].count
166 167
               }
167 168
             }
168 169
               addtotal =  Math.floor(addtotal * 100) / 100
169 170
         }
171
+        
172
+        return total + addtotal
170 173
        }
171
-       return total + addtotal
172 174
       }, 
173 175
 
174 176
 
@@ -178,12 +180,11 @@ export default {
178 180
       this.getInitData()
179 181
       this.getPrescriptionPrint()
180 182
       this.getHisPatientDetail()
181
-      var xtuser = this.$store.getters.xt_user
182
-      this.orgname = xtuser.org.org_name
183
+
183 184
      
184 185
    },
185 186
    watch:{
186
-    ids:function(val){
187
+     ids:function(val){
187 188
       this.ids = val
188 189
       this.getPrescriptionPrint()
189 190
     }

+ 23 - 23
src/xt_pages/outpatientDoctorStation/treatTemplate/printOne.vue Zobrazit soubor

@@ -1,40 +1,39 @@
1 1
 <template>
2
-   <div>
2
+   <div id='prescriptionPrint'>
3 3
     <div id='prescription-print' class="prescription-print" v-for="(item,index) in advicePrint" :key="index">
4 4
 
5
-        <div style="display:flex;justify-content: space-between;font-weight:bold;">
6
-            <p style="width:300px;display:flex;justify-content: space-between;font-weight:bold;">
5
+        <div style="display:flex;justify-content: space-between;font-weight:bold;align-items:center;">
6
+            <div style="width:200px;display:flex;justify-content: space-between;font-weight:bold;">
7 7
                 <span>费别</span>
8 8
                 <span>自费</span>
9 9
                 <span>公费</span>
10 10
                 <span>保险</span>
11 11
                 <span>其他</span>
12
-            </p>
13
-            <p>就诊日期:{{getTime(item.ctime)}}</p>
12
+            </div>
13
+            <div>就诊日期:{{getTime(item.ctime,"{y}-{m}-{d}")}}</div>
14 14
         </div>
15 15
 
16
-        <div class="printTitle">{{orgname}} &nbsp;&nbsp; 血液透析中心处方、治疗单</div>
17
-
18
-        <!-- <div class="printTitle">处方、治疗单</div> -->
16
+        <div class="printTitle">{{orgname}}</div>
17
+        <div class="printTitle">血液透析中心处方、治疗单</div>
19 18
 
20 19
         <div class="infoTitle">
21
-            <p>门诊编号:</p>
22
-            <p>电脑号:</p>
20
+            <div>门诊编号:</div>
21
+            <div>电脑号:</div>
23 22
         </div>
24 23
 
25 24
         <div class="infoMain">
26
-            <p style="margin-bottom: 10px;width:25%">姓名:{{item.patient.name}}</p>
27
-            <p style="margin-bottom: 10px;width:25%">性别:
25
+            <div style="margin-bottom: 10px;width:25%">姓名:{{item.patient.name}}</div>
26
+            <div style="margin-bottom: 10px;width:25%">性别:
28 27
                 <span v-if="item.patient.gender == 1">男</span>
29 28
                 <span v-if="item.patient.gender == 2">女</span>
30
-            </p>
31
-            <p style="margin-bottom: 10px;width:25%">年龄:
29
+            </div>
30
+            <div style="margin-bottom: 10px;width:25%">年龄:
32 31
                 <span>{{item.patient.age}}</span>
33
-            </p>
34
-            <p style="margin-bottom: 10px;width:25%">参保类型:</p>
35
-            <p style="margin-bottom: 10px;width:50%;">联系电话:{{item.patient.phone}}</p>
36
-            <p style="width:50%;">地址:{{item.patient.unit_address}}</p>
37
-            <p style="width:50%;">诊断:{{item.patient.diagnose}}</p>
32
+            </div>
33
+            <div style="margin-bottom: 10px;width:25%">参保类型:</div>
34
+            <div style="margin-bottom: 10px;width:50%;">联系电话:{{item.patient.phone}}</div>
35
+            <div style="width:50%;">地址:{{item.patient.unit_address}}</div>
36
+            <div style="width:100%;">诊断:{{item.patient.diagnose}}</div>
38 37
         </div>
39 38
 
40 39
         <div class="prescriptionBox">
@@ -64,13 +63,13 @@
64 63
         </div>
65 64
 
66 65
         <div class="infoTitle">
67
-            <p>开单医生:{{item.doctor?item.doctor:""}}</p>
68
-            <p>签章:</p>
66
+            <div>开单医生:{{item.doctor?item.doctor:""}}</div>
67
+            <div>签章:</div>
69 68
         </div>
70 69
 
71 70
         <div class="actionBar">
72
-            <p>执行医生:{{item.doctor?item.doctor:""}}</p>
73
-            <p>费用:{{getTotalOne(item.id)?getTotalOne(item.id):''}}元</p>
71
+            <div>执行医生:{{item.doctor?item.doctor:""}}</div>
72
+            <div>费用:{{getTotalOne(item.id)?getTotalOne(item.id):''}}元</div>
74 73
         </div>
75 74
 
76 75
         <table style="width:100%;text-align:center;line-height:25px;border-collapse: collapse;" border="1">
@@ -369,6 +368,7 @@ export default {
369 368
     font-size: 18px;
370 369
     text-align: center;
371 370
     font-weight: bold;
371
+    margin-top: 10px;
372 372
 }
373 373
 .infoTitle{
374 374
     display: flex;