Bläddra i källkod

HIS 系统提交

XMLWAN 4 år sedan
förälder
incheckning
364e173b89

+ 5 - 2
src/xt_pages/outpatientCharges/outpatientChargesManagement.vue Visa fil

@@ -368,6 +368,7 @@
368 368
         console.log("val",val.name)
369 369
         for (let i = 0; i < this.prescriptions.length; i++) {
370 370
           if (this.prescriptions[i].name == val.name) {
371
+
371 372
             this.curPrescriptions = {}
372 373
             var temp = this.deepClone(this.prescriptions[i])
373 374
             this.curPrescriptions = temp
@@ -450,7 +451,7 @@
450 451
 
451 452
         } else if (index == 2) {
452 453
            
453
-           this.$router.push("/outpatientDoctorStation/printtwo?record="+this.record_date)
454
+           this.$router.push("/outpatientDoctorStation/printtwo?record="+this.record_date+"&patient_id="+this.patient_id+"&prescription_id="+this.prescription_id)
454 455
         
455 456
         } else if(index == 3){
456 457
             this.$router.push("/outpatientCharges/treatPrint?record_date="+this.record_date+"&patient_id="+this.patient_id+"&prescription_id="+this.prescription_id)
@@ -548,7 +549,6 @@
548 549
           } else {
549 550
             this.patientTableData = []
550 551
             for (let i = 0; i < response.data.data.list.length; i++) {
551
-               console.log("99999999",response.data.data.list)
552 552
               if (response.data.data.list[i].prescription != null && response.data.data.list[i].prescription.length > 0) {
553 553
                 this.patientTableData.push(response.data.data.list[i])
554 554
               }
@@ -582,6 +582,9 @@
582 582
             this.hisPatientInfo = response.data.data.his_info
583 583
             this.info = response.data.data.info
584 584
             this.prescriptions = []
585
+            console.log("9991323242r5253535",response.data.data.prescription)
586
+            this.prescription_id = response.data.data.prescription[0].advices[0].prescription_id
587
+            console.log("222222",this.prescription_id)
585 588
             for (let i = 0; i < response.data.data.prescription.length; i++) {
586 589
               var prescription = response.data.data.prescription[i]
587 590
 

+ 28 - 21
src/xt_pages/outpatientDoctorStation/printtwo.vue Visa fil

@@ -32,7 +32,7 @@
32 32
             </div>
33 33
             
34 34
             <div class='dialysisPage' style="flex: 1;height: calc(100vh - 178px);overflow-x:auto;::-webkit-scrollbar:height:15px">
35
-              <printTwo v-bind:childResponse="childResponse" :advicePrint="advicePrint" :patient="patient" :hisPatient="hisPatient"></printTwo>
35
+              <printTwo v-bind:childResponse="childResponse" :advicePrint="advicePrint" :patient="patient" :hisPatient="hisPatient" :doctorPorject="doctorPorject" :patient_id="patient_id" :record_date="record_date" :prescription_id="prescription_id"></printTwo>
36 36
             </div>
37 37
         </el-container>
38 38
     </div>
@@ -63,7 +63,9 @@ export default {
63 63
        patientTableData:[],
64 64
        advicePrint:[],
65 65
        hisPatient:{},
66
-       patient:{}
66
+       patient:{},
67
+       patient_id:0,
68
+       prescription_id:0,
67 69
     };
68 70
   },
69 71
   methods:{
@@ -129,25 +131,28 @@ export default {
129 131
 
130 132
     changePatient(row){
131 133
       console.log("row",row)
132
-        var params = {
133
-          patient_id:row.patient_id,
134
-          record_date:this.record_date,
135
-        }
136
-      getPrescriptionPrint(params).then(response=>{
137
-          if(response.data.state == 1){
138
-            var advicePrint =  response.data.data.advicePrint
139
-            console.log("adviceprint",advicePrint)
140
-            this.advicePrint = advicePrint
141
-            // var hisPatient =  response.data.data.hisPatient
142
-            // console.log("hispatient",hisPatient)
143
-            // this.hisPatient = hisPatient
144
-            var patient =  response.data.data.patient
145
-            console.log("patient",patient)
146
-            this.patient = patient
147
-            var doctorPorject = response.data.data.doctorPorject
148
-            console.log("doctorporject",doctorPorject)
149
-          }
150
-      })
134
+      this.patient_id = row.patient_id
135
+      this.record_date = this.record_date
136
+      this.prescription_id = this.prescription_id
137
+      //   var params = {
138
+      //     patient_id:row.patient_id,
139
+      //     record_date:this.record_date,
140
+      //   }
141
+      // getPrescriptionPrint(params).then(response=>{
142
+      //     if(response.data.state == 1){
143
+      //       var advicePrint =  response.data.data.advicePrint
144
+      //       console.log("adviceprint",advicePrint)
145
+      //       this.advicePrint = advicePrint
146
+      //       // var hisPatient =  response.data.data.hisPatient
147
+      //       // console.log("hispatient",hisPatient)
148
+      //       // this.hisPatient = hisPatient
149
+      //       var patient =  response.data.data.patient
150
+      //       console.log("patient",patient)
151
+      //       this.patient = patient
152
+      //       var doctorPorject = response.data.data.doctorPorject
153
+      //       console.log("doctorporject",doctorPorject)
154
+      //     }
155
+      // })
151 156
     }
152 157
     
153 158
   },
@@ -157,6 +162,8 @@ export default {
157 162
     var record_date = this.$route.query.record
158 163
     this.record_date = record_date
159 164
     console.log("record_date",record_date)
165
+    this.patient_id = this.$route.query.patient_id
166
+    this.prescription_id = this.$route.query.prescription_id
160 167
     this.getAllHisPatientList(record_date)
161 168
   },
162 169
 

+ 91 - 17
src/xt_pages/outpatientDoctorStation/template/printTwo.vue Visa fil

@@ -10,9 +10,9 @@
10 10
             <p>年龄:{{patient.age}}岁</p>
11 11
         </div>
12 12
         <div class="infoMain">
13
-            <p style="margin-bottom: 10px;">门诊号:</p>
14
-            <p style="margin-bottom: 10px;">科室:</p>
15
-            <p style="margin-bottom: 10px;">医保卡号:</p>
13
+            <p style="margin-bottom: 10px;">门诊号:{{this.hisPatient.number?this.hisPatient.number:""}}</p>
14
+            <p style="margin-bottom: 10px;">科室:{{getDepart(this.hisPatient.departments?this.hisPatient.departments:"")}}</p>
15
+            <p style="margin-bottom: 10px;">医保卡号:{{this.hisPatient.number?this.hisPatient.number:""}}</p>
16 16
             <p style="margin-bottom: 10px;">电话:{{patient.phone}}</p>
17 17
             <p>地址:{{patient.home_address}}</p>
18 18
             <p>临床诊断:{{patient.diagnose}}</p>
@@ -20,35 +20,42 @@
20 20
         <div class="prescriptionBox">
21 21
             <p class="Rp">Rp:</p>
22 22
             <div class="drugsBox" v-for="(item,index) in advicePrint" :key="index">
23
-                <p class="drugsOne">{{item.advice_name}}&nbsp;&nbsp;{{item.single_dose}}{{item.single_dose_unit}}&nbsp;×&nbsp; {{item.prescribing_number}}{{item.prescribing_number_unit}}</p>
23
+                <p class="drugsOne">{{item.advice_name?item.advice_name:""}}&nbsp;&nbsp;{{item.single_dose}}{{item.single_dose_unit}}&nbsp;×&nbsp; {{item.prescribing_number}}{{item.prescribing_number_unit}}</p>
24 24
                 <p style="margin-left:100px;"><span>用法:{{item.single_dose}}{{item.single_dose_unit}}</span>&nbsp;&nbsp;<span>{{item.execution_frequency}}</span>&nbsp;&nbsp;<span>{{item.advice_desc}}</span></p>
25 25
             </div>
26 26
         </div>
27 27
         <div class="doctorBox">
28
-            <p>医师:{{getDoctor(advicePrint[0].advice_doctor)}}</p>
29
-            <p>日期:{{getTime(advicePrint[0].advice_date)}}</p>
28
+            <p>医师:{{getDoctor(advicePrint[0].advice_doctor)?getDoctor(advicePrint[0].advice_doctor):""}}</p>
29
+            <p>日期:{{getTime(advicePrint[0].advice_date)?getTime(advicePrint[0].advice_date):""}}</p>
30 30
         </div>
31 31
         <div class="actionBar">
32
-            <p>审核:{{getDoctor(advicePrint[0].advice_doctor)}}</p>
33
-            <p>配对:{{getDoctor(advicePrint[0].advice_doctor)}}</p>
34
-            <p>核对:{{getDoctor(advicePrint[0].checker)}}</p>
35
-            <p>发药:{{getDoctor(advicePrint[0].execution_staff)}}</p>
36
-            <p>药费:{{advicePrint[0].price}}</p>
32
+            <p>审核:{{getDoctor(advicePrint[0].advice_doctor)?getDoctor(advicePrint[0].advice_doctor):""}}</p>
33
+            <p>配对:{{getDoctor(advicePrint[0].advice_doctor)?getDoctor(advicePrint[0].advice_doctor):""}}</p>
34
+            <p>核对:{{getDoctor(advicePrint[0].checker)?getDoctor(advicePrint[0].checker):""}}</p>
35
+            <p>发药:{{getDoctor(advicePrint[0].execution_staff)?getDoctor(advicePrint[0].execution_staff):""}}</p>
36
+            <p>药费:{{advicePrint[0].price?advicePrint[0].price:""}}</p>
37 37
         </div>
38 38
     </div>
39 39
 </template>
40 40
 <script>
41 41
 import { jsGetAge, uParseTime } from '@/utils/tools'
42
-  import {getAllDoctorList} from "@/api/project/project"
42
+import {getAllDoctorList,getPrescriptionPrint,getHisPatientDetail} from "@/api/project/project"
43
+import {getInitData} from "@/api/his/his"
43 44
 export default {
44 45
     props:{
45
-      patient:Object,
46
-      advicePrint:Array,
47
-      hisPatient:Object,
46
+      patient_id:Number,
47
+      record_date:String,
48
+      prescription_id:Number
48 49
     }, 
49 50
     data(){
50
-      return{
51
-        doctorList:[]
51
+      return {
52
+        doctorList:[],
53
+        advicePrint:{},
54
+        patient:{},
55
+        tableData:[],
56
+        prescriptionInfo:[],
57
+        hisPatient:{},
58
+        department:[]
52 59
       }
53 60
     },
54 61
    methods:{
@@ -78,9 +85,76 @@ export default {
78 85
         }
79 86
         return ''
80 87
      },
88
+       getPrescriptionPrint(){
89
+         var params = {
90
+          patient_id:this.patient_id,
91
+          record_date:this.record_date,
92
+          prescription_id:this.prescription_id,
93
+        }
94
+        console.log("params---",params)
95
+       getPrescriptionPrint(params).then(response=>{
96
+         if(response.data.state == 1){
97
+            var advicePrint =  response.data.data.advicePrint
98
+            console.log("adviceprint",advicePrint)
99
+            this.advicePrint = advicePrint
100
+            var patient =  response.data.data.patient
101
+            console.log("patient",patient)
102
+            this.patient = patient
103
+            var doctorPorject = response.data.data.doctorPorject
104
+          
105
+            var arr = doctorPorject.project
106
+              console.log("我的中谷歌",arr)
107
+            for(let i=0;i<arr.length;i++){
108
+              console.log("arr",arr[i].project_name)
109
+            }
110
+            this.tableData = arr
111
+            console.log("3333",this.tableData)
112
+            var prescriptioninfo = response.data.data.prescriptionInfo
113
+            console.log("prescriptioninfo",prescriptioninfo)
114
+            this.prescriptionInfo = prescriptioninfo
115
+          }
116
+       })
117
+     },
118
+     getHisPatientDetail(){
119
+          const params = {
120
+              patient_id:this.patient_id
121
+          }
122
+       getHisPatientDetail(params).then(response=>{
123
+          if(response.data.state == 1){
124
+             var hisPatient =  response.data.data.hisPatient
125
+             console.log("挂号病人",hisPatient)
126
+             this.hisPatient = hisPatient
127
+          }
128
+       })
129
+     },
130
+     getInitData(){
131
+       getInitData().then(response=>{
132
+          if(response.data.state == 1){
133
+            this.department = response.data.data.department
134
+           
135
+          }
136
+       })
137
+     },
138
+     getDepart(id){
139
+         var name = ""
140
+       for(let i=0;i<this.department.length;i++){
141
+           if(id == this.department[i].id){
142
+               name = this.department[i].name
143
+           }
144
+       }
145
+       return name
146
+     }
81 147
    },
82 148
    created(){
83 149
       this.getAllDoctorList()
150
+      this.getInitData()
151
+   },
152
+   watch:{
153
+     patient_id:function(val){
154
+       console.log("999999888888",this.patient_id,this.record_date,this.prescription_id)
155
+       this.getPrescriptionPrint()
156
+       this.getHisPatientDetail()
157
+     }
84 158
    }
85 159
 }
86 160
 </script>