see999 пре 3 година
родитељ
комит
4fe5164757
24 измењених фајлова са 2578 додато и 125 уклоњено
  1. 8 0
      src/api/project/project.js
  2. 10 2
      src/xt_pages/data/components/addDrugs.vue
  3. 9 1
      src/xt_pages/data/components/addProject.vue
  4. 27 0
      src/xt_pages/dialysis/dialysisPrintOrder.vue
  5. 1379 0
      src/xt_pages/dialysis/template/DialysisPrintOrderThirtyEight.vue
  6. 4 4
      src/xt_pages/dialysis/template/DialysisPrintOrderThirtySeven.vue
  7. 1 1
      src/xt_pages/outpatientCharges/costComparison.vue
  8. 152 0
      src/xt_pages/outpatientCharges/invoicePrint.vue
  9. 172 0
      src/xt_pages/outpatientCharges/invoiceTemplate/printOne.vue
  10. 1 1
      src/xt_pages/outpatientCharges/newStatementPrint.vue
  11. 9 9
      src/xt_pages/outpatientCharges/outpatientChargesManagement.vue
  12. 8 3
      src/xt_pages/outpatientCharges/statementPrint.vue
  13. 129 0
      src/xt_pages/outpatientCharges/statementTemplate/printTwo.vue
  14. 3 25
      src/xt_pages/outpatientDoctorStation/components/deskPrescription.vue
  15. 26 17
      src/xt_pages/outpatientDoctorStation/components/deskRecord.vue
  16. 19 0
      src/xt_pages/outpatientDoctorStation/components/prescriptionTable.vue
  17. 521 2
      src/xt_pages/outpatientDoctorStation/doctorDesk.vue
  18. 2 2
      src/xt_pages/outpatientRegistration/index.vue
  19. 56 51
      src/xt_pages/qcd/basicInformationAnalysis.vue
  20. 14 1
      src/xt_pages/stock/Dialog/goodInfoDailog.vue
  21. 1 1
      src/xt_pages/upload/fast/One.vue
  22. 1 1
      src/xt_pages/user/components/PatientForm.vue
  23. 18 2
      src/xt_pages/user/components/PatientSidebar.vue
  24. 8 2
      src/xt_pages/user/editPatient.vue

+ 8 - 0
src/api/project/project.js Прегледај датотеку

@@ -533,4 +533,12 @@ export function postProjectInformation(params){
533 533
     method:"post",
534 534
     data:params
535 535
   })
536
+}
537
+
538
+export function getInvoice(params){
539
+  return request({
540
+    url:"/api/fapiao/get",
541
+    method:"get",
542
+    data:params
543
+  })
536 544
 }

+ 10 - 2
src/xt_pages/data/components/addDrugs.vue Прегледај датотеку

@@ -589,7 +589,7 @@
589 589
         this.$refs[formName].validate((valid) => {
590 590
           console.log(valid)
591 591
           if (valid) {
592
-            console.log(this.getValue())
592
+            console.log(1111,this.getValue())
593 593
             this.$emit('dialog-comfirm', this.getValue())
594 594
           }
595 595
         })
@@ -603,7 +603,15 @@
603 603
       },
604 604
       _close: function(done) {
605 605
         // this.clear()
606
-        done()
606
+        // done()
607
+        this.$confirm('是否保存')
608
+          .then(_ => {
609
+            this.comfirm('form')
610
+            // done();
611
+          })
612
+          .catch(_ => {
613
+            done()
614
+          });
607 615
       },
608 616
       clear: function() {
609 617
         this.form.id = 0

+ 9 - 1
src/xt_pages/data/components/addProject.vue Прегледај датотеку

@@ -315,7 +315,15 @@ export default {
315 315
     methods:{
316 316
         _close: function(done) {
317 317
             // this.clear()
318
-            done()
318
+            // done()
319
+            this.$confirm('是否保存')
320
+            .then(_ => {
321
+                this.submitAction('form')
322
+                // done();
323
+            })
324
+            .catch(_ => {
325
+                done()
326
+            });
319 327
         },
320 328
         clear: function() {
321 329
             this.form.id = 0;

+ 27 - 0
src/xt_pages/dialysis/dialysisPrintOrder.vue Прегледај датотеку

@@ -533,6 +533,16 @@
533 533
           >打印</el-button
534 534
         >
535 535
       </template>
536
+      <template v-if="org_template_info.template_id == 38">
537
+        <el-button
538
+          :loading="loading"
539
+          size="small"
540
+          icon="el-icon-printer"
541
+          @click="printThisPage"
542
+          type="primary"
543
+          >打印</el-button
544
+        >
545
+      </template>
536 546
     </div>
537 547
     <div class="app-container" style="min-height:0;">
538 548
       <!--<div class="order-print-btn"-->
@@ -798,6 +808,11 @@
798 808
             v-if="org_template_info.template_id == 37"
799 809
           >
800 810
           </DialysisPrintOrderThirtySeven>
811
+          <DialysisPrintOrderThirtyEight
812
+            v-bind:childResponse="childResponse"
813
+            v-if="org_template_info.template_id == 38"
814
+          >
815
+          </DialysisPrintOrderThirtyEight>
801 816
         </div>
802 817
       </el-container>
803 818
     </div>
@@ -854,9 +869,11 @@ import DialysisPrintOrderThirtyFour from "./template/DialysisPrintOrderThirtyFou
854 869
 import DialysisPrintOrderThirtyFive from "./template/DialysisPrintOrderThirtyFive";
855 870
 import DialysisPrintOrderThirtySix from "./template/DialysisPrintOrderThirtySix";
856 871
 import DialysisPrintOrderThirtySeven from "./template/DialysisPrintOrderThirtySeven";
872
+import DialysisPrintOrderThirtyEight from "./template/DialysisPrintOrderThirtyEight";
857 873
 export default {
858 874
   name: "dialysisPrintOrder",
859 875
   components: {
876
+    DialysisPrintOrderThirtyEight,
860 877
     DialysisPrintOrderThirtySeven,
861 878
     DialysisPrintOrderThirtySix,
862 879
     DialysisPrintOrderThirtyFive,
@@ -1069,6 +1086,9 @@ export default {
1069 1086
         '@media print {.dialysis-print-order{width:960px;margin:0 auto}.dialysis-print-order .order-yy-name{margin:auto;text-align:center;font-size:20px;letter-spacing:5px}.dialysis-print-order .order-title{margin:auto;font-weight:600;text-align:center;font-size:22px;padding:10px 20px 20px 20px}.dialysis-print-order .table-box{width:100%;line-height:23px;font-size:16px}.dialysis-print-order .print-table{width:100%;text-align:center;border-collapse:collapse;line-height:25px;font-size:16px}.dialysis-print-order .print-table-no{width:100%;text-align:center;border-collapse:collapse;font-size:16px}.dialysis-print-order .under-line{border-bottom:1px solid #999;width:95%;text-align:center;margin-left:2px}.dialysis-print-order .title-box{text-align:center;font-size:16px;border:1px solid #666}.dialysis-print-order .radio-lebel-box{font-weight:400;cursor:pointer}.dialysis-print-order .radio-no{opacity:0;outline:0;position:absolute;margin:0;width:0;height:0;z-index:-1}.dialysis-print-order .radio-inner{white-space:nowrap;cursor:pointer;outline:0;display:inline-block;line-height:1;position:relative;vertical-align:middle}.dialysis-print-order .radio-fang{display:inline-block;position:relative;border:1px solid #000;box-sizing:border-box;width:14px;height:14px;background-color:#fff;z-index:1;transition:border-color .25s cubic-bezier(.71,-.46,.29,1.46),background-color .25s cubic-bezier(.71,-.46,.29,1.46)}.dialysis-print-order .is-checked-radio::after{content:"√";font-size:15px}}.dialysis-print-order .print-table-no tr td { padding: 8px 5px; line-height: 25px; }.es-img{height: 20px; }.advice-name{text-align: left;}.advice-children{display:flex;} .dialysis-print-order .print-table tr td{padding: 0px 0px;} .print-template-two tr {line-height: 30px;}   .title-box-pro{border: 0 #fff;line-height: 40px;height: 40px;text-align: left;padding-left: 10px !important;}  .text-align-left{text-align: left !important;padding-left:10px !important;font-size: 14px !important;line-height: 25px;}';
1070 1087
       const style7 =
1071 1088
         '@media print {.dialysis-print-order {width: 960px; margin: 0 auto;}.dialysis-print-order .order-yy-name {margin: auto;text-align: center;font-size: 20px;letter-spacing: 5px;}.dialysis-print-order .order-title {  margin: auto;  font-weight: 600;  text-align: center;  font-size: 22px;  padding: 10px 20px 0px 20px;}.dialysis-print-order .table-box {  width: 100%;  line-height: 18px;  font-size: 18px;}.dialysis-print-order .print-table {  width: 100%;  text-align: center;  border-collapse: collapse;  line-height: 28px;  font-size: 18px;}.dialysis-print-order .print-table-no {  width: 100%;  text-align: center;  border-collapse: collapse;  font-size: 14px;}.dialysis-print-order .under-line {  border-bottom: 1px solid #999;  width: 95%;  text-align: center;  margin-left: 2px;}.dialysis-print-order .title-box {  text-align: center;  font-size: 16px;}.dialysis-print-order .radio-lebel-box {  font-weight: 400;  cursor: pointer;}.dialysis-print-order .radio-no {  opacity: 0;  outline: none;  position: absolute;  margin: 0;  width: 0;  height: 0;  z-index: -1;}.dialysis-print-order .radio-inner {  white-space: nowrap;  cursor: pointer;  outline: none;  display: inline-block;  line-height: 1;  position: relative;  vertical-align: middle;}.dialysis-print-order .radio-fang {  display: inline-block;  position: relative;  border: 1px solid #000;  box-sizing: border-box;  width: 18px;  height: 18px;  background-color: #fff;  z-index: 1;  transition: border-color 0.25s cubic-bezier(0.71, -0.46, 0.29, 1.46),    background-color 0.25s cubic-bezier(0.71, -0.46, 0.29, 1.46);}.dialysis-print-order .is-checked-radio::after {  content: "√";  font-size: 19px;}.dialysis-print-order .print-table-no tr td {  padding: 8px 5px;  line-height: 25px;}.dialysis-print-order .print-table tr td {  padding: 1px 1px;  /*line-height: 25px;*/}.es-img {  height: 25px;}.advice-name {  text-align: left;}.advice-children {  display: flex;}.title-box-pro {  border: 0 #fff;  line-height: 25px;  height: 25px;  text-align: left;  padding-left: 10px !important;}.title-box-pro-tr {  border: 0 #fff;}.text-align-left {  text-align: left !important;  padding-left: 10px !important;  font-size: 14px !important;  line-height: 25px;}.print-table-tr-new td {line-height: 20px !important;}.border-top-solid {border: solid 1px #000;}.print-template-two tr {line-height: 30px;}}';
1089
+      const style8 =
1090
+        '@media print {.dialysis-print-order{width:960px;margin:0 auto;font-size:10px;}.dialysis-print-order .order-yy-name{margin:auto;text-align:center;font-size:20px;letter-spacing:5px}.dialysis-print-order .order-title{margin:auto;font-weight:600;text-align:center;font-size:22px;padding:10px 20px 20px 20px}.dialysis-print-order .table-box{width:100%;line-height:23px;font-size:10px}.dialysis-print-order .print-table{width:100%;text-align:center;border-collapse:collapse;line-height:25px;font-size:14px}.dialysis-print-order .print-table-no{width:100%;text-align:center;border-collapse:collapse;font-size:14px}.dialysis-print-order .under-line{border-bottom:1px solid #999;width:95%;text-align:center;margin-left:2px}.dialysis-print-order .title-box{text-align:center;font-size:16px;border:1px solid #666}.dialysis-print-order .radio-lebel-box{font-weight:400;cursor:pointer}.dialysis-print-order .radio-no{opacity:0;outline:0;position:absolute;margin:0;width:0;height:0;z-index:-1}.dialysis-print-order .radio-inner{white-space:nowrap;cursor:pointer;outline:0;display:inline-block;line-height:1;position:relative;vertical-align:middle}.dialysis-print-order .radio-fang{display:inline-block;position:relative;border:1px solid #000;box-sizing:border-box;width:14px;height:14px;background-color:#fff;z-index:1;transition:border-color .25s cubic-bezier(.71,-.46,.29,1.46),background-color .25s cubic-bezier(.71,-.46,.29,1.46)}.dialysis-print-order .is-checked-radio::after{content:"√";font-size:15px}}.dialysis-print-order .print-table-no tr td { padding: 8px 5px; line-height: 25px; }.es-img{height: 20px; }.advice-name{text-align: left;}.advice-children{display:flex;} .dialysis-print-order .print-table tr td{padding: 0px 0px;} .print-template-two tr {line-height: 30px;}   .title-box-pro{border: 0 #fff;line-height: 40px;height: 40px;text-align: left;padding-left: 10px !important;}  .text-align-left{text-align: left !important;padding-left:10px !important;font-size: 14px !important;line-height: 25px;}.widthLength25{width: 25%;}.lineHeight{line-height: 20px;display: flex;justify-content: space-between;}';
1091
+
1072 1092
 
1073 1093
       if (this.org_template_info.template_id == 1) {
1074 1094
         printJS({
@@ -1315,6 +1335,13 @@ export default {
1315 1335
           style: style,
1316 1336
           scanStyles: false
1317 1337
         });
1338
+      } else if (this.org_template_info.template_id == 38) {
1339
+        printJS({
1340
+          printable: "dialysis-print-box",
1341
+          type: "html",
1342
+          style: style8,
1343
+          scanStyles: false
1344
+        });
1318 1345
       }
1319 1346
     },
1320 1347
     printThisOnePage() {

Разлика између датотеке није приказан због своје велике величине
+ 1379 - 0
src/xt_pages/dialysis/template/DialysisPrintOrderThirtyEight.vue


+ 4 - 4
src/xt_pages/dialysis/template/DialysisPrintOrderThirtySeven.vue Прегледај датотеку

@@ -187,8 +187,8 @@
187 187
                     <span style="display:inline-block;width:30%">
188 188
                         医生签名:
189 189
                         <span>
190
-                            <span v-if="setAdminUserES(prescription==null?0:(prescription.prescription_doctor?prescription.prescription_doctor:'')) == ''"> {{ getAdminUser(prescription==null?0:(prescription.prescription_doctor?prescription.prescription_doctor:'')) }} </span>
191
-                            <img style="height:30px;" :src="setAdminUserES(prescription==null?0:(prescription.prescription_doctor?prescription.prescription_doctor:''))" alt="" srcset="" v-else />
190
+                            <span v-if="setAdminUserES(tableAdvice[0].advice_doctor) == ''">{{ getAdminUser(tableAdvice[0].advice_doctor) }}</span>
191
+                            <img class="es-img" style="height:30px;" :src="setAdminUserES(tableAdvice[0].advice_doctor)" alt="" srcset="" v-else />
192 192
                         </span>
193 193
                     </span>
194 194
                 </span>
@@ -415,8 +415,8 @@
415 415
             <div style="text-align:right;">
416 416
                 医生签名:
417 417
                 <span style="display:inline-block;width:100px;text-align:left;">
418
-                    <span v-if="setAdminUserES(prescription==null?0:(prescription.prescription_doctor?prescription.prescription_doctor:'')) == ''"> {{ getAdminUser(prescription==null?0:(prescription.prescription_doctor?prescription.prescription_doctor:'')) }} </span>
419
-                    <img style="height:30px;" :src="setAdminUserES(prescription==null?0:(prescription.prescription_doctor?prescription.prescription_doctor:''))" alt="" srcset="" v-else />
418
+                    <span v-if="setAdminUserES(tableAdvice[0].advice_doctor) == ''">{{ getAdminUser(tableAdvice[0].advice_doctor) }}</span>
419
+                    <img class="es-img" style="height:30px;" :src="setAdminUserES(tableAdvice[0].advice_doctor)" alt="" srcset="" v-else />
420 420
                 </span>
421 421
                 护士签名:
422 422
                 <span style="display:inline-block;width:100px;text-align:left;">

+ 1 - 1
src/xt_pages/outpatientCharges/costComparison.vue Прегледај датотеку

@@ -435,7 +435,7 @@
435 435
             clr_type: '11'
436 436
           }
437 437
           var that = this
438
-          if (this.$store.getters.xt_user.org_id == 4 || this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 10106) {
438
+          if (this.$store.getters.xt_user.org_id == 4 || this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 10106 || this.$store.getters.xt_user.org_id == 9990 ) {
439 439
             axios.get('http://127.0.0.1:9532/api/checkaccount/get', {
440 440
               params: params
441 441
             })

+ 152 - 0
src/xt_pages/outpatientCharges/invoicePrint.vue Прегледај датотеку

@@ -0,0 +1,152 @@
1
+<template>
2
+  <div>
3
+    <template>
4
+      <el-button
5
+        style="position:fixed;right:25px;z-index:999"
6
+        :loading="loading"
7
+        size="small"
8
+        icon="el-icon-printer"
9
+        @click="printThisPage"
10
+        type="primary"
11
+        >打印</el-button
12
+      >
13
+    </template>
14
+    <div class="app-container" style="padding-top:40px;">
15
+        <div class='dialysisPage'>
16
+            <printOne :paramsObj="invoiceParams"></printOne>
17
+        </div>
18
+    </div>
19
+  </div>
20
+</template>
21
+
22
+<script>
23
+import printOne from './invoiceTemplate/printOne'
24
+export default {
25
+  name: "invoicePrint",
26
+  components: {
27
+    printOne
28
+  },
29
+  props:{
30
+    invoiceParams:Object
31
+  },
32
+  data() {
33
+    return {
34
+      childResponse: {},
35
+    //   invoiceParams:{}
36
+      
37
+
38
+    };
39
+  },
40
+  methods: {
41
+    getAdminUser(id) {
42
+      if (id == 0) {
43
+        return "";
44
+      }
45
+      if (id == undefined) {
46
+        return "";
47
+      }
48
+      for (let i = 0; i < this.adminUser.length; i++) {
49
+        if (this.adminUser[i].id == id) {
50
+          return this.adminUser[i].name;
51
+        }
52
+      }
53
+    },
54
+    getTime(value, temp) {
55
+      if (value == 0) {
56
+        return "";
57
+      }
58
+      if (value != undefined) {
59
+        return uParseTime(value, temp);
60
+      }
61
+      return "";
62
+    },
63
+    printThisPage() {
64
+
65
+      const style =
66
+        '@media print {.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
+        printJS({
68
+            printable: "invoice-print",
69
+            type: "html",
70
+            style: style,
71
+            scanStyles: false
72
+        });
73
+
74
+      // if (this.org_template_info.template_id == 1) {
75
+      //   printJS({
76
+      //     printable: "dialysis-print-box",
77
+      //     type: "html",
78
+      //     style: style,
79
+      //     scanStyles: false
80
+      //   });
81
+      // }
82
+    },
83
+  },
84
+  created() {
85
+      console.log('this.invoiceParams',this.invoiceParams)
86
+  },
87
+  watch:{
88
+    paramsObj:{//深度监听,可监听到对象、数组的变化
89
+      handler(val, oldVal){
90
+        this.invoiceParams = val
91
+        
92
+      },
93
+      deep:true
94
+    }
95
+  }
96
+};
97
+</script>
98
+
99
+<style lang="scss" scoped>
100
+.printTitle{
101
+    font-size: 22px;
102
+    text-align: center;
103
+    font-weight: bold;
104
+}
105
+.infoMain{
106
+    display: flex;
107
+    flex-wrap: wrap;
108
+    border-bottom: 2px solid #000;
109
+    padding:0 10px;
110
+}
111
+.infoMain .infoP{
112
+    width: 33%;
113
+    line-height: 24px;
114
+}
115
+.prescriptionBox{
116
+    padding:0 10px;
117
+    height:600px;
118
+}
119
+.Rp{
120
+    font-size: 22px;
121
+    font-weight: bold;
122
+}
123
+.drugsBox{
124
+    padding-left: 40px;
125
+    margin-bottom: 10px;
126
+}
127
+.drugsBox p{
128
+    line-height: 30px;
129
+}
130
+.drugsOne{
131
+    line-height: 24px;
132
+}
133
+.drugsOne span{
134
+    margin-right: 20px;
135
+}
136
+.doctorBox{
137
+    display: flex;
138
+    justify-content: space-between;
139
+    padding:0 10px;
140
+    line-height: 24px;
141
+    border-bottom: 2px solid #000;
142
+}
143
+.actionBar{
144
+    display: flex;
145
+    justify-content: space-between; 
146
+    line-height: 24px;
147
+    padding:0 10px;
148
+}
149
+.actionBar p{
150
+    width:150px;
151
+}
152
+</style>

+ 172 - 0
src/xt_pages/outpatientCharges/invoiceTemplate/printOne.vue Прегледај датотеку

@@ -0,0 +1,172 @@
1
+<template>
2
+    <div id='invoice-print'>
3
+        <div style="display:flex;">
4
+            <div>业务流水号:{{ 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>门诊号:{{ list.number }}</div>
10
+            <div>医院类型:</div>
11
+            <div>
12
+                <span>{{ printDate.slice(0,4) }}</span>年
13
+                <span>{{ printDate.slice(5,7) }}</span>月
14
+                <span>{{ printDate.slice(8,11) }}</span>日
15
+            </div>
16
+        </div>
17
+        <div style="display:flex;justify-content: space-between;">
18
+            <div>姓名: {{ paramsObj.name }}</div>
19
+            <div>{{ list.pay_way }}</div>
20
+            <div>住院日期: {{ paramsObj.setl_time.split(' ')[0] }}</div>
21
+            <div>出院日期: {{ paramsObj.setl_time.split(' ')[0] }}</div>
22
+        </div>
23
+        <div style="display:flex;justify-content: space-between;">
24
+            <div>性别: {{ paramsObj.gend == 1 ? '男' : '女' }}</div>
25
+            <div>医保/公医记账:{{ totalPrice - list.psn_cash_money }}</div>
26
+            <div>个人缴费: {{ list.psn_cash_money }}</div>
27
+            <div>结算方式: {{ list.pay_way }}</div>
28
+        </div>
29
+        <div style="display:flex;justify-content: space-between;">
30
+            <div style="width:12.5%">西药</div>
31
+            <div style="width:12.5%">{{ list.westernMedicineCostTotal }}</div>
32
+            <div style="width:12.5%">检查费</div>
33
+            <div style="width:12.5%">{{ list.checkCostTotal }}</div>
34
+            <div style="width:12.5%">治疗费</div>
35
+            <div style="width:12.5%">{{ list.treatCostTotal }}</div>
36
+            <div style="width:12.5%">床位费</div>
37
+            <div style="width:12.5%">{{ list.bedCostTotal }}</div>
38
+        </div>
39
+        <div style="display:flex;justify-content: space-between;">
40
+            <div style="width:12.5%">中成药</div>
41
+            <div style="width:12.5%">{{ list.chineseTraditionalMedicineCostTotal }}</div>
42
+            <div style="width:12.5%">化验费</div>
43
+            <div style="width:12.5%">{{ list.laboratoryCostTotal }}</div>
44
+            <div style="width:12.5%">手术费</div>
45
+            <div style="width:12.5%">{{ list.operationCostTotal }}</div>
46
+            <div style="width:12.5%">其他费</div>
47
+            <div style="width:12.5%">{{ list.otherCostTotal }}</div>
48
+        </div>
49
+        <div style="display:flex;justify-content: space-between;">
50
+            <div style="width:12.5%"></div>
51
+            <div style="width:12.5%"></div>
52
+            <div style="width:12.5%"></div>
53
+            <div style="width:12.5%"></div>
54
+            <div style="width:12.5%">材料费</div>
55
+            <div style="width:12.5%">{{ list.materialCostTotal }}</div>
56
+            <div style="width:12.5%"></div>
57
+            <div style="width:12.5%"></div>
58
+        </div>
59
+        <div>
60
+            <span>
61
+                <span v-if="zhongwen.indexOf('万') > -1">
62
+                    {{ zhongwen.substring(zhongwen.indexOf('万'),-1) }}
63
+                </span>
64
+                <span v-else>零</span>
65
+            </span>
66
+            <span>
67
+                <span v-if="zhongwen.indexOf('仟') > -1">
68
+                    {{ zhongwen.substring(zhongwen.indexOf('仟'),-1) }}
69
+                </span>
70
+                <span v-else>零</span>
71
+            </span>
72
+            <span>
73
+                <span v-if="zhongwen.indexOf('佰') > -1">
74
+                    {{ zhongwen.substring(zhongwen.indexOf('佰') - 1,zhongwen.indexOf('佰')) }}
75
+                </span>
76
+                <span v-else>零</span>
77
+            </span>
78
+            <span>
79
+                <span v-if="zhongwen.indexOf('拾') > -1">
80
+                    {{ zhongwen.substring(zhongwen.indexOf('拾') - 1,zhongwen.indexOf('拾')) }}
81
+                </span>
82
+                <span v-else>零</span>
83
+            </span>
84
+            <span>
85
+                <span v-if="zhongwen.indexOf('元') > -1">
86
+                    {{ zhongwen.substring(zhongwen.indexOf('元') - 1,zhongwen.indexOf('元')) }}
87
+                </span>
88
+                <span v-else>零</span>
89
+            </span>
90
+            <span>
91
+                <span v-if="zhongwen.indexOf('角') > -1">
92
+                    {{ zhongwen.substring(zhongwen.indexOf('角') - 1,zhongwen.indexOf('角')) }}
93
+                </span>
94
+                <span v-else>零</span>
95
+            </span>
96
+            <span>
97
+                <span v-if="zhongwen.indexOf('分') > -1">
98
+                    {{ zhongwen.substring(zhongwen.indexOf('分') - 1,zhongwen.indexOf('分')) }}
99
+                </span>
100
+                <span v-else>零</span>
101
+            </span>
102
+            <span>{{ totalPrice }}</span>
103
+        </div>
104
+    </div>
105
+</template>
106
+
107
+
108
+<script>
109
+import { getInvoice } from '@/api/project/project'
110
+export default {
111
+    props:{
112
+        paramsObj:Object
113
+    },
114
+    data(){
115
+        return{
116
+            list:{},
117
+            printDate:'',
118
+            zhongwen:'',
119
+            totalPrice:0.0
120
+        }
121
+    },
122
+    created(){
123
+        console.log('paramsObj',this.paramsObj)
124
+        let params = {
125
+            order_id: this.paramsObj.order_id,
126
+            patient_id: this.paramsObj.patient_id,
127
+        }
128
+        this.getInvoice(params)
129
+        var data = new Date();
130
+        var month =data.getMonth() < 9 ? "0" + (data.getMonth() + 1) : data.getMonth() + 1;
131
+        var date = data.getDate() <= 9 ? "0" + data.getDate() : data.getDate();
132
+        this.printDate = data.getFullYear() + "-" + month + "-" + date;
133
+        
134
+    },
135
+    methods:{
136
+        getInvoice(params){
137
+            getInvoice(params).then((res) => {
138
+                console.log('res',res)
139
+                this.list = res.data.data
140
+                this.totalPrice = this.list.westernMedicineCostTotal + this.list.checkCostTotal + this.list.treatCostTotal + this.list.bedCostTotal + this.list.chineseTraditionalMedicineCostTotal +
141
+                                    this.list.laboratoryCostTotal + this.list.operationCostTotal + this.list.otherCostTotal + this.list.materialCostTotal
142
+                this.smalltoBIG(this.totalPrice)
143
+            })
144
+        },
145
+        smalltoBIG(price) {
146
+            let fraction = ['角', '分'];
147
+            let digit = ['零', '壹', '贰', '叁', '肆', '伍', '陆', '柒', '捌', '玖'];
148
+            let unit = [['元.', '万,', '亿,'], ['元', '拾', '佰', '仟']];
149
+            let head = price < 0 ? '欠' : '';
150
+            price = Math.abs(price);
151
+            let upper = '';
152
+            for (let i = 0; i < fraction.length; i++) {
153
+            upper += (digit[Math.floor(price * 10 * Math.pow(10, i)) % 10] + fraction[i]).replace(/零./, '');
154
+            }
155
+            upper = upper || '整';
156
+            price = Math.floor(price);
157
+            for (let i = 0; i < unit[0].length && price > 0; i++) {
158
+            let p = '';
159
+            for (let j = 0; j < unit[1].length && price > 0; j++) {
160
+                p = digit[price % 10] + unit[1][j] + p;
161
+                price = Math.floor(price / 10);
162
+            }
163
+            upper = p.replace(/(零.)*零$/, '').replace(/^$/, '零') + unit[0][i] + upper;
164
+            }
165
+            this.zhongwen = head + upper.replace(/(零.)*零圆/, '圆').replace(/(零.)+/g, '零').replace(/^整$/, '零圆整')
166
+            console.log('6666',head + upper.replace(/(零.)*零圆/, '圆').replace(/(零.)+/g, '零').replace(/^整$/, '零圆整'))
167
+    
168
+        },
169
+
170
+    }
171
+}
172
+</script>

+ 1 - 1
src/xt_pages/outpatientCharges/newStatementPrint.vue Прегледај датотеку

@@ -152,7 +152,7 @@
152 152
 
153 153
       },
154 154
       getInfo(order_id) {
155
-        if (this.$store.getters.xt_user.org_id == 3877 || this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 4  || this.$store.getters.xt_user.org_id == 9538 || this.$store.getters.xt_user.org_id == 9671 ||  this.$store.getters.xt_user.org_id == 9674 || this.$store.getters.xt_user.org_id == 10106) {
155
+        if (this.$store.getters.xt_user.org_id == 3877 || this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 4  || this.$store.getters.xt_user.org_id == 9538 || this.$store.getters.xt_user.org_id == 9671 ||  this.$store.getters.xt_user.org_id == 9674 || this.$store.getters.xt_user.org_id == 10106 || this.$store.getters.xt_user.org_id == 9990 ) {
156 156
 
157 157
           var that = this
158 158
 

+ 9 - 9
src/xt_pages/outpatientCharges/outpatientChargesManagement.vue Прегледај датотеку

@@ -133,13 +133,13 @@
133 133
                         </el-button>
134 134
 
135 135
                         <el-button
136
-                                v-if="this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 4  || this.$store.getters.xt_user.org_id == 9538 || this.$store.getters.xt_user.org_id == 9671 || this.$store.getters.xt_user.org_id == 9674 || this.$store.getters.xt_user.org_id == 10106"
136
+                                v-if="this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 4  || this.$store.getters.xt_user.org_id == 9538 || this.$store.getters.xt_user.org_id == 9671 || this.$store.getters.xt_user.org_id == 9674 || this.$store.getters.xt_user.org_id == 10106 || this.$store.getters.xt_user.org_id == 9990"
137 137
                                 size="small" @click="open(10)" type="primary"
138 138
                         >退号
139 139
                         </el-button>
140 140
 
141 141
                         <el-button
142
-                        v-if="$store.getters.xt_user.org_id == 4 || this.$store.getters.xt_user.org_id == 9919  || this.$store.getters.xt_user.org_id == 9671 || this.$store.getters.xt_user.org_id == 9674   || this.$store.getters.xt_user.org_id == 10106"
142
+                        v-if="$store.getters.xt_user.org_id == 4 || this.$store.getters.xt_user.org_id == 9919  || this.$store.getters.xt_user.org_id == 9671 || this.$store.getters.xt_user.org_id == 9674   || this.$store.getters.xt_user.org_id == 10106 || this.$store.getters.xt_user.org_id == 9990"
143 143
                         size="small" @click="open(11)" type="primary"
144 144
                         >撤销明细
145 145
                         </el-button>
@@ -525,7 +525,7 @@
525 525
     },
526 526
     methods: {
527 527
       query() {
528
-        if (this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 4 || this.$store.getters.xt_user.org_id == 9538 || this.$store.getters.xt_user.org_id == 10106) {
528
+        if (this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 4 || this.$store.getters.xt_user.org_id == 9538 || this.$store.getters.xt_user.org_id == 10106 || this.$store.getters.xt_user.org_id == 9990 ) {
529 529
           var that = this
530 530
           axios.get('http://127.0.0.1:9532/api/org/info', {
531 531
             params: {}
@@ -643,7 +643,7 @@
643 643
 
644 644
             })
645 645
 
646
-        } else if (this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 4 || this.$store.getters.xt_user.org_id == 9538 || this.$store.getters.xt_user.org_id == 9671 || this.$store.getters.xt_user.org_id == 9674 || this.$store.getters.xt_user.org_id == 10106) {
646
+        } else if (this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 4 || this.$store.getters.xt_user.org_id == 9538 || this.$store.getters.xt_user.org_id == 9671 || this.$store.getters.xt_user.org_id == 9674 || this.$store.getters.xt_user.org_id == 10106 || this.$store.getters.xt_user.org_id == 9990  ) {
647 647
           var that = this
648 648
           axios.get('http://127.0.0.1:9532/api/upload/get', {
649 649
             params: form,
@@ -870,7 +870,7 @@
870 870
 
871 871
             })
872 872
 
873
-        } else if (this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 4 || this.$store.getters.xt_user.org_id == 9538 || this.$store.getters.xt_user.org_id == 9671  || this.$store.getters.xt_user.org_id == 9674 || this.$store.getters.xt_user.org_id == 10106) {
873
+        } else if (this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 4 || this.$store.getters.xt_user.org_id == 9538 || this.$store.getters.xt_user.org_id == 9671  || this.$store.getters.xt_user.org_id == 9674 || this.$store.getters.xt_user.org_id == 10106 || this.$store.getters.xt_user.org_id == 9990) {
874 874
 
875 875
           axios.get('http://127.0.0.1:9532/api/register/get', {
876 876
             params: forms,
@@ -1495,7 +1495,7 @@
1495 1495
           }
1496 1496
 
1497 1497
         } else if (index == 5) {
1498
-          if (this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 4 || this.$store.getters.xt_user.org_id == 9538 || this.$store.getters.xt_user.org_id == 9671 || this.$store.getters.xt_user.org_id == 9674 || this.$store.getters.xt_user.org_id == 10106) {
1498
+          if (this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 4 || this.$store.getters.xt_user.org_id == 9538 || this.$store.getters.xt_user.org_id == 9671 || this.$store.getters.xt_user.org_id == 9674 || this.$store.getters.xt_user.org_id == 10106 || this.$store.getters.xt_user.org_id == 9990 ) {
1499 1499
 
1500 1500
             var that = this
1501 1501
             this.$confirm('是否退费', '退费', {
@@ -1594,7 +1594,7 @@
1594 1594
 
1595 1595
           var that = this
1596 1596
 
1597
-          if (this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 10106) {
1597
+          if (this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 10106 || this.$store.getters.xt_user.org_id == 9990) {
1598 1598
             axios.get('http://127.0.0.1:9532/api/checkaccount/get', {
1599 1599
               params: params
1600 1600
             })
@@ -1745,7 +1745,7 @@
1745 1745
             })
1746 1746
         } else if (index == 15) {
1747 1747
           var that = this
1748
-          if (this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 4 || this.$store.getters.xt_user.org_id == 9538 || this.$store.getters.xt_user.org_id == 10106) {
1748
+          if (this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 4 || this.$store.getters.xt_user.org_id == 9538 || this.$store.getters.xt_user.org_id == 10106 ||   this.$store.getters.xt_user.org_id == 9990) {
1749 1749
 
1750 1750
             if (this.diagnosis.length || this.diagnosis == 0) {
1751 1751
               that.$message.error('诊断不能为空,请选择诊断内容')
@@ -1854,7 +1854,7 @@
1854 1854
 
1855 1855
           }
1856 1856
           this.loadingtwo = true
1857
-          if (this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 10106) {
1857
+          if (this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 10106 || this.$store.getters.xt_user.org_id == 9990) {
1858 1858
             var that = this
1859 1859
             axios.get('http://127.0.0.1:9532/api/pre_upload/get', {
1860 1860
               params: form

+ 8 - 3
src/xt_pages/outpatientCharges/statementPrint.vue Прегледај датотеку

@@ -13,7 +13,8 @@
13 13
       </template>
14 14
 
15 15
       <div class='dialysisPage' style="padding-top:40px;">
16
-        <printOne :info="info"></printOne>
16
+        <printOne :info="info" v-if="org_id != 0"></printOne>
17
+        <printTwo  v-if="org_id == 0"></printTwo>
17 18
       </div>
18 19
   </div>
19 20
 </template>
@@ -30,12 +31,14 @@ import axios from 'axios'
30 31
 import BreadCrumb from "@/xt_pages/components/bread-crumb";
31 32
 import print from "print-js";
32 33
 import printOne from "./statementTemplate/printOne"
34
+import printTwo from "./statementTemplate/printTwo"
33 35
 import { getAllDoctorList,getAllHisPatientList,getPrescriptionPrint } from "@/api/project/project"
34 36
 export default {
35 37
   name: "dialysisPrintOrder",
36 38
   components: {
37 39
     BreadCrumb,
38
-    printOne
40
+    printOne,
41
+    printTwo
39 42
   },
40 43
   props:{
41 44
     paramsObj:Object
@@ -57,6 +60,7 @@ export default {
57 60
       prescription_id:0,
58 61
       ids:'',
59 62
       info:null,
63
+      org_id:""
60 64
     };
61 65
   },
62 66
   methods:{
@@ -150,7 +154,7 @@ export default {
150 154
 
151 155
     },
152 156
     getInfo(order_id) {
153
-      if (this.$store.getters.xt_user.org_id == 3877 || this.$store.getters.xt_user.org_id == 9919 ||  this.$store.getters.xt_user.org_id == 9671 ||  this.$store.getters.xt_user.org_id == 9674 ||  this.$store.getters.xt_user.org_id == 10106  ||  this.$store.getters.xt_user.org_id == 4) {
157
+      if (this.$store.getters.xt_user.org_id == 3877 || this.$store.getters.xt_user.org_id == 9919 ||  this.$store.getters.xt_user.org_id == 9671 ||  this.$store.getters.xt_user.org_id == 9674 ||  this.$store.getters.xt_user.org_id == 10106  ||  this.$store.getters.xt_user.org_id == 4 || this.$store.getters.xt_user.org_id == 9990) {
154 158
 
155 159
         var that = this
156 160
 
@@ -222,6 +226,7 @@ export default {
222 226
 
223 227
   created() {
224 228
     this.getInfo(this.paramsObj.order_id)
229
+    this.org_id = this.$store.getters.xt_user.org_id
225 230
   },
226 231
   watch:{
227 232
     paramsObj:{//深度监听,可监听到对象、数组的变化

+ 129 - 0
src/xt_pages/outpatientCharges/statementTemplate/printTwo.vue Прегледај датотеку

@@ -0,0 +1,129 @@
1
+<template>
2
+  <div id="statement-print" class="statement-print">
3
+    <div class="statementTitle">珠海市职工基本医疗保险门慢就医结算单</div>
4
+    <div style="display:flex">
5
+        <div style="width:70%">医疗机构名称:</div>
6
+        <div style="width:30%">医院等级:</div>
7
+    </div>
8
+    <div style="display:flex;justify-content: space-between;border-bottom:1px solid #000;padding-bottom:10px;">
9
+        <div style="flex:1;">单据编码:</div>
10
+        <div style="width:33%">就诊时间:</div>
11
+        <div>金额单位:</div>
12
+    </div>
13
+    <div style="display:flex">
14
+        <div style="width:50%">姓名:</div>
15
+        <div style="width:50%">个人电脑号: </div>
16
+    </div>
17
+    <div style="display:flex">
18
+        <div style="width:50%">社保卡号</div>
19
+        <div style="width:50%">诊断: </div>
20
+    </div>
21
+    <div style="display:flex">
22
+        <div style="width:50%">人员类别:</div>
23
+        <div style="width:50%">待遇类别: </div>
24
+    </div>
25
+    <div style="display:flex;padding:10px 0;border-top:1px solid #000;border-bottom:1px solid #000;">
26
+        <div style="width:50%;text-align:center;">项目名称</div>
27
+        <div style="width:10%;text-align:center;">单价</div>
28
+        <div style="width:10%;text-align:center;">数量</div>
29
+        <div style="width:10%;text-align:center;">金额</div>
30
+        <div style="width:10%;text-align:center;">门诊目录</div>
31
+        <div style="width:10%;text-align:center;">医保目录</div>
32
+    </div>
33
+    <div style="border-bottom:1px solid #000;padding:10px 0;display:flex;">
34
+        <div style="width:50%;text-align:center;">1</div>
35
+        <div style="width:10%;text-align:center;">2</div>
36
+        <div style="width:10%;text-align:center;">3</div>
37
+        <div style="width:10%;text-align:center;">4</div>
38
+        <div style="width:10%;text-align:center;">5</div>
39
+        <div style="width:10%;text-align:center;">6</div>
40
+    </div>
41
+    <div style="display:flex;border-bottom:1px solid #000;padding:20px 0 10px;">
42
+        <div style="width:70%;">合计:</div>
43
+        <div style="width:10%;text-align:center;">4</div>
44
+        <div style="width:20%;"></div>
45
+    </div>
46
+    <div>医保基金支付金额:</div>
47
+    <div>个人现金支付金额:</div>
48
+    <div>其中</div>
49
+    <div style="display:flex;border-bottom:1px solid #000;padding-bottom:10px;">
50
+        <div>个人自付:</div>
51
+        <div>其中:1.乙类自付    </div>
52
+        <div>2.自费    </div>
53
+    </div>
54
+    <div style="display:flex;padding-top:10px;">
55
+        <div style="width:33%">参保人签名:</div>
56
+        <div style="width:33%">审核人: </div>
57
+        <div style="width:33%">医院盖章: </div>
58
+    </div>
59
+    
60
+  </div>
61
+</template>
62
+<script>
63
+  export default {
64
+    props: {
65
+      info: {
66
+        type: Object,
67
+        default: function() {
68
+          return {}
69
+        }
70
+      }, p_admin: {
71
+        type: Object,
72
+        default: function() {
73
+          return {}
74
+        }
75
+      }, charge_admin: {
76
+        type: Object,
77
+        default: function() {
78
+          return {}
79
+        }
80
+      }
81
+    },methods:{
82
+      getNowTime: function () {
83
+        let dateTime
84
+        let yy = new Date().getFullYear()
85
+        let mm = new Date().getMonth() + 1
86
+        let dd = new Date().getDate()
87
+        let hh = new Date().getHours()
88
+        let mf = new Date().getMinutes() < 10 ? '0' + new Date().getMinutes()
89
+          :
90
+          new Date().getMinutes()
91
+        let ss = new Date().getSeconds() < 10 ? '0' + new Date().getSeconds()
92
+          :
93
+          new Date().getSeconds()
94
+        dateTime = yy + '-' + mm + '-' + dd + ' ' + hh + ':' + mf + ':' + ss
95
+        return dateTime
96
+      },
97
+
98
+    }
99
+  }
100
+
101
+
102
+</script>
103
+
104
+
105
+<style lang="scss" scoped>
106
+  .statement-print {
107
+    -webkit-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 60px rgba(0, 0, 0, 0.06) inset;
108
+    -moz-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 40px rgba(0, 0, 0, 0.06) inset;
109
+    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 40px rgba(0, 0, 0, 0.06) inset;
110
+    margin-bottom: 20px;
111
+    padding: 20px 10px;
112
+  }
113
+
114
+  .statementTitle {
115
+    font-size: 28px;
116
+    text-align: center;
117
+    font-weight: bold;
118
+    margin-bottom: 10px;
119
+  }
120
+
121
+  .statementTable {
122
+    width: 100%;
123
+    text-align: center;
124
+    border-collapse: collapse;
125
+    line-height: 40px;
126
+    font-size: 14px;
127
+    border-color: #000;
128
+  }
129
+</style>

+ 3 - 25
src/xt_pages/outpatientDoctorStation/components/deskPrescription.vue Прегледај датотеку

@@ -360,9 +360,6 @@
360 360
                 </div>
361 361
               </el-tab-pane>
362 362
               <el-tab-pane label="项目组套" name="2">
363
-                <el-input style="width:100%;" @input="searchProjectList" @keyup.enter.native='searchProjectList'
364
-                            v-model.trim="project_item_keyword"
365
-                            placeholder="请输入项目组套名称"></el-input>
366 363
                 <div style="width: 100%;flex:1;overflow-y: auto;">
367 364
                   <el-table :data="tabPrjectTeam" border
368 365
                             :height="multipleTableHeight != '' ? multipleTableHeight : '200'"
@@ -576,9 +573,8 @@
576 573
             }
577 574
           }
578 575
         },
579
-        hisList:[],
580
-        project_item_keyword:"",
581
-        projectList:[] 
576
+        hisList:[]
577
+
582 578
       }
583 579
     },
584 580
     methods: {
@@ -1397,8 +1393,7 @@
1397 1393
         }
1398 1394
         this.$refs.additionalCharges.hide()
1399 1395
 
1400
-      }, 
1401
-      searchProjectAction() {
1396
+      }, searchProjectAction() {
1402 1397
 
1403 1398
         if (this.search_project_keyword.length == 0) {
1404 1399
           this.tabProject = this.allProject
@@ -1415,20 +1410,6 @@
1415 1410
         }
1416 1411
 
1417 1412
       },
1418
-      searchProjectList(){
1419
-         if(this.project_item_keyword.length == 0){
1420
-             this.tabPrjectTeam = this.projectList
1421
-         }else{
1422
-           let arr = []
1423
-           for(let i=0;i<this.projectList.length;i++){
1424
-              if(this.projectList[i].project_team.indexOf(this.project_item_keyword)!=-1){
1425
-                 arr = arr.concat(this.projectList[i])
1426
-              }
1427
-           }
1428
-           this.tabPrjectTeam = arr
1429
-         }
1430
-      },
1431
-
1432 1413
       searchAction() {
1433 1414
         if (this.search_keyword.length == 0) {
1434 1415
           this.drugs = this.allDrugs
@@ -1951,8 +1932,6 @@
1951 1932
               'prescriptions': this.prescriptions
1952 1933
             }
1953 1934
             isLoading = true
1954
-           
1955
-            
1956 1935
             createHisPrescription(data, params).then(response => {
1957 1936
               if (response.data.state == 1) {
1958 1937
                 this.$emit('change')
@@ -2485,7 +2464,6 @@
2485 2464
             var team = response.data.data.team
2486 2465
             console.log("team2222",team)
2487 2466
             this.tabPrjectTeam = team
2488
-            this.projectList = team
2489 2467
           }
2490 2468
         })
2491 2469
       },

+ 26 - 17
src/xt_pages/outpatientDoctorStation/components/deskRecord.vue Прегледај датотеку

@@ -316,7 +316,8 @@
316 316
         allergic_history:"",
317 317
         form:{
318 318
           id:0,
319
-        }
319
+        },
320
+        watchSign:0
320 321
       }
321 322
     },
322 323
     methods: {
@@ -330,7 +331,7 @@
330 331
 
331 332
 
332 333
       // },
333
-      createCaseHistory() {
334
+      createCaseHistory(id) {
334 335
           if(this.patientInfo.id == undefined){
335 336
             this.$message.error("请先选择病人")
336 337
             return
@@ -344,7 +345,7 @@
344 345
           let params = {
345 346
             "his_patient_id":this.hisPatientInfo.id,
346 347
             "delivery_way":this.delivery_way?"":0,
347
-            "patient_id":this.patientInfo.id,
348
+            "patient_id":id ? id : this.patientInfo.id,
348 349
             "temperature":this.case_history.temperature,
349 350
             "blood_sugar":this.case_history.blood_sugar,
350 351
             "pulse":this.case_history.pulse,
@@ -375,6 +376,7 @@
375 376
           createCaseHistory(params).then(response => {
376 377
             if (response.data.state == 0) {
377 378
               this.$message.error("患者病历已存在")
379
+              this.watchSign = 0
378 380
               return false
379 381
             } else {
380 382
               var caseHistory = response.data.data.caseHistory
@@ -382,6 +384,7 @@
382 384
               this.$message.success("保存成功")
383 385
               this.doctor_advice = ""
384 386
               this.remark = ""
387
+              this.watchSign = 0
385 388
             }
386 389
           })
387 390
 
@@ -562,20 +565,26 @@
562 565
         immediate: true,
563 566
         deep: true
564 567
       },
565
-      case_history:function(val){
566
-        console.log("南京人明",this.case_history)
567
-        if(this.case_history.breathing == 0){
568
-           this.case_history.breathing = ""
569
-        }
570
-        if(this.case_history.sick == 0){
571
-          this.case_history.sick = ""
572
-        }
573
-        if(this.case_history.diagnose == 0){
574
-           this.case_history.diagnose = ""
575
-        }
576
-        this.form.id = this.case_history.id
577
-        this.allergic_history = this.case_history.allergic_history
578
-        
568
+      case_history:{
569
+        handler(val){
570
+          console.log("南京人明",this.case_history)
571
+          if(this.case_history.breathing == 0){
572
+            this.case_history.breathing = ""
573
+          }
574
+          if(this.case_history.sick == 0){
575
+            this.case_history.sick = ""
576
+          }
577
+          if(this.case_history.diagnose == 0){
578
+            this.case_history.diagnose = ""
579
+          }
580
+          this.form.id = this.case_history.id
581
+          this.allergic_history = this.case_history.allergic_history
582
+          this.watchSign++
583
+        },
584
+        deep:true
585
+      },
586
+      allergic_history:function(){
587
+        this.watchSign++
579 588
       }
580 589
     }
581 590
   }

+ 19 - 0
src/xt_pages/outpatientDoctorStation/components/prescriptionTable.vue Прегледај датотеку

@@ -204,6 +204,7 @@
204 204
         input: 1,
205 205
       }
206 206
     },
207
+    
207 208
    methods:{
208 209
      createFilter(queryString) {
209 210
        return (restaurant) => {
@@ -380,6 +381,24 @@
380 381
       this.getInitData()
381 382
      
382 383
     },
384
+    watch:{
385
+      "prescription.advices":{
386
+        handler(newVal,oldVal){
387
+          newVal.map(item => {
388
+            item.prescribing_number = item.single_dose * item.day
389
+          })
390
+        },
391
+        deep:true
392
+      },
393
+      "prescription.project":{
394
+        handler(newVal,oldVal){
395
+          newVal.map(item => {
396
+            item.total = item.single_dose * item.number_days
397
+          })
398
+        },
399
+        deep:true
400
+      }
401
+    }
383 402
     
384 403
   }
385 404
 </script>

+ 521 - 2
src/xt_pages/outpatientDoctorStation/doctorDesk.vue Прегледај датотеку

@@ -903,7 +903,520 @@
903 903
       },
904 904
 
905 905
       choosePatient(val) {
906
+        console.log(val)
907
+        if(this.titleType == '电子病历'){
908
+          console.log('this.$refs.child.watchSign',this.$refs.child.watchSign)
909
+          if(this.$refs.child.watchSign > 2){
910
+            this.$confirm('是否保存当前病例', '保存', {
911
+              confirmButtonText: '确 定',
912
+              cancelButtonText: '取 消',
913
+              type: 'warning'
914
+            }).then(() => {
915
+              
916
+              this.$refs.child.createCaseHistory(this.newPatientId)
917
+              this.patientid = val.id
918
+              
919
+              let params = {
920
+                'record_date': this.record_date,
921
+                'patient_id': val.id,
922
+                'start_time': moment(new Date()).subtract(30, 'days').format('YYYY-MM-DD'),
923
+                'end_time': moment(new Date()).add('year', 0).format("YYYY-MM-DD")
924
+              }
925
+              getPatientInfo(params).then(response => {
926
+                if (response.data.state == 0) {
927
+                  this.$message.error(response.data.msg)
928
+                  return false
929
+                } else {
930
+                  this.prescriptions = []
931
+
932
+                  this.month_prescriptions = []
933
+
934
+                  var month_prescriptions = response.data.data.month_prescriptions
935
+                  this.setMonthPrescription(month_prescriptions)
936
+
937
+
938
+                  this.patientInfo = response.data.data.xt_info
939
+                  this.hisPatientInfo = response.data.data.his_info
940
+                  this.case_history = response.data.data.case_history
941
+                  console.log("数据是22222多少",this.case_history)
942
+                  this.info = response.data.data.info
943
+                  this.doctors = response.data.data.doctors
944
+                  this.department = response.data.data.department
945
+
946
+                  for (let i = 0; i < this.doctors.length; i++){
947
+                    if(this.doctors[i].user_type == 1){
948
+                      this.doctors.splice(i,1)
949
+                    }
950
+                  }
951
+                  this.patientInfo.birth = uParseTime(this.patientInfo.birthday, '{y}-{m}-{d}')
952
+                  if (this.case_history.breathing <= 0) {
953
+                    this.case_history.breathing = ""
954
+                  }
955
+                  if (this.case_history.sick <= 0) {
956
+                    this.case_history.sick = ""
957
+                  }
958
+                  if (this.case_history.diagnose <= 0) {
959
+                    this.case_history.diagnose = ""
960
+                  }
961
+
962
+                  if (this.case_history.temperature <= 0) {
963
+                    this.case_history.temperature = ''
964
+                  }
965
+                  if (this.case_history.blood_sugar <= 0) {
966
+                    this.case_history.blood_sugar = ''
967
+                  }
968
+                  if (this.case_history.pulse <= 0) {
969
+                    this.case_history.pulse = ''
970
+                  }
971
+                  if (this.case_history.sbp <= 0) {
972
+                    this.case_history.sbp = ''
973
+                  }
974
+                  if (this.case_history.dbp <= 0) {
975
+                    this.case_history.dbp = ''
976
+                  }
977
+                  if (this.case_history.height <= 0) {
978
+                    this.case_history.height = ''
979
+                  }
980
+                  if (this.case_history.blood_fat <= 0) {
981
+                    this.case_history.blood_fat = ''
982
+                  }
983
+                  if (this.case_history.sick_type <= 0) {
984
+                    this.case_history.sick_type = ''
985
+                  }
986
+                  this.case_history.sick_date = uParseTime(this.case_history.sick_date, '{y}-{m}-{d}')
987
+                  if (this.case_history.is_infect == 1) {
988
+                    this.case_history.is_infect = true
989
+                  } else {
990
+                    this.case_history.is_infect = false
991
+                  }
992
+                  this.prescriptionList = response.data.data.prescription
993
+                  if (response.data.data.prescription.length > 0) {
994
+                    for (let i = 0; i < response.data.data.prescription.length; i++) {
995
+                      var prescription = response.data.data.prescription[i]
996
+                      let tempAdvice = []
997
+                      let tempProject = []
998
+                      let tempAddition = []
999
+                      for (let b = 0; b < prescription.advices.length; b++) {
1000
+                        let obj = {
1001
+                          advice_id: prescription.advices[b].id,
1002
+                          drug_name: prescription.advices[b].advice_name,
1003
+                          single_dose: prescription.advices[b].single_dose,
1004
+                          delivery_way: prescription.advices[b].delivery_way,
1005
+                          execution_frequency: prescription.advices[b].execution_frequency,
1006
+                          retail_price: prescription.advices[b].price.toString(),
1007
+                          remark: prescription.advices[b].remark,
1008
+                          day: prescription.advices[b].day,
1009
+                          prescribing_number: prescription.advices[b].prescribing_number.toString(),
1010
+                          single_dose_unit: prescription.advices[b].single_dose_unit,
1011
+                          prescribing_number_unit: prescription.advices[b].prescribing_number_unit,
1012
+                          medical_insurance_number: prescription.advices[b].med_list_codg,
1013
+                          id: prescription.advices[b].drug_id
1014
+                        }
1015
+                        tempAdvice.push(obj)
1016
+                      }
1017
+                      for (let b = 0; b < prescription.project.length; b++) {
1018
+                        let obj = {
1019
+                          id: prescription.project[b].id,
1020
+                          project_id: prescription.project[b].project_id,
1021
+                          project_name: prescription.project[b].project.project_name,
1022
+                          statistical_classification: prescription.project[b].project.statistical_classification,
1023
+                          single_dose: prescription.project[b].single_dose,
1024
+                          delivery_way: prescription.project[b].delivery_way,
1025
+                          execution_frequency: prescription.project[b].execution_frequency,
1026
+                          number_days: prescription.project[b].day,
1027
+                          total: prescription.project[b].count.toString(),
1028
+                          price: prescription.project[b].price,
1029
+                          remark: prescription.project[b].remark,
1030
+                          medical_code: prescription.project[b].project.medical_code,
1031
+                          unit: prescription.project[b].unit
1032
+                        }
1033
+                        tempProject.push(obj)
1034
+                      }
1035
+                      for (let b = 0; b < prescription.addition.length; b++) {
1036
+                        let obj = {
1037
+                          id: prescription.addition[b].id,
1038
+                          item_name: prescription.addition[b].item_name,
1039
+                          price: prescription.addition[b].price,
1040
+                          count: prescription.addition[b].count,
1041
+                          item_id: prescription.addition[b].item_id,
1042
+                        }
1043
+                        tempAddition.push(obj)
1044
+                      }
1045
+
1046
+                      var preTime = ""
1047
+
1048
+                      if (prescription.pre_time == 0) {
1049
+                        preTime = nowTime
1050
+                      } else {
1051
+                        preTime = this.getTime(prescription.pre_time, "{y}-{m}-{d} {h}:{i}")
1052
+                      }
1053
+
1054
+                      let index = i + 1
1055
+                      let obj = {
1056
+                        id: prescription.id,
1057
+                        name: '处方' + index,
1058
+                        advices: tempAdvice,
1059
+                        project: tempProject,
1060
+                        addition: tempAddition,
1061
+                        order_status: prescription.order_status,
1062
+                        pre_time: preTime
1063
+                      }
1064
+                      this.prescriptions.push(obj)
1065
+                    }
1066
+                  } else {
1067
+                    let obj = {
1068
+                      id: 0,
1069
+                      name: '处方' + 1,
1070
+                      advices: [],
1071
+                      project: [],
1072
+                      addition: [],
1073
+                      orderStatus: 0,
1074
+                      pre_time: nowTime,
1075
+                    }
1076
+                    this.prescriptions.push(obj)
1077
+                  }
1078
+                  this.$refs.prescriptions.setData(this.prescriptions, this.info, this.admin_info, this.doctors, this.department,this.hisPatientInfo, this.month_prescriptions)
1079
+                  this.$refs.child.watchSign = 0
1080
+                }
1081
+              })
1082
+              this.$refs.child.watchSign = 0
1083
+            }).catch(() => {
1084
+              
1085
+              this.patientid = val.id
1086
+              let params = {
1087
+                'record_date': this.record_date,
1088
+                'patient_id': val.id,
1089
+                'start_time': moment(new Date()).subtract(30, 'days').format('YYYY-MM-DD'),
1090
+                'end_time': moment(new Date()).add('year', 0).format("YYYY-MM-DD")
1091
+              }
1092
+              getPatientInfo(params).then(response => {
1093
+                if (response.data.state == 0) {
1094
+                  this.$message.error(response.data.msg)
1095
+                  return false
1096
+                } else {
1097
+                  this.prescriptions = []
1098
+
1099
+                  this.month_prescriptions = []
1100
+
1101
+                  var month_prescriptions = response.data.data.month_prescriptions
1102
+                  this.setMonthPrescription(month_prescriptions)
1103
+
1104
+
1105
+                  this.patientInfo = response.data.data.xt_info
1106
+                  this.hisPatientInfo = response.data.data.his_info
1107
+                  this.case_history = response.data.data.case_history
1108
+                  console.log("数据是22222多少",this.case_history)
1109
+                  this.info = response.data.data.info
1110
+                  this.doctors = response.data.data.doctors
1111
+                  this.department = response.data.data.department
1112
+
1113
+                  for (let i = 0; i < this.doctors.length; i++){
1114
+                    if(this.doctors[i].user_type == 1){
1115
+                      this.doctors.splice(i,1)
1116
+                    }
1117
+                  }
1118
+                  this.patientInfo.birth = uParseTime(this.patientInfo.birthday, '{y}-{m}-{d}')
1119
+                  if (this.case_history.breathing <= 0) {
1120
+                    this.case_history.breathing = ""
1121
+                  }
1122
+                  if (this.case_history.sick <= 0) {
1123
+                    this.case_history.sick = ""
1124
+                  }
1125
+                  if (this.case_history.diagnose <= 0) {
1126
+                    this.case_history.diagnose = ""
1127
+                  }
1128
+
1129
+                  if (this.case_history.temperature <= 0) {
1130
+                    this.case_history.temperature = ''
1131
+                  }
1132
+                  if (this.case_history.blood_sugar <= 0) {
1133
+                    this.case_history.blood_sugar = ''
1134
+                  }
1135
+                  if (this.case_history.pulse <= 0) {
1136
+                    this.case_history.pulse = ''
1137
+                  }
1138
+                  if (this.case_history.sbp <= 0) {
1139
+                    this.case_history.sbp = ''
1140
+                  }
1141
+                  if (this.case_history.dbp <= 0) {
1142
+                    this.case_history.dbp = ''
1143
+                  }
1144
+                  if (this.case_history.height <= 0) {
1145
+                    this.case_history.height = ''
1146
+                  }
1147
+                  if (this.case_history.blood_fat <= 0) {
1148
+                    this.case_history.blood_fat = ''
1149
+                  }
1150
+                  if (this.case_history.sick_type <= 0) {
1151
+                    this.case_history.sick_type = ''
1152
+                  }
1153
+                  this.case_history.sick_date = uParseTime(this.case_history.sick_date, '{y}-{m}-{d}')
1154
+                  if (this.case_history.is_infect == 1) {
1155
+                    this.case_history.is_infect = true
1156
+                  } else {
1157
+                    this.case_history.is_infect = false
1158
+                  }
1159
+                  this.prescriptionList = response.data.data.prescription
1160
+                  if (response.data.data.prescription.length > 0) {
1161
+                    for (let i = 0; i < response.data.data.prescription.length; i++) {
1162
+                      var prescription = response.data.data.prescription[i]
1163
+                      let tempAdvice = []
1164
+                      let tempProject = []
1165
+                      let tempAddition = []
1166
+                      for (let b = 0; b < prescription.advices.length; b++) {
1167
+                        let obj = {
1168
+                          advice_id: prescription.advices[b].id,
1169
+                          drug_name: prescription.advices[b].advice_name,
1170
+                          single_dose: prescription.advices[b].single_dose,
1171
+                          delivery_way: prescription.advices[b].delivery_way,
1172
+                          execution_frequency: prescription.advices[b].execution_frequency,
1173
+                          retail_price: prescription.advices[b].price.toString(),
1174
+                          remark: prescription.advices[b].remark,
1175
+                          day: prescription.advices[b].day,
1176
+                          prescribing_number: prescription.advices[b].prescribing_number.toString(),
1177
+                          single_dose_unit: prescription.advices[b].single_dose_unit,
1178
+                          prescribing_number_unit: prescription.advices[b].prescribing_number_unit,
1179
+                          medical_insurance_number: prescription.advices[b].med_list_codg,
1180
+                          id: prescription.advices[b].drug_id
1181
+                        }
1182
+                        tempAdvice.push(obj)
1183
+                      }
1184
+                      for (let b = 0; b < prescription.project.length; b++) {
1185
+                        let obj = {
1186
+                          id: prescription.project[b].id,
1187
+                          project_id: prescription.project[b].project_id,
1188
+                          project_name: prescription.project[b].project.project_name,
1189
+                          statistical_classification: prescription.project[b].project.statistical_classification,
1190
+                          single_dose: prescription.project[b].single_dose,
1191
+                          delivery_way: prescription.project[b].delivery_way,
1192
+                          execution_frequency: prescription.project[b].execution_frequency,
1193
+                          number_days: prescription.project[b].day,
1194
+                          total: prescription.project[b].count.toString(),
1195
+                          price: prescription.project[b].price,
1196
+                          remark: prescription.project[b].remark,
1197
+                          medical_code: prescription.project[b].project.medical_code,
1198
+                          unit: prescription.project[b].unit
1199
+                        }
1200
+                        tempProject.push(obj)
1201
+                      }
1202
+                      for (let b = 0; b < prescription.addition.length; b++) {
1203
+                        let obj = {
1204
+                          id: prescription.addition[b].id,
1205
+                          item_name: prescription.addition[b].item_name,
1206
+                          price: prescription.addition[b].price,
1207
+                          count: prescription.addition[b].count,
1208
+                          item_id: prescription.addition[b].item_id,
1209
+                        }
1210
+                        tempAddition.push(obj)
1211
+                      }
1212
+
1213
+                      var preTime = ""
1214
+
1215
+                      if (prescription.pre_time == 0) {
1216
+                        preTime = nowTime
1217
+                      } else {
1218
+                        preTime = this.getTime(prescription.pre_time, "{y}-{m}-{d} {h}:{i}")
1219
+                      }
1220
+
1221
+                      let index = i + 1
1222
+                      let obj = {
1223
+                        id: prescription.id,
1224
+                        name: '处方' + index,
1225
+                        advices: tempAdvice,
1226
+                        project: tempProject,
1227
+                        addition: tempAddition,
1228
+                        order_status: prescription.order_status,
1229
+                        pre_time: preTime
1230
+                      }
1231
+                      this.prescriptions.push(obj)
1232
+                    }
1233
+                  } else {
1234
+                    let obj = {
1235
+                      id: 0,
1236
+                      name: '处方' + 1,
1237
+                      advices: [],
1238
+                      project: [],
1239
+                      addition: [],
1240
+                      orderStatus: 0,
1241
+                      pre_time: nowTime,
1242
+                    }
1243
+                    this.prescriptions.push(obj)
1244
+                  }
1245
+                  this.$refs.prescriptions.setData(this.prescriptions, this.info, this.admin_info, this.doctors, this.department,this.hisPatientInfo, this.month_prescriptions)
1246
+                  this.$refs.child.watchSign = 0
1247
+                }
1248
+              })
1249
+              
1250
+            })
1251
+            this.$refs.child.watchSign = 0
1252
+          }else{
1253
+            this.patientid = val.id
1254
+            let params = {
1255
+              'record_date': this.record_date,
1256
+              'patient_id': val.id,
1257
+              'start_time': moment(new Date()).subtract(30, 'days').format('YYYY-MM-DD'),
1258
+              'end_time': moment(new Date()).add('year', 0).format("YYYY-MM-DD")
1259
+            }
1260
+            getPatientInfo(params).then(response => {
1261
+                if (response.data.state == 0) {
1262
+                  this.$message.error(response.data.msg)
1263
+                  return false
1264
+                } else {
1265
+                  this.prescriptions = []
1266
+
1267
+                  this.month_prescriptions = []
1268
+
1269
+                  var month_prescriptions = response.data.data.month_prescriptions
1270
+                  this.setMonthPrescription(month_prescriptions)
1271
+
1272
+
1273
+                  this.patientInfo = response.data.data.xt_info
1274
+                  this.hisPatientInfo = response.data.data.his_info
1275
+                  this.case_history = response.data.data.case_history
1276
+                  console.log("数据是22222多少",this.case_history)
1277
+                  this.info = response.data.data.info
1278
+                  this.doctors = response.data.data.doctors
1279
+                  this.department = response.data.data.department
1280
+
1281
+                  for (let i = 0; i < this.doctors.length; i++){
1282
+                    if(this.doctors[i].user_type == 1){
1283
+                      this.doctors.splice(i,1)
1284
+                    }
1285
+                  }
1286
+                  this.patientInfo.birth = uParseTime(this.patientInfo.birthday, '{y}-{m}-{d}')
1287
+                  if (this.case_history.breathing <= 0) {
1288
+                    this.case_history.breathing = ""
1289
+                  }
1290
+                  if (this.case_history.sick <= 0) {
1291
+                    this.case_history.sick = ""
1292
+                  }
1293
+                  if (this.case_history.diagnose <= 0) {
1294
+                    this.case_history.diagnose = ""
1295
+                  }
1296
+
1297
+                  if (this.case_history.temperature <= 0) {
1298
+                    this.case_history.temperature = ''
1299
+                  }
1300
+                  if (this.case_history.blood_sugar <= 0) {
1301
+                    this.case_history.blood_sugar = ''
1302
+                  }
1303
+                  if (this.case_history.pulse <= 0) {
1304
+                    this.case_history.pulse = ''
1305
+                  }
1306
+                  if (this.case_history.sbp <= 0) {
1307
+                    this.case_history.sbp = ''
1308
+                  }
1309
+                  if (this.case_history.dbp <= 0) {
1310
+                    this.case_history.dbp = ''
1311
+                  }
1312
+                  if (this.case_history.height <= 0) {
1313
+                    this.case_history.height = ''
1314
+                  }
1315
+                  if (this.case_history.blood_fat <= 0) {
1316
+                    this.case_history.blood_fat = ''
1317
+                  }
1318
+                  if (this.case_history.sick_type <= 0) {
1319
+                    this.case_history.sick_type = ''
1320
+                  }
1321
+                  this.case_history.sick_date = uParseTime(this.case_history.sick_date, '{y}-{m}-{d}')
1322
+                  if (this.case_history.is_infect == 1) {
1323
+                    this.case_history.is_infect = true
1324
+                  } else {
1325
+                    this.case_history.is_infect = false
1326
+                  }
1327
+                  this.prescriptionList = response.data.data.prescription
1328
+                  if (response.data.data.prescription.length > 0) {
1329
+                    for (let i = 0; i < response.data.data.prescription.length; i++) {
1330
+                      var prescription = response.data.data.prescription[i]
1331
+                      let tempAdvice = []
1332
+                      let tempProject = []
1333
+                      let tempAddition = []
1334
+                      for (let b = 0; b < prescription.advices.length; b++) {
1335
+                        let obj = {
1336
+                          advice_id: prescription.advices[b].id,
1337
+                          drug_name: prescription.advices[b].advice_name,
1338
+                          single_dose: prescription.advices[b].single_dose,
1339
+                          delivery_way: prescription.advices[b].delivery_way,
1340
+                          execution_frequency: prescription.advices[b].execution_frequency,
1341
+                          retail_price: prescription.advices[b].price.toString(),
1342
+                          remark: prescription.advices[b].remark,
1343
+                          day: prescription.advices[b].day,
1344
+                          prescribing_number: prescription.advices[b].prescribing_number.toString(),
1345
+                          single_dose_unit: prescription.advices[b].single_dose_unit,
1346
+                          prescribing_number_unit: prescription.advices[b].prescribing_number_unit,
1347
+                          medical_insurance_number: prescription.advices[b].med_list_codg,
1348
+                          id: prescription.advices[b].drug_id
1349
+                        }
1350
+                        tempAdvice.push(obj)
1351
+                      }
1352
+                      for (let b = 0; b < prescription.project.length; b++) {
1353
+                        let obj = {
1354
+                          id: prescription.project[b].id,
1355
+                          project_id: prescription.project[b].project_id,
1356
+                          project_name: prescription.project[b].project.project_name,
1357
+                          statistical_classification: prescription.project[b].project.statistical_classification,
1358
+                          single_dose: prescription.project[b].single_dose,
1359
+                          delivery_way: prescription.project[b].delivery_way,
1360
+                          execution_frequency: prescription.project[b].execution_frequency,
1361
+                          number_days: prescription.project[b].day,
1362
+                          total: prescription.project[b].count.toString(),
1363
+                          price: prescription.project[b].price,
1364
+                          remark: prescription.project[b].remark,
1365
+                          medical_code: prescription.project[b].project.medical_code,
1366
+                          unit: prescription.project[b].unit
1367
+                        }
1368
+                        tempProject.push(obj)
1369
+                      }
1370
+                      for (let b = 0; b < prescription.addition.length; b++) {
1371
+                        let obj = {
1372
+                          id: prescription.addition[b].id,
1373
+                          item_name: prescription.addition[b].item_name,
1374
+                          price: prescription.addition[b].price,
1375
+                          count: prescription.addition[b].count,
1376
+                          item_id: prescription.addition[b].item_id,
1377
+                        }
1378
+                        tempAddition.push(obj)
1379
+                      }
906 1380
 
1381
+                      var preTime = ""
1382
+
1383
+                      if (prescription.pre_time == 0) {
1384
+                        preTime = nowTime
1385
+                      } else {
1386
+                        preTime = this.getTime(prescription.pre_time, "{y}-{m}-{d} {h}:{i}")
1387
+                      }
1388
+
1389
+                      let index = i + 1
1390
+                      let obj = {
1391
+                        id: prescription.id,
1392
+                        name: '处方' + index,
1393
+                        advices: tempAdvice,
1394
+                        project: tempProject,
1395
+                        addition: tempAddition,
1396
+                        order_status: prescription.order_status,
1397
+                        pre_time: preTime
1398
+                      }
1399
+                      this.prescriptions.push(obj)
1400
+                    }
1401
+                  } else {
1402
+                    let obj = {
1403
+                      id: 0,
1404
+                      name: '处方' + 1,
1405
+                      advices: [],
1406
+                      project: [],
1407
+                      addition: [],
1408
+                      orderStatus: 0,
1409
+                      pre_time: nowTime,
1410
+                    }
1411
+                    this.prescriptions.push(obj)
1412
+                  }
1413
+                  this.$refs.prescriptions.setData(this.prescriptions, this.info, this.admin_info, this.doctors, this.department,this.hisPatientInfo, this.month_prescriptions)
1414
+                  this.$refs.child.watchSign = 0
1415
+                }
1416
+              })
1417
+            this.$refs.child.watchSign = 0
1418
+          }
1419
+        }else{
907 1420
         var nowDate = new Date()
908 1421
         var nowYear = nowDate.getFullYear()
909 1422
         var nowMonth = nowDate.getMonth() + 1
@@ -1296,11 +1809,16 @@
1296 1809
 
1297 1810
 
1298 1811
         }
1812
+        }
1813
+        
1299 1814
 
1300 1815
 
1816
+      
1817
+      
1301 1818
       },
1302 1819
       currentChange(currentRow, oldCurrentRow) {
1303
-
1820
+        this.newPatientId = oldCurrentRow.id
1821
+        console.log('执行',this.newPatientId)
1304 1822
         let isShowDailog = false
1305 1823
         for (let i = 0; i < this.prescriptions.length; i++) {
1306 1824
           if ((this.prescriptions[i].id == 0 && this.prescriptions[i].advices.length > 0) || (this.prescriptions[i].id == 0 && this.prescriptions[i].project.length > 0)) {
@@ -1311,7 +1829,8 @@
1311 1829
           this.oldCurrentRow = currentRow
1312 1830
           return
1313 1831
         }
1314
-
1832
+        
1833
+        
1315 1834
 
1316 1835
       }, open_two() {
1317 1836
         this.$refs.prescriptions.open_two()

+ 2 - 2
src/xt_pages/outpatientRegistration/index.vue Прегледај датотеку

@@ -1000,7 +1000,7 @@
1000 1000
                 .catch(function(error) {
1001 1001
 
1002 1002
                 })
1003
-            } else if (this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 10106 || this.$store.getters.xt_user.org_id == 4 || this.$store.getters.xt_user.org_id == 9538) {
1003
+            } else if (this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 10106 || this.$store.getters.xt_user.org_id == 4 || this.$store.getters.xt_user.org_id == 9538 || this.$store.getters.xt_user.org_id == 9990) {
1004 1004
               var that = this
1005 1005
 
1006 1006
               axios.get('http://127.0.0.1:9532/api/register/get', {
@@ -1259,7 +1259,7 @@
1259 1259
                 .catch(function(error) {
1260 1260
 
1261 1261
                 })
1262
-            } else if (this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 10106 || this.$store.getters.xt_user.org_id == 4 || this.$store.getters.xt_user.org_id == 9538) {
1262
+            } else if (this.$store.getters.xt_user.org_id == 9919 || this.$store.getters.xt_user.org_id == 10106 || this.$store.getters.xt_user.org_id == 4 || this.$store.getters.xt_user.org_id == 9538 || this.$store.getters.xt_user.org_id == 9990) {
1263 1263
               var that = this
1264 1264
 
1265 1265
               axios.get('http://127.0.0.1:9532/api/register/get', {

+ 56 - 51
src/xt_pages/qcd/basicInformationAnalysis.vue Прегледај датотеку

@@ -63,13 +63,13 @@
63 63
           :picker-options="pickerOptions"
64 64
         ></el-date-picker>
65 65
       </div>
66
-       <div class="cell clearfix">
66
+       <!-- <div class="cell clearfix">
67 67
         <label class="title"><span class="name">转归情况</span> : </label>
68 68
         <div class="time ">
69 69
           <ul class="">
70 70
             <li
71 71
               :class="item.lapseto == lapsetoType ? 'active' : ''"
72
-              @click="selectLapseOne(item.lapseto)"
72
+              @click="selectLapseTo(item.lapseto)"
73 73
               v-for="item in lapsetoArr"
74 74
               :key="item.value"
75 75
             >
@@ -77,8 +77,8 @@
77 77
             </li>
78 78
           </ul>
79 79
         </div>
80
-      </div>
81
-      <div class="cell clearfix">
80
+      </div> -->
81
+      <!-- <div class="cell clearfix">
82 82
         <label class="title"><span class="name">病人来源</span> : </label>
83 83
         <div class="time ">
84 84
           <ul class="">
@@ -92,7 +92,7 @@
92 92
             </li>
93 93
           </ul>
94 94
         </div>
95
-      </div>
95
+      </div> -->
96 96
 
97 97
        <div class="cell clearfix" v-show="treatShow">
98 98
         <label class="title">
@@ -243,12 +243,10 @@
243 243
                 <p class="infoTitle">转归统计(总人数{{patientCount}}人)</p>
244 244
               </div>
245 245
               <div class="borderBox1">
246
-                 <span v-if="lapsetoType == 0 || lapsetoType == 1"><p>留治:{{rollOutTotal}}人({{(rollOutTotal/patientCount*100).toFixed(1)}}%)</p>
247
-                  <el-progress :percentage="(rollOutTotal/patientCount*100).toFixed(1)"></el-progress>
248
-                </span>
249
-                <span v-if="lapsetoType == 0 || lapsetoType == 2"><p>转出:{{outTotal}}人({{(outTotal/patientCount*100).toFixed(1)}}%)</p>
250
-                 <el-progress :percentage="(outTotal/patientCount*100).toFixed(1)"></el-progress>
251
-                </span> 
246
+                <p>留治:{{rollOutTotal}}人({{(rollOutTotal/patientCount*100).toFixed(1)}}%)</p>
247
+                <el-progress :percentage="(rollOutTotal/patientCount*100).toFixed(1)"></el-progress>
248
+                <p>转出:{{outTotal}}人({{(outTotal/patientCount*100).toFixed(1)}}%)</p>
249
+                <el-progress :percentage="(outTotal/patientCount*100).toFixed(1)"></el-progress>
252 250
               </div>
253 251
             </div>
254 252
             <div class="infoOne">
@@ -329,7 +327,7 @@
329 327
         </div>
330 328
         <div>
331 329
 
332
-        <!-- <div class="cell clearfix" v-show="treatShow">
330
+        <div class="cell clearfix" v-show="treatShow">
333 331
         <label class="title">
334 332
           <span class="name">转归状态</span> :
335 333
         </label>
@@ -343,7 +341,7 @@
343 341
             >{{ item.label }}</li>
344 342
           </ul>
345 343
         </div>
346
-       </div> -->
344
+       </div>
347 345
 
348 346
           <p style="font-size: 16px;font-weight: bold;color: #000;">转归统计</p>
349 347
           <line-chart :options="bar"></line-chart>
@@ -423,7 +421,7 @@ export default {
423 421
         { value: 0, label: '全部', source: 0, lapseto: 0 },
424 422
         { value: 1, label: '转出', source: 0, lapseto: 2 },
425 423
         { value: 2, label: '留治', source: 0, lapseto: 1 },
426
-        // { value: 3, label: '死亡', source:0,  lapseto: 3 },
424
+        { value: 3, label: '死亡', source:0,  lapseto: 3 },
427 425
       ],
428 426
       sourceType: 0,
429 427
       sourceArr: [
@@ -654,7 +652,7 @@ export default {
654 652
         //统计转归状态
655 653
         this.getTotalLapseCount(this.listQuery.start_time,this.listQuery.end_time,this.lapsetoType,this.sourceType)
656 654
         //统计男女比例
657
-        this.getTotalSexCount(timeStar,timeEnd,this.lapsetoType,this.sourceType)
655
+        this.getTotalSexCount(timeStar,timeEnd)
658 656
         //统计传染病
659 657
         this.getTotalInfectiousCount(this.listQuery.start_time,this.listQuery.end_time,this.lapsetoType,this.sourceType)
660 658
         //统计年龄
@@ -664,7 +662,7 @@ export default {
664 662
         this.start = timeStar
665 663
         this.end =timeEnd
666 664
         this.getCountModeId()
667
-        this.getRolloutCount(timeStar,timeEnd,this.lapsetoType,this.sourceType)
665
+        this.getRolloutCount(timeStar,timeEnd)
668 666
       }
669 667
     },
670 668
     changeEndTime(val) {
@@ -692,7 +690,7 @@ export default {
692 690
         this.start = timeStar
693 691
         this.end =timeEnd
694 692
         this.getCountModeId()
695
-        this.getRolloutCount(timeStar,timeEnd,this.lapsetoType,this.sourceType)
693
+        this.getRolloutCount(timeStar,timeEnd)
696 694
       }
697 695
     },
698 696
     selectLapseTo(state) {
@@ -701,7 +699,7 @@ export default {
701 699
       //获取本月当前机构的透析模式
702 700
       const startDate = moment().subtract('month', 0).format('YYYY-MM') + '-01'
703 701
       const endDate = moment(new Date()).format('YYYY-MM-DD')
704
-     
702
+
705 703
       var now = new Date()
706 704
       var nowMonth = now.getMonth(); //当前月
707 705
       var nowYear = now.getFullYear(); //当前年
@@ -730,14 +728,14 @@ export default {
730 728
         this.start = timeStar
731 729
         this.end = timeEnd
732 730
         this.getCountModeId()
733
-        this.getRolloutCount(timeStar,timeEnd,this.lapsetoType,this.sourceType)
731
+        this.getRolloutCount(timeStar,timeEnd)
734 732
       }
735 733
       //近三月
736 734
       if(state == 1){
737 735
         this.listQuery.start_time = ""
738 736
         this.listQuery.end_time = ""
739 737
         const startDate = moment().subtract('month', 3).format('YYYY-MM-DD')
740
-       
738
+
741 739
         var startunitx = Date.parse(startDate)/1000
742 740
         // console.log("开始时间搓",startunitx)
743 741
         const endDate = moment(new Date()).format('YYYY-MM-DD')
@@ -759,7 +757,7 @@ export default {
759 757
         this.start = startunitx
760 758
         this.end = endunitx
761 759
         this.getCountModeId()
762
-        this.getRolloutCount(startunitx,endunitx,this.lapsetoType,this.sourceType)
760
+        this.getRolloutCount(startunitx,endunitx)
763 761
       }
764 762
 
765 763
      //近半年
@@ -790,7 +788,7 @@ export default {
790 788
         this.start = startunitx
791 789
         this.end = endunitx
792 790
         this.getCountModeId()
793
-        this.getRolloutCount(startunitx,endunitx,this.lapsetoType,this.sourceType)
791
+        this.getRolloutCount(startunitx,endunitx)
794 792
      }
795 793
 
796 794
      //近一年
@@ -817,10 +815,11 @@ export default {
817 815
         this.getTotalAgeCount(startunitx,endunitx,this.lapsetoType,this.sourceType)
818 816
         //统计透析年龄
819 817
         this.getTotalDialysisCount(startunitx,endunitx,this.lapsetoType,this.sourceType)
818
+
820 819
         this.start = startunitx
821 820
         this.end = endunitx
822 821
         this.getCountModeId()
823
-        this.getRolloutCount(startunitx,endunitx,this.lapsetoType,this.sourceType)
822
+        this.getRolloutCount(startunitx,endunitx)
824 823
      }
825 824
 
826 825
 
@@ -843,12 +842,12 @@ export default {
843 842
          if(response.data.state == 1){
844 843
 
845 844
           var modetype =  response.data.data.modetype
846
-         
845
+
847 846
           this.modetype = modetype
848 847
           var total =  response.data.data.total
849
-          
850
-          this.total = total.count
851
-          // this.total = total
848
+
849
+          // this.total = total.count
850
+          this.total = total
852 851
           // console.log("数据",this.modetype)
853 852
           var modedate = response.data.data.modetype
854 853
           for(let i=0;i<modedate.length;i++){
@@ -920,52 +919,61 @@ export default {
920 919
       })
921 920
     },
922 921
     //统计转归
923
-    getTotalLapseCount(startDate,endDate,lapsetoType,sourceType ){
924
-   
922
+    getTotalLapseCount(startDate,endDate){
925 923
        this.modesDataTwo.series = []
926 924
        this.modesDataTwo.xAxis = []
927
-      getTotalLapseCount(startDate,endDate,lapsetoType,sourceType).then(response=>{
925
+      getTotalLapseCount(startDate,endDate).then(response=>{
928 926
          if(response.data.state == 1){
929 927
            var arr = [
930 928
              {name:"留治",count:0},
931 929
              {name:"转出",count:0}
932 930
            ]
933 931
           var patients =  response.data.data.patients
934
-      
935
-          this.rollOutTotal = patients.length
936 932
 
933
+          this.rollOutTotal = patients.length
937 934
           var patienttwo = response.data.data.patienttwo
935
+
938 936
           this.outTotal = patienttwo.length
939 937
           var count = response.data.data.count
940 938
           this.patientCount = count
941 939
 
942 940
           var rollout = response.data.data.rollout
943
-        
941
+          console.log("rollout",rollout)
944 942
 
945 943
           for(let i=0;i<arr.length;i++){
946 944
             arr[0].count = this.rollOutTotal
947 945
             arr[1].count = this.outTotal
948 946
           }
947
+
948
+          // for(let j=0;j<arr.length;j++){
949
+          //   this.modesDataTwo.xAxis.push(arr[j].name)
950
+          //   this.modesDataTwo.series.push(((arr[j].count/count)*100).toFixed(1))
951
+          // }
952
+          // this.bar.series[0].data = this.modesDataTwo.series
953
+          // this.bar.xAxis.data = this.modesDataTwo.xAxis
954
+          // this.getArrLength(this.bar.xAxis.data)
955
+
949 956
          }
950 957
       })
951 958
     },
952 959
     //统计男女比例
953
-    getTotalSexCount(timeStar,timeEnd,lapsetoType,sourceType){
954
-      getTotalSexCount(timeStar,timeEnd,lapsetoType,sourceType).then(response=>{
960
+    getTotalSexCount(timeStar,timeEnd){
961
+      getTotalSexCount(timeStar,timeEnd).then(response=>{
955 962
         if(response.data.state === 1){
956
-          console.log("resp2222",response.data.data.totalWoman)
957 963
           var total = response.data.data.total
964
+        //  console.log("总人数",total)
958 965
           this.totalGender = total
959 966
           var totalMan = response.data.data.totalSex
967
+       //  console.log("男人",totalMan)
960 968
           this.totalMan = totalMan
961
-          var totalWoman = response.data.data.totalWoman
969
+          var totalWoman = total - totalMan
962 970
           this.totalWoman = totalWoman
963 971
         }
964 972
       })
965 973
     },
966 974
     //统计传染病
967
-    getTotalInfectiousCount(timeStar,timeEnd,lapsetoType,sourceType){
968
-       getTotalInfectiousCount(timeStar,timeEnd,lapsetoType,sourceType).then(response=>{
975
+    getTotalInfectiousCount(timeStar,timeEnd){
976
+       getTotalInfectiousCount(timeStar,timeEnd).then(response=>{
969 977
            if(response.data.state === 1){
970 978
              this.InfectiousTotal = response.data.data.total
971 979
              var infectious = response.data.data.count
@@ -988,10 +996,11 @@ export default {
988 996
            }
989 997
        })
990 998
     },
991
-    getTotalAgeCount(timeStar,timeEnd,lapsetoType,sourceType){
992
-      getTotalAgeCount(timeStar,timeEnd,lapsetoType,sourceType).then(response=>{
999
+    getTotalAgeCount(timeStar,timeEnd){
1000
+      getTotalAgeCount(timeStar,timeEnd).then(response=>{
993 1001
          if(response.data.state == 1){
994 1002
           var ageCount =  response.data.data.ageCount
1003
+          // console.log("ageCount",ageCount)
995 1004
           var arr = []
996 1005
           arr =  ageCount.sort(this.compare('age'))
997 1006
           this.ageCount = arr
@@ -1009,8 +1018,8 @@ export default {
1009 1018
           }
1010 1019
       },
1011 1020
     //统计透析年龄
1012
-    getTotalDialysisCount(timeStar,timeEnd,lapsetoType,sourceType){
1013
-      getTotalDialysisCount(timeStar,timeEnd,lapsetoType,sourceType).then(response=>{
1021
+    getTotalDialysisCount(timeStar,timeEnd){
1022
+      getTotalDialysisCount(timeStar,timeEnd).then(response=>{
1014 1023
          if(response.data.state == 1){
1015 1024
            var dataage =  response.data.data.dataage
1016 1025
           //  console.log("dataage",dataage)
@@ -1167,9 +1176,7 @@ export default {
1167 1176
        this.modesDataTwo.xAxis = []
1168 1177
         const params = {
1169 1178
           start_time:this.start,
1170
-          end_time:this.end,
1171
-          lapsetotype:this.lapsetoType,
1172
-          sourcetype:this.sourceType,
1179
+          end_time:this.end
1173 1180
         }
1174 1181
       getRolloutCount(params).then(response=>{
1175 1182
          if(response.data.state == 1){
@@ -1218,10 +1225,8 @@ export default {
1218 1225
       this.getTotalInfectiousCount(this.startDate,this.endDate,this.lapsetoType,this.sourceType)
1219 1226
       this.getTotalAgeCount(this.startDate,this.endDate,this.lapsetoType,this.sourceType)
1220 1227
       this.getTotalDialysisCount(this.startDate,this.endDate,this.lapsetoType,this.sourceType)
1221
-      this.getRolloutCount(this.lapsetoType,this.sourceType)
1222 1228
     },
1223
-    selectLapseOne(lapseto) {
1224
-      console.log("lapseto22222",lapseto)
1229
+    selectLapseTo(lapseto) {
1225 1230
       this.lapsetoType = lapseto
1226 1231
       this.getDialysisModeType(this.startDate,this.endDate,this.lapsetoType,this.sourceType)
1227 1232
       this.getTotalLapseCount(this.startDate,this.endDate,this.lapsetoType,this.sourceType)
@@ -1229,7 +1234,6 @@ export default {
1229 1234
       this.getTotalInfectiousCount(this.startDate,this.endDate,this.lapsetoType,this.sourceType)
1230 1235
       this.getTotalAgeCount(this.startDate,this.endDate,this.lapsetoType,this.sourceType)
1231 1236
       this.getTotalDialysisCount(this.startDate,this.endDate,this.lapsetoType,this.sourceType)
1232
-      this.getRolloutCount(this.lapsetoType,this.sourceType)
1233 1237
     },
1234 1238
   },
1235 1239
   created() {
@@ -1266,7 +1270,7 @@ export default {
1266 1270
       this.start = timeStar
1267 1271
       this.end = timeEnd
1268 1272
 
1269
-     this.getRolloutCount(timeStar,timeEnd,this.lapsetoType,this.sourceType)
1273
+     this.getRolloutCount(timeStar,timeEnd)
1270 1274
 
1271 1275
 
1272 1276
   },
@@ -1417,3 +1421,4 @@ export default {
1417 1421
 </style>
1418 1422
 
1419 1423
 
1424
+

+ 14 - 1
src/xt_pages/stock/Dialog/goodInfoDailog.vue Прегледај датотеку

@@ -3,7 +3,8 @@
3 3
              :title="titles"
4 4
              :visible.sync="visible"
5 5
              :close-on-click-modal="isClose"
6
-             :close-on-press-escape="isClose">
6
+             :close-on-press-escape="isClose"
7
+             :before-close="_close">
7 8
 
8 9
     <el-tabs v-model="activeName">
9 10
       <el-tab-pane label="基础数据" name="first">
@@ -471,6 +472,18 @@
471 472
           }
472 473
         })
473 474
       },
475
+      _close: function(done) {
476
+        // this.clear()
477
+        // done()
478
+        this.$confirm('是否保存')
479
+          .then(_ => {
480
+            this.comfirm('form')
481
+            // done();
482
+          })
483
+          .catch(_ => {
484
+            done()
485
+          });
486
+      },
474 487
       getValue: function() {
475 488
         
476 489
         const form = {}

+ 1 - 1
src/xt_pages/upload/fast/One.vue Прегледај датотеку

@@ -5,7 +5,7 @@
5 5
       <div class="information">
6 6
         <div class="row">
7 7
           <div class="rowOne">
8
-            <p class="rowName">首次诊治时间:</p>
8
+            <p class="rowName">首次透析时间:</p>
9 9
             <el-input
10 10
               placeholder="请输入内容"
11 11
               v-model="form.first_treatment_date"

+ 1 - 1
src/xt_pages/user/components/PatientForm.vue Прегледај датотеку

@@ -785,7 +785,7 @@
785 785
             </el-col>
786 786
 
787 787
             <el-col :span="6" :style="isEdit ? 'width:360px' : ''">
788
-              <el-form-item label="首次诊治时间 : ">
788
+              <el-form-item label="首次透析时间 : ">
789 789
                 <el-date-picker
790 790
                   v-model="form.first_treatment_date"
791 791
                   type="date"

+ 18 - 2
src/xt_pages/user/components/PatientSidebar.vue Прегледај датотеку

@@ -188,8 +188,24 @@ export default {
188 188
     },
189 189
     changePatient(value) {
190 190
       console.log(value)
191
-
192
-      this.$router.push('/patients/patient/' + value)
191
+      if(this.$route.path.indexOf('edit') > -1){
192
+        this.$confirm('是否保存当前病历', '保存', {
193
+          confirmButtonText: '确 定',
194
+          cancelButtonText: '取 消',
195
+          type: 'warning'
196
+        }).then(() => {
197
+            this.$emit('updateInfo')
198
+            setTimeout(() => {
199
+              this.$router.push('/patients/patient/' + value)
200
+            },1000)
201
+        }).catch(() => {
202
+          this.$router.push('/patients/patient/' + value)
203
+        })
204
+      }else{
205
+        this.$router.push('/patients/patient/' + value)
206
+      }
207
+      
208
+      
193 209
     },
194 210
     getList() {
195 211
       fetchAllList().then(response => {

+ 8 - 2
src/xt_pages/user/editPatient.vue Прегледај датотеку

@@ -1,8 +1,8 @@
1 1
 
2 2
 <template>
3 3
   <div class="patient-container">
4
-  <patient-sidebar :id="patientID"></patient-sidebar>
5
-  <patient-form :is-edit='true' :class='panelClass' v-on:tran-patient-info="patientInfo=$event"></patient-form>
4
+  <patient-sidebar :id="patientID" @updateInfo="submit"></patient-sidebar>
5
+  <patient-form :is-edit='true' :class='panelClass' ref="patientForm" v-on:tran-patient-info="patientInfo=$event"></patient-form>
6 6
   </div>
7 7
 </template>
8 8
 
@@ -33,6 +33,12 @@ export default {
33 33
           });
34 34
           this.$router.push('/patients/patients');
35 35
       }
36
+  },
37
+  methods:{
38
+    submit(){
39
+      this.$refs.patientForm.onSubmit('form')
40
+    }
41
+    
36 42
   }
37 43
 
38 44
 }