see999 3 years ago
parent
commit
7b73662248

+ 11 - 9
src/xt_pages/outpatientDoctorStation/checkPrint.vue View File

@@ -56,15 +56,17 @@ export default {
56 56
     printThisPage() {
57 57
         var ptime = Math.round(new Date().getTime() / 1000);
58 58
         this.print_time = uParseTime(ptime, "{y}-{m}-{d} {h}:{i}");
59
-
60
-        const style =
61
-        '@media print {#prescription-print{font-size:14px;}.prescription-print:last-child {page-break-after: auto;}.prescription-print{font-size: 14px;}.printTitle{font-size: 18px;text-align: center;font-weight: bold;}.infoTitle{display: flex;border-bottom: 2px solid #000;margin-top:5px;padding:0 10px;}.infoTitle div{width: 300px;margin-bottom:5px;}.infoMain{display: flex;flex-wrap: wrap;border-bottom: 2px solid #000;padding:0 10px;}.infoMain div{width: 50%;}.prescriptionBox{padding:0 10px;min-height:380px;}.Rp{font-size: 22px;font-weight: bold;line-height:1px;}.drugsBox{padding-left: 40px;margin-bottom: 10px;margin-bottom: 10px;}.drugsBox p{line-height: 1px;padding-bottom:10px !important;} .drugsOne{line-height: 1px;margin-bottom:10px !important;} .drugsOne span{margin-right: 20px;} .doctorBox{display: flex; justify-content: space-between; padding:0 10px; border-bottom: 2px solid #000;} .actionBar{display: flex; justify-content: space-between; padding:0 10px;margin:5px 0;} .actionBar div{width:150px;}}';
62
-        printJS({
63
-          printable: "prescription-print",
64
-          type: "html",
65
-          style: style,
66
-          scanStyles: false
67
-        });
59
+        setTimeout(() => {
60
+            const style =
61
+            '@media print {#prescription-print{font-size:14px;}.prescription-print:last-child {page-break-after: auto;}.prescription-print{font-size: 14px;}.printTitle{font-size: 18px;text-align: center;font-weight: bold;}.infoTitle{display: flex;border-bottom: 2px solid #000;margin-top:5px;padding:0 10px;}.infoTitle div{width: 300px;margin-bottom:5px;}.infoMain{display: flex;flex-wrap: wrap;border-bottom: 2px solid #000;padding:0 10px;}.infoMain div{width: 50%;}.prescriptionBox{padding:0 10px;min-height:380px;}.Rp{font-size: 22px;font-weight: bold;line-height:1px;}.drugsBox{padding-left: 40px;margin-bottom: 10px;margin-bottom: 10px;}.drugsBox p{line-height: 1px;padding-bottom:10px !important;} .drugsOne{line-height: 1px;margin-bottom:10px !important;} .drugsOne span{margin-right: 20px;} .doctorBox{display: flex; justify-content: space-between; padding:0 10px; border-bottom: 2px solid #000;} .actionBar{display: flex; justify-content: space-between; padding:0 10px;margin:5px 0;} .actionBar div{width:150px;}}';
62
+            printJS({
63
+                printable: "prescription-print",
64
+                type: "html",
65
+                style: style,
66
+                scanStyles: false
67
+            });
68
+        },500)
69
+        
68 70
     },
69 71
     getAllDoctorList(){
70 72
       getAllDoctorList().then(response=>{

+ 8 - 8
src/xt_pages/outpatientDoctorStation/checkTemplate/printOne.vue View File

@@ -5,12 +5,12 @@
5 5
             <div class="printTitle">检验申请单</div>
6 6
 
7 7
             <div style="border:1px solid #000;">
8
-                <div style="display:flex;justify-content: space-between;border-bottom:1px solid #000;line-height:40px;">
8
+                <div style="display:flex;justify-content: space-between;border-bottom:1px solid #000;line-height:40px;padding:0 10px;">
9 9
                     <div>是否急诊:否</div>
10 10
                     <div>结算方式:{{ faber && faber.transBody ? getName(faber.transBody.outputlist1) : '' }}</div>
11 11
                     <div>金额:{{ total }}</div>
12 12
                 </div>
13
-                <div style="display:flex;justify-content: space-between;border-bottom:1px solid #000;line-height:40px;">
13
+                <div style="display:flex;justify-content: space-between;border-bottom:1px solid #000;line-height:40px;padding:0 10px;">
14 14
                     <div>姓名:{{advicePrint[0].patient.name?advicePrint[0].patient.name:""}}</div>
15 15
                     <div>性别:
16 16
                         <span v-if="advicePrint[0].patient.gender == 1">男</span>
@@ -18,21 +18,21 @@
18 18
                     </div>
19 19
                     <div>年龄:{{advicePrint[0].patient.age?advicePrint[0].patient.age:""}}岁</div>
20 20
                 </div>
21
-                <div>病史摘要:{{history.history_of_present_illness?history.history_of_present_illness:''}}</div>
22
-                <div>体格检查:
21
+                <div style="margin-bottom:20px;padding:10px 10px 0;">病史摘要:{{history.history_of_present_illness?history.history_of_present_illness:''}}</div>
22
+                <div style="margin-bottom:20px;padding:0 10px;">体格检查:
23 23
                     <span>体温:{{ history.temperature ? history.temperature + '℃' : '/' }}</span>
24 24
                     <span>脉搏:{{ history.pulse ? history.pulse + '次/分' : '/' }}</span>
25 25
                     <span>呼吸:{{ history.breathing ? history.breathing + '次/分' : '/' }}</span>
26 26
                     <span>血压:{{ history.sbp }}/{{ history.dbp }}mmHg</span>
27 27
                 </div>
28
-                <div>临床诊断:{{ getDiagnosis(advicePrint[0].info.diagnosis) }}</div>
29
-                <div style="display:flex">
28
+                <div style="margin-bottom:20px;padding:0 10px;">临床诊断:{{ getDiagnosis(advicePrint[0].info.diagnosis) }}</div>
29
+                <div style="display:flex;margin-bottom:20px;padding:0 10px;">
30 30
                     <div>检验项目:</div>
31 31
                     <div>
32
-                        <div v-for="item in projectPrint">{{ item.project.project_name }}</div>
32
+                        <div v-for="item in projectPrint" style="margin-bottom:10px;">{{ item.project.project_name }}</div>
33 33
                     </div>
34 34
                 </div>
35
-                <div style="display:flex;justify-content: space-between;border-top:1px solid #000;line-height:40px;">
35
+                <div style="display:flex;justify-content: space-between;border-top:1px solid #000;line-height:40px;padding:0 10px;">
36 36
                     <div>开单医生:{{ doctor ? doctor : '' }}</div>
37 37
                     <div>开单日期:
38 38
                         {{getTime(pre_time) ? getTime(pre_time).split(' ')[0] : ''}}

+ 18 - 6
src/xt_pages/outpatientDoctorStation/treatTemplate/printTwo.vue View File

@@ -229,10 +229,7 @@ export default {
229 229
           {value: 4,label:'农保'},
230 230
           {value: 5,label:'会员'},
231 231
           {value: 6,label:'职工'},
232
-          {value: 7,label:'合同'},
233
-           {value: 8,label:'医保自费'},
234
-
235
-
232
+          {value: 7,label:'合同'}
236 233
          ],
237 234
          hisPatient:{},
238 235
          diagnoses:[],
@@ -307,6 +304,21 @@ export default {
307 304
             this.projectList = projectlist
308 305
             this.hisPatient = response.data.data.hisPatient
309 306
 
307
+            let projectPrint = []
308
+            let total = 0
309
+            this.advicePrint.map(item => {
310
+              console.log(item.project.length)
311
+              if(item.project.length > 0){
312
+                for(var i=item.project.length-1;i>=0;i--){
313
+                  if(item.project[i].type==2){
314
+                    if(item.project[i].project.cost_classify == 3){
315
+                      item.project.splice(i,1);
316
+                    }
317
+                  }
318
+                }
319
+              }
320
+            })
321
+
310 322
             let outputlist1Name = JSON.parse(response.data.data.his.patient_info);
311 323
             this.faber = outputlist1Name
312 324
 
@@ -495,7 +507,7 @@ export default {
495 507
 <style lang="scss" scoped>
496 508
 .prescription-print{
497 509
   -webkit-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 60px rgba(0, 0, 0, 0.06) inset;
498
-    -moz-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 40px rgba(0, 0, 0, 0.06) inset;
510
+    -moz-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 40px rgba(0, 0, 0, 0.06) inset; 
499 511
     box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 40px rgba(0, 0, 0, 0.06) inset;
500 512
     margin-bottom: 20px;
501 513
     padding:20px 10px;
@@ -553,7 +565,7 @@ export default {
553 565
 }
554 566
 .actionBar{
555 567
     display: flex;
556
-    justify-content: space-between;
568
+    justify-content: space-between; 
557 569
     line-height: 24px;
558 570
     padding:0 10px;
559 571
 }