2 Ревизии 9ff827f418 ... 79e9f160fc

Автор SHA1 Съобщение Дата
  陈少旭 79e9f160fc Merge branch '20230223_pc_vue_new_branch' of http://git.shengws.com/csx/Vue_New into 20230223_pc_vue_new_branch преди 1 седмица
  陈少旭 2d9c15533a 1111 преди 1 седмица
променени са 2 файла, в които са добавени 82 реда и са изтрити 7 реда
  1. 73 2
      src/xt_pages/eleFaPiao/settleDetail.vue
  2. 9 5
      src/xt_pages/hospitalStation/batchStatementTemplate/hospitalBatchPrint.vue

+ 73 - 2
src/xt_pages/eleFaPiao/settleDetail.vue Целия файл

@@ -61,11 +61,19 @@
61 61
         <el-button v-if="$store.getters.xt_user.org_id != 10318"  size="small" type="primary"
62 62
                    @click="auth">认证
63 63
         </el-button>
64
+
65
+        <el-button v-if="$store.getters.xt_user.org_id == 10318 || $store.getters.xt_user.org_id == 0"  size="small" type="primary"
66
+                   @click="batchOpen">批量开票
67
+        </el-button>
64 68
       </div>
65 69
 
66 70
       <el-table
67 71
         :data="tableData"
68 72
         border
73
+        v-loading="isbatchloading"
74
+        @select="selectCostInfo"
75
+        @selection-change="changeCostInfoTableData"
76
+        @select-all="changeAllCostInfoTableData"
69 77
         style="width: 100%"
70 78
         :row-style="{ color: '#303133' }"
71 79
         :header-cell-style="{
@@ -74,6 +82,8 @@
74 82
         }"
75 83
         highlight-current-row
76 84
       >
85
+        <el-table-column align="center" type="selection" width="55"></el-table-column>
86
+
77 87
         <el-table-column
78 88
           prop="date"
79 89
           label="序号"
@@ -374,6 +384,7 @@ export default {
374 384
         { path: false, name: '项目消费明细汇总' }
375 385
       ],
376 386
       tableData: [],
387
+      isbatchloading:false,
377 388
       tableData2:[],
378 389
       selecting_schs: [],
379 390
       dialogfapiaoVisible:false,
@@ -418,6 +429,7 @@ export default {
418 429
         verify:[{ required: true, message: '请输入活动名称', trigger: 'blur' },]
419 430
       },
420 431
       time:null,
432
+      selection:[],
421 433
       countdown: 0,
422 434
 
423 435
     }
@@ -432,6 +444,14 @@ export default {
432 444
   },
433 445
 
434 446
   methods: {
447
+    selectCostInfo(selection, row) {
448
+      this.selection = selection
449
+    },
450
+    changeCostInfoTableData(val) {
451
+      this.selection = val
452
+    }, changeAllCostInfoTableData(selection) {
453
+      this.selection = selection
454
+    },
435 455
     searchAction(){
436 456
 
437 457
       this.getHisOrderList()
@@ -822,7 +842,7 @@ export default {
822 842
       }
823 843
 
824 844
       var that = this;
825
-      axios.get('http://127.0.0.1:9532/api/bwfapiao/red',{params:params}).then(function(response) {
845
+      axios.get('http://127.0.0.1:9531/api/bwfapiao/red',{params:params}).then(function(response) {
826 846
         if (response.data.state == 0) {
827 847
           that.red_loading = false
828 848
 
@@ -996,8 +1016,59 @@ export default {
996 1016
         });
997 1017
 
998 1018
 
999
-    },
1019
+    },batchOpen(){
1020
+      let ids  = ""
1021
+      for (var i = 0; i < this.selection.length; i++){
1022
+        if (ids.length == 0){
1023
+          ids = this.selection[i].id
1024
+        }else{
1025
+          ids = ids + "," + this.selection[i].id
1026
+        }
1027
+      }
1028
+      if(ids.length == 0 ){
1029
+        this.$message.error("请勾选需要开票的数据");
1030
+        return
1031
+      }
1032
+      let params = {
1033
+        id: ids,
1034
+        admin_user_id: this.$store.getters.xt_user.user.id,
1035
+      };
1036
+      var that = this;
1037
+      that.isbatchloading = true
1038
+
1039
+      axios.get('http://127.0.0.1:9531/api/bwfapiao/batchopen',{params:params}).then(function(response) {
1040
+        if (response.data.state == 0) {
1041
+          this.isbatchloading = false
1042
+
1043
+          that.$message.error(response.data.data.msg);
1044
+          return false
1045
+        } else {
1046
+          that.isbatchloading = false
1047
+          if(response.data.data.failed_code == -10){
1048
+            that.$confirm(response.data.data.msg, '错误信息', {
1049
+              confirmButtonText: '确 定',
1050
+              type: 'warning'
1051
+            }).then(() => {
1052
+
1053
+            }).catch(() => {
1054
+            })
1055
+          }else{
1056
+            that.$confirm(response.data.data.msg, '上传信息', {
1057
+              confirmButtonText: '确 定',
1058
+              type: 'warning'
1059
+            }).then(() => {
1060
+              // that.$message.success( response.data.data.msg)
1061
+              that.getHisOrderList()
1062
+            }).catch(() => {
1063
+              that.getHisOrderList()
1064
+            })
1065
+          }
1066
+        }
1067
+      }).catch(function(error) {
1068
+        that.isbatchloading = false
1000 1069
 
1070
+      })
1071
+    },
1001 1072
     handleSelectionChange(val) {
1002 1073
       this.selecting_schs = val
1003 1074
     },

+ 9 - 5
src/xt_pages/hospitalStation/batchStatementTemplate/hospitalBatchPrint.vue Целия файл

@@ -87,16 +87,20 @@
87 87
         <td>住院号</td>
88 88
         <td>{{info.number}}</td>
89 89
         <td>科别</td>
90
-        <td width="100"></td>
90
+        <td width="100">血透室</td>
91 91
         <td>床号</td>
92 92
         <td></td>
93 93
         <td>入院日期</td>
94
-        <td>{{info.his.in_hosptial_time.split(" ")[0]}}</td>
94
+        <td v-if="$store.getters.xt_user.org_id == 10215">{{info.his.in_hosptial_time.split(" ")[0]}}</td>
95
+        <td v-if="$store.getters.xt_user.org_id != 10215">{{info.order.setl_time.split(" ")[0]}}</td>
96
+
95 97
         <td>出院日期</td>
96
-        <td width="100">{{info.his.out_hosptial_time.split(" ")[0]}}</td>
97
-        <td>住院天数</td>
98
-        <td>{{getDay(info.his.in_hosptial_time.split(" ")[0],info.his.out_hosptial_time.split(" ")[0])}}</td>
98
+        <td width="100" v-if="$store.getters.xt_user.org_id == 10215">{{info.his.out_hosptial_time.split(" ")[0]}}</td>
99
+        <td v-if="$store.getters.xt_user.org_id != 10215">{{info.order.setl_time.split(" ")[0]}}</td>
99 100
 
101
+        <td>住院天数</td>
102
+        <td v-if="$store.getters.xt_user.org_id == 10215">{{getDay(info.his.in_hosptial_time.split(" ")[0],info.his.out_hosptial_time.split(" ")[0])}}</td>
103
+        <td v-if="$store.getters.xt_user.org_id != 10215">{{getDay(info.order.setl_time.split(" ")[0],info.order.setl_time.split(" ")[0])}}</td>
100 104
       </tr>
101 105
       <tr>
102 106
         <td>险种</td>