safecheck-client 3.0.33-103 → 3.0.33-104

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.
@@ -1,1205 +1,1205 @@
1
- <template>
2
- <div class="flex">
3
- <work-busy :is-busy="isbusy"></work-busy>
4
- <criteria-paged v-ref:paged :model="model">
5
- <criteria v-ref:criteria partial='criteria' @condition-changed='$parent.search'>
6
- <div class="form-horizontal select-overspread container-fluid auto" novalidate partial>
7
- <div v-show="!$parent.$parent.$parent.showItem" class="row">
8
- <div :class="$parent.$parent.style">
9
- <label class="font_normal_body">安检计划</label>
10
- <input v-model="$parent.$parent.f_check_plan.f_plan_name" class="input_search" placeholder="安检计划"
11
- readonly="readonly"
12
- style="width: 60%" type="text" @click="$parent.$parent.showChooser">
13
- </div>
14
- <div :class="$parent.$parent.style">
15
- <label class="font_normal_body">存在隐患</label>
16
- <v-select v-model="model.f_has_defect"
17
- :options='$parent.$parent.hasDefectOptions'
18
- :placeholder='model.f_has_defect'
19
- :value.sync="model.f_has_defect"
20
- class="select select_list"
21
- close-on-select
22
- condition="f_has_defect = '{}'"
23
- style="width:60% ">
24
- </v-select>
25
- </div>
26
- <div :class="$parent.$parent.style">
27
- <label class="font_normal_body">用户编号</label>
28
- <input v-model="model.f_userinfo_code" class="input_search" condition="f_userinfo_code = '{}'"
29
- placeholder="用户编号"
30
- style="width: 60%" type="text">
31
- </div>
32
- <div :class="$parent.$parent.style">
33
- <label class="font_normal_body">用户表号</label>
34
- <input v-model="model.f_meternumber" class="input_search" condition="f_meternumber = '{}'"
35
- placeholder="用户表号"
36
- style="width: 60%" type="text">
37
- </div>
38
- <div :class="$parent.$parent.style">
39
- <label class="font_normal_body">结果查询</label>
40
- <v-select
41
- v-model='model.f_is_repair'
42
- :options='$parent.$parent.repaired'
43
- :value-single="true" :value.sync="model.f_is_repair"
44
- class="select select_list"
45
- clear-button
46
- close-on-select
47
- condition="f_is_repair = '{}'"
48
- placeholder='维修结果查询' style="width: 60%"></v-select>
49
- </div>
50
- <div class=" col-sm-4 form-group button-range">
51
- <div class="span" style="float: right;margin-top: 8px">
52
- <div :class="{'button_shrink_left':$parent.$parent.$parent.showItem,'button_shrink_right':!$parent.$parent.$parent.showItem}" class="button_spacing"
53
- style="float: right"
54
- @click="$parent.$parent.hiddenr()"></div>
55
- <div :class="{'button_shrink_top':$parent.$parent.criteriaShow,'button_shrink_bottom':!$parent.$parent.criteriaShow}" class="button_spacing"
56
- style="float: right"
57
- @click="$parent.$parent.hidden()"></div>
58
- <button class="button_search button_spacing" style="float: right" @click="search">查询</button>
59
- <!-- <button style="float: right" class="button_search button_spacing" @click="$parent.$parent.toRepair">转维修</button>-->
60
- <div style="float: right">
61
- <export-excel-safe
62
- :choose-col="true"
63
- :data="{condition: $parent.$parent.model.condition,f_filialeids:$parent.$parent.model.f_filialeids,f_defect_content:$parent.$parent.model.f_defect_content}"
64
- :field="$parent.$parent.getfield"
65
- progress="safeGetExportProgress" sql-name="GetCheckPaperByDefectNew2" sqlurl="rs/logic/SafeExportExcel"
66
- template-name='安检隐患明细'></export-excel-safe>
67
- </div>
68
- </div>
69
- </div>
70
- </div>
71
- <div v-show="$parent.$parent.criteriaShow&&!$parent.$parent.$parent.showItem" class="row">
72
- <div :class="$parent.$parent.style">
73
- <label class="font_normal_body">片&emsp;&emsp;区</label>
74
- <v-select v-model="model.f_slice_area"
75
- :options='$parent.$parent.sliceArea' :value-single="true"
76
- :value.sync="model.f_slice_area" class="select_list select"
77
- clear-button
78
- close-on-select
79
- condition="f_slice_area='{}'" filer-key="name"
80
- placeholder='片区/管理站'
81
- style="width: 60%"
82
- @change="$parent.$parent.getmeterbook(model.f_slice_area)">
83
- </v-select>
84
- </div>
85
- <!-- <div :class="$parent.$parent.style2" style="margin: 0">-->
86
- <!-- <role-selector-safe-->
87
- <!-- role-name="安检员"-->
88
- <!-- role-lable="安&nbsp;检&nbsp;员&nbsp;"-->
89
- <!-- :resobjprop.sync="$parent.$parent.resids"-->
90
- <!-- @re-res="$parent.$parent.getRes"-->
91
- <!-- :value.sync="model.f_checker_id"-->
92
- <!-- v-model="model.f_checker_id"-->
93
- <!-- condition="f_checker_name = '{}'">-->
94
- <!-- </role-selector-safe>-->
95
- <!-- </div>-->
96
- <div :class="$parent.$parent.style">
97
- <label class="font_normal_body">区&emsp;&emsp;域</label>
98
- <v-select v-model="model.f_quyu" :options='$parent.$parent.quyus' :value-single="true"
99
- :value.sync="model.f_quyu" class="select_list select" close-on-select
100
- placeholder='区域'
101
- style="width: 60%"
102
- @change="$parent.$parent.quyuChange">
103
- </v-select>
104
- </div>
105
- <div :class="$parent.$parent.style">
106
- <label class="font_normal_body">营&ensp;业&ensp;厅</label>
107
- <v-select v-model="model.f_bumen" :options='$parent.$parent.bumens' :value-single="true"
108
- :value.sync="model.f_bumen" class="select_list select"
109
- close-on-select placeholder='营业厅' style="width: 60%"
110
- @change="$parent.$parent.bumenChange">
111
- </v-select>
112
- </div>
113
- <div :class="$parent.$parent.style">
114
- <label class="font_normal_body">小&emsp;&emsp;组</label>
115
- <v-select v-model="model.f_team" :options='$parent.$parent.teams' :value-single="true"
116
- :value.sync="model.f_team" class="select_list select"
117
- close-on-select placeholder='小组' style="width: 60%"
118
- @change="$parent.$parent.teamChange">
119
- </v-select>
120
- </div>
121
- <div :class="$parent.$parent.style">
122
- <label class="font_normal_body">安&ensp;检&ensp;员</label>
123
- <v-select v-model="model.f_checker_id" :multiple="true"
124
- :options='$parent.$parent.checkers' :value.sync="model.f_checker_id" class="select_list select"
125
- close-on-select condition="f_checker_name in {}" placeholder='安检员'
126
- style="width: 60%">
127
- </v-select>
128
- </div>
129
- <div :class="$parent.$parent.style">
130
- <label class="font_normal_body">抄&ensp;表&ensp;册</label>
131
- <v-select v-model="model.f_meter_book_num"
132
- :options='$parent.$parent.cbc' :value-single="true"
133
- :value.sync="model.f_meter_book_num" class="select_list select"
134
- clear-button
135
- close-on-select
136
- condition="f_meter_book_num={}" filer-key="name"
137
- placeholder='抄表册'
138
- style="width: 60%">
139
- </v-select>
140
- </div>
141
- <div :class="$parent.$parent.style">
142
- <label class="font_normal_body">起始时间</label>
143
- <datepicker
144
- v-model="model.f_start_time" :disabled-days-of-week="[]"
145
- :format="'yyyy-MM-dd'"
146
- :show-rest-button="reset"
147
- :value.sync="model.f_start_time"
148
- condition="f_offsite_time >= '{} 00:00:00'"
149
- placeholder='起始时间'
150
- style="width:60%">
151
- </datepicker>
152
- </div>
153
- <div :class="$parent.$parent.style">
154
- <label class="font_normal_body">结束时间</label>
155
- <datepicker
156
- v-model="model.f_end_time" :disabled-days-of-week="[]"
157
- :format="'yyyy-MM-dd'"
158
- :show-rest-button="reset"
159
- :value.sync="model.f_end_time"
160
- condition="f_offsite_time <= '{} 23:59:59'"
161
- placeholder='结束时间'
162
- style="width:60%">
163
- </datepicker>
164
- </div>
165
- <div :class="$parent.$parent.style">
166
- <label class="font_normal_body">维&ensp;修&ensp;员</label>
167
- <input v-model="model.f_repairman" class="input_search" condition="f_repairman = '{}'"
168
- placeholder="维修员"
169
- style="width: 60%" type="text">
170
- </div>
171
- <div :class="$parent.$parent.style">
172
- <label class="font_normal_body">处理查询</label>
173
- <v-select
174
- v-model='model.f_is_deal'
175
- :options='$parent.$parent.deals'
176
- :value-single="true" :value.sync="model.f_is_deal"
177
- class="select select_list"
178
- clear-button
179
- close-on-select
180
- condition="f_is_deal = '{}'"
181
- placeholder='处理结果查询' style="width: 60%"></v-select>
182
- </div>
183
- <div :class="$parent.$parent.style">
184
- <label class="font_normal_body">是否维修</label>
185
- <v-select
186
- v-model='model.f_repaired'
187
- :options='$parent.$parent.repairedOptions'
188
- :value-single="true" :value.sync="model.f_repaired"
189
- class="select select_list"
190
- clear-button
191
- close-on-select
192
- condition="f_repaired = '{}'"
193
- placeholder='是否维修' style="width: 60%"></v-select>
194
- </div>
195
- <div :class="$parent.$parent.style">
196
- <label class="font_normal_body">地&ensp;&ensp;&ensp;&ensp;址</label>
197
- <input v-model="model.f_address" class="input_search" condition="f_address like '%{}%'"
198
- placeholder="地址"
199
- style="width: 60%" type="text">
200
- </div>
201
- <div :class="$parent.$parent.style">
202
- <label class="font_normal_body">开户时间</label>
203
- <datepicker
204
- v-model="model.f_start_gastime" :disabled-days-of-week="[]"
205
- :format="'yyyy-MM-dd'"
206
- :show-rest-button="reset"
207
- :value.sync="model.f_start_gastime"
208
- condition="f_gas_date >= '{} 00:00:00'"
209
- placeholder='起始时间'
210
- style="width:60%">
211
- </datepicker>
212
- </div>
213
- <div :class="$parent.$parent.style">
214
- <label class="font_normal_body">开户时间</label>
215
- <datepicker
216
- v-model="model.f_end_gastime" :disabled-days-of-week="[]"
217
- :format="'yyyy-MM-dd'"
218
- :show-rest-button="reset"
219
- :value.sync="model.f_end_gastime"
220
- condition="f_gas_date <= '{} 23:59:59'"
221
- placeholder='结束时间'
222
- style="width:60%">
223
- </datepicker>
224
- </div>
225
- </div>
226
-
227
- <div v-show="$parent.$parent.$parent.showItem" class="row">
228
- <div :class="$parent.$parent.style">
229
- <label class="font_normal_body">安检计划</label>
230
- <input v-model="$parent.$parent.f_check_plan.f_plan_name" class="input_search" placeholder="安检计划"
231
- readonly="readonly"
232
- style="width: 60%" type="text" @click="$parent.$parent.showChooser">
233
- </div>
234
- <div :class="$parent.$parent.style">
235
- <label class="font_normal_body">存在隐患</label>
236
- <v-select v-model="model.f_has_defect"
237
- :options='$parent.$parent.hasDefectOptions'
238
- :placeholder='model.f_has_defect'
239
- :value.sync="model.f_has_defect"
240
- class="select select_list"
241
- close-on-select
242
- condition="f_has_defect = '{}'"
243
- style="width:60% ">
244
- </v-select>
245
- </div>
246
-
247
- <div class=" col-sm-4 form-group button-range">
248
- <div class="span" style="float: right;margin-top: 8px;margin-right: 50px">
249
- <div :class="{'button_shrink_left':$parent.$parent.$parent.showItem,'button_shrink_right':!$parent.$parent.$parent.showItem}" class="button_spacing"
250
- style="float: right"
251
- @click="$parent.$parent.hiddenr()"></div>
252
- <div :class="{'button_shrink_top':$parent.$parent.criteriaShow,'button_shrink_bottom':!$parent.$parent.criteriaShow}" class="button_spacing"
253
- style="float: right"
254
- @click="$parent.$parent.hidden()"></div>
255
- <button class="button_search button_spacing" style="float: right" @click="search">查询</button>
256
- <!-- <button style="float: right" class="button_search button_spacing" @click="$parent.$parent.toRepair">转维修</button>-->
257
- <div style="float: right">
258
- <export-excel-safe
259
- :choose-col="true"
260
- :data="{condition: $parent.$parent.model.condition,f_filialeids:$parent.$parent.model.f_filialeids,f_defect_content:$parent.$parent.model.f_defect_content}"
261
- :field="$parent.$parent.getfield"
262
- progress="safeGetExportProgress" sql-name="GetCheckPaperByDefectNew2" sqlurl="rs/logic/SafeExportExcel"
263
- template-name='安检计划明细'></export-excel-safe>
264
- </div>
265
- </div>
266
- </div>
267
-
268
-
269
- </div>
270
- <div v-show="$parent.$parent.criteriaShow&&$parent.$parent.$parent.showItem" class="row">
271
- <div :class="$parent.$parent.style">
272
- <label class="font_normal_body">用户编号</label>
273
- <input v-model="model.f_userinfo_code" class="input_search" condition="f_userinfo_code = '{}'"
274
- placeholder="用户编号"
275
- style="width: 60%" type="text">
276
- </div>
277
- <div :class="$parent.$parent.style">
278
- <label class="font_normal_body">用户表号</label>
279
- <input v-model="model.f_meternumber" class="input_search" condition="f_meternumber = '{}'"
280
- placeholder="用户表号"
281
- style="width: 60%" type="text">
282
- </div>
283
- <div :class="$parent.$parent.style">
284
- <label class="font_normal_body">结果查询</label>
285
- <v-select
286
- v-model='model.f_repaired'
287
- :options='$parent.$parent.repaired'
288
- :value-single="true" :value.sync="model.f_repaired"
289
- class="select select_list"
290
- clear-button
291
- close-on-select
292
- condition="f_repaired = '{}'"
293
- placeholder='处理结果查询' style="width: 60%"></v-select>
294
- </div>
295
- <div :class="$parent.$parent.style">
296
- <label class="font_normal_body">开户时间</label>
297
- <datepicker
298
- v-model="model.f_end_gastime" :disabled-days-of-week="[]"
299
- :format="'yyyy-MM-dd'"
300
- :show-rest-button="reset"
301
- :value.sync="model.f_end_gastime"
302
- condition="f_gas_date <= '{} 23:59:59'"
303
- placeholder='结束时间'
304
- style="width:60%">
305
- </datepicker>
306
- </div>
307
- <div :class="$parent.$parent.style">
308
- <label class="font_normal_body">区&emsp;&emsp;域</label>
309
- <v-select v-model="model.f_quyu" :options='$parent.$parent.quyus' :value-single="true"
310
- :value.sync="model.f_quyu" class="select_list select" close-on-select
311
- placeholder='区域'
312
- style="width: 60%"
313
- @change="$parent.$parent.quyuChange">
314
- </v-select>
315
- </div>
316
- <div :class="$parent.$parent.style">
317
- <label class="font_normal_body">营&ensp;业&ensp;厅</label>
318
- <v-select v-model="model.f_bumen" :options='$parent.$parent.bumens' :value-single="true"
319
- :value.sync="model.f_bumen" class="select_list select"
320
- close-on-select placeholder='营业厅' style="width: 60%"
321
- @change="$parent.$parent.bumenChange">
322
- </v-select>
323
- </div>
324
- <div :class="$parent.$parent.style">
325
- <label class="font_normal_body">小&emsp;&emsp;组</label>
326
- <v-select v-model="model.f_team" :options='$parent.$parent.teams' :value-single="true"
327
- :value.sync="model.f_team" class="select_list select"
328
- close-on-select placeholder='小组' style="width: 60%"
329
- @change="$parent.$parent.teamChange">
330
- </v-select>
331
- </div>
332
- <div :class="$parent.$parent.style">
333
- <label class="font_normal_body">安&ensp;检&ensp;员</label>
334
- <v-select v-model="model.f_checker_id" :multiple="true"
335
- :options='$parent.$parent.checkers' :value.sync="model.f_checker_id" class="select_list select"
336
- close-on-select condition="f_checker_name in {}" placeholder='安检员'
337
- style="width: 60%">
338
- </v-select>
339
- </div>
340
- </div>
341
- <div v-show="$parent.$parent.criteriaShow && $parent.$parent.$parent.showItem" class="row">
342
- <div :class="$parent.$parent.style">
343
- <label class="font_normal_body">片&emsp;&emsp;区</label>
344
- <v-select v-model="model.f_slice_area"
345
- :options='$parent.$parent.sliceArea' :value-single="true"
346
- :value.sync="model.f_slice_area" class="select_list select"
347
- clear-button
348
- close-on-select
349
- condition="f_slice_area='{}'" filer-key="name"
350
- placeholder='片区/管理站'
351
- style="width: 60%"
352
- @change="$parent.$parent.getmeterbook(model.f_slice_area)">
353
- </v-select>
354
- </div>
355
- <div :class="$parent.$parent.style">
356
- <label class="font_normal_body">抄&ensp;表&ensp;册</label>
357
- <v-select v-model="model.f_meter_book_num"
358
- :options='$parent.$parent.cbc' :value-single="true"
359
- :value.sync="model.f_meter_book_num" class="select_list select"
360
- clear-button
361
- close-on-select
362
- condition="f_meter_book_num={}" filer-key="name"
363
- placeholder='抄表册'
364
- style="width: 60%">
365
- </v-select>
366
- </div>
367
- <div :class="$parent.$parent.style">
368
- <label class="font_normal_body">起始时间</label>
369
- <datepicker
370
- v-model="model.f_start_time" :disabled-days-of-week="[]"
371
- :format="'yyyy-MM-dd'"
372
- :show-rest-button="reset"
373
- :value.sync="model.f_start_time"
374
- condition="f_offsite_time >= '{} 00:00:00'"
375
- placeholder='起始时间'
376
- style="width:60%">
377
- </datepicker>
378
- </div>
379
- <div :class="$parent.$parent.style">
380
- <label class="font_normal_body">结束时间</label>
381
- <datepicker
382
- v-model="model.f_end_time" :disabled-days-of-week="[]"
383
- :format="'yyyy-MM-dd'"
384
- :show-rest-button="reset"
385
- :value.sync="model.f_end_time"
386
- condition="f_offsite_time <= '{} 23:59:59'"
387
- placeholder='结束时间'
388
- style="width:60%">
389
- </datepicker>
390
- </div>
391
- </div>
392
- <div v-show="$parent.$parent.criteriaShow && $parent.$parent.$parent.showItem" class="row">
393
-
394
- <div :class="$parent.$parent.style">
395
- <label class="font_normal_body">维&ensp;修&ensp;员</label>
396
- <input v-model="model.f_repairman" class="input_search" condition="f_repairman = '{}'"
397
- placeholder="维修员"
398
- style="width: 60%" type="text">
399
- </div>
400
- <div :class="$parent.$parent.style">
401
- <label class="font_normal_body">处理查询</label>
402
- <v-select
403
- v-model='model.f_is_deal'
404
- :options='$parent.$parent.deals'
405
- :value-single="true" :value.sync="model.f_is_deal"
406
- class="select select_list"
407
- clear-button
408
- close-on-select
409
- condition="f_is_deal = '{}'"
410
- placeholder='处理结果查询' style="width: 60%"></v-select>
411
- </div>
412
- <div :class="$parent.$parent.style">
413
- <label class="font_normal_body">地&ensp;&ensp;&ensp;&ensp;址</label>
414
- <input v-model="model.f_address" class="input_search" condition="f_address like '%{}%'"
415
- placeholder="地址"
416
- style="width: 60%" type="text">
417
- </div>
418
- <div :class="$parent.$parent.style">
419
- <label class="font_normal_body">开户时间</label>
420
- <datepicker
421
- v-model="model.f_start_gastime" :disabled-days-of-week="[]"
422
- :format="'yyyy-MM-dd'"
423
- :show-rest-button="reset"
424
- :value.sync="model.f_start_gastime"
425
- condition="f_gas_date >= '{} 00:00:00'"
426
- placeholder='起始时间'
427
- style="width:60%">
428
- </datepicker>
429
- </div>
430
-
431
- </div>
432
- </div>
433
- </criteria>
434
- <data-grid v-ref:grid :model="model" class="list_area table_sy" partial='list'>
435
- <template partial='head'>
436
- <tr>
437
- <!-- <th><nobr><input type="checkbox" v-model="$parent.$parent.$parent.checkAll" @click.stop="()=>{return}" />全选</nobr></th>-->
438
- <th>
439
- <nobr>入户状态</nobr>
440
- </th>
441
- <th>
442
- <nobr>用户编号</nobr>
443
- </th>
444
- <th>
445
- <nobr>用户名</nobr>
446
- </th>
447
- <th>
448
- <nobr>用户表号</nobr>
449
- </th>
450
- <th>
451
- <nobr>用户电话</nobr>
452
- </th>
453
- <th>
454
- <nobr>用户小区</nobr>
455
- </th>
456
- <th>
457
- <nobr>用户地址</nobr>
458
- </th>
459
- <th>
460
- <nobr>开户时间</nobr>
461
- </th>
462
- <th>
463
- <nobr>安检时间</nobr>
464
- </th>
465
- <th>
466
- <nobr>安检员</nobr>
467
- </th>
468
- <th>
469
- <nobr>计划名</nobr>
470
- </th>
471
- <th>
472
- <nobr>是否有隐患</nobr>
473
- </th>
474
- <th>
475
- <nobr>隐患数</nobr>
476
- </th>
477
- <th>
478
- <nobr>处理数</nobr>
479
- </th>
480
- <th>
481
- <nobr>处理情况</nobr>
482
- </th>
483
- <th>
484
- <nobr>维修员</nobr>
485
- </th>
486
- <th>
487
- <nobr>隐患明细</nobr>
488
- </th>
489
- <!-- <th><nobr>备注</nobr></th>-->
490
- </tr>
491
- </template>
492
- <template partial='body'>
493
- <!-- <td style="text-align: center;white-space:nowrap;"><input type="checkbox" @click="$event.cancelBubble=true" :checked="$parent.$parent.$parent.isChecked(row.id)" @change="$parent.$parent.$parent.setCheckes(row.id)"></input></td>-->
494
- <td style="text-align: center;white-space:nowrap;">{{ row.f_entry_status }}</td>
495
- <td style="text-align: center;white-space:nowrap;">{{ row.f_userinfo_code }}</td>
496
- <td style="text-align: center;white-space:nowrap;">{{ row.f_user_name }}</td>
497
- <td style="text-align: center;white-space:nowrap;">{{ row.f_meternumber }}</td>
498
- <td style="text-align: center;white-space:nowrap;">{{ row.f_user_phone }}</td>
499
- <td style="text-align: center;white-space:nowrap;">{{ row.f_residential_area }}</td>
500
- <td style="text-align: center;white-space:nowrap;">{{ row.f_address }}</td>
501
- <td style="text-align: center;white-space:nowrap;">{{ row.f_gas_date }}</td>
502
- <td style="text-align: center;white-space:nowrap;">{{ row.f_offsite_time }}</td>
503
- <td style="text-align: center;white-space:nowrap;">{{ row.f_checker_name }}</td>
504
- <td style="text-align: center;white-space:nowrap;">{{ row.f_plan_name }}</td>
505
- <td style="text-align: center;white-space:nowrap;">{{ row.f_has_defect }}</td>
506
- <td style="text-align: center;white-space:nowrap;">{{ row.f_defect_count }}</td>
507
- <td style="text-align: center;white-space:nowrap;">{{ row.f_deal_count }}</td>
508
- <td style="text-align: center;white-space:nowrap;">{{ row.f_is_deal }}</td>
509
- <td style="text-align: center;white-space:nowrap;">{{ row.f_repairman }}</td>
510
- <td style="text-align: center;white-space:nowrap;">
511
- {{ $parent.$parent.$parent.trouble(row.f_defect_content) }}
512
- </td>
513
- <!-- <td style="text-align: center;white-space:nowrap;">{{ row.f_deal_remark}}</td>-->
514
- </template>
515
- </data-grid>
516
- </criteria-paged>
517
- <modal v-ref:modal :show.sync="showModal" backdrop="false">
518
- <div slot="modal-header" class="modal-header">
519
- <h4 class="modal-title">
520
- 选择计划
521
- </h4>
522
- </div>
523
- <div slot="modal-body" class="modal-body">
524
- <plan-chooser v-ref:chooser :f.sync="$login.f"></plan-chooser>
525
- </div>
526
- <div slot="modal-footer" class="modal-footer" style="text-align: center">
527
- <button class="button_search" @click="ok">确认</button>
528
- <button class="button_search" @click="cancel">取消</button>
529
- </div>
530
- </modal>
531
- <modal :backdrop="false" :show.sync="showModal2">
532
- <div slot="modal-header" class="modal-header">
533
- <h4 class="modal-title">
534
- 转维修
535
- </h4>
536
- </div>
537
- <div slot="modal-body" class="modal-body">
538
- <div v-if="true">
539
- <div class="row" style="margin-top: 10px">
540
- <label class="control-label font text-left"
541
- style="float:left;margin-left:20%;margin-top:5px">派发类型</label>
542
- <div class="col-xs-8 col-md-8">
543
- <v-select v-model="selectData.dispatchType" :options='dispatchTypeOptions' :value-single="true"
544
- :value.sync="selectData.dispatchType" close-on-select
545
- placeholder='派发类型'>
546
- </v-select>
547
- </div>
548
- </div>
549
- <div v-if="selectData.dispatchType=='派发给维修员'" class="row" style="margin-top: 10px">
550
- <label class="control-label font text-left" style="float:left;margin-left:20%;margin-top:5px">维&ensp;修&ensp;员</label>
551
- <div class="col-xs-8 col-md-8">
552
- <v-select
553
- :options='repairers'
554
- :value-single="true"
555
- :value.sync="selectData.f_repairman"
556
- close-on-select
557
- placeholder='请选择维修员'></v-select>
558
- </div>
559
- </div>
560
- <div v-if="selectData.dispatchType=='派发给站点'" class="row" style="margin-top: 10px">
561
- <label class="control-label font text-left" style="float:left;margin-left:20%;margin-top:5px">站&ensp;&ensp;&ensp;&ensp;点</label>
562
- <div class="col-xs-8 col-md-8">
563
- <right-tree
564
- :source="'dep=this.getParentByType($organization$).getSpecialResByType($department$),tool.getFullTree(dep.where(row.hasSpecialRole($派单员$)))'"
565
- :userid="userid"
566
- islist
567
- @re-res="getSiteRes"></right-tree>
568
- </div>
569
- </div>
570
- <div class="row" style="margin-top: 10px">
571
- <label class="control-label font text-left"
572
- style="float:left;margin-left:20%;margin-top:5px">报修类型</label>
573
- <div class="col-xs-8 col-md-8">
574
- <v-select :options='repairTypeOptions' :value-single="true"
575
- :value.sync="selectData.f_repairtype"
576
- class="select select_list"
577
- close-on-select
578
- style="width:60%">
579
- </v-select>
580
- </div>
581
- </div>
582
- <div class="row" style="margin-top: 10px">
583
- <label class="control-label font text-left" style="float:left;margin-left:20%;margin-top:5px">备&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;注</label>
584
- <div class="col-xs-8 col-md-8">
585
- <textarea v-model="selectData.f_remarks" style="width: 60%; height: 100px"></textarea>
586
- </div>
587
- </div>
588
- </div>
589
- </div>
590
- <div slot="modal-footer" class="modal-footer" style="text-align: center">
591
- <!-- <button class="button_search" @click="rectification">转维修</button>-->
592
- <button class="button_search" @click="cancel1">取消</button>
593
- </div>
594
- </modal>
595
- <modal :show.sync="showModal3">
596
- <div slot="modal-header" class="modal-header">
597
- <h4 class="modal-title">
598
- 转维修进度{{ progressbarWidth }}%
599
- </h4>
600
- </div>
601
- <div slot="modal-body" class="modal-body">
602
- <div class="progress">
603
- <div :style="'width:'+ progressbarWidth+'%'" aria-valuemax="100" aria-valuemin="0"
604
- aria-valuenow="60" class="progress-bar" role="progressbar">
605
- <!-- <span class="sr-only">40% 完成</span>-->
606
- </div>
607
- </div>
608
- </div>
609
- <div v-show="false" slot="modal-footer" class="modal-footer" style="text-align: center"></div>
610
- </modal>
611
- </div>
612
- </template>
613
- <script>
614
- import {PagedList} from 'vue-client'
615
- import HttpResetClass from "vue-client/src/plugins/HttpResetClass";
616
- import co from 'co'
617
- import Vue from 'vue'
618
- import * as Util from '../../../components/Util'
619
-
620
- let select = function* (self) {
621
- let http = new HttpResetClass()
622
- let getGasman = yield http.load('POST', '/rs/search', {
623
- source: 'this.getParentByType($department$).getAllChildrens().where(row.getAttributes().get($rolestr$).indexOf($安检员$) != -1))',
624
- userid: self.$login.f.id
625
- }, {resolveMsg: null, rejectMsg: null})
626
- //tag
627
- self.checkersid.push({label: '全部', value: ''})
628
- getGasman.data.forEach((checker) => {
629
- self.checkersid.push({label: checker.name, value: checker.name})
630
- })
631
- }
632
- export default {
633
- title: '隐患查询',
634
- data() {
635
- let model = new PagedList('rs/sql/GetCheckPaperByDefectNew2', 20, {
636
- f_filialeids: 'this.f_filialeids', f_defect_content: 'this.f_defect_content'
637
- })
638
- model.f_filialeids = '(' + this.$login.f.orgid + ')'
639
- model.f_defect_content = "CASE WHEN CHARINDEX( '\"result\":\"正常\"', f_defect_content ) > 0 THEN '无隐患' ELSE replace(replace(replace( replace( RIGHT ( f_defect_content, len( f_defect_content ) - 26 ), substring('{}',2,1), '' ), substring('{}',1,1), '' ),']',''),'\"','') END"
640
- return {
641
- quyus: [{label: '请选择', value: ''}, ...this.$appdata.getParam('区域')],
642
- bumens: [{label: '请选择', value: ''}],
643
- teams: [{label: '请选择', value: ''}],
644
- checkers: [{label: '请选择', value: ''}],
645
- allCheckers: [{label: '请选择', value: ''}],
646
- repaired: [{label: '全部', value: ''}, {label: '未完成', value: '未完成'}, {label: '已完成', value: '已完成'}],
647
- deals: [{label: '全部', value: ''}, {label: '未处理', value: '未处理'}, {
648
- label: '已处理',
649
- value: '已处理'
650
- }, {label: '处理中', value: '处理中'}],
651
- hasDefectOptions: [{label: '全部', value: ''}, {label: '有隐患', value: '有隐患'}, {
652
- label: '无隐患',
653
- value: '无隐患'
654
- }],
655
- f: this.$login.f,
656
- model: model,
657
- criteriaShow: false,
658
- checkAll: false,
659
- timercount: 0,
660
- showModal2: false,
661
- repairTypeOptions: this.$appdata.getParam('转维修类型'),
662
- dispatchTypeOptions: [{label: '派发给维修员', value: '派发给维修员'}],
663
- checkes: [],
664
- showModal: false,
665
- f_check_plan: {f_plan_name: '', id: ''},
666
- sumsmodel: {},
667
- resids: {},
668
- all: false,
669
- fields: {},
670
-
671
- selectData: {
672
- dispatchType: '',
673
- f_repairman: '',
674
- f_remarks: '',
675
- f_repairtype: ''
676
- },
677
- progressbarWidth: '0',
678
- modelval: [],
679
- isbusy: false,
680
- checkersid: [],
681
- showModal3: false,
682
- toRepairCount: 0,
683
- sliceArea: [],
684
- callSends: [],
685
- cbc: [],
686
- repairedOptions: [{label: '全部', value: ''}, {label: '已修', value: '已修'}, {label: '未修', value: '未修'}],
687
- repairers: [],
688
- cbcs: [],
689
- thead: '',
690
- headData: ['入户状态', '用户编号', '用户表号', '用户名', '用户电话', '用户小区', '用户地址', '开户时间', '安检时间', '安检员', '计划名', '是否有隐患', '隐患数', '隐患明细', '处理情况'],
691
- bodyData: ['f_entry_status', 'f_userinfo_code', 'f_meternumber', 'f_user_name', 'f_user_phone', 'f_residential_area', 'f_address', 'f_gas_date', 'f_offsite_time', 'f_checker_name', 'f_plan_name', 'f_has_defect', 'f_defect_count', 'defecttext', 'f_is_deal'],
692
- }
693
- },
694
- props: {
695
- style: {
696
- type: String,
697
- default: 'col-sm-2 form-group'
698
- },
699
- style2: {
700
- type: String,
701
- default: 'col-sm-4 form-group'
702
- }
703
-
704
- },
705
-
706
- methods: {
707
- bumenChange(val) {
708
- if (val) {
709
- this.teams = this.$appdata.getParam(`工单-` + val) ? [{
710
- label: '请选择',
711
- value: ''
712
- }, ...this.$appdata.getParam(`工单-` + val)] : [{label: '请选择', value: ''}]
713
- }
714
- },
715
- teamChange(val) {
716
- if (val) {
717
- this.checkers = this.$appdata.getParam(val) ? [{
718
- label: '请选择',
719
- value: ''
720
- }, ...this.$appdata.getParam(val)] : [{label: '请选择', value: ''}]
721
- }
722
- },
723
- quyuChange(val) {
724
- if (val) {
725
- this.bumens = this.$appdata.getParam(val) ? [{
726
- label: '请选择',
727
- value: ''
728
- }, ...this.$appdata.getParam(val)] : [{label: '请选择', value: ''}]
729
- }
730
- },
731
- trouble(val) {
732
- // return val.replaceAll("'",'')
733
- // .replaceAll("\"",'')
734
- // .replaceAll("{",'')
735
- // .replaceAll("}",'')
736
- // .replaceAll("]",'')
737
- // .replaceAll("[",'')
738
- // .replaceAll("result:",'')
739
- // .replaceAll("data:",'')
740
- // .replaceAll("有隐患",'')
741
- // .replaceAll(",",'')
742
-
743
-
744
- const defect_content = JSON.parse(val)
745
- let result = ''
746
- if (defect_content.data) {
747
- const jsonData = defect_content.data
748
- for (const itemdata of jsonData) {
749
- const keys = Object.keys(itemdata)
750
- for (const itm of keys) {
751
- const value = itemdata[itm]
752
- result += itm + ':' + value
753
- }
754
- }
755
- }
756
- return result
757
- },
758
- getEmp() {
759
- let val = {
760
- source: 'this.getParentByType($organization$).getSpecialResByType($user$).where(row.getAttributes().get($rolestr$)!=null ).where(row.getAttributes().get($rolestr$).indexOf($维修员$) != -1))',
761
- userid: `${this.$login.f.id}`
762
- }
763
- let http = new HttpResetClass()
764
- http.load('POST', '/rs/search', {data: val}, {resolveMsg: null, rejectMsg: null}).then((res) => {
765
- let str = ''
766
- res.data.forEach((item, idx, arr) => {
767
- //tag
768
- if (idx + 1 == arr.length) {
769
- str += item.id
770
- } else {
771
- str += item.id + ','
772
- }
773
-
774
- })
775
- let http1 = new HttpResetClass()
776
- http1.load('POST', 'rs/sql/tel_singleTable_OrderBy', {
777
- data: {
778
- items: 'id,f_user_telephone',
779
- tablename: 't_user',
780
- condition: `id in (${str})`,
781
- orderitem: 'id'
782
- }
783
- }, {resolveMsg: null, rejectMsg: null}).then((ress) => {
784
-
785
- res.data.forEach((user) => {
786
- try {
787
- ress.data.forEach((tel, tidx, arr) => {
788
- //tag
789
- if (user.id == tel.id) {
790
- this.repairers.push({label: `${user.name}:${tel.f_user_telephone}`, value: user.name})
791
- ress.data.splice(tidx, 1)
792
- //tag
793
- throw new Error("跳出循环");
794
- }
795
- })
796
- } catch (e) {
797
- //tag
798
- }
799
- })
800
- })
801
-
802
- })
803
- },
804
- toRepair() {
805
- //tag
806
- this.showModal2 = true
807
- },
808
- async rectification() {
809
- this.isbusy = true
810
- // if (this.checkAll){
811
- let data = {
812
- f_filialeids: this.model.params.f_filialeids,
813
- f_defect_content: this.model.params.f_defect_content,
814
- condition: this.model.params.condition
815
- }
816
- let res1 = await new HttpResetClass().load('post', 'rs/sql/GetCheckPaperByDefectNew2', {data: data})
817
- for (let i = 0; i < res1.data.length; i++) {
818
- let data1 = {
819
- f_paper_id: res1.data[i].id,
820
- condition: `f_repaire_type != '无隐患'`
821
- }
822
- let res2 = await new HttpResetClass().load('POST', 'rs/sql/GetDefectByPaperIdNew2', {data: data1})
823
- //tag
824
- const uploadData = {
825
- model: {
826
- serviceacitivity: [{
827
- f_service_acitivity_type: '派单'
828
- }],
829
- f_repairitems: {},
830
- failure: '',
831
- f_source: '安检',
832
- f_service_id: '',
833
- f_contact_phone: '',
834
- f_meetunit: '',
835
- f_phone: '',
836
- f_user_name: '',
837
- f_address: '',
838
- f_repair_date: '',
839
- f_reciever: '',
840
- f_remarks: '',
841
- f_user_type: '',
842
- f_area: '',
843
- f_unit_name: '',
844
- f_street: '',
845
- f_residential_area: '',
846
- f_building: '',
847
- f_unit: '',
848
- f_floor: '',
849
- f_room: '',
850
- aState: '',
851
- f_repairtype: '',
852
- f_userinfo_id: '',
853
- f_userinfo_code: '',
854
- f_orgstr: '',
855
- f_outlets: '',
856
- f_attendant: this.$login.f.name
857
- },
858
- loginUser: {
859
- name: this.$login.f.name,
860
- ename: this.$login.f.ename
861
- },
862
- user: {
863
- f_userinfo_id: ''
864
- },
865
- callObj: null
866
- }
867
-
868
- uploadData.model.serviceacitivity[0].f_reciever = this.selectData.f_repairman
869
- // uploadData.model.f_meetunit = self.$login.f.orgpathnames
870
- // uploadData.model.f_orgstr = self.$login.f.orgpathstr
871
- // uploadData.model.f_outlets = self.$login.f.f_parentname
872
- uploadData.model.f_meetunit = this.$login.f.deps
873
- uploadData.model.f_orgid = this.$login.f.orgid
874
- uploadData.model.f_filiale = this.$login.f.org
875
- uploadData.model.f_outlets = this.$login.f.deps
876
- uploadData.model.f_filiale_id = this.$login.f.orgid
877
- uploadData.toRepair = '一级派单'
878
- let res3 = await new HttpResetClass().load('post', '/rs/sql/GetUserForRepaireNew2', {data: {f_userinfo_id: res1.data[i].f_userinfo_id}})
879
- uploadData.model = Object.assign(uploadData.model, res3.data[0])
880
- uploadData.user.f_userinfo_id = res3.data[0].f_userinfo_id
881
- uploadData.model.f_repair_date = Util.getNowDate()
882
- uploadData.model.f_repairtype = res3.data[0].f_repairtype
883
- uploadData.model.f_remarks = res3.data[0].f_remarks
884
- let failure = []
885
- res2.data.forEach(row => {
886
- if (row.f_repaire_type == '隐患未处理') {
887
- console.log('row.f_item_value', row.f_item_value)
888
- failure.push({
889
- f_failure_type: row.f_item_name,
890
- failurecase: row.f_item_value ? row.f_item_value.split(',') : ''
891
- })
892
- }
893
- })
894
- uploadData.model.failure = failure
895
- // 拼接repairitems
896
- let rows = JSON.parse(JSON.stringify(res2.data))
897
- let repairitems = {
898
- data: []
899
- }
900
- let safecheckOptions = [{"data": "已处理"}, {"data": "未处理"}]
901
- // 取隐患未处理的
902
- rows = rows.filter(row => row.f_repaire_type == '隐患未处理')
903
- //tag)
904
- // 开始拼接
905
- rows.forEach(row => {
906
- let existIndex = -1
907
- // 判断该设备是否已经存在
908
- for (let i = 0; i < repairitems.data.length; i++) {
909
- if (repairitems.data[i].f_type == row.f_device_type) {
910
- existIndex = i
911
- break
912
- }
913
- }
914
- if (existIndex == -1) {
915
- // 不存在则新建
916
- let newItem = {
917
- f_type: row.f_device_type,
918
- details: [{
919
- f_defect_id: row.id,
920
- f_project: `${row.f_item_name}:${row.f_item_value}`,
921
- type: 'selector',
922
- options: safecheckOptions
923
- }]
924
- }
925
- repairitems.data.push(newItem)
926
- } else {
927
- // 存在则追加
928
- repairitems.data[existIndex].details.push({
929
- f_defect_id: row.id,
930
- f_project: `${row.f_item_name}:${row.f_item_value}`,
931
- type: 'selector',
932
- options: safecheckOptions
933
- })
934
- }
935
- })
936
- uploadData.model.f_repairitems = repairitems
937
- uploadData.rows = rows
938
- //tag)
939
- //tag
940
- if (uploadData.model.f_repairitems.data.length > 0) {
941
- this.callSends.push(uploadData)
942
- } else {
943
- //tag
944
- }
945
- }
946
- //tag)
947
- let timer = setInterval(async () => {
948
- this.showModal3 = true
949
- this.isbusy = false
950
- if (this.timercount < this.callSends.length) {
951
- //tag)
952
- let rows = this.callSends[this.timercount].rows
953
- //tag)
954
- let result = await this.$resetpost('/rs/logic/callerSend', this.callSends[this.timercount])
955
- //tag)
956
- if (result.data.f_service_id) {
957
- const data = {
958
- f_paper_id: rows[0].f_paper_id,
959
- f_service_id: result.data.f_service_id,
960
- itemsId: this.$login.convertToIn(rows.map(row => row.id))
961
- }
962
- //tag
963
- let updateRes = await this.$resetpost('/rs/logic/updateDefectStateNew', data)
964
- }
965
- this.toRepairCount++
966
- //tag
967
- this.timercount++
968
- } else {
969
- clearInterval(timer)
970
- //tag
971
- this.callSends = []
972
- this.timercount = 0
973
- this.showModal3 = false
974
- this.cancel1()
975
- this.$showMessage('本次转维修成功' + this.toRepairCount + '单')
976
- this.toRepairCount = 0
977
- }
978
- }, 3000)
979
- },
980
- cancel1() {
981
- this.showModal2 = false
982
- this.selectData = {
983
- dispatchType: '',
984
- f_repairman: '',
985
- f_remarks: '',
986
- f_repairtype: ''
987
- }
988
- },
989
- sleep(d) {
990
- //tag)
991
- var t = Date.now()
992
- while (Date.now - t <= d) {
993
-
994
- }
995
- //tag)
996
- },
997
- isChecked(v) {
998
- // 如果全选,不在的按选中算,否则,在的按选中算
999
- if (this.checkAll) {
1000
- return this.checkes.indexOf(v) == -1
1001
- } else {
1002
- return this.checkes.indexOf(v) != -1
1003
- }
1004
- },
1005
- setCheckAll() {
1006
- this.checkAll = this.checkAll ? false : true;
1007
- // 全选改变后,清空选中数据
1008
- this.checkes = []
1009
- },
1010
- setCheckes(id) {
1011
- let index = this.checkes.indexOf(id)
1012
- if (index < 0) {
1013
- this.checkes.push(id)
1014
- } else {
1015
- this.checkes.splice(index, 1)
1016
- }
1017
- },
1018
-
1019
- getmeterbook(val) {
1020
- this.cbc = []
1021
- this.cbc.push({
1022
- label: '全部',
1023
- value: ''
1024
- })
1025
- if (val == '') {
1026
-
1027
- this.cbcs.forEach(res => {
1028
- this.cbc.push({
1029
- label: res.f_book_name,
1030
- value: res.id
1031
- })
1032
- })
1033
- } else {
1034
- this.cbcs.forEach(res => {
1035
- if (res.f_book_slice_area == val) {
1036
- this.cbc.push({
1037
- label: res.f_book_name,
1038
- value: res.id
1039
- })
1040
- }
1041
- })
1042
- }
1043
- },
1044
-
1045
- Mreadibook(val) {
1046
- //tag
1047
- //tag
1048
- this.sliceArea = []
1049
- if (val) {
1050
- new HttpResetClass().load('POST', `/rs/sql/tel_singleTable_OrderBy`, {
1051
- data: {
1052
- items: 'name',
1053
- tablename: 't_zone',
1054
- condition: `parentid in ${val}`,
1055
- orderitem: 'id'
1056
- }
1057
- }, {resolveMsg: null, rejectMsg: null}).then((res) => {
1058
- this.sliceArea.push({
1059
- label: '全部',
1060
- value: ''
1061
- })
1062
- res.data.forEach(ress => {
1063
- this.sliceArea.push({
1064
- label: ress.name,
1065
- value: ress.name
1066
- })
1067
- })
1068
-
1069
- })
1070
- }
1071
- },
1072
- getAllMeterBook(val) {
1073
- //tag
1074
- //tag
1075
- this.cbcs = []
1076
- if (val) {
1077
- new HttpResetClass().load('POST', `/rs/sql/tel_singleTable_OrderBy`, {
1078
- data: {
1079
- items: 'f_book_name,f_book_slice_area,id',
1080
- tablename: 't_meter_book',
1081
- condition: `f_filiale_id in ${val}`,
1082
- orderitem: 'id'
1083
- }
1084
- }, {resolveMsg: null, rejectMsg: null}).then((res) => {
1085
- res.data.forEach(ress => {
1086
- this.cbcs.push({
1087
- id: ress.id,
1088
- f_book_name: ress.f_book_name,
1089
- f_book_slice_area: ress.f_book_slice_area
1090
- })
1091
- })
1092
- this.cbc = []
1093
- this.cbc.push({
1094
- label: '全部',
1095
- value: ''
1096
- })
1097
- this.cbcs.forEach(res => {
1098
- this.cbc.push({
1099
- label: res.f_book_name,
1100
- value: res.id
1101
- })
1102
- })
1103
- })
1104
- }
1105
- },
1106
- hiddenr() {
1107
- this.$parent.showItem = !this.$parent.showItem
1108
- },
1109
- hidden() {
1110
- this.criteriaShow = !this.criteriaShow
1111
- },
1112
- search(args) {
1113
- //tag
1114
- if (this.f_check_plan.f_plan_name) {
1115
- args.condition += ` and f_check_plan_id = '${this.f_check_plan.id}'`
1116
- }
1117
- this.checkes = []
1118
- this.checkAll = false
1119
- this.model.search(args.condition, args.model)
1120
- },
1121
- getRes(obj) {
1122
- //tag
1123
- this.resids = {res: obj.res[0], resids: obj.resids[0]}
1124
- this.model.f_filialeids = this.$login.convertToIn(obj.resids);
1125
- this.Mreadibook(this.model.f_filialeids)
1126
- this.getAllMeterBook(this.model.f_filialeids)
1127
- },
1128
- showChooser() {
1129
- this.showModal = true
1130
- },
1131
- ok() {
1132
- this.showModal = false
1133
- if (this.$refs.modal.$children[0].selectedRow.id) {
1134
- this.f_check_plan = this.$refs.modal.$children[0].selectedRow
1135
- }
1136
- },
1137
- cancel() {
1138
- this.showModal = false
1139
- this.f_check_plan = {f_plan_name: '', id: ''}
1140
- },
1141
- getAllChecker() {
1142
- new HttpResetClass().load('POST', `/rs/sql/tel_singleTable_OrderBy`, {
1143
- data: {
1144
- items: 'name',
1145
- tablename: 't_user',
1146
- condition: `state = '在职' and rolestr like '%安检员%'`,
1147
- orderitem: 'id'
1148
- }
1149
- }, {resolveMsg: null, rejectMsg: null}).then((res) => {
1150
- res.data.forEach(ress => {
1151
- this.allCheckers.push({
1152
- label: ress.name,
1153
- value: ress.name
1154
- })
1155
- })
1156
- this.checkers = this.allCheckers
1157
- })
1158
- }
1159
- },
1160
- ready() {
1161
- //tag
1162
- this.$refs.paged.$refs.criteria.model.f_has_defect = '有隐患'
1163
- this.getEmp()
1164
- let gen = select(this)
1165
- // this.Mreadibook(`('${this.$login.f.orgid}')`)
1166
- co(gen)
1167
- this.getAllChecker()
1168
- },
1169
- watch: {
1170
- 'timercount'() {
1171
- if (this.timercount === 0) {
1172
- this.progressbarWidth = '0'
1173
- } else {
1174
- //tag
1175
- //tag
1176
- this.progressbarWidth = parseInt(this.timercount * 100 / (this.callSends.length + 1))
1177
- }
1178
-
1179
- }
1180
- },
1181
- computed: {
1182
- selected() {
1183
- return this.$refs.paged.$refs.grid.selected
1184
- },
1185
- getfield() {
1186
- //tag
1187
- let data = {}
1188
- this.bodyData.forEach((value, index) => {
1189
- data[this.bodyData[index]] = this.headData[index]
1190
- })
1191
- //合计字段打印
1192
- this.tfoot = `<tr><th colspan=${this.modelval.length}>全表汇总信息: `
1193
- if (this.sumsmodel) {
1194
- Object.keys(this.sumsmodel).forEach((key) => {
1195
- this.tfoot += this.fields[key] + '合计: ' + `<font color="blue">${this.sumsmodel[key]} </font>`
1196
- })
1197
- } else {
1198
- this.tfoot += '暂无'
1199
- }
1200
- this.tfoot += '</th></tr>'
1201
- return data
1202
- }
1203
- }
1204
- }
1205
- </script>
1
+ <template>
2
+ <div class="flex">
3
+ <work-busy :is-busy="isbusy"></work-busy>
4
+ <criteria-paged v-ref:paged :model="model">
5
+ <criteria v-ref:criteria partial='criteria' @condition-changed='$parent.search'>
6
+ <div class="form-horizontal select-overspread container-fluid auto" novalidate partial>
7
+ <div v-show="!$parent.$parent.$parent.showItem" class="row">
8
+ <div :class="$parent.$parent.style">
9
+ <label class="font_normal_body">安检计划</label>
10
+ <input v-model="$parent.$parent.f_check_plan.f_plan_name" class="input_search" placeholder="安检计划"
11
+ readonly="readonly"
12
+ style="width: 60%" type="text" @click="$parent.$parent.showChooser">
13
+ </div>
14
+ <div :class="$parent.$parent.style">
15
+ <label class="font_normal_body">存在隐患</label>
16
+ <v-select v-model="model.f_has_defect"
17
+ :options='$parent.$parent.hasDefectOptions'
18
+ :placeholder='model.f_has_defect'
19
+ :value.sync="model.f_has_defect"
20
+ class="select select_list"
21
+ close-on-select
22
+ condition="f_has_defect = '{}'"
23
+ style="width:60% ">
24
+ </v-select>
25
+ </div>
26
+ <div :class="$parent.$parent.style">
27
+ <label class="font_normal_body">用户编号</label>
28
+ <input v-model="model.f_userinfo_code" class="input_search" condition="f_userinfo_code = '{}'"
29
+ placeholder="用户编号"
30
+ style="width: 60%" type="text">
31
+ </div>
32
+ <div :class="$parent.$parent.style">
33
+ <label class="font_normal_body">用户表号</label>
34
+ <input v-model="model.f_meternumber" class="input_search" condition="f_meternumber = '{}'"
35
+ placeholder="用户表号"
36
+ style="width: 60%" type="text">
37
+ </div>
38
+ <div :class="$parent.$parent.style">
39
+ <label class="font_normal_body">结果查询</label>
40
+ <v-select
41
+ v-model='model.f_is_repair'
42
+ :options='$parent.$parent.repaired'
43
+ :value-single="true" :value.sync="model.f_is_repair"
44
+ class="select select_list"
45
+ clear-button
46
+ close-on-select
47
+ condition="f_is_repair = '{}'"
48
+ placeholder='维修结果查询' style="width: 60%"></v-select>
49
+ </div>
50
+ <div class=" col-sm-4 form-group button-range">
51
+ <div class="span" style="float: right;margin-top: 8px">
52
+ <div :class="{'button_shrink_left':$parent.$parent.$parent.showItem,'button_shrink_right':!$parent.$parent.$parent.showItem}" class="button_spacing"
53
+ style="float: right"
54
+ @click="$parent.$parent.hiddenr()"></div>
55
+ <div :class="{'button_shrink_top':$parent.$parent.criteriaShow,'button_shrink_bottom':!$parent.$parent.criteriaShow}" class="button_spacing"
56
+ style="float: right"
57
+ @click="$parent.$parent.hidden()"></div>
58
+ <button class="button_search button_spacing" style="float: right" @click="search">查询</button>
59
+ <!-- <button style="float: right" class="button_search button_spacing" @click="$parent.$parent.toRepair">转维修</button>-->
60
+ <div style="float: right">
61
+ <export-excel-safe
62
+ :choose-col="true"
63
+ :data="{condition: $parent.$parent.model.condition,f_filialeids:$parent.$parent.model.f_filialeids,f_defect_content:$parent.$parent.model.f_defect_content}"
64
+ :field="$parent.$parent.getfield"
65
+ progress="safeGetExportProgress" sql-name="GetCheckPaperByDefectNew2" sqlurl="rs/logic/SafeExportExcel"
66
+ template-name='安检隐患明细'></export-excel-safe>
67
+ </div>
68
+ </div>
69
+ </div>
70
+ </div>
71
+ <div v-show="$parent.$parent.criteriaShow&&!$parent.$parent.$parent.showItem" class="row">
72
+ <div :class="$parent.$parent.style">
73
+ <label class="font_normal_body">片&emsp;&emsp;区</label>
74
+ <v-select v-model="model.f_slice_area"
75
+ :options='$parent.$parent.sliceArea' :value-single="true"
76
+ :value.sync="model.f_slice_area" class="select_list select"
77
+ clear-button
78
+ close-on-select
79
+ condition="f_slice_area='{}'" filer-key="name"
80
+ placeholder='片区/管理站'
81
+ style="width: 60%"
82
+ @change="$parent.$parent.getmeterbook(model.f_slice_area)">
83
+ </v-select>
84
+ </div>
85
+ <!-- <div :class="$parent.$parent.style2" style="margin: 0">-->
86
+ <!-- <role-selector-safe-->
87
+ <!-- role-name="安检员"-->
88
+ <!-- role-lable="安&nbsp;检&nbsp;员&nbsp;"-->
89
+ <!-- :resobjprop.sync="$parent.$parent.resids"-->
90
+ <!-- @re-res="$parent.$parent.getRes"-->
91
+ <!-- :value.sync="model.f_checker_id"-->
92
+ <!-- v-model="model.f_checker_id"-->
93
+ <!-- condition="f_checker_name = '{}'">-->
94
+ <!-- </role-selector-safe>-->
95
+ <!-- </div>-->
96
+ <div :class="$parent.$parent.style">
97
+ <label class="font_normal_body">区&emsp;&emsp;域</label>
98
+ <v-select v-model="model.f_quyu" :options='$parent.$parent.quyus' :value-single="true"
99
+ :value.sync="model.f_quyu" class="select_list select" close-on-select
100
+ placeholder='区域'
101
+ style="width: 60%"
102
+ @change="$parent.$parent.quyuChange">
103
+ </v-select>
104
+ </div>
105
+ <div :class="$parent.$parent.style">
106
+ <label class="font_normal_body">营&ensp;业&ensp;厅</label>
107
+ <v-select v-model="model.f_bumen" :options='$parent.$parent.bumens' :value-single="true"
108
+ :value.sync="model.f_bumen" class="select_list select"
109
+ close-on-select placeholder='营业厅' style="width: 60%"
110
+ @change="$parent.$parent.bumenChange">
111
+ </v-select>
112
+ </div>
113
+ <div :class="$parent.$parent.style">
114
+ <label class="font_normal_body">小&emsp;&emsp;组</label>
115
+ <v-select v-model="model.f_team" :options='$parent.$parent.teams' :value-single="true"
116
+ :value.sync="model.f_team" class="select_list select"
117
+ close-on-select placeholder='小组' style="width: 60%"
118
+ @change="$parent.$parent.teamChange">
119
+ </v-select>
120
+ </div>
121
+ <div :class="$parent.$parent.style">
122
+ <label class="font_normal_body">安&ensp;检&ensp;员</label>
123
+ <v-select v-model="model.f_checker_id" :multiple="true"
124
+ :options='$parent.$parent.checkers' :value.sync="model.f_checker_id" class="select_list select"
125
+ close-on-select condition="f_checker_name in {}" placeholder='安检员'
126
+ style="width: 60%">
127
+ </v-select>
128
+ </div>
129
+ <div :class="$parent.$parent.style">
130
+ <label class="font_normal_body">抄&ensp;表&ensp;册</label>
131
+ <v-select v-model="model.f_meter_book_num"
132
+ :options='$parent.$parent.cbc' :value-single="true"
133
+ :value.sync="model.f_meter_book_num" class="select_list select"
134
+ clear-button
135
+ close-on-select
136
+ condition="f_meter_book_num={}" filer-key="name"
137
+ placeholder='抄表册'
138
+ style="width: 60%">
139
+ </v-select>
140
+ </div>
141
+ <div :class="$parent.$parent.style">
142
+ <label class="font_normal_body">起始时间</label>
143
+ <datepicker
144
+ v-model="model.f_start_time" :disabled-days-of-week="[]"
145
+ :format="'yyyy-MM-dd'"
146
+ :show-rest-button="reset"
147
+ :value.sync="model.f_start_time"
148
+ condition="f_offsite_time >= '{} 00:00:00'"
149
+ placeholder='起始时间'
150
+ style="width:60%">
151
+ </datepicker>
152
+ </div>
153
+ <div :class="$parent.$parent.style">
154
+ <label class="font_normal_body">结束时间</label>
155
+ <datepicker
156
+ v-model="model.f_end_time" :disabled-days-of-week="[]"
157
+ :format="'yyyy-MM-dd'"
158
+ :show-rest-button="reset"
159
+ :value.sync="model.f_end_time"
160
+ condition="f_offsite_time <= '{} 23:59:59'"
161
+ placeholder='结束时间'
162
+ style="width:60%">
163
+ </datepicker>
164
+ </div>
165
+ <div :class="$parent.$parent.style">
166
+ <label class="font_normal_body">维&ensp;修&ensp;员</label>
167
+ <input v-model="model.f_repairman" class="input_search" condition="f_repairman = '{}'"
168
+ placeholder="维修员"
169
+ style="width: 60%" type="text">
170
+ </div>
171
+ <div :class="$parent.$parent.style">
172
+ <label class="font_normal_body">处理查询</label>
173
+ <v-select
174
+ v-model='model.f_is_deal'
175
+ :options='$parent.$parent.deals'
176
+ :value-single="true" :value.sync="model.f_is_deal"
177
+ class="select select_list"
178
+ clear-button
179
+ close-on-select
180
+ condition="f_is_deal = '{}'"
181
+ placeholder='处理结果查询' style="width: 60%"></v-select>
182
+ </div>
183
+ <div :class="$parent.$parent.style">
184
+ <label class="font_normal_body">是否维修</label>
185
+ <v-select
186
+ v-model='model.f_repaired'
187
+ :options='$parent.$parent.repairedOptions'
188
+ :value-single="true" :value.sync="model.f_repaired"
189
+ class="select select_list"
190
+ clear-button
191
+ close-on-select
192
+ condition="f_repaired = '{}'"
193
+ placeholder='是否维修' style="width: 60%"></v-select>
194
+ </div>
195
+ <div :class="$parent.$parent.style">
196
+ <label class="font_normal_body">地&ensp;&ensp;&ensp;&ensp;址</label>
197
+ <input v-model="model.f_address" class="input_search" condition="f_address like '%{}%'"
198
+ placeholder="地址"
199
+ style="width: 60%" type="text">
200
+ </div>
201
+ <div :class="$parent.$parent.style">
202
+ <label class="font_normal_body">开户时间</label>
203
+ <datepicker
204
+ v-model="model.f_start_gastime" :disabled-days-of-week="[]"
205
+ :format="'yyyy-MM-dd'"
206
+ :show-rest-button="reset"
207
+ :value.sync="model.f_start_gastime"
208
+ condition="f_gas_date >= '{} 00:00:00'"
209
+ placeholder='起始时间'
210
+ style="width:60%">
211
+ </datepicker>
212
+ </div>
213
+ <div :class="$parent.$parent.style">
214
+ <label class="font_normal_body">开户时间</label>
215
+ <datepicker
216
+ v-model="model.f_end_gastime" :disabled-days-of-week="[]"
217
+ :format="'yyyy-MM-dd'"
218
+ :show-rest-button="reset"
219
+ :value.sync="model.f_end_gastime"
220
+ condition="f_gas_date <= '{} 23:59:59'"
221
+ placeholder='结束时间'
222
+ style="width:60%">
223
+ </datepicker>
224
+ </div>
225
+ </div>
226
+
227
+ <div v-show="$parent.$parent.$parent.showItem" class="row">
228
+ <div :class="$parent.$parent.style">
229
+ <label class="font_normal_body">安检计划</label>
230
+ <input v-model="$parent.$parent.f_check_plan.f_plan_name" class="input_search" placeholder="安检计划"
231
+ readonly="readonly"
232
+ style="width: 60%" type="text" @click="$parent.$parent.showChooser">
233
+ </div>
234
+ <div :class="$parent.$parent.style">
235
+ <label class="font_normal_body">存在隐患</label>
236
+ <v-select v-model="model.f_has_defect"
237
+ :options='$parent.$parent.hasDefectOptions'
238
+ :placeholder='model.f_has_defect'
239
+ :value.sync="model.f_has_defect"
240
+ class="select select_list"
241
+ close-on-select
242
+ condition="f_has_defect = '{}'"
243
+ style="width:60% ">
244
+ </v-select>
245
+ </div>
246
+
247
+ <div class=" col-sm-4 form-group button-range">
248
+ <div class="span" style="float: right;margin-top: 8px;margin-right: 50px">
249
+ <div :class="{'button_shrink_left':$parent.$parent.$parent.showItem,'button_shrink_right':!$parent.$parent.$parent.showItem}" class="button_spacing"
250
+ style="float: right"
251
+ @click="$parent.$parent.hiddenr()"></div>
252
+ <div :class="{'button_shrink_top':$parent.$parent.criteriaShow,'button_shrink_bottom':!$parent.$parent.criteriaShow}" class="button_spacing"
253
+ style="float: right"
254
+ @click="$parent.$parent.hidden()"></div>
255
+ <button class="button_search button_spacing" style="float: right" @click="search">查询</button>
256
+ <!-- <button style="float: right" class="button_search button_spacing" @click="$parent.$parent.toRepair">转维修</button>-->
257
+ <div style="float: right">
258
+ <export-excel-safe
259
+ :choose-col="true"
260
+ :data="{condition: $parent.$parent.model.condition,f_filialeids:$parent.$parent.model.f_filialeids,f_defect_content:$parent.$parent.model.f_defect_content}"
261
+ :field="$parent.$parent.getfield"
262
+ progress="safeGetExportProgress" sql-name="GetCheckPaperByDefectNew2" sqlurl="rs/logic/SafeExportExcel"
263
+ template-name='安检计划明细'></export-excel-safe>
264
+ </div>
265
+ </div>
266
+ </div>
267
+
268
+
269
+ </div>
270
+ <div v-show="$parent.$parent.criteriaShow&&$parent.$parent.$parent.showItem" class="row">
271
+ <div :class="$parent.$parent.style">
272
+ <label class="font_normal_body">用户编号</label>
273
+ <input v-model="model.f_userinfo_code" class="input_search" condition="f_userinfo_code = '{}'"
274
+ placeholder="用户编号"
275
+ style="width: 60%" type="text">
276
+ </div>
277
+ <div :class="$parent.$parent.style">
278
+ <label class="font_normal_body">用户表号</label>
279
+ <input v-model="model.f_meternumber" class="input_search" condition="f_meternumber = '{}'"
280
+ placeholder="用户表号"
281
+ style="width: 60%" type="text">
282
+ </div>
283
+ <div :class="$parent.$parent.style">
284
+ <label class="font_normal_body">结果查询</label>
285
+ <v-select
286
+ v-model='model.f_repaired'
287
+ :options='$parent.$parent.repaired'
288
+ :value-single="true" :value.sync="model.f_repaired"
289
+ class="select select_list"
290
+ clear-button
291
+ close-on-select
292
+ condition="f_repaired = '{}'"
293
+ placeholder='处理结果查询' style="width: 60%"></v-select>
294
+ </div>
295
+ <div :class="$parent.$parent.style">
296
+ <label class="font_normal_body">开户时间</label>
297
+ <datepicker
298
+ v-model="model.f_end_gastime" :disabled-days-of-week="[]"
299
+ :format="'yyyy-MM-dd'"
300
+ :show-rest-button="reset"
301
+ :value.sync="model.f_end_gastime"
302
+ condition="f_gas_date <= '{} 23:59:59'"
303
+ placeholder='结束时间'
304
+ style="width:60%">
305
+ </datepicker>
306
+ </div>
307
+ <div :class="$parent.$parent.style">
308
+ <label class="font_normal_body">区&emsp;&emsp;域</label>
309
+ <v-select v-model="model.f_quyu" :options='$parent.$parent.quyus' :value-single="true"
310
+ :value.sync="model.f_quyu" class="select_list select" close-on-select
311
+ placeholder='区域'
312
+ style="width: 60%"
313
+ @change="$parent.$parent.quyuChange">
314
+ </v-select>
315
+ </div>
316
+ <div :class="$parent.$parent.style">
317
+ <label class="font_normal_body">营&ensp;业&ensp;厅</label>
318
+ <v-select v-model="model.f_bumen" :options='$parent.$parent.bumens' :value-single="true"
319
+ :value.sync="model.f_bumen" class="select_list select"
320
+ close-on-select placeholder='营业厅' style="width: 60%"
321
+ @change="$parent.$parent.bumenChange">
322
+ </v-select>
323
+ </div>
324
+ <div :class="$parent.$parent.style">
325
+ <label class="font_normal_body">小&emsp;&emsp;组</label>
326
+ <v-select v-model="model.f_team" :options='$parent.$parent.teams' :value-single="true"
327
+ :value.sync="model.f_team" class="select_list select"
328
+ close-on-select placeholder='小组' style="width: 60%"
329
+ @change="$parent.$parent.teamChange">
330
+ </v-select>
331
+ </div>
332
+ <div :class="$parent.$parent.style">
333
+ <label class="font_normal_body">安&ensp;检&ensp;员</label>
334
+ <v-select v-model="model.f_checker_id" :multiple="true"
335
+ :options='$parent.$parent.checkers' :value.sync="model.f_checker_id" class="select_list select"
336
+ close-on-select condition="f_checker_name in {}" placeholder='安检员'
337
+ style="width: 60%">
338
+ </v-select>
339
+ </div>
340
+ </div>
341
+ <div v-show="$parent.$parent.criteriaShow && $parent.$parent.$parent.showItem" class="row">
342
+ <div :class="$parent.$parent.style">
343
+ <label class="font_normal_body">片&emsp;&emsp;区</label>
344
+ <v-select v-model="model.f_slice_area"
345
+ :options='$parent.$parent.sliceArea' :value-single="true"
346
+ :value.sync="model.f_slice_area" class="select_list select"
347
+ clear-button
348
+ close-on-select
349
+ condition="f_slice_area='{}'" filer-key="name"
350
+ placeholder='片区/管理站'
351
+ style="width: 60%"
352
+ @change="$parent.$parent.getmeterbook(model.f_slice_area)">
353
+ </v-select>
354
+ </div>
355
+ <div :class="$parent.$parent.style">
356
+ <label class="font_normal_body">抄&ensp;表&ensp;册</label>
357
+ <v-select v-model="model.f_meter_book_num"
358
+ :options='$parent.$parent.cbc' :value-single="true"
359
+ :value.sync="model.f_meter_book_num" class="select_list select"
360
+ clear-button
361
+ close-on-select
362
+ condition="f_meter_book_num={}" filer-key="name"
363
+ placeholder='抄表册'
364
+ style="width: 60%">
365
+ </v-select>
366
+ </div>
367
+ <div :class="$parent.$parent.style">
368
+ <label class="font_normal_body">起始时间</label>
369
+ <datepicker
370
+ v-model="model.f_start_time" :disabled-days-of-week="[]"
371
+ :format="'yyyy-MM-dd'"
372
+ :show-rest-button="reset"
373
+ :value.sync="model.f_start_time"
374
+ condition="f_offsite_time >= '{} 00:00:00'"
375
+ placeholder='起始时间'
376
+ style="width:60%">
377
+ </datepicker>
378
+ </div>
379
+ <div :class="$parent.$parent.style">
380
+ <label class="font_normal_body">结束时间</label>
381
+ <datepicker
382
+ v-model="model.f_end_time" :disabled-days-of-week="[]"
383
+ :format="'yyyy-MM-dd'"
384
+ :show-rest-button="reset"
385
+ :value.sync="model.f_end_time"
386
+ condition="f_offsite_time <= '{} 23:59:59'"
387
+ placeholder='结束时间'
388
+ style="width:60%">
389
+ </datepicker>
390
+ </div>
391
+ </div>
392
+ <div v-show="$parent.$parent.criteriaShow && $parent.$parent.$parent.showItem" class="row">
393
+
394
+ <div :class="$parent.$parent.style">
395
+ <label class="font_normal_body">维&ensp;修&ensp;员</label>
396
+ <input v-model="model.f_repairman" class="input_search" condition="f_repairman = '{}'"
397
+ placeholder="维修员"
398
+ style="width: 60%" type="text">
399
+ </div>
400
+ <div :class="$parent.$parent.style">
401
+ <label class="font_normal_body">处理查询</label>
402
+ <v-select
403
+ v-model='model.f_is_deal'
404
+ :options='$parent.$parent.deals'
405
+ :value-single="true" :value.sync="model.f_is_deal"
406
+ class="select select_list"
407
+ clear-button
408
+ close-on-select
409
+ condition="f_is_deal = '{}'"
410
+ placeholder='处理结果查询' style="width: 60%"></v-select>
411
+ </div>
412
+ <div :class="$parent.$parent.style">
413
+ <label class="font_normal_body">地&ensp;&ensp;&ensp;&ensp;址</label>
414
+ <input v-model="model.f_address" class="input_search" condition="f_address like '%{}%'"
415
+ placeholder="地址"
416
+ style="width: 60%" type="text">
417
+ </div>
418
+ <div :class="$parent.$parent.style">
419
+ <label class="font_normal_body">开户时间</label>
420
+ <datepicker
421
+ v-model="model.f_start_gastime" :disabled-days-of-week="[]"
422
+ :format="'yyyy-MM-dd'"
423
+ :show-rest-button="reset"
424
+ :value.sync="model.f_start_gastime"
425
+ condition="f_gas_date >= '{} 00:00:00'"
426
+ placeholder='起始时间'
427
+ style="width:60%">
428
+ </datepicker>
429
+ </div>
430
+
431
+ </div>
432
+ </div>
433
+ </criteria>
434
+ <data-grid v-ref:grid :model="model" class="list_area table_sy" partial='list'>
435
+ <template partial='head'>
436
+ <tr>
437
+ <!-- <th><nobr><input type="checkbox" v-model="$parent.$parent.$parent.checkAll" @click.stop="()=>{return}" />全选</nobr></th>-->
438
+ <th>
439
+ <nobr>入户状态</nobr>
440
+ </th>
441
+ <th>
442
+ <nobr>用户编号</nobr>
443
+ </th>
444
+ <th>
445
+ <nobr>用户名</nobr>
446
+ </th>
447
+ <th>
448
+ <nobr>用户表号</nobr>
449
+ </th>
450
+ <th>
451
+ <nobr>用户电话</nobr>
452
+ </th>
453
+ <th>
454
+ <nobr>用户小区</nobr>
455
+ </th>
456
+ <th>
457
+ <nobr>用户地址</nobr>
458
+ </th>
459
+ <th>
460
+ <nobr>开户时间</nobr>
461
+ </th>
462
+ <th>
463
+ <nobr>安检时间</nobr>
464
+ </th>
465
+ <th>
466
+ <nobr>安检员</nobr>
467
+ </th>
468
+ <th>
469
+ <nobr>计划名</nobr>
470
+ </th>
471
+ <th>
472
+ <nobr>是否有隐患</nobr>
473
+ </th>
474
+ <th>
475
+ <nobr>隐患数</nobr>
476
+ </th>
477
+ <th>
478
+ <nobr>处理数</nobr>
479
+ </th>
480
+ <th>
481
+ <nobr>处理情况</nobr>
482
+ </th>
483
+ <th>
484
+ <nobr>维修员</nobr>
485
+ </th>
486
+ <th>
487
+ <nobr>隐患明细</nobr>
488
+ </th>
489
+ <!-- <th><nobr>备注</nobr></th>-->
490
+ </tr>
491
+ </template>
492
+ <template partial='body'>
493
+ <!-- <td style="text-align: center;white-space:nowrap;"><input type="checkbox" @click="$event.cancelBubble=true" :checked="$parent.$parent.$parent.isChecked(row.id)" @change="$parent.$parent.$parent.setCheckes(row.id)"></input></td>-->
494
+ <td style="text-align: center;white-space:nowrap;">{{ row.f_entry_status }}</td>
495
+ <td style="text-align: center;white-space:nowrap;">{{ row.f_userinfo_code }}</td>
496
+ <td style="text-align: center;white-space:nowrap;">{{ row.f_user_name }}</td>
497
+ <td style="text-align: center;white-space:nowrap;">{{ row.f_meternumber }}</td>
498
+ <td style="text-align: center;white-space:nowrap;">{{ row.f_user_phone }}</td>
499
+ <td style="text-align: center;white-space:nowrap;">{{ row.f_residential_area }}</td>
500
+ <td style="text-align: center;white-space:nowrap;">{{ row.f_address }}</td>
501
+ <td style="text-align: center;white-space:nowrap;">{{ row.f_gas_date }}</td>
502
+ <td style="text-align: center;white-space:nowrap;">{{ row.f_offsite_time }}</td>
503
+ <td style="text-align: center;white-space:nowrap;">{{ row.f_checker_name }}</td>
504
+ <td style="text-align: center;white-space:nowrap;">{{ row.f_plan_name }}</td>
505
+ <td style="text-align: center;white-space:nowrap;">{{ row.f_has_defect }}</td>
506
+ <td style="text-align: center;white-space:nowrap;">{{ row.f_defect_count }}</td>
507
+ <td style="text-align: center;white-space:nowrap;">{{ row.f_deal_count }}</td>
508
+ <td style="text-align: center;white-space:nowrap;">{{ row.f_is_deal }}</td>
509
+ <td style="text-align: center;white-space:nowrap;">{{ row.f_repairman }}</td>
510
+ <td style="text-align: center;white-space:nowrap;">
511
+ {{ $parent.$parent.$parent.trouble(row.f_defect_content) }}
512
+ </td>
513
+ <!-- <td style="text-align: center;white-space:nowrap;">{{ row.f_deal_remark}}</td>-->
514
+ </template>
515
+ </data-grid>
516
+ </criteria-paged>
517
+ <modal v-ref:modal :show.sync="showModal" backdrop="false">
518
+ <div slot="modal-header" class="modal-header">
519
+ <h4 class="modal-title">
520
+ 选择计划
521
+ </h4>
522
+ </div>
523
+ <div slot="modal-body" class="modal-body">
524
+ <plan-chooser v-ref:chooser :f.sync="$login.f"></plan-chooser>
525
+ </div>
526
+ <div slot="modal-footer" class="modal-footer" style="text-align: center">
527
+ <button class="button_search" @click="ok">确认</button>
528
+ <button class="button_search" @click="cancel">取消</button>
529
+ </div>
530
+ </modal>
531
+ <modal :backdrop="false" :show.sync="showModal2">
532
+ <div slot="modal-header" class="modal-header">
533
+ <h4 class="modal-title">
534
+ 转维修
535
+ </h4>
536
+ </div>
537
+ <div slot="modal-body" class="modal-body">
538
+ <div v-if="true">
539
+ <div class="row" style="margin-top: 10px">
540
+ <label class="control-label font text-left"
541
+ style="float:left;margin-left:20%;margin-top:5px">派发类型</label>
542
+ <div class="col-xs-8 col-md-8">
543
+ <v-select v-model="selectData.dispatchType" :options='dispatchTypeOptions' :value-single="true"
544
+ :value.sync="selectData.dispatchType" close-on-select
545
+ placeholder='派发类型'>
546
+ </v-select>
547
+ </div>
548
+ </div>
549
+ <div v-if="selectData.dispatchType=='派发给维修员'" class="row" style="margin-top: 10px">
550
+ <label class="control-label font text-left" style="float:left;margin-left:20%;margin-top:5px">维&ensp;修&ensp;员</label>
551
+ <div class="col-xs-8 col-md-8">
552
+ <v-select
553
+ :options='repairers'
554
+ :value-single="true"
555
+ :value.sync="selectData.f_repairman"
556
+ close-on-select
557
+ placeholder='请选择维修员'></v-select>
558
+ </div>
559
+ </div>
560
+ <div v-if="selectData.dispatchType=='派发给站点'" class="row" style="margin-top: 10px">
561
+ <label class="control-label font text-left" style="float:left;margin-left:20%;margin-top:5px">站&ensp;&ensp;&ensp;&ensp;点</label>
562
+ <div class="col-xs-8 col-md-8">
563
+ <right-tree
564
+ :source="'dep=this.getParentByType($organization$).getSpecialResByType($department$),tool.getFullTree(dep.where(row.hasSpecialRole($派单员$)))'"
565
+ :userid="userid"
566
+ islist
567
+ @re-res="getSiteRes"></right-tree>
568
+ </div>
569
+ </div>
570
+ <div class="row" style="margin-top: 10px">
571
+ <label class="control-label font text-left"
572
+ style="float:left;margin-left:20%;margin-top:5px">报修类型</label>
573
+ <div class="col-xs-8 col-md-8">
574
+ <v-select :options='repairTypeOptions' :value-single="true"
575
+ :value.sync="selectData.f_repairtype"
576
+ class="select select_list"
577
+ close-on-select
578
+ style="width:60%">
579
+ </v-select>
580
+ </div>
581
+ </div>
582
+ <div class="row" style="margin-top: 10px">
583
+ <label class="control-label font text-left" style="float:left;margin-left:20%;margin-top:5px">备&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;注</label>
584
+ <div class="col-xs-8 col-md-8">
585
+ <textarea v-model="selectData.f_remarks" style="width: 60%; height: 100px"></textarea>
586
+ </div>
587
+ </div>
588
+ </div>
589
+ </div>
590
+ <div slot="modal-footer" class="modal-footer" style="text-align: center">
591
+ <!-- <button class="button_search" @click="rectification">转维修</button>-->
592
+ <button class="button_search" @click="cancel1">取消</button>
593
+ </div>
594
+ </modal>
595
+ <modal :show.sync="showModal3">
596
+ <div slot="modal-header" class="modal-header">
597
+ <h4 class="modal-title">
598
+ 转维修进度{{ progressbarWidth }}%
599
+ </h4>
600
+ </div>
601
+ <div slot="modal-body" class="modal-body">
602
+ <div class="progress">
603
+ <div :style="'width:'+ progressbarWidth+'%'" aria-valuemax="100" aria-valuemin="0"
604
+ aria-valuenow="60" class="progress-bar" role="progressbar">
605
+ <!-- <span class="sr-only">40% 完成</span>-->
606
+ </div>
607
+ </div>
608
+ </div>
609
+ <div v-show="false" slot="modal-footer" class="modal-footer" style="text-align: center"></div>
610
+ </modal>
611
+ </div>
612
+ </template>
613
+ <script>
614
+ import {PagedList} from 'vue-client'
615
+ import HttpResetClass from "vue-client/src/plugins/HttpResetClass";
616
+ import co from 'co'
617
+ import Vue from 'vue'
618
+ import * as Util from '../../../components/Util'
619
+
620
+ let select = function* (self) {
621
+ let http = new HttpResetClass()
622
+ let getGasman = yield http.load('POST', '/rs/search', {
623
+ source: 'this.getParentByType($department$).getAllChildrens().where(row.getAttributes().get($rolestr$).indexOf($安检员$) != -1))',
624
+ userid: self.$login.f.id
625
+ }, {resolveMsg: null, rejectMsg: null})
626
+ //tag
627
+ self.checkersid.push({label: '全部', value: ''})
628
+ getGasman.data.forEach((checker) => {
629
+ self.checkersid.push({label: checker.name, value: checker.name})
630
+ })
631
+ }
632
+ export default {
633
+ title: '隐患查询',
634
+ data() {
635
+ let model = new PagedList('rs/sql/GetCheckPaperByDefectNew2', 20, {
636
+ f_filialeids: 'this.f_filialeids', f_defect_content: 'this.f_defect_content'
637
+ })
638
+ model.f_filialeids = '(' + this.$login.f.orgid + ')'
639
+ model.f_defect_content = "CASE WHEN CHARINDEX( '\"result\":\"正常\"', f_defect_content ) > 0 THEN '无隐患' ELSE replace(replace(replace( replace( RIGHT ( f_defect_content, len( f_defect_content ) - 26 ), substring('{}',2,1), '' ), substring('{}',1,1), '' ),']',''),'\"','') END"
640
+ return {
641
+ quyus: [{label: '请选择', value: ''}, ...this.$appdata.getParam('区域')],
642
+ bumens: [{label: '请选择', value: ''}],
643
+ teams: [{label: '请选择', value: ''}],
644
+ checkers: [{label: '请选择', value: ''}],
645
+ allCheckers: [{label: '请选择', value: ''}],
646
+ repaired: [{label: '全部', value: ''}, {label: '未完成', value: '未完成'}, {label: '已完成', value: '已完成'}],
647
+ deals: [{label: '全部', value: ''}, {label: '未处理', value: '未处理'}, {
648
+ label: '已处理',
649
+ value: '已处理'
650
+ }, {label: '处理中', value: '处理中'}],
651
+ hasDefectOptions: [{label: '全部', value: ''}, {label: '有隐患', value: '有隐患'}, {
652
+ label: '无隐患',
653
+ value: '无隐患'
654
+ }],
655
+ f: this.$login.f,
656
+ model: model,
657
+ criteriaShow: false,
658
+ checkAll: false,
659
+ timercount: 0,
660
+ showModal2: false,
661
+ repairTypeOptions: this.$appdata.getParam('转维修类型'),
662
+ dispatchTypeOptions: [{label: '派发给维修员', value: '派发给维修员'}],
663
+ checkes: [],
664
+ showModal: false,
665
+ f_check_plan: {f_plan_name: '', id: ''},
666
+ sumsmodel: {},
667
+ resids: {},
668
+ all: false,
669
+ fields: {},
670
+
671
+ selectData: {
672
+ dispatchType: '',
673
+ f_repairman: '',
674
+ f_remarks: '',
675
+ f_repairtype: ''
676
+ },
677
+ progressbarWidth: '0',
678
+ modelval: [],
679
+ isbusy: false,
680
+ checkersid: [],
681
+ showModal3: false,
682
+ toRepairCount: 0,
683
+ sliceArea: [],
684
+ callSends: [],
685
+ cbc: [],
686
+ repairedOptions: [{label: '全部', value: ''}, {label: '已修', value: '已修'}, {label: '未修', value: '未修'}],
687
+ repairers: [],
688
+ cbcs: [],
689
+ thead: '',
690
+ headData: ['入户状态', '用户编号', '用户表号', '用户名', '用户电话', '用户小区', '用户地址', '开户时间', '安检时间', '安检员', '计划名', '是否有隐患', '隐患数', '隐患明细', '处理情况'],
691
+ bodyData: ['f_entry_status', 'f_userinfo_code', 'f_meternumber', 'f_user_name', 'f_user_phone', 'f_residential_area', 'f_address', 'f_gas_date', 'f_offsite_time', 'f_checker_name', 'f_plan_name', 'f_has_defect', 'f_defect_count', 'defecttext', 'f_is_deal'],
692
+ }
693
+ },
694
+ props: {
695
+ style: {
696
+ type: String,
697
+ default: 'col-sm-2 form-group'
698
+ },
699
+ style2: {
700
+ type: String,
701
+ default: 'col-sm-4 form-group'
702
+ }
703
+
704
+ },
705
+
706
+ methods: {
707
+ bumenChange(val) {
708
+ if (val) {
709
+ this.teams = this.$appdata.getParam(`工单-` + val) ? [{
710
+ label: '请选择',
711
+ value: ''
712
+ }, ...this.$appdata.getParam(`工单-` + val)] : [{label: '请选择', value: ''}]
713
+ }
714
+ },
715
+ teamChange(val) {
716
+ if (val) {
717
+ this.checkers = this.$appdata.getParam(val) ? [{
718
+ label: '请选择',
719
+ value: ''
720
+ }, ...this.$appdata.getParam(val)] : [{label: '请选择', value: ''}]
721
+ }
722
+ },
723
+ quyuChange(val) {
724
+ if (val) {
725
+ this.bumens = this.$appdata.getParam(val) ? [{
726
+ label: '请选择',
727
+ value: ''
728
+ }, ...this.$appdata.getParam(val)] : [{label: '请选择', value: ''}]
729
+ }
730
+ },
731
+ trouble(val) {
732
+ // return val.replaceAll("'",'')
733
+ // .replaceAll("\"",'')
734
+ // .replaceAll("{",'')
735
+ // .replaceAll("}",'')
736
+ // .replaceAll("]",'')
737
+ // .replaceAll("[",'')
738
+ // .replaceAll("result:",'')
739
+ // .replaceAll("data:",'')
740
+ // .replaceAll("有隐患",'')
741
+ // .replaceAll(",",'')
742
+
743
+
744
+ const defect_content = JSON.parse(val)
745
+ let result = ''
746
+ if (defect_content.data) {
747
+ const jsonData = defect_content.data
748
+ for (const itemdata of jsonData) {
749
+ const keys = Object.keys(itemdata)
750
+ for (const itm of keys) {
751
+ const value = itemdata[itm]
752
+ result += itm + ':' + value
753
+ }
754
+ }
755
+ }
756
+ return result
757
+ },
758
+ getEmp() {
759
+ let val = {
760
+ source: 'this.getParentByType($organization$).getSpecialResByType($user$).where(row.getAttributes().get($rolestr$)!=null ).where(row.getAttributes().get($rolestr$).indexOf($维修员$) != -1))',
761
+ userid: `${this.$login.f.id}`
762
+ }
763
+ let http = new HttpResetClass()
764
+ http.load('POST', '/rs/search', {data: val}, {resolveMsg: null, rejectMsg: null}).then((res) => {
765
+ let str = ''
766
+ res.data.forEach((item, idx, arr) => {
767
+ //tag
768
+ if (idx + 1 == arr.length) {
769
+ str += item.id
770
+ } else {
771
+ str += item.id + ','
772
+ }
773
+
774
+ })
775
+ let http1 = new HttpResetClass()
776
+ http1.load('POST', 'rs/sql/tel_singleTable_OrderBy', {
777
+ data: {
778
+ items: 'id,f_user_telephone',
779
+ tablename: 't_user',
780
+ condition: `id in (${str})`,
781
+ orderitem: 'id'
782
+ }
783
+ }, {resolveMsg: null, rejectMsg: null}).then((ress) => {
784
+
785
+ res.data.forEach((user) => {
786
+ try {
787
+ ress.data.forEach((tel, tidx, arr) => {
788
+ //tag
789
+ if (user.id == tel.id) {
790
+ this.repairers.push({label: `${user.name}:${tel.f_user_telephone}`, value: user.name})
791
+ ress.data.splice(tidx, 1)
792
+ //tag
793
+ throw new Error("跳出循环");
794
+ }
795
+ })
796
+ } catch (e) {
797
+ //tag
798
+ }
799
+ })
800
+ })
801
+
802
+ })
803
+ },
804
+ toRepair() {
805
+ //tag
806
+ this.showModal2 = true
807
+ },
808
+ async rectification() {
809
+ this.isbusy = true
810
+ // if (this.checkAll){
811
+ let data = {
812
+ f_filialeids: this.model.params.f_filialeids,
813
+ f_defect_content: this.model.params.f_defect_content,
814
+ condition: this.model.params.condition
815
+ }
816
+ let res1 = await new HttpResetClass().load('post', 'rs/sql/GetCheckPaperByDefectNew2', {data: data})
817
+ for (let i = 0; i < res1.data.length; i++) {
818
+ let data1 = {
819
+ f_paper_id: res1.data[i].id,
820
+ condition: `f_repaire_type != '无隐患'`
821
+ }
822
+ let res2 = await new HttpResetClass().load('POST', 'rs/sql/GetDefectByPaperIdNew2', {data: data1})
823
+ //tag
824
+ const uploadData = {
825
+ model: {
826
+ serviceacitivity: [{
827
+ f_service_acitivity_type: '派单'
828
+ }],
829
+ f_repairitems: {},
830
+ failure: '',
831
+ f_source: '安检',
832
+ f_service_id: '',
833
+ f_contact_phone: '',
834
+ f_meetunit: '',
835
+ f_phone: '',
836
+ f_user_name: '',
837
+ f_address: '',
838
+ f_repair_date: '',
839
+ f_reciever: '',
840
+ f_remarks: '',
841
+ f_user_type: '',
842
+ f_area: '',
843
+ f_unit_name: '',
844
+ f_street: '',
845
+ f_residential_area: '',
846
+ f_building: '',
847
+ f_unit: '',
848
+ f_floor: '',
849
+ f_room: '',
850
+ aState: '',
851
+ f_repairtype: '',
852
+ f_userinfo_id: '',
853
+ f_userinfo_code: '',
854
+ f_orgstr: '',
855
+ f_outlets: '',
856
+ f_attendant: this.$login.f.name
857
+ },
858
+ loginUser: {
859
+ name: this.$login.f.name,
860
+ ename: this.$login.f.ename
861
+ },
862
+ user: {
863
+ f_userinfo_id: ''
864
+ },
865
+ callObj: null
866
+ }
867
+
868
+ uploadData.model.serviceacitivity[0].f_reciever = this.selectData.f_repairman
869
+ // uploadData.model.f_meetunit = self.$login.f.orgpathnames
870
+ // uploadData.model.f_orgstr = self.$login.f.orgpathstr
871
+ // uploadData.model.f_outlets = self.$login.f.f_parentname
872
+ uploadData.model.f_meetunit = this.$login.f.deps
873
+ uploadData.model.f_orgid = this.$login.f.orgid
874
+ uploadData.model.f_filiale = this.$login.f.org
875
+ uploadData.model.f_outlets = this.$login.f.deps
876
+ uploadData.model.f_filiale_id = this.$login.f.orgid
877
+ uploadData.toRepair = '一级派单'
878
+ let res3 = await new HttpResetClass().load('post', '/rs/sql/GetUserForRepaireNew2', {data: {f_userinfo_id: res1.data[i].f_userinfo_id}})
879
+ uploadData.model = Object.assign(uploadData.model, res3.data[0])
880
+ uploadData.user.f_userinfo_id = res3.data[0].f_userinfo_id
881
+ uploadData.model.f_repair_date = Util.getNowDate()
882
+ uploadData.model.f_repairtype = res3.data[0].f_repairtype
883
+ uploadData.model.f_remarks = res3.data[0].f_remarks
884
+ let failure = []
885
+ res2.data.forEach(row => {
886
+ if (row.f_repaire_type == '隐患未处理') {
887
+ console.log('row.f_item_value', row.f_item_value)
888
+ failure.push({
889
+ f_failure_type: row.f_item_name,
890
+ failurecase: row.f_item_value ? row.f_item_value.split(',') : ''
891
+ })
892
+ }
893
+ })
894
+ uploadData.model.failure = failure
895
+ // 拼接repairitems
896
+ let rows = JSON.parse(JSON.stringify(res2.data))
897
+ let repairitems = {
898
+ data: []
899
+ }
900
+ let safecheckOptions = [{"data": "已处理"}, {"data": "未处理"}]
901
+ // 取隐患未处理的
902
+ rows = rows.filter(row => row.f_repaire_type == '隐患未处理')
903
+ //tag)
904
+ // 开始拼接
905
+ rows.forEach(row => {
906
+ let existIndex = -1
907
+ // 判断该设备是否已经存在
908
+ for (let i = 0; i < repairitems.data.length; i++) {
909
+ if (repairitems.data[i].f_type == row.f_device_type) {
910
+ existIndex = i
911
+ break
912
+ }
913
+ }
914
+ if (existIndex == -1) {
915
+ // 不存在则新建
916
+ let newItem = {
917
+ f_type: row.f_device_type,
918
+ details: [{
919
+ f_defect_id: row.id,
920
+ f_project: `${row.f_item_name}:${row.f_item_value}`,
921
+ type: 'selector',
922
+ options: safecheckOptions
923
+ }]
924
+ }
925
+ repairitems.data.push(newItem)
926
+ } else {
927
+ // 存在则追加
928
+ repairitems.data[existIndex].details.push({
929
+ f_defect_id: row.id,
930
+ f_project: `${row.f_item_name}:${row.f_item_value}`,
931
+ type: 'selector',
932
+ options: safecheckOptions
933
+ })
934
+ }
935
+ })
936
+ uploadData.model.f_repairitems = repairitems
937
+ uploadData.rows = rows
938
+ //tag)
939
+ //tag
940
+ if (uploadData.model.f_repairitems.data.length > 0) {
941
+ this.callSends.push(uploadData)
942
+ } else {
943
+ //tag
944
+ }
945
+ }
946
+ //tag)
947
+ let timer = setInterval(async () => {
948
+ this.showModal3 = true
949
+ this.isbusy = false
950
+ if (this.timercount < this.callSends.length) {
951
+ //tag)
952
+ let rows = this.callSends[this.timercount].rows
953
+ //tag)
954
+ let result = await this.$resetpost('/rs/logic/callerSend', this.callSends[this.timercount])
955
+ //tag)
956
+ if (result.data.f_service_id) {
957
+ const data = {
958
+ f_paper_id: rows[0].f_paper_id,
959
+ f_service_id: result.data.f_service_id,
960
+ itemsId: this.$login.convertToIn(rows.map(row => row.id))
961
+ }
962
+ //tag
963
+ let updateRes = await this.$resetpost('/rs/logic/updateDefectStateNew', data)
964
+ }
965
+ this.toRepairCount++
966
+ //tag
967
+ this.timercount++
968
+ } else {
969
+ clearInterval(timer)
970
+ //tag
971
+ this.callSends = []
972
+ this.timercount = 0
973
+ this.showModal3 = false
974
+ this.cancel1()
975
+ this.$showMessage('本次转维修成功' + this.toRepairCount + '单')
976
+ this.toRepairCount = 0
977
+ }
978
+ }, 3000)
979
+ },
980
+ cancel1() {
981
+ this.showModal2 = false
982
+ this.selectData = {
983
+ dispatchType: '',
984
+ f_repairman: '',
985
+ f_remarks: '',
986
+ f_repairtype: ''
987
+ }
988
+ },
989
+ sleep(d) {
990
+ //tag)
991
+ var t = Date.now()
992
+ while (Date.now - t <= d) {
993
+
994
+ }
995
+ //tag)
996
+ },
997
+ isChecked(v) {
998
+ // 如果全选,不在的按选中算,否则,在的按选中算
999
+ if (this.checkAll) {
1000
+ return this.checkes.indexOf(v) == -1
1001
+ } else {
1002
+ return this.checkes.indexOf(v) != -1
1003
+ }
1004
+ },
1005
+ setCheckAll() {
1006
+ this.checkAll = this.checkAll ? false : true;
1007
+ // 全选改变后,清空选中数据
1008
+ this.checkes = []
1009
+ },
1010
+ setCheckes(id) {
1011
+ let index = this.checkes.indexOf(id)
1012
+ if (index < 0) {
1013
+ this.checkes.push(id)
1014
+ } else {
1015
+ this.checkes.splice(index, 1)
1016
+ }
1017
+ },
1018
+
1019
+ getmeterbook(val) {
1020
+ this.cbc = []
1021
+ this.cbc.push({
1022
+ label: '全部',
1023
+ value: ''
1024
+ })
1025
+ if (val == '') {
1026
+
1027
+ this.cbcs.forEach(res => {
1028
+ this.cbc.push({
1029
+ label: res.f_book_name,
1030
+ value: res.id
1031
+ })
1032
+ })
1033
+ } else {
1034
+ this.cbcs.forEach(res => {
1035
+ if (res.f_book_slice_area == val) {
1036
+ this.cbc.push({
1037
+ label: res.f_book_name,
1038
+ value: res.id
1039
+ })
1040
+ }
1041
+ })
1042
+ }
1043
+ },
1044
+
1045
+ Mreadibook(val) {
1046
+ //tag
1047
+ //tag
1048
+ this.sliceArea = []
1049
+ if (val) {
1050
+ new HttpResetClass().load('POST', `/rs/sql/tel_singleTable_OrderBy`, {
1051
+ data: {
1052
+ items: 'name',
1053
+ tablename: 't_zone',
1054
+ condition: `parentid in ${val}`,
1055
+ orderitem: 'id'
1056
+ }
1057
+ }, {resolveMsg: null, rejectMsg: null}).then((res) => {
1058
+ this.sliceArea.push({
1059
+ label: '全部',
1060
+ value: ''
1061
+ })
1062
+ res.data.forEach(ress => {
1063
+ this.sliceArea.push({
1064
+ label: ress.name,
1065
+ value: ress.name
1066
+ })
1067
+ })
1068
+
1069
+ })
1070
+ }
1071
+ },
1072
+ getAllMeterBook(val) {
1073
+ //tag
1074
+ //tag
1075
+ this.cbcs = []
1076
+ if (val) {
1077
+ new HttpResetClass().load('POST', `/rs/sql/tel_singleTable_OrderBy`, {
1078
+ data: {
1079
+ items: 'f_book_name,f_book_slice_area,id',
1080
+ tablename: 't_meter_book',
1081
+ condition: `f_filiale_id in ${val}`,
1082
+ orderitem: 'id'
1083
+ }
1084
+ }, {resolveMsg: null, rejectMsg: null}).then((res) => {
1085
+ res.data.forEach(ress => {
1086
+ this.cbcs.push({
1087
+ id: ress.id,
1088
+ f_book_name: ress.f_book_name,
1089
+ f_book_slice_area: ress.f_book_slice_area
1090
+ })
1091
+ })
1092
+ this.cbc = []
1093
+ this.cbc.push({
1094
+ label: '全部',
1095
+ value: ''
1096
+ })
1097
+ this.cbcs.forEach(res => {
1098
+ this.cbc.push({
1099
+ label: res.f_book_name,
1100
+ value: res.id
1101
+ })
1102
+ })
1103
+ })
1104
+ }
1105
+ },
1106
+ hiddenr() {
1107
+ this.$parent.showItem = !this.$parent.showItem
1108
+ },
1109
+ hidden() {
1110
+ this.criteriaShow = !this.criteriaShow
1111
+ },
1112
+ search(args) {
1113
+ //tag
1114
+ if (this.f_check_plan.f_plan_name) {
1115
+ args.condition += ` and f_check_plan_id = '${this.f_check_plan.id}'`
1116
+ }
1117
+ this.checkes = []
1118
+ this.checkAll = false
1119
+ this.model.search(args.condition, args.model)
1120
+ },
1121
+ getRes(obj) {
1122
+ //tag
1123
+ this.resids = {res: obj.res[0], resids: obj.resids[0]}
1124
+ this.model.f_filialeids = this.$login.convertToIn(obj.resids);
1125
+ this.Mreadibook(this.model.f_filialeids)
1126
+ this.getAllMeterBook(this.model.f_filialeids)
1127
+ },
1128
+ showChooser() {
1129
+ this.showModal = true
1130
+ },
1131
+ ok() {
1132
+ this.showModal = false
1133
+ if (this.$refs.modal.$children[0].selectedRow.id) {
1134
+ this.f_check_plan = this.$refs.modal.$children[0].selectedRow
1135
+ }
1136
+ },
1137
+ cancel() {
1138
+ this.showModal = false
1139
+ this.f_check_plan = {f_plan_name: '', id: ''}
1140
+ },
1141
+ getAllChecker() {
1142
+ new HttpResetClass().load('POST', `/rs/sql/tel_singleTable_OrderBy`, {
1143
+ data: {
1144
+ items: 'name',
1145
+ tablename: 't_user',
1146
+ condition: `state = '在职' and rolestr like '%安检员%'`,
1147
+ orderitem: 'id'
1148
+ }
1149
+ }, {resolveMsg: null, rejectMsg: null}).then((res) => {
1150
+ res.data.forEach(ress => {
1151
+ this.allCheckers.push({
1152
+ label: ress.name,
1153
+ value: ress.name
1154
+ })
1155
+ })
1156
+ this.checkers = this.allCheckers
1157
+ })
1158
+ }
1159
+ },
1160
+ ready() {
1161
+ //tag
1162
+ this.$refs.paged.$refs.criteria.model.f_has_defect = '有隐患'
1163
+ this.getEmp()
1164
+ let gen = select(this)
1165
+ // this.Mreadibook(`('${this.$login.f.orgid}')`)
1166
+ co(gen)
1167
+ this.getAllChecker()
1168
+ },
1169
+ watch: {
1170
+ 'timercount'() {
1171
+ if (this.timercount === 0) {
1172
+ this.progressbarWidth = '0'
1173
+ } else {
1174
+ //tag
1175
+ //tag
1176
+ this.progressbarWidth = parseInt(this.timercount * 100 / (this.callSends.length + 1))
1177
+ }
1178
+
1179
+ }
1180
+ },
1181
+ computed: {
1182
+ selected() {
1183
+ return this.$refs.paged.$refs.grid.selected
1184
+ },
1185
+ getfield() {
1186
+ //tag
1187
+ let data = {}
1188
+ this.bodyData.forEach((value, index) => {
1189
+ data[this.bodyData[index]] = this.headData[index]
1190
+ })
1191
+ //合计字段打印
1192
+ this.tfoot = `<tr><th colspan=${this.modelval.length}>全表汇总信息: `
1193
+ if (this.sumsmodel) {
1194
+ Object.keys(this.sumsmodel).forEach((key) => {
1195
+ this.tfoot += this.fields[key] + '合计: ' + `<font color="blue">${this.sumsmodel[key]} </font>`
1196
+ })
1197
+ } else {
1198
+ this.tfoot += '暂无'
1199
+ }
1200
+ this.tfoot += '</th></tr>'
1201
+ return data
1202
+ }
1203
+ }
1204
+ }
1205
+ </script>