manage-client 3.3.122 → 3.3.123

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,837 @@
1
+ <template>
2
+ <div id="unit" class="flex-row">
3
+ <div class="basic-main" @keyup.enter="search">
4
+ <div class="flex" v-if="!show">
5
+ <criteria-paged :model="model" v-ref:paged>
6
+ <criteria partial='criteria' @condition-changed='$parent.selfSearch' v-ref:cri>
7
+ <div novalidate class="form-inline auto" partial>
8
+ <div class="row">
9
+ <div class="col-sm-2 form-group">
10
+ <label for="startDate" class="font_normal_body">录入日期</label>
11
+ <datepicker id="startDate" placeholder="开始日期" style="width:60%"
12
+ v-model="model.startDate"
13
+ :value.sync="model.startDate"
14
+ :format="'yyyy-MM-dd HH:mm:ss'"
15
+ :show-reset-button="true"
16
+ >
17
+ </datepicker>
18
+ </div>
19
+ <div class="col-sm-2 form-group">
20
+ <label for="endDate" class="font_normal_body">&emsp;&emsp;&emsp;至</label>
21
+ <datepicker id="endDate" placeholder="结束日期" style="width:60%"
22
+ v-model="model.endDate"
23
+ :value.sync="model.endDate"
24
+ :format="'yyyy-MM-dd HH:mm:ss'"
25
+ :show-reset-button="true"
26
+ >
27
+ </datepicker>
28
+ </div>
29
+ <div class="col-sm-2 form-group">
30
+ <label for="startHandDate" class="font_normal_body">下发日期</label>
31
+ <datepicker id="startHandDate" placeholder="开始日期" style="width:60%"
32
+ v-model="model.startHandDate"
33
+ :value.sync="model.startHandDate"
34
+ :format="'yyyy-MM-dd HH:mm:ss'"
35
+ :show-reset-button="true"
36
+ >
37
+ </datepicker>
38
+ </div>
39
+ <div class="col-sm-2 form-group">
40
+ <label for="endHandDate" class="font_normal_body">&emsp;&emsp;&emsp;至</label>
41
+ <datepicker id="endHandDate" placeholder="结束日期" style="width:60%"
42
+ v-model="model.endHandDate"
43
+ :value.sync="model.endHandDate"
44
+ :format="'yyyy-MM-dd HH:mm:ss'"
45
+ :show-reset-button="true"
46
+ >
47
+ </datepicker>
48
+ </div>
49
+
50
+
51
+ <div class="span" style="float:right;">
52
+ <button class="button_search button_spacing" @click="search()">查询</button>
53
+ <button class="button_clear button_spacing" @click="$parent.$parent.clear()">清空</button>
54
+ <export-excel :data="$parent.$parent.getCondition"
55
+ :field="$parent.$parent.getfield"
56
+ :footer="$parent.$parent.footer"
57
+ :header="$parent.$parent.other"
58
+ sqlurl="rs/logic/exportfile"
59
+ sql-name="FMYgasQuery"
60
+ template-name='用气查询导出'
61
+ :choose-col="true"></export-excel>
62
+ <print-data :model="$parent.model" :field="$parent.$parent.getfield"
63
+ :defaultfield="$parent.$parent.defaultfield" print-name="用气查询打印"
64
+ ></print-data>
65
+
66
+ <div style="float: right" class="button_spacing"
67
+ :class="{'button_shrink_top':$parent.$parent.criteriaShow,'button_shrink_bottom':!$parent.$parent.criteriaShow}"
68
+ @click="$parent.$parent.hidden()"></div>
69
+ </div>
70
+ </div>
71
+ <div class="row" v-show="$parent.$parent.criteriaShow">
72
+
73
+ <res-select-group :initres="$parent.$parent.initres" @re-res="$parent.$parent.getRes"
74
+ v-ref:sel></res-select-group>
75
+
76
+ <div class="col-sm-2 form-group">
77
+
78
+ <label class="font_normal_body">客户编号</label>
79
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_userinfo_code"
80
+ condition="f_userinfo_code = '{}' " placeholder="客户编号">
81
+ </div>
82
+ <div class="col-sm-2 form-group">
83
+ <label class="font_normal_body">客户名称</label>
84
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_user_name"
85
+ condition="f_user_name like '%{}%'" placeholder="客户名称">
86
+ </div>
87
+ <div class="col-sm-2 form-group">
88
+ <label class="font_normal_body" title="旧客户编号">档案编号</label>
89
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_olduserinfo_code"
90
+ condition="f_olduserinfo_code = '{}' " placeholder="档案编号">
91
+ </div>
92
+ <div class="col-sm-2 form-group">
93
+ <label class="font_normal_body">&nbsp;&nbsp;&nbsp;小区&nbsp;&nbsp;&nbsp;</label>
94
+ <v-select :value.sync="model.f_residential_area"
95
+ class="select_list select"
96
+ v-model="model.f_residential_area"
97
+ style="width: 60%"
98
+ multiple
99
+ condition="f_residential_area in {}"
100
+ :options='$parent.$parent.residentialArea' placeholder='选择小区'
101
+ close-on-select>
102
+
103
+ </v-select>
104
+ </div>
105
+ <div class="col-sm-2 form-group">
106
+ <label class="font_normal_body">客户地址</label>
107
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_address"
108
+ condition="f_address like '%{}%'" placeholder='客户地址'>
109
+ </div>
110
+ <div class="col-sm-2 form-group">
111
+ <label class="font_normal_body">客户表号</label>
112
+ <input type="text" style="width:60%" class="input_search" v-model="model.f_meternumber"
113
+ condition="f_meternumber = '{}'" placeholder='客户表号'>
114
+ </div>
115
+ <div class="col-sm-2 form-group">
116
+ <label class="font_normal_body" title="参数名称:气表类型">气表类型</label>
117
+ <v-select :value.sync="model.f_meter_classify"
118
+ v-model="model.f_meter_classify"
119
+ :options='$parent.$parent.metertype' placeholder='请选择'
120
+ condition="f_meter_classify like '%{}%'"
121
+ close-on-select></v-select>
122
+ </div>
123
+ <div class="col-sm-2 form-group">
124
+ <label class="font_normal_body" title="参数名称:用户类型">客户类型</label>
125
+ <v-select :value.sync="model.f_user_type"
126
+ @change="$parent.$parent.userTypeChange()"
127
+ :options='$parent.$parent.usertypes' placeholder='请选择' v-model="model.f_user_type"
128
+ condition="f_user_type = '{}'"
129
+ close-on-select></v-select>
130
+ </div>
131
+ <div class="col-sm-2 form-group">
132
+ <label class="font_normal_body">客户状态</label>
133
+ <v-select :value.sync="model.f_user_state"
134
+ v-model="model.f_user_state"
135
+ :options='$parent.$parent.userstates' placeholder='请选择'
136
+ condition="f_user_state = '{}'"
137
+ close-on-select></v-select>
138
+ </div>
139
+ <div class="col-sm-2 form-group">
140
+ <label class="font_normal_body">用气性质</label>
141
+ <v-select :value.sync="model.f_gasproperties"
142
+ v-model="model.f_gasproperties"
143
+ :options='$parent.$parent.gasproperties' placeholder='请选择'
144
+ :multiple="true"
145
+ condition="f_gasproperties in {}">
146
+ </v-select>
147
+ </div>
148
+ <!--表册片区-->
149
+ <div class="col-sm-2 form-group">
150
+ <label class="font_normal_body">表册片区</label>
151
+ <v-select :value.sync="model.f_book_slice_area" v-model="model.f_book_slice_area"
152
+ @change="$parent.$parent.inputtorchange"
153
+ :options='$parent.$parent.bookSlice' placeholder='片区/表册'
154
+ style="width:60%"
155
+ close-on-select
156
+ condition="f_book_slice_area = '{}'"></v-select>
157
+ </div>
158
+ <div class="col-sm-2 form-group">
159
+ <label class="font_normal_body">抄&ensp;表&ensp;册</label>
160
+ <v-select :value.sync="model.f_meter_book" v-model="model.f_meter_book"
161
+ :options='$parent.$parent.meterbooks' placeholder='抄表册'
162
+ style="width:60%" :multiple="true"
163
+ condition="f_meter_book_num in {}"></v-select>
164
+ </div>
165
+ <div class="col-sm-2 form-group">
166
+ <label class="font_normal_body">气表品牌</label>
167
+ <v-select :value.sync="model.f_meter_brand" multiple
168
+ v-model="model.f_meter_brand"
169
+ :options='$parent.$parent.meterbrands' placeholder='请选择'
170
+ condition="f_meter_brand in {}"
171
+ close-on-select></v-select>
172
+ </div>
173
+ <div class="col-sm-2 form-group">
174
+ <label class="font_normal_body">用&nbsp;气&nbsp;量&nbsp;</label>
175
+ <input type="text" style="width:30%" class="input_search" title="大于等于"
176
+ v-model="model.f_oughtamount_small"
177
+ condition="f_oughtamount >= '{}' " placeholder="大于等于">
178
+ <input type="text" style="width:30%" class="input_search" title="小于等于"
179
+ v-model="model.f_oughtamount_big"
180
+ condition="f_oughtamount <= '{}' " placeholder="小于等于">
181
+ </div>
182
+ <div class="col-sm-2 form-group">
183
+ <label for="startHandDate" class="font_normal_body">通气时间</label>
184
+ <datepicker id="startHandDate" placeholder="开始日期" style="width:60%"
185
+ v-model="model.startGasDate"
186
+ :value.sync="model.startGasDate"
187
+ :format="'yyyy-MM-dd HH:mm:ss'"
188
+ condition="f_gas_date >= '{}'"
189
+ :show-reset-button="true"
190
+ >
191
+ </datepicker>
192
+ </div>
193
+ <div class="col-sm-2 form-group">
194
+ <label for="endHandDate" class="font_normal_body">&emsp;&emsp;&emsp;至</label>
195
+ <datepicker id="endHandDate" placeholder="结束日期" style="width:60%"
196
+ v-model="model.endGasDate"
197
+ :value.sync="model.endGasDate"
198
+ :format="'yyyy-MM-dd HH:mm:ss'"
199
+ condition="f_gas_date <= '{}'"
200
+ :show-reset-button="true"
201
+ >
202
+ </datepicker>
203
+ </div>
204
+ <div class="col-sm-2 form-group">
205
+ <label class="font_normal_body">&nbsp;抄&nbsp;表&nbsp;员</label>
206
+ <v-select :value.sync="model.f_inputtor"
207
+ v-model="model.f_inputtor"
208
+ :multiple="true"
209
+ :options='$parent.$parent.inputtores' placeholder='请选择'
210
+ condition="f_inputtor in {}"
211
+ :search="false">
212
+ </v-select>
213
+ </div>
214
+ </div>
215
+ </div>
216
+ </criteria>
217
+ <data-grid :model="model" partial='list' class="list_area table_sy" v-ref:grid :classname="$parent.classname">
218
+ <template partial='head'>
219
+ <tr>
220
+ <th>
221
+ <nobr>客户编号</nobr>
222
+ </th>
223
+ <th>
224
+ <nobr>客户名称</nobr>
225
+ </th>
226
+ <th>
227
+ <nobr>档案编号</nobr>
228
+ </th>
229
+ <th>
230
+ <nobr>客户电话</nobr>
231
+ </th>
232
+ <th>
233
+ <nobr>证件类型</nobr>
234
+ </th>
235
+ <th>
236
+ <nobr>证件号码</nobr>
237
+ </th>
238
+ <th>
239
+ <nobr>小区</nobr>
240
+ </th>
241
+ <th>
242
+ <nobr>客户地址</nobr>
243
+ </th>
244
+ <th>
245
+ <nobr>客户类型</nobr>
246
+ </th>
247
+ <th>
248
+ <nobr>用气性质</nobr>
249
+ </th>
250
+ <th>
251
+ <nobr>表号</nobr>
252
+ </th>
253
+ <th>
254
+ <nobr>气表品牌</nobr>
255
+ </th>
256
+ <th>
257
+ <nobr>气表类型</nobr>
258
+ </th>
259
+ <th>
260
+ <nobr>气价详情</nobr>
261
+ </th>
262
+ <!--<th><nobr>气表底数</nobr></th>-->
263
+ <!--<th><nobr>表上余额</nobr></th>-->
264
+ <!--<th><nobr>账户余额</nobr></th>-->
265
+ <th>
266
+ <nobr>预购气量</nobr>
267
+ </th>
268
+ <th>
269
+ <nobr>预购金额</nobr>
270
+ </th>
271
+ <th>
272
+ <nobr>实交金额</nobr>
273
+ </th>
274
+ <th>
275
+ <nobr>抄表员</nobr>
276
+ </th>
277
+ <th>
278
+ <nobr>表册片区</nobr>
279
+ </th>
280
+ <th>
281
+ <nobr>抄表次数</nobr>
282
+ </th>
283
+ <th>
284
+ <nobr>抄表区间</nobr>
285
+ </th>
286
+ <th title="抄表区间间隔天数">
287
+ <nobr>天数</nobr>
288
+ </th>
289
+ <th>
290
+ <nobr>用气量</nobr>
291
+ </th>
292
+ <th>
293
+ <nobr>用气金额</nobr>
294
+ </th>
295
+ <th>
296
+ <nobr>一阶气量</nobr>
297
+ </th>
298
+ <th>
299
+ <nobr>一阶气费</nobr>
300
+ </th>
301
+ <th>
302
+ <nobr>二阶气量</nobr>
303
+ </th>
304
+ <th>
305
+ <nobr>二阶气费</nobr>
306
+ </th>
307
+ <th>
308
+ <nobr>三阶气量</nobr>
309
+ </th>
310
+ <th>
311
+ <nobr>三阶气费</nobr>
312
+ </th>
313
+ <th>
314
+ <nobr>通气时间</nobr>
315
+ </th>
316
+ </tr>
317
+ </template>
318
+ <template partial='body'>
319
+ <td style="text-align: center;">
320
+ <nobr>{{ row.f_userinfo_code }}</nobr>
321
+ </td>
322
+ <td style="text-align: center;">
323
+ <nobr>{{ row.f_user_name }}</nobr>
324
+ </td>
325
+ <td style="text-align: center;">
326
+ <nobr>{{ row.f_olduserinfo_code }}</nobr>
327
+ </td>
328
+ <td style="text-align: center;">
329
+ <nobr>{{ row.f_user_phone }}</nobr>
330
+ </td>
331
+ <td style="text-align: center;">
332
+ <nobr>{{ row.f_credentials }}</nobr>
333
+ </td>
334
+ <td style="text-align: center;">
335
+ <nobr>{{ row.f_idnumber }}</nobr>
336
+ </td>
337
+ <td style="text-align: center;">
338
+ <nobr>{{ row.f_residential_area }}</nobr>
339
+ </td>
340
+ <td style="text-align: center;">
341
+ <nobr>{{ row.f_address }}</nobr>
342
+ </td>
343
+ <td style="text-align: center;">
344
+ <nobr>{{ row.f_user_type }}</nobr>
345
+ </td>
346
+ <td style="text-align: center;">
347
+ <nobr>{{ row.f_gasproperties }}</nobr>
348
+ </td>
349
+ <td style="text-align: center;">
350
+ <nobr>{{ row.f_meternumber }}</nobr>
351
+ </td>
352
+ <td style="text-align: center;">
353
+ <nobr>{{ row.f_meter_brand }}</nobr>
354
+ </td>
355
+ <td style="text-align: center;">
356
+ <nobr>{{ row.f_meter_classify }}</nobr>
357
+ </td>
358
+ <td style="text-align: center;">
359
+ <nobr>{{ row.f_price_value }}</nobr>
360
+ </td>
361
+ <!--<td style="text-align: center;">-->
362
+ <!--<nobr>{{row.f_meter_base}}</nobr>-->
363
+ <!--</td>-->
364
+ <!--<td style="text-align: center;">-->
365
+ <!--<nobr>{{row.f_balance_amount}}</nobr>-->
366
+ <!--</td>-->
367
+ <!--<td style="text-align: center;">-->
368
+ <!--<nobr>{{row.f_balance}}</nobr>-->
369
+ <!--</td>-->
370
+ <td style="text-align: center;">
371
+ <nobr>{{ row.f_pregas }}</nobr>
372
+ </td>
373
+ <td style="text-align: center;">
374
+ <nobr>{{ row.f_preamount }}</nobr>
375
+ </td>
376
+ <td style="text-align: center;">
377
+ <nobr>{{ row.f_collection }}</nobr>
378
+ </td>
379
+ <td style="text-align: center;">
380
+ <nobr>{{ row.f_inputtor }}</nobr>
381
+ </td>
382
+ <td style="text-align: center;">
383
+ <nobr>{{ row.f_book_slice_area }}</nobr>
384
+ </td>
385
+ <td style="text-align: center;">
386
+ <nobr>{{ row.f_hand_number }}</nobr>
387
+ </td>
388
+ <td style="text-align: center;">
389
+ <nobr>{{ row.f_date }}</nobr>
390
+ </td>
391
+ <td style="text-align: center;" title="抄表区间间隔天数">
392
+ <nobr>{{ row.f_input_day }}</nobr>
393
+ </td>
394
+ <td style="text-align: center;">
395
+ <nobr>{{ row.f_oughtamount }}</nobr>
396
+ </td>
397
+ <td style="text-align: center;">
398
+ <nobr>{{ row.f_oughtfee }}</nobr>
399
+ </td>
400
+ <td style="text-align:center">
401
+ <nobr>{{ row.f_stair1amount }}</nobr>
402
+ </td>
403
+ <td style="text-align:center">
404
+ <nobr>{{ row.f_stair1fee }}</nobr>
405
+ </td>
406
+ <td style="text-align:center">
407
+ <nobr>{{ row.f_stair2amount }}</nobr>
408
+ </td>
409
+ <td style="text-align:center">
410
+ <nobr>{{ row.f_stair2fee }}</nobr>
411
+ </td>
412
+ <td style="text-align:center">
413
+ <nobr>{{ row.f_stair3amount }}</nobr>
414
+ </td>
415
+ <td style="text-align:center">
416
+ <nobr>{{ row.f_stair3fee }}</nobr>
417
+ </td>
418
+ <td style="text-align: center;">
419
+ <nobr>{{ row.f_gas_date }}</nobr>
420
+ </td>
421
+ </template>
422
+ <template partial='foot'></template>
423
+ </data-grid>
424
+ </criteria-paged>
425
+ <table class="table-hover">
426
+ <tr style="position: relative" class="table-bordered">
427
+ <td
428
+ style="display: inline-block;width: auto;border-right: 1px solid #F2F6FA;padding: 0px 10px 0px 10px;color: #5CB95C;font-weight: bold">
429
+ 汇总信息
430
+ </td>
431
+ <td
432
+ style="display: inline-block;width: auto;border-right: 1px solid #F2F6FA;padding: 0px 10px 0px 10px;font-weight: bold">
433
+ 预购气量合计:&emsp;{{ sumsmodel.f_pregas }}
434
+ </td>
435
+ <td
436
+ style="display: inline-block;width: auto;border-right: 1px solid #F2F6FA;padding: 0px 10px 0px 10px;font-weight: bold">
437
+ 预购金额合计:&emsp;{{ sumsmodel.f_preamount }}
438
+ </td>
439
+ <td
440
+ style="display: inline-block;width: auto;border-right: 1px solid #F2F6FA;padding: 0px 10px 0px 10px;font-weight: bold">
441
+ 实交金额合计:&emsp;{{ sumsmodel.f_collection }}
442
+ </td>
443
+ <td
444
+ style="display: inline-block;width: auto;border-right: 1px solid #F2F6FA;padding: 0px 10px 0px 10px;font-weight: bold">
445
+ 用气量合计:&emsp;{{ sumsmodel.f_oughtamount }}
446
+ </td>
447
+ <td
448
+ style="display: inline-block;width: auto;border-right: 1px solid #F2F6FA;padding: 0px 10px 0px 10px;font-weight: bold">
449
+ 用气金额合计:&emsp;{{ sumsmodel.f_oughtfee }}
450
+ </td>
451
+ </tr>
452
+ </table>
453
+ </div>
454
+ <div v-if="show">
455
+ <user-info-detail-manage :f_userinfo_id="rowdata.f_userinfo_id" @cancel-main="cancel"></user-info-detail-manage>
456
+ </div>
457
+ </div>
458
+ </div>
459
+ </template>
460
+ <script>
461
+ import {HttpResetClass, PagedList} from 'vue-client'
462
+ import defaultPrint from './config/DefaultPrint'
463
+ import exportConfig from './config/exportConfig'
464
+
465
+
466
+ let readySomething = async function (self) {
467
+ //加载抄表册
468
+ self.initmeterbook();
469
+ self.initSlice(self.$login.f.orgid)
470
+
471
+ self.$refs.paged.$refs.cri.model.startDate = self.$login.toStandardDateString() + ' 00:00:00'
472
+ self.$refs.paged.$refs.cri.model.endDate = self.$login.toStandardDateString() + ' 23:59:59'
473
+ await self.$MagLoadParams.loadParam()
474
+ self.initParams()
475
+ self.getaddress()
476
+ self.sumsmodel = self.$refs.paged.$refs.grid.model.sums
477
+ }
478
+ export default {
479
+ title: '用气查询',
480
+ name: 'AddMaterial',
481
+ data() {
482
+ return {
483
+ other: [],
484
+ footer: [],
485
+ model: new PagedList('rs/sql/FMYgasQuery', 30, {
486
+ startDate: 'this.model.startDate != null && this.model.startDate != "" ? this.model.startDate : this.model.startHandDate',
487
+ endDate: 'this.model.endDate != null && this.model.endDate != "" ? this.model.endDate : this.model.endHandDate',
488
+ f_queryweb: 'this.model.f_queryweb'
489
+ }, {
490
+ f_pregas: 0,
491
+ f_preamount: 0,
492
+ f_collection: 0,
493
+ f_oughtamount: 0,
494
+ f_oughtfee: 0
495
+ }),
496
+ initres: {
497
+ org: [this.$login.f.orgid],
498
+ dep: [],
499
+ user: [],
500
+ },
501
+ gasproperties: [],
502
+ residentialArea: [],
503
+ f_filialeid: this.$login.f.orgid,
504
+ show: false,
505
+ rowdata: {},
506
+ criteriaShow: false,
507
+ orgCondtionStr: '',
508
+ modelval: [],
509
+ meterbrands: [],
510
+ printshow: false,
511
+ all: false,
512
+ fields: {},
513
+ inputtores: [{label: '全部', value: ''}],
514
+ thead: '',
515
+ tfoot: '',
516
+ //表册片区
517
+ bookSlice: [{label: '全部', value: ''}],
518
+ // 下拉框
519
+
520
+ //合计数据
521
+ sumsmodel: {},
522
+ defaultfield: [],
523
+ // 使用类型,壁挂炉
524
+ usetypes: [{label: '全部', value: ''}, {label: '是', value: `= '壁挂炉'`}, {label: '否', value: `!= '壁挂炉'`}],
525
+ userstates: this.$appdata.getParam('用户状态') ? [{
526
+ label: '全部',
527
+ value: ''
528
+ }, ...this.$appdata.getParam('用户状态')] : [],
529
+ meterbooks: [{label: '全部', value: ''}], //抄表册
530
+ tempfalg: false,
531
+ lastorgstr: '',
532
+ isQueryWeb: this.$appdata.getSingleValue('用气查询是否查物联网表') ? this.$appdata.getSingleValue('用气查询是否查物联网表') : '否',
533
+ allorgid: [],
534
+ }
535
+ },
536
+ ready() {
537
+ readySomething(this)
538
+ this.getinputtores()
539
+ },
540
+ methods: {
541
+ initParams() {
542
+ //初始化气表品牌
543
+ let brandArr = []
544
+ this.$MagGetSaleParam.getGasbrand().forEach((item) => {
545
+ let temp = {}
546
+ temp.label = item.label
547
+ temp.value = item.value.f_meter_brand
548
+ brandArr.push(temp)
549
+ })
550
+ this.meterbrands = [{label: '全部', value: ''}, ...brandArr]
551
+ },
552
+ //初始化片区
553
+ async initSlice(val) {
554
+ if (val) {
555
+ let getAllArea = await this.$resetpost('/rs/search', {
556
+ source: 'this.getParentByType($organization$).getAllChildrens().where(row.getType() == $zone$)',
557
+ userid: this.$login.f.id
558
+ }, {resolveMsg: null, rejectMsg: '获取片区出错!!!'})
559
+ let arr = getAllArea.data.filter((res) => {
560
+ return res.parentid == val
561
+ })
562
+ this.bookSlice = []
563
+ arr.forEach((res) => {
564
+ this.bookSlice.push({label: res.name, value: res.name})
565
+ })
566
+ }
567
+ },
568
+ async getinputtores() {
569
+ // 获取抄表员
570
+ let rs = []
571
+ if (this.$login.f.f_gasman.length > 0) {
572
+ for (let i = 0; i < this.$login.f.f_gasman.length; i++) {
573
+ let temp = {
574
+ label: this.$login.f.f_gasman[i].name,
575
+ value: this.$login.f.f_gasman[i].name
576
+ }
577
+ rs.push(temp)
578
+ }
579
+ }
580
+ this.inputtores = [{label: '全部', value: ''}, ...rs]
581
+ },
582
+ //表册片区和抄表册关联
583
+ async inputtorchange() {
584
+ /*let val1=this.$refs.paged.$refs.cri.model.f_meter_book*/
585
+ this.$set('$refs.paged.$refs.cri.model.f_meter_book', []);
586
+ let val2 = this.$refs.paged.$refs.cri.model.f_book_slice_area
587
+ if ((val2.length > 0)) {
588
+ let condition = ` 1=1 and f_orgid ='${this.f_filialeid}' and f_book_state='有效' `
589
+ if (val2[0]) {
590
+ condition = condition + ` and f_book_slice_area = '${val2}' `
591
+ }
592
+ let param = {
593
+ items: '*',
594
+ tablename: 't_meter_book',
595
+ condition: condition,
596
+ orderitem: 'id'
597
+ }
598
+ let getMeterBooks = await this.$resetpost('rs/sql/singleTable_OrderBy', {data: param}, {
599
+ resolveMsg: null,
600
+ rejectMsg: '获取营收参数出错!!!'
601
+ })
602
+ if (getMeterBooks.data) {
603
+ if (getMeterBooks.data.length > 0) {
604
+ let rs = [];
605
+ getMeterBooks.data.forEach((item) => {
606
+ let temp = {
607
+ label: item.f_book_name,
608
+ value: item.id
609
+ };
610
+ rs.push(temp);
611
+
612
+ })
613
+ this.meterbooks = [{label: '全部', value: ''}, ...rs];
614
+ } else {
615
+
616
+ this.meterbooks = [{label: '全部', value: ''}];
617
+ }
618
+ }
619
+ } else {
620
+ this.meterbooks = [{label: '全部', value: ''}];
621
+ this.initmeterbook();
622
+ }
623
+ },
624
+ async getaddress() {
625
+ let HttpReset = new HttpResetClass()
626
+ var data = await HttpReset.load('POST', 'rs/sql/manage_getarealist', {
627
+ data: {
628
+ condition: `1=1 and s.f_orgid = '${this.$login.f.orgid}'`
629
+ }
630
+ }, {resolveMsg: null, rejectMsg: '获取小区失败!'})
631
+ console.log('小区', data)
632
+ let house = [{label: '全部', value: ''}]
633
+ for (let row of data.data) {
634
+ house.push({label: row.f_residential_area, value: row.f_residential_area})
635
+ }
636
+ this.residentialArea = house
637
+ },
638
+ async initmeterbook(orgstr) {
639
+ if (orgstr == null) {
640
+ orgstr = this.f_filialeid;
641
+ }
642
+ //获取新的抄表册,先去清理所有的抄表册
643
+ this.$GetSaleParam.meterbooks = [];
644
+ //开始加载新的抄表册
645
+ await this.$LoadParams.loadMeterBook(orgstr)
646
+ this.meterbooks = [{label: '全部', value: ''}, ...this.$GetSaleParam.getMeterBooks()]
647
+ },
648
+ getotherfooter() {
649
+ this.other = [];
650
+ this.footer = [];
651
+ // let exportdata = this.getCondition;
652
+ let otherInData = [];
653
+ otherInData.push(`导出时间: ${this.$login.toStandardTimeString()}`);
654
+ let footerData = [], exportfield = this.getfield;
655
+ footerData.push("合计");
656
+ let self = this;
657
+ for (var field in self.sumsmodel) {
658
+ footerData.push(`${exportfield[field]}合计:${self.sumsmodel[field]}`);
659
+ }
660
+ this.footer.push(footerData);
661
+ this.other.push(otherInData);
662
+ },
663
+ userTypeChange() {
664
+ this.gasproperties = []
665
+ if (this.$refs.paged.$refs.cri.model !== null) {
666
+ this.$refs.paged.$refs.cri.model.f_gasproperties = []
667
+
668
+ console.log(this.$refs.paged.$refs.cri.model.f_user_type[0])
669
+ this.gasproperties = this.$appdata.getParam(this.$refs.paged.$refs.cri.model.f_user_type[0])
670
+ // this.gasproperties.push({label: '全部', value: ''})
671
+ } else {
672
+ this.gasproperties = [{label: '全部', value: ''}]
673
+ }
674
+ },
675
+ search() {
676
+ this.$refs.paged.$refs.cri.search()
677
+ },
678
+ cancel() {
679
+ this.show = false
680
+ },
681
+ selfSearch(args) {
682
+ args.condition = `${args.condition} ` + this.orgCondtionStr
683
+ let con = '1=1'
684
+ let mod = this.$refs.paged.$refs.cri.model
685
+ if (mod.startDate != null && mod.startDate != '') {
686
+ con += ` and f_input_date >= '${mod.startDate}'`
687
+ }
688
+ if (mod.endDate != null && mod.endDate != '') {
689
+ con += ` and f_input_date <= '${mod.endDate}'`
690
+ }
691
+ if (mod.startHandDate != null && mod.startHandDate != '') {
692
+ con += ` and f_hand_date >= '${mod.startHandDate}'`
693
+ }
694
+ if (mod.endHandDate != null && mod.endHandDate != '') {
695
+ con += ` and f_hand_date <= '${mod.endHandDate}'`
696
+ }
697
+ this.$refs.paged.$refs.cri.model.f_queryweb = this.isQueryWeb
698
+ this.model.search(args.condition, args.model, con)
699
+ this.sumsmodel = this.$refs.paged.$refs.grid.model.sums
700
+ },
701
+ clear() {
702
+ //清空部门和人员
703
+ this.$refs.paged.$refs.cri.$refs.sel.$children[1].selectres = []
704
+ //部门和人员变为全选
705
+ this.$refs.paged.$refs.cri.$refs.sel.$children[1].$children[0].isSelectAll = false
706
+ this.$refs.paged.$refs.cri.$refs.sel.$children[2].$children[0].isSelectAll = false
707
+ Object.keys(this.$refs.paged.$refs.cri.model).forEach((key) => {
708
+ this.$refs.paged.$refs.cri.model[key] = []
709
+ })
710
+ },
711
+ show() {
712
+ this.criteriaShow = true
713
+ },
714
+ hidden() {
715
+ this.criteriaShow = !this.criteriaShow
716
+ },
717
+ showmsg(obj) {
718
+ this.rowdata = obj
719
+ this.show = true
720
+ },
721
+ async getRes(condition, obj) {
722
+ this.orgCondtionStr = condition
723
+
724
+ },
725
+ stamp() {
726
+ this.all = false
727
+ //默认选择要打印的列
728
+ this.modelval = defaultPrint.config
729
+ this.fields = this.getfield
730
+ console.log('所有打印字段', this.fields)
731
+ this.printshow = true
732
+ this.put()
733
+ },
734
+ put() {
735
+ // 对Modelval进行排序
736
+ this.sortModelval()
737
+ this.thead = `<tr><th colspan=${this.modelval.length}>非民用用气查询</th></tr><tr>`
738
+ for (let key of this.modelval) {
739
+ this.thead += '<th>' + this.fields[key] + '</th>'
740
+ }
741
+ this.thead += '</tr>'
742
+ },
743
+ print() {
744
+ this.$refs.print.PrintAsFile()
745
+ this.printshow = false
746
+ },
747
+ dealmsg(val) {
748
+ this.rowdata = val
749
+ this.show = true
750
+ val.model = this.model.model
751
+ this.$dispatch('deal-msg', val)
752
+ },
753
+ close() {
754
+ this.printshow = false
755
+ this.all = false
756
+ },
757
+ // 对选择的列进行排序
758
+ sortModelval() {
759
+ let sortModel = []
760
+ Object.keys(this.fields).forEach((key) => {
761
+ if (this.modelval.includes(key)) {
762
+ sortModel.push(key)
763
+ }
764
+ })
765
+ this.modelval = sortModel
766
+ console.log('选择的打印的字段', this.modelval)
767
+ }
768
+
769
+ },
770
+ computed: {
771
+ getCondition() {
772
+ return {
773
+ condition: `${this.$refs.paged.$refs.cri.condition}` + this.orgCondtionStr,
774
+ condValue: this.$refs.paged.model.condValue,
775
+ startDate: this.$refs.paged.$refs.cri.model.startDate,
776
+ endDate: this.$refs.paged.$refs.cri.model.endDate,
777
+ f_queryweb: this.$refs.paged.$refs.cri.model.f_queryweb
778
+ }
779
+ },
780
+ getfield() {
781
+ return exportConfig.fmygasConfig
782
+ },
783
+ usertypes() {
784
+ return [{label: ' 全部 ', value: ''}, ...this.$appdata.getParam('用户类型')]
785
+ },
786
+ credentials() {
787
+ return [{label: ' 全部 ', value: ''}, ...this.$appdata.getParam('证件类型')]
788
+ },
789
+ metertype() {
790
+ return [{label: ' 全部 ', value: ''}, ...this.$appdata.getParam('气表类型')]
791
+ }
792
+ },
793
+ events: {},
794
+ watch: {
795
+ 'all'(val) {
796
+ if (val) {
797
+ this.modelval = this.bodyData
798
+ } else {
799
+ this.modelval = defaultPrint.config
800
+ this.put()
801
+ }
802
+ },
803
+ 'modelval.length'() {
804
+ this.put()
805
+ },
806
+ sumsmodel: {
807
+ handler: function (val) {
808
+ this.getotherfooter();
809
+ },
810
+ deep: true
811
+ },
812
+ async 'orgCondtionStr'(val) {
813
+ this.$refs.paged.$refs.cri.model.f_book_slice_area = []
814
+ this.$refs.paged.$refs.cri.model.f_meter_book = []
815
+ this.meterbooks = [{label: '全部', value: ''}];
816
+ if (this.lastorgstr != val) {
817
+ this.tempfalg = true;
818
+ this.lastorgstr = val;
819
+ }
820
+ if (this.tempfalg && val != null && val != '' && val.indexOf("(") > -1) {
821
+ this.tempfalg = false;
822
+ let a = val.substring(val.indexOf("(") + 2)
823
+ await this.initmeterbook(a.substring(0, a.indexOf(")") - 1));
824
+ }
825
+ this.updateParams()
826
+ },
827
+ }
828
+ }
829
+ </script>
830
+ <style>
831
+ .datapanel {
832
+ color: #333;
833
+ background-color: white;
834
+ padding: 10px 20px;
835
+ border-radius: 15px;
836
+ }
837
+ </style>