|
@@ -28,6 +28,9 @@
|
28
|
28
|
import { getDialysisRecord } from '@/api/dialysis'
|
29
|
29
|
import { getDataConfig } from '@/utils/data'
|
30
|
30
|
import { jsGetAge, uParseTime } from '@/utils/tools'
|
|
31
|
+ import { getPrivateExpenses } from '@/api/his/his'
|
|
32
|
+
|
|
33
|
+
|
31
|
34
|
import axios from 'axios'
|
32
|
35
|
import BreadCrumb from '@/xt_pages/components/bread-crumb'
|
33
|
36
|
import printOne from './newTreatTemplate/printOne'
|
|
@@ -110,113 +113,131 @@
|
110
|
113
|
|
111
|
114
|
},
|
112
|
115
|
getInfo(obj) {
|
113
|
|
- if (this.$store.getters.xt_user.org_id == 9504 || this.$store.getters.xt_user.org_id == 10028 || this.$store.getters.xt_user.org_id == 10138) {
|
114
|
|
- var that = this;
|
115
|
|
- axios.get('http://127.0.0.1:9532/sz/api/settle/query', {
|
116
|
|
- params: obj
|
117
|
|
- })
|
118
|
|
- .then(function (response) {
|
119
|
|
- if (response.data.state == 0) {
|
120
|
|
- this.$message.error(response.data.msg);
|
121
|
|
- return false
|
122
|
|
- } else {
|
123
|
|
- if (response.data.data.failed_code == -10) {
|
124
|
|
- // that.$message.error(response.data.data.msg)
|
125
|
|
- that.$confirm(response.data.data.msg, '医保错误信息', {
|
126
|
|
- confirmButtonText: '确 定',
|
127
|
|
- type: 'warning'
|
128
|
|
- }).then(() => {
|
129
|
|
-
|
130
|
|
- }).catch(() => {
|
131
|
|
- })
|
|
116
|
+ if (obj.balance_accounts_type == 2){
|
|
117
|
+ let params = {
|
|
118
|
+ his_patient_id: obj.his_patient_id,
|
|
119
|
+ id: obj.order_id,
|
132
|
120
|
|
133
|
|
- } else {
|
134
|
|
-
|
135
|
|
- console.log("~~~~");
|
136
|
|
- that.info = response.data.data.result;
|
137
|
|
- console.log(that.info);
|
138
|
|
-
|
139
|
|
- that.info['patient_info']= response.data.data.patient_info
|
140
|
|
- that.info['dialysis_no'] = response.data.data.dialysis_no
|
141
|
|
- that.info['org_code'] = response.data.data.org_code;
|
142
|
|
- that.info['patient_name'] = response.data.data.patient_name;
|
143
|
|
- that.info['doctor_code'] = response.data.data.doctor_code;
|
144
|
|
- that.info['doctor_name'] = response.data.data.doctor_name;
|
145
|
|
- if(response.data.data.health_card_no_two.length == 0){
|
146
|
|
- that.info['health_card_no'] = response.data.data.health_card_no
|
147
|
|
- }else{
|
148
|
|
- that.info['health_card_no'] = response.data.data.health_card_no_two
|
149
|
|
- }
|
|
121
|
+ }
|
|
122
|
+ getPrivateExpenses(params).then(response => {
|
|
123
|
+ if (response.data.state == 0) {
|
|
124
|
+ this.$message.error(response.data.msg)
|
150
|
125
|
|
151
|
|
- that.info['order_number'] = response.data.data.order_number;
|
|
126
|
+ return false
|
|
127
|
+ } else {
|
|
128
|
+ console.log(response.data.data)
|
152
|
129
|
|
153
|
|
- that.info['department'] = response.data.data.department;
|
154
|
|
- that.info['yiliao_leibie'] = response.data.data.yiliao_leibie;
|
|
130
|
+ }
|
|
131
|
+ })
|
155
|
132
|
|
156
|
|
- that.info['before_money'] = response.data.data.before_money;
|
157
|
|
- that.info['after_money'] = response.data.data.after_money;
|
158
|
133
|
|
159
|
|
- that.info['org_name'] = that.$store.getters.xt_user.org.org_name;
|
160
|
|
- console.log("~~~~" + that.info);
|
|
134
|
+ }else {
|
161
|
135
|
|
162
|
|
- var name_arr = [];
|
163
|
|
- var spec_arr = [];
|
164
|
|
- var count_arr = [];
|
165
|
|
- var price_arr = [];
|
166
|
|
- var total_arr = [];
|
167
|
|
- for (let i = 0; i < that.info.transBody.outputlist1.length; i++) {
|
168
|
|
- name_arr.push(that.info.transBody.outputlist1[i].ake006);
|
169
|
|
- spec_arr.push(that.info.transBody.outputlist1[i].aka074);
|
170
|
|
- count_arr.push(that.info.transBody.outputlist1[i].akc226);
|
171
|
|
- price_arr.push(that.info.transBody.outputlist1[i].akc225);
|
172
|
|
- total_arr.push(that.info.transBody.outputlist1[i].akc264)
|
173
|
|
- }
|
|
136
|
+ if (this.$store.getters.xt_user.org_id == 9504 || this.$store.getters.xt_user.org_id == 10028 || this.$store.getters.xt_user.org_id == 10138) {
|
|
137
|
+ var that = this;
|
|
138
|
+ axios.get('http://127.0.0.1:9532/sz/api/settle/query', {
|
|
139
|
+ params: obj
|
|
140
|
+ })
|
|
141
|
+ .then(function(response) {
|
|
142
|
+ if (response.data.state == 0) {
|
|
143
|
+ this.$message.error(response.data.msg);
|
|
144
|
+ return false
|
|
145
|
+ } else {
|
|
146
|
+ if (response.data.data.failed_code == -10) {
|
|
147
|
+ // that.$message.error(response.data.data.msg)
|
|
148
|
+ that.$confirm(response.data.data.msg, '医保错误信息', {
|
|
149
|
+ confirmButtonText: '确 定',
|
|
150
|
+ type: 'warning'
|
|
151
|
+ }).then(() => {
|
|
152
|
+
|
|
153
|
+ }).catch(() => {
|
|
154
|
+ })
|
|
155
|
+
|
|
156
|
+ } else {
|
|
157
|
+
|
|
158
|
+ console.log("~~~~");
|
|
159
|
+ that.info = response.data.data.result;
|
|
160
|
+ console.log(that.info);
|
|
161
|
+
|
|
162
|
+ that.info['patient_info'] = response.data.data.patient_info
|
|
163
|
+ that.info['dialysis_no'] = response.data.data.dialysis_no
|
|
164
|
+ that.info['org_code'] = response.data.data.org_code;
|
|
165
|
+ that.info['patient_name'] = response.data.data.patient_name;
|
|
166
|
+ that.info['doctor_code'] = response.data.data.doctor_code;
|
|
167
|
+ that.info['doctor_name'] = response.data.data.doctor_name;
|
|
168
|
+ if (response.data.data.health_card_no_two.length == 0) {
|
|
169
|
+ that.info['health_card_no'] = response.data.data.health_card_no
|
|
170
|
+ } else {
|
|
171
|
+ that.info['health_card_no'] = response.data.data.health_card_no_two
|
|
172
|
+ }
|
174
|
173
|
|
175
|
|
- console.log("~~~" + that.info);
|
|
174
|
+ that.info['order_number'] = response.data.data.order_number;
|
176
|
175
|
|
177
|
|
- that.info['name_arr'] = name_arr;
|
178
|
|
- that.info['spec_arr'] = spec_arr;
|
179
|
|
- that.info['count_arr'] = count_arr;
|
180
|
|
- that.info['price_arr'] = price_arr;
|
181
|
|
- that.info['total_arr'] = total_arr;
|
182
|
|
- that.info['record_date'] = obj.record_time;
|
|
176
|
+ that.info['department'] = response.data.data.department;
|
|
177
|
+ that.info['yiliao_leibie'] = response.data.data.yiliao_leibie;
|
183
|
178
|
|
184
|
|
- console.log("~~" + that.info)
|
|
179
|
+ that.info['before_money'] = response.data.data.before_money;
|
|
180
|
+ that.info['after_money'] = response.data.data.after_money;
|
185
|
181
|
|
|
182
|
+ that.info['org_name'] = that.$store.getters.xt_user.org.org_name;
|
|
183
|
+ console.log("~~~~" + that.info);
|
186
|
184
|
|
187
|
|
- let type_arr = []
|
188
|
|
- for (let i = 0; i < that.info.transBody.outputlist1.length; i++) {
|
189
|
|
- type_arr.push(that.info.transBody.outputlist1[i].aka111)
|
190
|
|
- }
|
|
185
|
+ var name_arr = [];
|
|
186
|
+ var spec_arr = [];
|
|
187
|
+ var count_arr = [];
|
|
188
|
+ var price_arr = [];
|
|
189
|
+ var total_arr = [];
|
|
190
|
+ for (let i = 0; i < that.info.transBody.outputlist1.length; i++) {
|
|
191
|
+ name_arr.push(that.info.transBody.outputlist1[i].ake006);
|
|
192
|
+ spec_arr.push(that.info.transBody.outputlist1[i].aka074);
|
|
193
|
+ count_arr.push(that.info.transBody.outputlist1[i].akc226);
|
|
194
|
+ price_arr.push(that.info.transBody.outputlist1[i].akc225);
|
|
195
|
+ total_arr.push(that.info.transBody.outputlist1[i].akc264)
|
|
196
|
+ }
|
191
|
197
|
|
|
198
|
+ console.log("~~~" + that.info);
|
192
|
199
|
|
193
|
|
- let typeArr = that.unique(type_arr)
|
|
200
|
+ that.info['name_arr'] = name_arr;
|
|
201
|
+ that.info['spec_arr'] = spec_arr;
|
|
202
|
+ that.info['count_arr'] = count_arr;
|
|
203
|
+ that.info['price_arr'] = price_arr;
|
|
204
|
+ that.info['total_arr'] = total_arr;
|
|
205
|
+ that.info['record_date'] = obj.record_time;
|
194
|
206
|
|
195
|
|
- that.info['new_detail_list'] = []
|
|
207
|
+ console.log("~~" + that.info)
|
196
|
208
|
|
197
|
|
- for(let i = 0; i < typeArr.length; i++){
|
198
|
|
- let obj = {
|
199
|
|
- aka111:typeArr[i],
|
200
|
|
- details:[],
|
201
|
|
- total:0
|
|
209
|
+ let type_arr = []
|
|
210
|
+ for (let i = 0; i < that.info.transBody.outputlist1.length; i++) {
|
|
211
|
+ type_arr.push(that.info.transBody.outputlist1[i].aka111)
|
202
|
212
|
}
|
203
|
213
|
|
204
|
|
- for(let b = 0; b < that.info.transBody.outputlist1.length;b++){
|
205
|
|
- if(typeArr[i] == that.info.transBody.outputlist1[b].aka111){
|
|
214
|
+ let typeArr = that.unique(type_arr)
|
|
215
|
+
|
|
216
|
+ that.info['new_detail_list'] = []
|
|
217
|
+
|
|
218
|
+ for (let i = 0; i < typeArr.length; i++) {
|
|
219
|
+ let obj = {
|
|
220
|
+ aka111: typeArr[i],
|
|
221
|
+ details: [],
|
|
222
|
+ total: 0
|
|
223
|
+ }
|
|
224
|
+
|
|
225
|
+ for (let b = 0; b < that.info.transBody.outputlist1.length; b++) {
|
|
226
|
+ if (typeArr[i] == that.info.transBody.outputlist1[b].aka111) {
|
206
|
227
|
obj.details.push(that.info.transBody.outputlist1[b])
|
207
|
228
|
obj.total += that.info.transBody.outputlist1[b].akc264
|
208
|
229
|
}
|
|
230
|
+ }
|
|
231
|
+ that.info.new_detail_list.push(obj)
|
209
|
232
|
}
|
210
|
|
- that.info.new_detail_list.push(obj)
|
211
|
|
- }
|
212
|
|
-
|
213
|
233
|
|
|
234
|
+ }
|
214
|
235
|
}
|
215
|
|
- }
|
216
|
|
- })
|
217
|
|
- .catch(function (error) {
|
|
236
|
+ })
|
|
237
|
+ .catch(function(error) {
|
218
|
238
|
|
219
|
|
- });
|
|
239
|
+ });
|
|
240
|
+ }
|
220
|
241
|
}
|
221
|
242
|
}, unique(array) {
|
222
|
243
|
|