huangyw 2 年 前
コミット
d4434089bf

+ 1 - 1
src/store/getters.js ファイルの表示

19
   configlist: state => state.data.configlist,
19
   configlist: state => state.data.configlist,
20
 
20
 
21
   dictionary_configlist: state => state.data.dictionary_configlist,
21
   dictionary_configlist: state => state.data.dictionary_configlist,
22
-
22
+  pagedata:state => state.pagedata,
23
 
23
 
24
   xt_permission: state => state.xt_permission,
24
   xt_permission: state => state.xt_permission,
25
   xt_user: state => state.xt_user,
25
   xt_user: state => state.xt_user,

+ 8 - 1
src/store/index.js ファイルの表示

14
 import data from './modules/data'
14
 import data from './modules/data'
15
 import temp_params from './modules/temp_params'
15
 import temp_params from './modules/temp_params'
16
 
16
 
17
+import pagedata from './modules/pagedata'
18
+
17
 Vue.use(Vuex)
19
 Vue.use(Vuex)
18
 
20
 
19
 const store = new Vuex.Store({
21
 const store = new Vuex.Store({
22
+
23
+  mutations:{
24
+  },
20
   modules: {
25
   modules: {
21
     app,
26
     app,
22
     errorLog,
27
     errorLog,
28
     xt_permission,
33
     xt_permission,
29
     xt_role_temps,
34
     xt_role_temps,
30
     global_config,
35
     global_config,
31
-    temp_params
36
+    temp_params,
37
+    pagedata
32
   },
38
   },
33
   getters
39
   getters
40
+
34
 })
41
 })
35
 
42
 
36
 // store.dispatch("InitAdminUserInfo")
43
 // store.dispatch("InitAdminUserInfo")

+ 39 - 0
src/store/modules/pagedata.js ファイルの表示

1
+
2
+const pagedata = {
3
+    state: {
4
+        list:{
5
+        limit: 10,
6
+        page: 1,
7
+        keywords: '',
8
+        start_time: '',
9
+        end_time: '',
10
+        type: '',
11
+        p_type: 2,
12
+        sort_type: '' ,
13
+        patient_id:0
14
+        },
15
+        pagestate:""
16
+        
17
+        
18
+    },
19
+
20
+    mutations: {
21
+        SET_PAGEDATA: (state, pagedata) => {
22
+            state.list = pagedata
23
+            console.log(pagedata,'store里面的pagedata')
24
+        },
25
+        SET_PAGENAME: (state, pagedata) => {
26
+            state.pagestate = pagedata
27
+            console.log(state,'store里面的pagestate')
28
+        },
29
+    },
30
+
31
+    actions: {
32
+        UPDATE_PAGEDATA({commit},param ){
33
+            commit('SET_PAGEDATA',param)
34
+        }
35
+
36
+    }
37
+}
38
+
39
+export default pagedata

+ 4 - 1
src/xt_pages/DepositManagement/DeductionDetailsSummary.vue ファイルの表示

105
   },
105
   },
106
 };
106
 };
107
 </script>
107
 </script>
108
-<style>
108
+<style lang="scss" scoped>
109
+/deep/ .el-tabs__header{
110
+margin: 0 0 -15px;
111
+}
109
 </style>
112
 </style>

+ 11 - 1
src/xt_pages/DepositManagement/DepositRefund.vue ファイルの表示

13
               新增
13
               新增
14
             </el-button>
14
             </el-button>
15
             <el-button size="small" type="primary" @click="pass_exam">
15
             <el-button size="small" type="primary" @click="pass_exam">
16
-              审核通过
16
+              批量审核
17
             </el-button>
17
             </el-button>
18
             <el-button size="small" type="warning" @click="reject_exam">
18
             <el-button size="small" type="warning" @click="reject_exam">
19
               审核拒绝
19
               审核拒绝
144
           </el-table-column>
144
           </el-table-column>
145
           <el-table-column label="操作" align="center" width="350px">
145
           <el-table-column label="操作" align="center" width="350px">
146
             <template slot-scope="scope">
146
             <template slot-scope="scope">
147
+              <el-button
148
+                size="small"
149
+                type="primary"
150
+                @click="examine(scope.row, scope.row.$index)"
151
+              >审核
152
+              </el-button>
147
               <el-button
153
               <el-button
148
                 size="small"
154
                 size="small"
149
                 type="primary"
155
                 type="primary"
270
         this.search()
276
         this.search()
271
       })
277
       })
272
     },
278
     },
279
+
280
+    examine(){
281
+
282
+    },
273
     updaterefundtype(){
283
     updaterefundtype(){
274
       console.log("refundtype",this.refundtype)
284
       console.log("refundtype",this.refundtype)
275
     },
285
     },

+ 4 - 1
src/xt_pages/DepositManagement/RechargeDetailsSummary.vue ファイルの表示

138
   },
138
   },
139
 };
139
 };
140
 </script>
140
 </script>
141
-<style>
141
+<style lang="scss" scoped>
142
+/deep/ .el-tabs__header{
143
+margin: 0 0 -15px;
144
+}
142
 </style>
145
 </style>

+ 2 - 1
src/xt_pages/DepositManagement/Template/RechargeDetails.vue ファイルの表示

256
   },
256
   },
257
 };
257
 };
258
 </script>
258
 </script>
259
-<style>
259
+<style lang="scss" scoped>
260
+
260
 </style>
261
 </style>

+ 3 - 3
src/xt_pages/hospitalStation/invoiceTemplate/printThree.vue ファイルの表示

29
           <div  style="position: absolute;left:650px;top:70px;" v-if="insutype == '310'">
29
           <div  style="position: absolute;left:650px;top:70px;" v-if="insutype == '310'">
30
             类别:职工基本医疗保险
30
             类别:职工基本医疗保险
31
           </div>
31
           </div>
32
-          <div  style="position: absolute;left:650px;top:70px;" v-else>
32
+          <div  style="position: absolute;left:400px;top:70px;" v-else>
33
             类别:
33
             类别:
34
           </div>
34
           </div>
35
         </div>
35
         </div>
156
                 </span>
156
                 </span>
157
                 <span v-else>零分</span>
157
                 <span v-else>零分</span>
158
             </span> -->
158
             </span> -->
159
-            <span style="position: absolute;top:280px;left:190px;letter-spacing: 20px;">{{zhongwen}}</span>
159
+            <span style="position: absolute;top:280px;left:170px;letter-spacing: 15px;">{{zhongwen}}</span>
160
             </span>
160
             </span>
161
-            <span style="position: absolute;top:280px;left:510px">合计:{{ list.order.medfee_sumamt }}</span>
161
+            <span style="position: absolute;top:280px;left:615px">合计:{{ list.order.medfee_sumamt }}</span>
162
         </div>
162
         </div>
163
 
163
 
164
 
164
 

+ 9 - 1
src/xt_pages/outpatientCharges/components/chargeDialog.vue ファイルの表示

38
         <el-form-item class="specialFormItem" >
38
         <el-form-item class="specialFormItem" >
39
           <div style="display:flex;">
39
           <div style="display:flex;">
40
 <!--            这里不要改成el-input,因为使用el-input会导致一个奇怪的bug,千万不要改!!!!!!!!!!!!!!!!!!!!-->
40
 <!--            这里不要改成el-input,因为使用el-input会导致一个奇怪的bug,千万不要改!!!!!!!!!!!!!!!!!!!!-->
41
-            <input style="" v-model="form.tmp_decimal"  onkeyup="this.value = this.value.replace(/[^\d.]/g,'');" @input="lilili"></input>元
41
+            <input  class="input_style" v-model="form.tmp_decimal"  onkeyup="this.value = this.value.replace(/[^\d.]/g,'');" @input="lilili"></input>元
42
           </div>
42
           </div>
43
         </el-form-item>
43
         </el-form-item>
44
         </span>
44
         </span>
379
     width:50%;
379
     width:50%;
380
   }
380
   }
381
 }
381
 }
382
+.input_style {
383
+  border-radius: 5px;
384
+  border: 1px solid #dddddd;
385
+}
386
+.input_style:focus {
387
+outline:none;
388
+border: 1px solid #66b1ff;
389
+}
382
 </style>
390
 </style>

+ 383 - 242
src/xt_pages/outpatientTool/components/detailStatistics.vue ファイルの表示

1
 <template>
1
 <template>
2
   <div>
2
   <div>
3
-    <div style="display: flex;justify-content: space-between;margin-bottom:10px;">
3
+    <div
4
+      style="display: flex; justify-content: space-between; margin-bottom: 10px"
5
+    >
4
       <div>
6
       <div>
5
-        <el-select size="small" v-model="item_type" placeholder="请选择"
6
-                   style="width:150px;margin-left:10px;" @change="changeItem">
7
-          <el-option
8
-              label="全部"
9
-              value="0">
10
-          </el-option>
7
+        <el-select
8
+          size="small"
9
+          v-model="item_type"
10
+          placeholder="请选择"
11
+          style="width: 150px; margin-left: 10px"
12
+          @change="changeItem"
13
+        >
14
+          <el-option label="全部" value=0> </el-option>
11
           <el-option
15
           <el-option
12
-              v-for="(item,index) in items"
13
-              :key="index"
14
-              :label="item.name"
15
-              :value="item.id">
16
+            v-for="(item, index) in items"
17
+            :key="index"
18
+            :label="item.name"
19
+            :value="item.id"
20
+          >
16
           </el-option>
21
           </el-option>
17
         </el-select>
22
         </el-select>
18
 
23
 
29
           class="filter-item"
34
           class="filter-item"
30
           type="primary"
35
           type="primary"
31
           @click="searchAction"
36
           @click="searchAction"
32
-        >搜索
37
+          >搜索
33
         </el-button>
38
         </el-button>
34
         <el-date-picker
39
         <el-date-picker
35
-            v-model="chargeDate"
36
-            type="daterange"
37
-            value-format="yyyy-MM-dd"
38
-            range-separator="至"
39
-            start-placeholder="开始日期"
40
-            @change="changeDate"
41
-            end-placeholder="结束日期">
40
+          v-model="chargeDate"
41
+          type="daterange"
42
+          value-format="yyyy-MM-dd"
43
+          range-separator="至"
44
+          start-placeholder="开始日期"
45
+          @change="changeDate"
46
+          end-placeholder="结束日期"
47
+        >
42
         </el-date-picker>
48
         </el-date-picker>
43
-        <el-button  type="primary" size="small" @click="toPrint">打印</el-button>
44
-      </div>
45
-      <div>
49
+        <el-button type="primary" size="small" @click="toPrint">打印</el-button>
46
       </div>
50
       </div>
51
+      <div></div>
47
     </div>
52
     </div>
48
-    <el-table :data="tableData" border :row-style="{ color: '#303133' }" ref="table"
49
-              :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}"
50
-              max-height="600"
51
-              show-summary
52
-              v-loading="detail_loading"
53
-              highlight-current-row>
53
+    <el-table
54
+      :data="tableData"
55
+      border
56
+      :row-style="{ color: '#303133' }"
57
+      ref="table"
58
+      :header-cell-style="{
59
+        backgroundColor: 'rgb(245, 247, 250)',
60
+        color: '#606266',
61
+      }"
62
+      max-height="600"
63
+      show-summary
64
+      v-loading="detail_loading"
65
+      highlight-current-row
66
+    >
54
       <el-table-column type="index" label="序号" width="60px" align="center">
67
       <el-table-column type="index" label="序号" width="60px" align="center">
55
         <template slot-scope="scope">
68
         <template slot-scope="scope">
56
-          {{scope.row.index}}
69
+          {{ scope.row.index }}
57
         </template>
70
         </template>
58
       </el-table-column>
71
       </el-table-column>
59
       <el-table-column align="center" label="处方日期">
72
       <el-table-column align="center" label="处方日期">
60
-        <template slot-scope="scope">{{getTime(scope.row.record_date)}}</template>
73
+        <template slot-scope="scope">{{
74
+          getTime(scope.row.record_date)
75
+        }}</template>
61
       </el-table-column>
76
       </el-table-column>
62
       <el-table-column align="center" label="费用编码">
77
       <el-table-column align="center" label="费用编码">
63
         <template slot-scope="scope">
78
         <template slot-scope="scope">
64
-          {{scope.row.number}}
79
+          {{ scope.row.number }}
65
         </template>
80
         </template>
66
       </el-table-column>
81
       </el-table-column>
67
       <el-table-column align="center" label="项目名称">
82
       <el-table-column align="center" label="项目名称">
68
         <template slot-scope="scope">
83
         <template slot-scope="scope">
69
-          <span v-if="scope.row.advice_id > 0">{{scope.row.advice.advice_name}}</span>
84
+          <span v-if="scope.row.advice_id > 0">{{
85
+            scope.row.advice.advice_name
86
+          }}</span>
70
           <span v-if="scope.row.project_id > 0">
87
           <span v-if="scope.row.project_id > 0">
71
-            <span v-if="scope.row.project.type == 2">{{scope.row.project.project.project_name}}</span>
72
-            <span v-if="scope.row.project.type == 3">{{scope.row.project.good_info.good_name}}</span>
88
+            <span v-if="scope.row.project.type == 2">{{
89
+              scope.row.project.project.project_name
90
+            }}</span>
91
+            <span v-if="scope.row.project.type == 3">{{
92
+              scope.row.project.good_info.good_name
93
+            }}</span>
73
           </span>
94
           </span>
74
         </template>
95
         </template>
75
       </el-table-column>
96
       </el-table-column>
76
       <el-table-column align="center" label="规格">
97
       <el-table-column align="center" label="规格">
77
         <template slot-scope="scope">
98
         <template slot-scope="scope">
78
-          <span v-if="scope.row.advice_id > 0">{{scope.row.advice.drug.dose}}{{scope.row.advice.drug.dose_unit}}*{{scope.row.advice.drug.min_number}}{{scope.row.advice.drug.min_unit}}/{{scope.row.advice.drug.max_unit}}</span>
99
+          <span v-if="scope.row.advice_id > 0"
100
+            >{{ scope.row.advice.drug.dose
101
+            }}{{ scope.row.advice.drug.dose_unit }}*{{
102
+              scope.row.advice.drug.min_number
103
+            }}{{ scope.row.advice.drug.min_unit }}/{{
104
+              scope.row.advice.drug.max_unit
105
+            }}</span
106
+          >
79
           <span v-if="scope.row.project_id > 0">
107
           <span v-if="scope.row.project_id > 0">
80
-            <span v-if="scope.row.project.type == 2">{{scope.row.project.project.project_name}}</span>
81
-            <span v-if="scope.row.project.type == 3">{{scope.row.project.good_info.specification_name}}</span>
108
+            <span v-if="scope.row.project.type == 2">{{
109
+              scope.row.project.project.project_name
110
+            }}</span>
111
+            <span v-if="scope.row.project.type == 3">{{
112
+              scope.row.project.good_info.specification_name
113
+            }}</span>
82
           </span>
114
           </span>
83
         </template>
115
         </template>
84
       </el-table-column>
116
       </el-table-column>
85
-      <el-table-column align="center"  label="数量">
117
+      <el-table-column align="center" label="数量">
86
         <template slot-scope="scope">
118
         <template slot-scope="scope">
87
-          {{scope.row.cnt}}
119
+          {{ scope.row.cnt }}
88
         </template>
120
         </template>
89
       </el-table-column>
121
       </el-table-column>
90
       <el-table-column align="center" label="单位">
122
       <el-table-column align="center" label="单位">
91
         <template slot-scope="scope">
123
         <template slot-scope="scope">
92
-          <span v-if="scope.row.advice_id > 0">{{scope.row.advice.prescribing_number_unit}}</span>
124
+          <span v-if="scope.row.advice_id > 0">{{
125
+            scope.row.advice.prescribing_number_unit
126
+          }}</span>
93
           <span v-if="scope.row.project_id > 0">
127
           <span v-if="scope.row.project_id > 0">
94
-            <span v-if="scope.row.project.type == 2">{{scope.row.project.project.unit}}</span>
95
-            <span v-if="scope.row.project.type == 3">{{scope.row.project.good_info.packing_unit}}</span>
128
+            <span v-if="scope.row.project.type == 2">{{
129
+              scope.row.project.project.unit
130
+            }}</span>
131
+            <span v-if="scope.row.project.type == 3">{{
132
+              scope.row.project.good_info.packing_unit
133
+            }}</span>
96
           </span>
134
           </span>
97
         </template>
135
         </template>
98
       </el-table-column>
136
       </el-table-column>
99
       <el-table-column align="center" label="单价">
137
       <el-table-column align="center" label="单价">
100
         <template slot-scope="scope">
138
         <template slot-scope="scope">
101
-          {{scope.row.pric}}
139
+          {{ scope.row.pric }}
102
         </template>
140
         </template>
103
       </el-table-column>
141
       </el-table-column>
104
       <el-table-column align="center" label="金额" prop="total_price">
142
       <el-table-column align="center" label="金额" prop="total_price">
105
         <template slot-scope="scope">
143
         <template slot-scope="scope">
106
           <div>
144
           <div>
107
-            {{scope.row.total_price}}
145
+            {{ scope.row.total_price }}
108
           </div>
146
           </div>
109
         </template>
147
         </template>
110
       </el-table-column>
148
       </el-table-column>
111
       <el-table-column align="center" prop="name" label="备注">
149
       <el-table-column align="center" prop="name" label="备注">
112
         <template slot-scope="scope">
150
         <template slot-scope="scope">
113
           <div>
151
           <div>
114
-            <span v-if="scope.row.advice_id > 0">{{scope.row.advice.remark}}</span>
152
+            <span v-if="scope.row.advice_id > 0">{{
153
+              scope.row.advice.remark
154
+            }}</span>
115
             <span v-if="scope.row.project_id > 0">
155
             <span v-if="scope.row.project_id > 0">
116
-              <span v-if="scope.row.project.type == 2">{{scope.row.project.remark}}</span>
117
-              <span v-if="scope.row.project.type == 3">{{scope.row.project.remark}}</span>
156
+              <span v-if="scope.row.project.type == 2">{{
157
+                scope.row.project.remark
158
+              }}</span>
159
+              <span v-if="scope.row.project.type == 3">{{
160
+                scope.row.project.remark
161
+              }}</span>
118
             </span>
162
             </span>
119
           </div>
163
           </div>
120
         </template>
164
         </template>
121
       </el-table-column>
165
       </el-table-column>
122
-     
123
     </el-table>
166
     </el-table>
124
-    <div style="display:flex;justify-content: space-around;margin-top: 25px;">
125
-      <div>总费用:{{getAllPice()}}</div>
126
-     <div>个人支付:
127
-        <span v-if="his_record_patient.balance_accounts_type == 2">{{getAllPice()}}</span>
128
-        <span v-if="his_record_patient.balance_accounts_type != 2">{{getActPay()}}</span>
129
-    </div>
130
-     <div>基金支付记账:{{getFundPaySumamt()}}</div>
131
-     <div>补充医疗支付记账:{{getHifesPay()}}</div>
132
-    <div>救助支付金额:{{getMafPay()}}</div>
167
+    <div style="display: flex; justify-content: space-around; margin-top: 25px">
168
+      <div>总费用:{{ getAllPice() }}</div>
169
+      <div>
170
+        个人支付: <span v-if="his_patient.balance_accounts_type == 2"></span>
171
+        {{ getAllPice() }}
172
+        <span v-if="his_patient.balance_accounts_type != 2"></span>
173
+        {{ getActPay() }}
174
+      </div>
175
+      <div>基金支付记账:{{ getFundPaySumamt() }}</div>
176
+      <div>补充医疗支付记账:{{ getHifesPay() }}</div>
177
+      <div>救助支付金额:{{ getMafPay() }}</div>
133
     </div>
178
     </div>
134
-    
135
   </div>
179
   </div>
136
 
180
 
137
   <!-- </div> -->
181
   <!-- </div> -->
139
 
183
 
140
 
184
 
141
 <script>
185
 <script>
142
-import BreadCrumb from '@/xt_pages/components/bread-crumb'
143
-import { getHisSummaryDetailList } from '@/api/his/his_tools'
144
-const moment = require('moment')
145
-import { uParseTime } from '@/utils/tools'
186
+import BreadCrumb from "@/xt_pages/components/bread-crumb";
187
+import { getHisSummaryDetailList } from "@/api/his/his_tools";
188
+const moment = require("moment");
189
+import { uParseTime } from "@/utils/tools";
146
 export default {
190
 export default {
147
   components: {
191
   components: {
148
-    BreadCrumb
149
-
192
+    BreadCrumb,
150
   },
193
   },
151
   props: {
194
   props: {
152
     patient_id: {
195
     patient_id: {
153
       type: Number,
196
       type: Number,
154
-      default: 0
155
-    }
197
+      default: 0,
198
+    },
156
   },
199
   },
157
 
200
 
158
   data() {
201
   data() {
159
-
160
     return {
202
     return {
161
       detail_loading: false,
203
       detail_loading: false,
162
       tempArr: [],
204
       tempArr: [],
163
       pos: 0,
205
       pos: 0,
164
-      search_input: '',
206
+      search_input: "",
165
 
207
 
166
       sameRowArr: [],
208
       sameRowArr: [],
167
-      keywords: '',
209
+      keywords: "",
168
       tableData: [],
210
       tableData: [],
169
-      chargeDate: [moment(new Date()).add('year', 0).format('YYYY-MM-DD'), moment(new Date()).add('year', 0).format('YYYY-MM-DD')],
170
-      item_type: '0',
211
+      chargeDate: [
212
+        moment(new Date()).add("year", 0).format("YYYY-MM-DD"),
213
+        moment(new Date()).add("year", 0).format("YYYY-MM-DD"),
214
+      ],
215
+      item_type: "0",
171
       items: [
216
       items: [
172
-        { id: 1, name: '药品' },
173
-        { id: 2, name: '项目' },
174
-        { id: 3, name: '耗材' },
175
-
217
+        { id: 1, name: "药品" },
218
+        { id: 2, name: "项目" },
219
+        { id: 3, name: "耗材" },
176
       ],
220
       ],
177
-      list:[],
178
-      his_patient:{},
179
-      id:0,
180
-      start_time:"",
181
-      end_time:"",
182
-      his_record_patient:{},
183
-      orderList:[],
184
-    }
221
+      list: [],
222
+      his_patient: {},
223
+      id: 0,
224
+      start_time: "",
225
+      end_time: "",
226
+    };
185
   },
227
   },
186
   methods: {
228
   methods: {
187
     getTime(val) {
229
     getTime(val) {
188
-      if(val <= 0){
189
-        return ""
230
+      if (val <= 0) {
231
+        return "";
232
+      }
233
+      if (val == "") {
234
+        return "";
235
+      } else {
236
+        return uParseTime(val, "{y}-{m}-{d}");
190
       }
237
       }
191
-      if(val == ""){
192
-      return ""
193
-      }else {
194
-      return uParseTime(val, '{y}-{m}-{d}')
238
+    },
239
+    searchAction() {
240
+      let table_id = this.$store.getters.pagedata.list.table_id;
241
+      if (table_id == undefined) {
242
+        this.$store.commit("SET_PAGEDATA", {
243
+          table_id: 0,
244
+          type_id: this.id,
245
+          keywords: this.keywords,
246
+          start_time: this.chargeDate[0],
247
+          end_time: this.chargeDate[1],
248
+          patient_id: this.patient_id,
249
+        });
250
+      } else {
251
+        this.$store.commit("SET_PAGEDATA", {
252
+          table_id: table_id,
253
+          type_id: this.id,
254
+          keywords: this.keywords,
255
+          start_time: this.chargeDate[0],
256
+          end_time: this.chargeDate[1],
257
+          patient_id: this.patient_id,
258
+        });
195
       }
259
       }
196
-     },
197
-    searchAction(){
198
-     this.getHisSummaryDetailList()
260
+      this.getHisSummaryDetailList();
199
     },
261
     },
200
     changeDate() {
262
     changeDate() {
201
-      this.start_time = this.chargeDate[0]
202
-      this.end_time = this.chargeDate[1]
203
-      this.getHisSummaryDetailList()
263
+      this.start_time = this.chargeDate[0];
264
+      this.end_time = this.chargeDate[1];
265
+      this.getHisSummaryDetailList();
204
     },
266
     },
205
     changeItem(id) {
267
     changeItem(id) {
206
-      this.id = id
207
-      this.getHisSummaryDetailList()
208
- 
268
+      this.id = id;
269
+      let table_id = this.$store.getters.pagedata.list.table_id;
270
+      if (table_id == undefined) {
271
+        this.$store.commit("SET_PAGEDATA", {
272
+          table_id: 0,
273
+          type_id: this.id,
274
+          keywords: this.keywords,
275
+          start_time: this.chargeDate[0],
276
+          end_time: this.chargeDate[1],
277
+          patient_id: this.patient_id,
278
+        });
279
+      } else {
280
+        this.$store.commit("SET_PAGEDATA", {
281
+          table_id: table_id,
282
+          type_id: this.id,
283
+          keywords: this.keywords,
284
+          start_time: this.chargeDate[0],
285
+          end_time: this.chargeDate[1],
286
+          patient_id: this.patient_id,
287
+        });
288
+      }
289
+      this.getHisSummaryDetailList();
209
     },
290
     },
210
     getHisSummaryDetailList() {
291
     getHisSummaryDetailList() {
211
-      let start_time = this.chargeDate[0]
212
-      let end_time = this.chargeDate[1]
213
-      
292
+      let start_time = this.chargeDate[0];
293
+      let end_time = this.chargeDate[1];
214
       let params = {
294
       let params = {
215
-        patient_id:this.patient_id,
295
+        patient_id: this.patient_id,
216
         start_time: start_time,
296
         start_time: start_time,
217
         end_time: end_time,
297
         end_time: end_time,
218
         type: this.item_type,
298
         type: this.item_type,
219
-        keyword: this.keywords
220
-      }
221
-     getHisSummaryDetailList(params).then(response=>{
222
-       if(response.data.state == 1){
223
-          var list =  response.data.data.list
224
-          this.his_patient = response.data.data.his_patient
225
-          this.his_record_patient = response.data.data.his_record_patient
226
-          console.log("his_record_patient",this.his_record_patient)
227
-
228
-          this.orderList = response.data.data.orderList
229
-          console.log("orderlist2332322333232323232",this.orderList)
230
-          this.list = list
231
-          this.tableData = []
232
-          for(let i=0;i<list.length;i++){
233
-            for(let j=0;j<list[i].orders.length;j++){
234
-              for(let z=0;z<list[i].orders[j].order_info.length;z++){
235
-                  list[i].orders[j].order_info[z].record_date = list[i].orders[j].settle_accounts_date
236
-                  list[i].orders[j].order_info[z].number = list[i].orders[j].number
237
-                  this.tableData.push(list[i].orders[j].order_info[z])
238
-               }
299
+        keyword: this.keywords,
300
+      };
301
+      getHisSummaryDetailList(params).then((response) => {
302
+        if (response.data.state == 1) {
303
+          var list = response.data.data.list;
304
+          this.his_patient = response.data.data.his_patient;
305
+          this.list = list;
306
+          this.tableData = [];
307
+          for (let i = 0; i < list.length; i++) {
308
+            for (let j = 0; j < list[i].orders.length; j++) {
309
+              for (let z = 0; z < list[i].orders[j].order_info.length; z++) {
310
+                list[i].orders[j].order_info[z].record_date =
311
+                  list[i].orders[j].settle_accounts_date;
312
+                list[i].orders[j].order_info[z].number =
313
+                  list[i].orders[j].number;
314
+                this.tableData.push(list[i].orders[j].order_info[z]);
315
+              }
239
             }
316
             }
240
           }
317
           }
241
-          var obj = {index:"合计",total_price:0,record_date:"0"}
242
-          for(let i=0;i<this.tableData.length;i++){
243
-            this.tableData[i].index = i+1
244
-            this.tableData[i].total_price = 0
245
-            this.tableData[i].total_price = (this.tableData[i].cnt * this.tableData[i].pric).toFixed(2)
246
-            obj.total_price += (this.tableData[i].cnt * this.tableData[i].pric)  
318
+
319
+          var obj = { index: "合计", total_price: 0, record_date: "0" };
320
+          for (let i = 0; i < this.tableData.length; i++) {
321
+            this.tableData[i].index = i + 1;
322
+            this.tableData[i].total_price = 0;
323
+            this.tableData[i].total_price = (
324
+              this.tableData[i].cnt * this.tableData[i].pric
325
+            ).toFixed(2);
326
+            obj.total_price += this.tableData[i].cnt * this.tableData[i].pric;
247
           }
327
           }
248
-          obj.total_price = (obj.total_price).toFixed(2)
249
-          
250
-          var new_arr = []
251
-           
252
-        
253
-          if(this.keywords!=""){
254
-            for(let i=0;i<this.tableData.length;i++){
255
-              if(this.tableData[i].index!="合计"){
256
-                if(this.tableData[i].advice_id > 0){
257
-                  if(this.tableData[i].advice.advice_name.indexOf(this.keywords) > -1){
258
-                  new_arr.push(this.tableData[i])
259
-                }
328
+          obj.total_price = obj.total_price.toFixed(2);
329
+
330
+          var new_arr = [];
331
+
332
+          let list_1 = this.$store.getters.pagedata.list;
333
+          if (list_1.keywords == undefined) {
334
+            this.keywords = "";
335
+          } else {
336
+            this.keywords = list_1.keywords;
337
+          }
338
+          this.id = list_1.type_id;
339
+          this.item_type = this.id
340
+
341
+          if (this.keywords != "") {
342
+            for (let i = 0; i < this.tableData.length; i++) {
343
+              if (this.tableData[i].index != "合计") {
344
+                if (this.tableData[i].advice_id > 0) {
345
+                  if (
346
+                    this.tableData[i].advice.advice_name.indexOf(
347
+                      this.keywords
348
+                    ) > -1
349
+                  ) {
350
+                    new_arr.push(this.tableData[i]);
351
+                  }
260
                 }
352
                 }
261
-                if(this.tableData[i].project_id >0){
262
-                  if(this.tableData[i].project.type == 2){
263
-                    if(this.tableData[i].project.project.project_name.indexOf(this.keywords) > -1){
264
-                        new_arr.push(this.tableData[i])
353
+                if (this.tableData[i].project_id > 0) {
354
+                  if (this.tableData[i].project.type == 2) {
355
+                    if (
356
+                      this.tableData[i].project.project.project_name.indexOf(
357
+                        this.keywords
358
+                      ) > -1
359
+                    ) {
360
+                      new_arr.push(this.tableData[i]);
265
                     }
361
                     }
266
                   }
362
                   }
267
-                  if(this.tableData[i].project.type == 3){
268
-                    if(this.tableData[i].project.good_info.good_name.indexOf(this.keywords)> - 1){
269
-                      new_arr.push(this.tableData[i])   
363
+                  if (this.tableData[i].project.type == 3) {
364
+                    if (
365
+                      this.tableData[i].project.good_info.good_name.indexOf(
366
+                        this.keywords
367
+                      ) > -1
368
+                    ) {
369
+                      new_arr.push(this.tableData[i]);
270
                     }
370
                     }
271
                   }
371
                   }
272
                 }
372
                 }
273
               }
373
               }
274
             }
374
             }
275
-            var objs = {index:"合计",total_price:0,record_date:"0"}
276
-            objs.total_price = this.getPrice(new_arr)
277
-            this.tableData = new_arr
375
+            var objs = { index: "合计", total_price: 0, record_date: "0" };
376
+            objs.total_price = this.getPrice(new_arr);
377
+            this.tableData = new_arr;
278
           }
378
           }
279
 
379
 
280
-           if(this.id == 1){
281
-              var obj = {index:"合计",total_price:0,record_date:"0"}
282
-              var new_arr = []
283
-              for(let i=0;i<this.tableData.length;i++){
284
-                if(this.tableData[i].index!="合计"){
285
-                  if(this.tableData[i].advice_id > 0){
286
-                    new_arr.push(this.tableData[i])
287
-                  }
288
-                } 
380
+          if (this.id == 1) {
381
+            var obj = { index: "合计", total_price: 0, record_date: "0" };
382
+            var new_arr = [];
383
+            for (let i = 0; i < this.tableData.length; i++) {
384
+              if (this.tableData[i].index != "合计") {
385
+                if (this.tableData[i].advice_id > 0) {
386
+                  new_arr.push(this.tableData[i]);
387
+                }
289
               }
388
               }
290
-              this.tableData = []
291
-              obj.total_price = this.getPrice(new_arr)
292
-              // new_arr.push(obj)
293
-              this.tableData = new_arr
294
-           }
295
-          if(this.id == 2){
296
-            var obj = {index:"合计",total_price:0,record_date:"0"}
297
-            var new_arr = []
298
-            for(let i=0;i<this.tableData.length;i++){
299
-              if(this.tableData[i].index!="合计"){
300
-                if(this.tableData[i].project_id > 0){
301
-                  if(this.tableData[i].project.type ==2){
302
-                    new_arr.push(this.tableData[i])
389
+            }
390
+            this.tableData = [];
391
+            obj.total_price = this.getPrice(new_arr);
392
+            this.tableData = new_arr;
393
+          }
394
+          if (this.id == 2) {
395
+            var obj = { index: "合计", total_price: 0, record_date: "0" };
396
+            var new_arr = [];
397
+            for (let i = 0; i < this.tableData.length; i++) {
398
+              if (this.tableData[i].index != "合计") {
399
+                if (this.tableData[i].project_id > 0) {
400
+                  if (this.tableData[i].project.type == 2) {
401
+                    new_arr.push(this.tableData[i]);
303
                   }
402
                   }
304
                 }
403
                 }
305
-              } 
306
-            }
307
-           
308
-            this.tableData = []
309
-            obj.total_price = this.getPrice(new_arr)
310
-           
311
-            this.tableData = new_arr
404
+              }
312
             }
405
             }
406
+            this.tableData = [];
407
+            obj.total_price = this.getPrice(new_arr);
408
+            this.tableData = new_arr;
409
+          }
313
 
410
 
314
-          if(this.id == 3){
315
-            var new_arr = []
316
-            var obj = {index:"合计",total_price:0,record_date:"0"}
317
-            for(let i=0;i<this.tableData.length;i++){
318
-              if(this.tableData[i].index!="合计"){
319
-                if(this.tableData[i].project_id > 0){
320
-                  if(this.tableData[i].project.type == 3){
321
-                    new_arr.push(this.tableData[i])
411
+          if (this.id == 3) {
412
+            var new_arr = [];
413
+            var obj = { index: "合计", total_price: 0, record_date: "0" };
414
+            for (let i = 0; i < this.tableData.length; i++) {
415
+              if (this.tableData[i].index != "合计") {
416
+                if (this.tableData[i].project_id > 0) {
417
+                  if (this.tableData[i].project.type == 3) {
418
+                    new_arr.push(this.tableData[i]);
322
                   }
419
                   }
323
                 }
420
                 }
324
-              } 
421
+              }
325
             }
422
             }
326
-            this.tableData = []
327
-            obj.total_price = this.getPrice(new_arr)
328
-            this.tableData = new_arr
329
-          }      
330
-          
331
-         
332
-       }
333
-     })
423
+            this.tableData = [];
424
+            obj.total_price = this.getPrice(new_arr);
425
+            this.tableData = new_arr;
426
+          }
427
+        }
428
+      });
334
     },
429
     },
335
-    getAllPice(){
336
-      var total_price = 0
337
-      for(let i=0;i<this.tableData.length;i++){
338
-        total_price += this.tableData[i].pric * this.tableData[i].cnt
430
+
431
+    getAllPice() {
432
+      var total_price = 0;
433
+      for (let i = 0; i < this.tableData.length; i++) {
434
+        total_price += this.tableData[i].pric * this.tableData[i].cnt;
339
       }
435
       }
340
-      return total_price.toFixed(2)
436
+      return total_price.toFixed(2);
341
     },
437
     },
342
-    getActPay(){
343
-      var act_pay = 0
344
-      for(let i=0;i<this.orderList.length;i++){
345
-         act_pay += this.orderList[i].psn_part_amt
438
+    getActPay() {
439
+      var act_pay = 0;
440
+      for (let i = 0; i < this.list.length; i++) {
441
+        for (let j = 0; j < this.list[i].orders.length; j++) {
442
+          act_pay += this.list[i].orders[j].acct_pay;
443
+        }
346
       }
444
       }
347
       return act_pay.toFixed(2)
445
       return act_pay.toFixed(2)
348
     },
446
     },
349
-    getFundPaySumamt(){
350
-      var fund_pay_sumamt = 0
351
-      for(let i=0;i<this.list.length;i++){
352
-        for(let j=0;j<this.list[i].orders.length;j++){
353
-           fund_pay_sumamt +=this.list[i].orders[j].fund_pay_sumamt
447
+    getFundPaySumamt() {
448
+      var fund_pay_sumamt = 0;
449
+      for (let i = 0; i < this.list.length; i++) {
450
+        for (let j = 0; j < this.list[i].orders.length; j++) {
451
+          fund_pay_sumamt += this.list[i].orders[j].fund_pay_sumamt;
354
         }
452
         }
355
       }
453
       }
356
-      return fund_pay_sumamt
454
+      return fund_pay_sumamt;
357
     },
455
     },
358
-    getHifesPay(){
359
-      var hifes_pay = 0
360
-      for(let i=0;i<this.list.length;i++){
361
-        for(let j=0;j<this.list[i].orders.length;j++){
362
-          hifes_pay +=this.list[i].orders[j].hifes_pay
456
+    getHifesPay() {
457
+      var hifes_pay = 0;
458
+      for (let i = 0; i < this.list.length; i++) {
459
+        for (let j = 0; j < this.list[i].orders.length; j++) {
460
+          hifes_pay += this.list[i].orders[j].hifes_pay;
363
         }
461
         }
364
       }
462
       }
365
-      return hifes_pay
463
+      return hifes_pay;
366
     },
464
     },
367
-    getMafPay(){
368
-      var maf_pay = 0
369
-      for(let i=0;i<this.list.length;i++){
370
-        for(let j=0;j<this.list[i].orders.length;j++){
371
-          maf_pay +=this.list[i].orders[j].maf_pay
465
+    getMafPay() {
466
+      var maf_pay = 0;
467
+      for (let i = 0; i < this.list.length; i++) {
468
+        for (let j = 0; j < this.list[i].orders.length; j++) {
469
+          maf_pay += this.list[i].orders[j].maf_pay;
372
         }
470
         }
373
       }
471
       }
374
-      return maf_pay
472
+      return maf_pay;
375
     },
473
     },
376
-    toPrint(){
377
-      this.$router.push({path:"/hisTool/detailPrint?patient_id="+this.patient_id+"&start_time="+this.start_time+"&end_time="+this.end_time+"&type="+this.item_type +"&keyword="+this.keywords+"&id="+this.id+"&balance_accounts_type="+this.his_patient.balance_accounts_type})
474
+    toPrint() {
475
+      this.$router.push({
476
+        path:
477
+          "/hisTool/detailPrint?patient_id=" +
478
+          this.patient_id +
479
+          "&start_time=" +
480
+          this.start_time +
481
+          "&end_time=" +
482
+          this.end_time +
483
+          "&type=" +
484
+          this.item_type +
485
+          "&keyword=" +
486
+          this.keywords +
487
+          "&id=" +
488
+          this.id +
489
+          "&balance_accounts_type=" +
490
+          this.his_patient.balance_accounts_type,
491
+      });
492
+
493
+      // ======打印时将查询参数保存至store中======
494
+      // table_id: 左栏表格下标
495
+      // type_id: 下拉框id
496
+      // keywords: 输入框
497
+      // start_time: this.chargeDate[0],
498
+      // end_time: this.chargeDate[1],
499
+      // patient_id:this.patient_id
500
+      let table_id = this.$store.getters.pagedata.list.table_id;
501
+      if (table_id == undefined) {
502
+        this.$store.commit("SET_PAGEDATA", {
503
+          table_id: 0,
504
+          type_id: this.id,
505
+          keywords: this.keywords,
506
+          start_time: this.chargeDate[0],
507
+          end_time: this.chargeDate[1],
508
+          patient_id: this.patient_id,
509
+        });
510
+      } else {
511
+        this.$store.commit("SET_PAGEDATA", {
512
+          table_id: table_id,
513
+          type_id: this.id,
514
+          keywords: this.keywords,
515
+          start_time: this.chargeDate[0],
516
+          end_time: this.chargeDate[1],
517
+          patient_id: this.patient_id,
518
+        });
519
+      }
378
     },
520
     },
379
-    getPrice(val){
380
-      var total_price = 0
381
-      for(let i=0;i<val.length;i++){
382
-         total_price += val[i].cnt * val[i].pric
521
+    getPrice(val) {
522
+      var total_price = 0;
523
+      for (let i = 0; i < val.length; i++) {
524
+        total_price += val[i].cnt * val[i].pric;
383
       }
525
       }
384
-      return total_price.toFixed(2)
385
-    }
386
-
526
+      return total_price.toFixed(2);
527
+    },
387
   },
528
   },
388
   created() {
529
   created() {
389
-    this.start_time = this.chargeDate[0]
390
-    this.end_time = this.chargeDate[1]
391
-    this.getHisSummaryDetailList()
530
+    this.start_time = this.chargeDate[0];
531
+    this.end_time = this.chargeDate[1];
532
+    this.getHisSummaryDetailList();
533
+  },
534
+  watch: {
535
+    patient_id: function () {
536
+      this.patient_id = this.patient_id;
537
+      this.getHisSummaryDetailList();
538
+    },
392
   },
539
   },
393
-  watch:{
394
-    "patient_id":function(){
395
-      this.patient_id = this.patient_id
396
-      this.getHisSummaryDetailList()
397
-    }
398
-  }
399
-}
540
+};
400
 </script>
541
 </script>

File diff suppressed because it is too large
+ 1019 - 1095
src/xt_pages/outpatientTool/components/gatherStatistics.vue


+ 74 - 27
src/xt_pages/outpatientTool/statistics.vue ファイルの表示

10
     >
10
     >
11
       <div class="mainLeft">
11
       <div class="mainLeft">
12
         <div>
12
         <div>
13
-          <div style="margin:10px 0;display: flex;justify-content: space-between;">
13
+          <div
14
+            style="
15
+              margin: 10px 0;
16
+              display: flex;
17
+              justify-content: space-between;
18
+            "
19
+          >
14
             <el-input
20
             <el-input
15
               size="small"
21
               size="small"
16
               style="width: 130px"
22
               style="width: 130px"
28
           </div>
34
           </div>
29
 
35
 
30
           <el-table
36
           <el-table
37
+            :row-class-name="tableRowClassName"
38
+            @row-click="onRowClick"
31
             :data="patientTableData"
39
             :data="patientTableData"
32
             :height="tableHeight"
40
             :height="tableHeight"
33
             border
41
             border
81
   },
89
   },
82
   data() {
90
   data() {
83
     return {
91
     return {
92
+      currentRowIndex: 0,
84
       patientTableData: [],
93
       patientTableData: [],
85
       tableHeight: 400,
94
       tableHeight: 400,
86
       crumbs: [
95
       crumbs: [
92
       keywords: "",
101
       keywords: "",
93
     };
102
     };
94
   },
103
   },
104
+
105
+  // beforeRouteEnter(to, from, next){
106
+  //     if(from.path == '/hisTool/detailPrint'){
107
+  //       next((vm) => {
108
+  //         vm.titleType = "明细"
109
+  //       })
110
+  //     }else if(from.path == '/hisTool/gatherPrint'){
111
+  //       vm.titleType = "汇总"
112
+  //       next((vm) => {
113
+  //         vm.titleType = "汇总"
114
+  //       })
115
+  //     }else{
116
+  //       next()
117
+  //     }
118
+  // },
119
+
95
   //判断列表页是否刷新
120
   //判断列表页是否刷新
96
-  beforeRouteEnter(to, from, next) {
97
-    console.log(from, "beforeRouteEnter");
98
-    if (from.path == "/hisTool/detailPrint") {
99
-      next((vm) => {
100
-        vm.patient_id = vm.$store.getters.pagedata.list.patient_id;
101
-        // setTimeout(() => {
102
-        //   vm.getHisOrderList();
103
-        // },300)
104
-        
105
-      });
121
+  beforeRouteLeave(to, from, next) {
122
+    console.log(to, "beforeRouteEnter");
123
+    if (to.path != "/hisTool/detailPrint"&&to.path != "/hisTool/gatherPrint") {
124
+      this.$store.getters.pagedata.list.table_id = 0
125
+      next()
106
     } else {
126
     } else {
107
-      next((vm) => {
108
-        vm.getPatientList()
109
-        // setTimeout(() => {
110
-        //   vm.getHisOrderList();
111
-        // },300)
112
-        
113
-      });
127
+     next()
128
+    }
129
+  },
130
+
131
+  watch:{
132
+    'titleType':{
133
+      handler(val){
134
+        this.$store.commit('SET_PAGENAME',val)
135
+      }
114
     }
136
     }
115
   },
137
   },
116
 
138
 
126
         } else {
148
         } else {
127
           this.patientTableData = response.data.data.patient;
149
           this.patientTableData = response.data.data.patient;
128
           this.patient_id = this.patientTableData[0].id;
150
           this.patient_id = this.patientTableData[0].id;
129
-
130
-          this.$refs.singleTable.setCurrentRow(this.patientTableData[0]);
151
+          if (this.$store.getters.pagedata.list.table_id == 0) {
152
+            this.$refs.singleTable.setCurrentRow(this.patientTableData[0]);
153
+          } else {
154
+            this.$refs.singleTable.setCurrentRow(
155
+              this.patientTableData[
156
+                this.$store.getters.pagedata.list.table_id
157
+              ]
158
+            );
159
+          }
131
         }
160
         }
132
       });
161
       });
133
     },
162
     },
163
+
164
+    tableRowClassName({ row, rowIndex }) {
165
+      row.row_index = rowIndex;
166
+    },
167
+
168
+    onRowClick(row, event, column) {
169
+      this.currentRowIndex = row.row_index;
170
+      console.log(this.currentRowIndex, "this.currentRowIndex");
171
+      this.$store.commit("SET_PAGEDATA", {
172
+        table_id: this.currentRowIndex,
173
+      });
174
+      console.log(this.$store.getters.pagedata.list.table_id, "kk");
175
+    },
134
     searchAction() {
176
     searchAction() {
135
       this.getPatientList();
177
       this.getPatientList();
136
     },
178
     },
137
-    handleCurrentChange(row,index) {
179
+    handleCurrentChange(row) {
138
       this.patient_id = row.id;
180
       this.patient_id = row.id;
181
+      // console.log(this.patientTableData[this.currentRowIndex],'this.tableData[this.currentRowIndex]')
182
+      //  this.$refs.singleTable.setCurrentRow(this.tableData[this.currentRowIndex])
139
       // this.$refs.child.getHisSummaryDetailList()
183
       // this.$refs.child.getHisSummaryDetailList()
140
       // this.$refs.childOne.getGatherDetailList()
184
       // this.$refs.childOne.getGatherDetailList()
141
-      // this.$store.commit("SET_PAGEDATA",{
142
-      //   patient_id: row.id,
143
-      // })
144
-      console.log(index,'po')
145
     },
185
     },
146
   },
186
   },
147
   created() {
187
   created() {
188
+
189
+    let type = this.$store.getters.pagedata.pagestate
190
+    if(type == ""){
191
+      this.titleType = "明细"
192
+    }else{
193
+      this.titleType = type
194
+    }
148
     const tableHeight = document.body.clientHeight - 290;
195
     const tableHeight = document.body.clientHeight - 290;
149
     this.tableHeight = tableHeight;
196
     this.tableHeight = tableHeight;
150
     this.getPatientList();
197
     this.getPatientList();
198
+    
151
   },
199
   },
152
 
200
 
153
-  mounted() {},
154
-  watch: {},
201
+  mounted() {}
155
 };
202
 };
156
 </script>
203
 </script>
157
 
204