safecheck-client 3.0.30-69 → 3.0.30-70

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,1231 +1,1231 @@
1
- <template>
2
- <div class="flex">
3
- <criteria-paged :model="model" v-ref:paged>
4
- <criteria partial='criteria' @condition-changed='$parent.search' v-ref:criteria>
5
- <div novalidate class="form-horizontal select-overspread container-fluid auto" partial>
6
- <div class="row" v-show="!$parent.$parent.$parent.showItem">
7
- <div :class="$parent.$parent.style">
8
- <label class="font_normal_body">用户编号</label>
9
- <input style="width: 60%" type="text" class="input_search" v-model="model.f_userinfo_code"
10
- id="f_userinfo_code"
11
-
12
- placeholder="用户编号" condition="f_userinfo_code like '%{}%'">
13
- </div>
14
- <div :class="$parent.$parent.style">
15
- <label class="font_normal_body">用户姓名</label>
16
- <input style="width: 60%" type="text" class="input_search" v-model="model.f_user_name" id="f_user_name"
17
- placeholder="用户姓名" condition="f_user_name like '%{}%'">
18
- </div>
19
- <div :class="$parent.$parent.style">
20
- <label class="font_normal_body">小&emsp;&emsp;区</label>
21
- <input style="width: 60%" type="text" class="input_search" v-model="model.f_residential_area"
22
- id="f_residential_area"
23
- placeholder="小区" condition="f_residential_area like '%{}%'">
24
- </div>
25
- <div :class="$parent.$parent.style">
26
- <label class="font_normal_body">地&emsp;&emsp;址</label>
27
- <input style="width: 60%" type="text" class="input_search" v-model="model.f_address" id="f_address"
28
- placeholder="地址" condition="f_address like '%{}%'">
29
- </div>
30
- <div :class="$parent.$parent.style" style="width: auto;margin-top:8px;float: right">
31
- <export-excel-safe :data="$parent.$parent.searchData"
32
- :field="$parent.$parent.excelHeaders"
33
- :choose-col="true"
34
- sqlurl="rs/logic/SafeExportExcel" sql-name="根据安检员查询用户档案"
35
- template-name='用户安检情况'></export-excel-safe>
36
- <button type="button" class="button_search button_spacing" @click="search()">查询</button>
37
- <button type="button" class="button_search button_spacing" @click="$parent.$parent.blacklist()">拉黑</button>
38
- <div style="float: right" class="button_spacing"
39
- :class="{'button_shrink_left':$parent.$parent.$parent.showItem,'button_shrink_right':!$parent.$parent.$parent.showItem}"
40
- @click="$parent.$parent.hiddenr()"></div>
41
- <div style="float: right" class="button_spacing"
42
- :class="{'button_shrink_top':$parent.$parent.criteriaShow,'button_shrink_bottom':!$parent.$parent.criteriaShow}"
43
- @click="$parent.$parent.hidden()">
44
-
45
- </div>
46
- </div>
47
-
48
-
49
- </div>
50
- <div class="row" v-show="!$parent.$parent.$parent.showItem">
51
- <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
52
- <label class="font_normal_body">用户类型</label>
53
- <v-select id="f_usertype"
54
- placeholder='用户类型'
55
- class="select select_list"
56
- :value.sync="model.f_usertype"
57
- :value-single="true"
58
- :options='$parent.$parent.usertypes'
59
- v-model="model.f_usertype"
60
- condition="f_user_type = '{}'"
61
- close-on-select clear-button></v-select>
62
- </div>
63
- <!-- <div class="form-group col-sm-2" v-show="$parent.$parent.criteriaShow && !$parent.$parent.$parent.showItem"></div>-->
64
-
65
- <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
66
- <label class="font_normal_body" style="color: red;">安检筛选</label>
67
- <v-select
68
- placeholder='安检筛选'
69
- :value-single="true"
70
- class="select select_list"
71
- :value.sync="$parent.$parent.SafeCheckXZ"
72
- :options='$parent.$parent.SafeCheckXZs'
73
- v-model="$parent.$parent.SafeCheckXZ"
74
- close-on-select clear-button></v-select>
75
- </div>
76
- <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
77
- <label class="font_normal_body">安检起始</label>
78
- <datepicker
79
- :value.sync="model.f_check_start"
80
- placeholder='最后安检时间起始'
81
- style="width: 60%"
82
- :format="'yyyy-MM-dd 00:00:00'"
83
- :show-rest-button="reset"
84
- v-model="model.f_check_start">
85
- </datepicker>
86
- </div>
87
- <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
88
- <label class="font_normal_body">安检结束</label>
89
- <datepicker
90
- :value.sync="model.f_check_end"
91
- placeholder='最后安检时间结束'
92
- style="width: 60%"
93
- :format="'yyyy-MM-dd 23:59:59'"
94
- :show-rest-button="reset"
95
- v-model="model.f_check_end">
96
- </datepicker>
97
- </div>
98
-
99
- <!-- <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
100
- <label class="font_normal_body">安检状态</label>
101
- <v-select id="f_entry"
102
- placeholder='安检状态'
103
- class="select select_list"
104
- :value.sync="model.f_last_check_state"
105
- :value-single="true"
106
- :options='$parent.$parent.checkstatus'
107
- v-model="model.f_last_check_state"
108
- condition="f_last_check_state = '{}'"
109
- close-on-select clear-button></v-select>
110
- </div>-->
111
- <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
112
- <label class="font_normal_body">隐患情况</label>
113
- <v-select
114
- placeholder='隐患情况'
115
- class="select select_list"
116
- :value-single="true"
117
- v-model='model.f_check_result'
118
- :value.sync="model.f_check_result"
119
- :options='$parent.$parent.f_check_results'
120
- condition="f_last_check_result like '%{}%'"
121
- close-on-select clear-button></v-select>
122
- </div>
123
- <!-- <div class="form-group col-sm-2" v-show="$parent.$parent.criteriaShow && !$parent.$parent.$parent.showItem"></div>-->
124
- </div>
125
- <div class="row" v-show="!$parent.$parent.$parent.showItem">
126
-
127
- <div class="col-sm-4 form-group" v-show="$parent.$parent.criteriaShow" style="margin: 0">
128
- <role-selector-safe
129
- role-name="安检员"
130
- role-lable="安&nbsp;检&nbsp;员&nbsp;"
131
- @re-res="$parent.$parent.getRes"
132
- :value.sync="model.f_checker_id"
133
- v-model="model.f_checker_id"
134
- :value-multiple="true"
135
- condition=" f_checker_name in {}">
136
- </role-selector-safe>
137
- </div>
138
- <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
139
- <label class="font_normal_body">片&emsp;&emsp;区</label>
140
- <v-select class="select_list select"
141
- placeholder='片区/管理站' style="width: 60%"
142
- :value.sync="model.f_slice_area" v-model="model.f_slice_area"
143
- :options='$parent.$parent.sliceArea'
144
- filer-key="name"
145
- close-on-select clear-button
146
- condition="f_slice_area='{}'"
147
- @change="$parent.$parent.getmeterbook(model.f_slice_area)"
148
- :value-single="true">
149
- </v-select>
150
- </div>
151
- <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
152
- <label class="font_normal_body">抄&ensp;表&ensp;册</label>
153
- <v-select class="select_list select"
154
- placeholder='抄表册' style="width: 60%"
155
- :value.sync="model.f_meter_book_num" v-model="model.f_meter_book_num"
156
- :options='$parent.$parent.cbc'
157
- filer-key="name"
158
- close-on-select clear-button
159
- condition="f_meter_book_num={}"
160
- :value-single="true">
161
- </v-select>
162
- </div>
163
- <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
164
- <label class="font_normal_body">省&ensp;市&ensp;区</label>
165
- <v-select class="select_list select"
166
- placeholder='请选择' style="width: 60%"
167
- :value.sync="model.f_pcd" v-model="model.f_pcd"
168
- :options='$parent.$parent.pcds'
169
- filer-key="name"
170
- close-on-select clear-button
171
- condition="f_pcd='{}'"
172
- :value-single="true">
173
- </v-select>
174
- </div>
175
- <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
176
- <label class="font_normal_body">用户状态</label>
177
- <v-select class="select_list select"
178
- placeholder='用户状态' style="width: 60%"
179
- :value.sync="model.f_user_state" v-model="model.f_user_state"
180
- :options='$parent.$parent.userstates'
181
- close-on-select clear-button
182
- condition="f_user_state = '{}'"
183
- :value-single="true">
184
- </v-select>
185
- </div>
186
- <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
187
- <label class="font_normal_body">用户性质</label>
188
- <v-select class="select_list select"
189
- placeholder='用户性质' style="width: 60%"
190
- :value.sync="model.f_gasproperties" v-model="model.f_gasproperties"
191
- :options='$parent.$parent.gasproperties'
192
- close-on-select clear-button
193
- condition="f_gasproperties = '{}'"
194
- :value-single="true">
195
- </v-select>
196
- </div>
197
- <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
198
- <label class="font_normal_body">片区</label>
199
- <v-select class="select_list select"
200
- placeholder='片区' style="width: 60%"
201
- :value.sync="model.f_outlets" v-model="model.f_outlets"
202
- :options='$parent.$parent.userareas'
203
- close-on-select clear-button
204
- condition="f_outlets = '{}'"
205
- :value-single="true">
206
- </v-select>
207
- </div>
208
- </div>
209
-
210
- <div class="row" v-show="$parent.$parent.$parent.showItem">
211
- <div :class="$parent.$parent.style">
212
- <label class="font_normal_body">用户编号</label>
213
- <input style="width: 60%" type="text" class="input_search" v-model="model.f_userinfo_code"
214
-
215
- placeholder="用户编号" condition="f_userinfo_code like '%{}%'">
216
- </div>
217
- <div :class="$parent.$parent.style">
218
- <label class="font_normal_body">用户姓名</label>
219
- <input style="width: 60%" type="text" class="input_search" v-model="model.f_user_name"
220
- placeholder="用户姓名" condition="f_user_name like '%{}%'">
221
- </div>
222
- <div :class="$parent.$parent.style" style="width: auto;margin-top:8px;float: right">
223
- <export-excel-safe :data="$parent.$parent.searchData"
224
- :field="$parent.$parent.excelHeaders"
225
- sqlurl="rs/logic/SafeExportExcel" sql-name="根据安检员查询用户档案"
226
- template-name='用户安检情况'></export-excel-safe>
227
- <button type="button" class="button_search button_spacing" @click="search()">查询</button>
228
- <button type="button" class="button_search button_spacing" @click="$parent.$parent.blacklist()">拉黑</button>
229
- <div style="float: right" class="button_spacing"
230
- :class="{'button_shrink_left':$parent.$parent.$parent.showItem,'button_shrink_right':!$parent.$parent.$parent.showItem}"
231
- @click="$parent.$parent.hiddenr()"></div>
232
- <div style="float: right" class="button_spacing"
233
- :class="{'button_shrink_top':$parent.$parent.criteriaShow,'button_shrink_bottom':!$parent.$parent.criteriaShow}"
234
- @click="$parent.$parent.hidden()">
235
-
236
- </div>
237
- </div>
238
-
239
- </div>
240
- <div class="row" v-show="$parent.$parent.$parent.showItem">
241
- <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
242
- <label class="font_normal_body">小&emsp;&emsp;区</label>
243
- <input style="width: 60%" type="text" class="input_search" v-model="model.f_residential_area"
244
-
245
- placeholder="小区" condition="f_residential_area like '%{}%'">
246
- </div>
247
- <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
248
- <label class="font_normal_body">地&emsp;&emsp;址</label>
249
- <input style="width: 60%" type="text" class="input_search" v-model="model.f_address"
250
-
251
- placeholder="地址" condition="f_address like '%{}%'">
252
- </div>
253
- <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
254
- <label class="font_normal_body">用户类型</label>
255
- <v-select
256
- placeholder='用户类型'
257
- class="select select_list"
258
-
259
- :value.sync="model.f_usertype"
260
- :value-single="true"
261
- :options='$parent.$parent.usertypes'
262
- v-model="model.f_usertype"
263
- condition="f_user_type = '{}'"
264
- close-on-select clear-button></v-select>
265
- </div>
266
- <!-- <div class="form-group col-sm-2" v-show="$parent.$parent.criteriaShow && !$parent.$parent.$parent.showItem"></div>-->
267
-
268
- <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
269
- <label class="font_normal_body" style="color: red;">安检筛选</label>
270
- <v-select
271
- placeholder='安检筛选'
272
- :value-single="true"
273
-
274
- class="select select_list"
275
- :value.sync="$parent.$parent.SafeCheckXZ"
276
- :options='$parent.$parent.SafeCheckXZs'
277
- v-model="$parent.$parent.SafeCheckXZ"
278
- close-on-select clear-button></v-select>
279
- </div>
280
-
281
- </div>
282
- <div class="row" v-show="$parent.$parent.$parent.showItem">
283
- <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
284
- <label class="font_normal_body">安检起始</label>
285
- <datepicker
286
- :value.sync="model.f_check_start"
287
- placeholder='最后安检时间起始'
288
- :disabled-days-of-week="[]"
289
- style="width: 60%"
290
- :format="'yyyy-MM-dd'"
291
- :show-rest-button="reset"
292
- v-model="model.f_check_start">
293
- </datepicker>
294
- </div>
295
- <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
296
- <label class="font_normal_body">安检结束</label>
297
- <datepicker
298
- :value.sync="model.f_check_end"
299
- placeholder='最后安检时间结束'
300
- style="width: 60%"
301
- :disabled-days-of-week="[]"
302
- :format="'yyyy-MM-dd'"
303
- :show-rest-button="reset"
304
- v-model="model.f_check_end">
305
- </datepicker>
306
- </div>
307
-
308
- <!-- <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
309
- <label class="font_normal_body">安检状态</label>
310
- <v-select
311
- placeholder='安检状态'
312
- class="select select_list"
313
-
314
- :value.sync="model.f_last_check_state"
315
- :value-single="true"
316
- :options='$parent.$parent.checkstatus'
317
- v-model="model.f_last_check_state"
318
- condition="f_last_check_state = '{}'"
319
- close-on-select clear-button></v-select>
320
- </div>-->
321
- <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
322
- <label class="font_normal_body">隐患情况</label>
323
- <v-select
324
- placeholder='隐患情况'
325
- class="select select_list"
326
- :value-single="true"
327
- v-model='model.f_check_result'
328
- :value.sync="model.f_check_result"
329
- :options='$parent.$parent.f_check_results'
330
- condition="f_last_check_result like '%{}%'"
331
- close-on-select clear-button></v-select>
332
- </div>
333
-
334
- </div>
335
- <!--<div class="row" v-show="$parent.$parent.$parent.showItem">
336
- <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
337
- <label class="font_normal_body">公&emsp;&emsp;司</label>
338
- <right-tree @re-res="$parent.$parent.getRes" :initresid="$parent.$parent.$login.f.orgid">
339
- </right-tree>
340
- </div>
341
-
342
- </div>-->
343
- </div>
344
- </criteria>
345
- <data-grid :model="model" partial="list" class="list_area table_sy" v-ref:grid>
346
- <template partial='head'>
347
- <tr>
348
- <th><nobr><input type="checkbox" v-model="$parent.$parent.$parent.checkAll" @click.stop="()=>{return}" />全选</nobr></th>
349
- <th>
350
- <nobr>用户编号</nobr>
351
- </th>
352
- <th>
353
- <nobr>用户名称</nobr>
354
- </th>
355
- <th>
356
- <nobr>用户电话</nobr>
357
- </th>
358
- <th>
359
- <nobr>用户表号</nobr>
360
- </th>
361
- <!-- <th>-->
362
- <!-- <nobr>气表品牌</nobr>-->
363
- <!-- </th>-->
364
- <th>
365
- <nobr>用户类型</nobr>
366
- </th>
367
- <!-- <th>-->
368
- <!-- <nobr>壁挂炉</nobr>-->
369
- <!-- </th>-->
370
- <!-- <th>-->
371
- <!-- <nobr>灶具</nobr>-->
372
- <!-- </th>-->
373
- <th>
374
- <nobr>小区名称</nobr>
375
- </th>
376
- <th style="padding: 0 40px">
377
- <nobr>地址</nobr>
378
- </th>
379
- <th>
380
- <nobr>安检员</nobr>
381
- </th>
382
- <!-- <th>-->
383
- <!-- <nobr>安检员备注</nobr>-->
384
- <!-- </th>-->
385
- <th>
386
- <nobr>安检日期</nobr>
387
- </th>
388
- <th>
389
- <nobr>安检状态</nobr>
390
- </th>
391
- <th>
392
- <nobr>安检结果</nobr>
393
- </th>
394
- <th>
395
- <nobr>二维码</nobr>
396
- </th>
397
- </tr>
398
- </template>
399
- <template partial='body'>
400
- <td style="text-align: center;white-space:nowrap;"><input type="checkbox" @click="$event.cancelBubble=true" :checked="$parent.$parent.$parent.isChecked(row.f_userinfo_code)" @change="$parent.$parent.$parent.setCheckes(row.f_userinfo_code)"></input></td>
401
- <td v-bind:class="{newcolor:row.code==1}" style="text-align: center;">{{ row.f_userinfo_code }}</td>
402
- <td v-bind:class="{newcolor:row.code==1}" style="text-align: center;">{{ row.f_user_name }}</td>
403
- <td v-bind:class="{newcolor:row.code==1}" style="text-align: center;">{{ row.f_user_phone }}</td>
404
- <td v-bind:class="{newcolor:row.code==1}" style="text-align: center;">{{row.f_meternumber}}</td>
405
- <!-- <td v-bind:class="{newcolor:row.code==1}" style="text-align: center;">{{row.f_meter_brand}}</td>-->
406
- <td v-bind:class="{newcolor:row.code==1}" style="text-align: center">{{ row.f_user_type }}</td>
407
- <!-- <td v-bind:class="{newcolor:row.code==1}" style="text-align: center">{{ row.f_safe_hasfurnace }}</td>-->
408
- <!-- <td v-bind:class="{newcolor:row.code==1}" style="text-align: center">{{ row.f_safe_haskitchen }}</td>-->
409
- <td v-bind:class="{newcolor:row.code==1}" style="text-align: center">{{ row.f_residential_area }}</td>
410
- <td v-bind:class="{newcolor:row.code==1}" style="text-align: center">{{ row.f_address }}</td>
411
- <td v-bind:class="{newcolor:row.code==1}" style="text-align: center">{{ row.f_checker_name }}</td>
412
- <td v-bind:class="{newcolor:row.code==1}" style="text-align: center">{{ row.f_last_check_date }}</td>
413
- <td v-bind:class="{newcolor:row.code==1}" style="text-align: center">{{ row.f_last_check_state }}</td>
414
- <td v-bind:class="{newcolor:row.code==1}" style="text-align: center">
415
- {{row.f_last_check_result1 }}
416
- </td>
417
- <td v-bind:class="{newcolor:row.code==1}" style="text-align: center">
418
- <button class="button_spacing button_search-1" @click.stop='$parent.$parent.$parent.searchInfo(row.f_userinfo_code,row.f_address,row.f_user_type,row.f_address_detail,row.f_house_number)' >点击</button>
419
- </td>
420
- </template>
421
- </data-grid>
422
- </criteria-paged>
423
- <modal :show.sync="dialogVisible" destroyOnClose={true} v-ref:modal v-if="dialogVisible">
424
- <div slot="modal-header" class="modal-header">
425
- <h4 class="modal-title" style="text-align: center">
426
- 二维码
427
- </h4>
428
- </div>
429
- <div slot="modal-body" class="modal-body" >
430
- <div id="aa" style="margin-left: 115px">
431
- <div id="bb">
432
- <style id="style1">
433
- #bb {
434
- width: 302px;
435
- height: 170px;
436
- }
437
- #bb .img{
438
- width: 40px;
439
- height: 40px;
440
- }
441
- #bb .td1{
442
- text-align: left;
443
- white-space: nowrap;
444
- font-size: 12px;
445
- font-weight: 900;
446
- }
447
- #bb .td2{
448
- text-align: right;
449
- font-size: 10px;
450
- font-weight: 900;
451
- }
452
- #bb .td3{
453
- text-align: center;
454
- font-weight: 900;
455
- }
456
- #bb .baseImg{
457
- width: 120px;
458
- height: 120px;
459
- float: right;
460
- overflow:hidden;
461
- }
462
- #bb .span{
463
- white-space: nowrap;
464
- }
465
- #bb .td0{
466
- text-align: left;
467
- width: 60px;
468
- }
469
- </style>
470
- <table>
471
- <tr>
472
- <td class="td0">
473
- <img class="img" src="../../../assets/wensu/1.jpg" alt="">
474
- </td>
475
- <td class="td0">
476
- <img class="img" src="../../../assets/wensu/2.jpg" alt="">
477
- </td>
478
- <td class="td3">
479
- <span class="span" style="font-size: 13px;font-weight: 900">温宿县曦隆燃气开发有限公司</span><br>
480
- <span class="span" style="font-weight: 900">天然气入户安全检查专用标签</span>
481
- </td>
482
- </tr>
483
- <tr>
484
- <td class="td1" colspan="2">用&nbsp;户&nbsp;类&nbsp;型&nbsp;:&nbsp;{{modal_user_type}}</td>
485
- <td colspan="3" rowspan="6"><img class="baseImg" :src="modal_base64_img" alt="">
486
- </tr>
487
- <tr><td class="td1" colspan="3">片区负责人&nbsp;:&nbsp;{{modal_responsible_checker}}</td></tr>
488
- <tr><td class="td1" colspan="3">联&nbsp;系&nbsp;电&nbsp;话&nbsp;:&nbsp;{{modal_responsible_phone}}</td></tr>
489
- <tr><td class="td1" style="font-size: 13px" colspan="3">燃气客服电话&nbsp;:&nbsp;0997-6150333</td></tr>
490
- <tr><td class="td1" style="font-size: 13px" colspan="3">燃气报警电话&nbsp;:&nbsp;0997-4533119</td></tr>
491
- <tr><td class="td1" colspan="3">地址&nbsp;:&nbsp;{{modal_user_address}}</td></tr>
492
- <tr><td class="td2" colspan="5">曦隆燃气&nbsp;&nbsp;&nbsp;&nbsp;情系万家</td></tr>
493
- </table>
494
- </div>
495
- </div>
496
- </div>
497
- <div slot="modal-footer" class="modal-footer">
498
- <print-element class="btn btn-success width-80" id="aa" styleid='style1' top='1' left='1' width='100%' height='100%' v-ref:printelement>打印</print-element>
499
- <button type="button" class="btn btn-success width-80" @click="dialogVisible = false">确认</button>
500
- <button type="button" class="btn btn-success width-80" @click="dialogVisible = false">取消</button>
501
- </div>
502
- </modal>
503
- <modal :show.sync="showModal2" :backdrop="false">
504
- <div slot="modal-header" class="modal-header">
505
- <h4 class="modal-title">
506
- 批量拉黑
507
- </h4>
508
- </div>
509
- <div slot="modal-body" class="modal-body">
510
- <div v-if="true">
511
- <div class="row" style="margin-top: 10px">
512
- <label class="control-label font text-left" style="float:left;margin-left:20%;margin-top:5px">拉黑备注</label>
513
- <div class="col-xs-8 col-md-8">
514
- <textarea style="width: 60%; height: 100px" v-model="f_remarks"></textarea>
515
- </div>
516
- </div>
517
- </div>
518
- </div>
519
- <div slot="modal-footer" class="modal-footer" style="text-align: center">
520
- <button class="button_search" @click="blacklist">确认</button>
521
- <button class="button_search" @click="showModal2=false">取消</button>
522
- </div>
523
- </modal>
524
- <!-- <modal :show.sync="showModal3">
525
- <div slot="modal-header" class="modal-header">
526
- <h4 class="modal-title">
527
- 转维修进度{{ progressbarWidth }}%
528
- </h4>
529
- </div>
530
- <div slot="modal-body" class="modal-body">
531
- <div class="progress">
532
- <div class="progress-bar" role="progressbar" aria-valuenow="60"
533
- aria-valuemin="0" aria-valuemax="100" :style="'width:'+ progressbarWidth+'%'">
534
- &lt;!&ndash; <span class="sr-only">40% 完成</span>&ndash;&gt;
535
- </div>
536
- </div>
537
- </div>
538
- <div slot="modal-footer" class="modal-footer" style="text-align: center" v-show="false"></div>
539
- </modal>-->
540
- </div>
541
-
542
- </template>
543
-
544
- <script>
545
- import {PagedList} from 'vue-client'
546
- import {HttpResetClass} from 'vue-client'
547
- import co from 'co'
548
- import * as Util from '../../Util'
549
- import Vue from 'vue'
550
-
551
-
552
- // let select = function * (self,userid) {
553
- // let http = new HttpResetClass()
554
- // let getGasman = yield http.load('POST','/rs/search', {
555
- // source: 'this.getChildByName($安检员$).getUsers()',
556
- // userid: userid
557
- // }, {resolveMsg: null, rejectMsg: null})
558
- // //tag
559
- // getGasman.data.forEach((checker)=>{
560
- // self.checkersid.push({label:checker.name,value:checker.id})
561
- // })
562
- // self.checkersid.push({label:'全部',value:''})
563
- // }
564
-
565
-
566
- export default {
567
- title: '用户安检情况',
568
- data() {
569
- let options = []
570
- let year = (new Date()).getFullYear()
571
- for (let i = year; i <= year + 3; i++)
572
- options.push({label: i + '', value: i + ''})
573
- let moptions = []
574
- for (let i = 1; i <= 12; i++)
575
- moptions.push({label: i + '', value: i + ''})
576
-
577
- return {
578
- dialogVisible: false,
579
- searchData: {
580
- condition: '1=1',
581
- orderitem: "f_userinfo_code",
582
- timetype: "dd",
583
- f_defect_content: "CASE WHEN CHARINDEX( '\"result\":\"正常\"', tp.f_defect_content ) > 0 THEN '正常' ELSE replace(replace(replace( replace( RIGHT ( tp.f_defect_content, len( tp.f_defect_content ) - 26 ), substring('{}',2,1), '' ), substring('{}',1,1), '' ),']',''),'\"','') END"
584
- },
585
- excelHeaders: {
586
- //用户编号 用户名称 用户电话 安检次数 用户类型 小区名称 地址 安检日期 安检状态 安检结果
587
-
588
- 'f_userinfo_code': '用户编号',
589
- 'f_user_name': '用户名称',
590
- 'f_user_phone': '用户电话',
591
- 'f_meternumber': '用户表号',
592
- 'f_user_type': '用户类型',
593
- 'f_checker_name': '安检员',
594
- 'f_residential_area': '小区名称',
595
- 'f_address': '地址',
596
- 'f_last_check_date': '安检日期',
597
- 'f_last_check_state': '安检状态',
598
- 'f_last_check_result1': '安检结果'
599
- },
600
- model: new PagedList('rs/sql/根据安检员查询用户档案', 20, {
601
- orderitem: "'f_last_check_date'",
602
- timetype: "'dd'",
603
- f_defect_content: 'this.f_defect_content'
604
- }),
605
- f_defect_content:"CASE WHEN CHARINDEX( '\"result\":\"正常\"', tp.f_defect_content ) > 0 THEN '无隐患' ELSE replace(replace(replace( replace( RIGHT ( tp.f_defect_content, len( tp.f_defect_content ) - 26 ), substring('{}',2,1), '' ), substring('{}',1,1), '' ),']',''),'\"','') END",
606
- orgstrs: [{label: '全部', value: ''}],
607
- checkersid: [],
608
- gasproperties:[],
609
- userareas:[],
610
- SafeCheckXZ: '',
611
- civil: '', //民用安检周期
612
- civilian: '', //非民用安检周期
613
- SafeCheckXZs: [{label: '全部', value: ''}, {label: '已入户', value: '已入户'}, {label: '未入户', value: '未入户'}], // 安检筛选选项
614
- SafeCheckSXs: [{label: '是', value: '是'}, {label: '否', value: '否'}, {label: '全部', value: ''}],
615
- // user_states:[{label: '全部', value: ''}, ...this.$appdata.getParam('用户状态')],
616
- IsShares: [{label: '是', value: '是'}, {label: '否', value: '否'}],
617
- IsShare: '否',
618
- checker: {},
619
- NoBuys: [{label: '是', value: '是'}, {label: '否', value: '否'}],
620
- criteriaShow: false,
621
- checkers: [],
622
- chosenOrg: {id: 0},
623
- showModal: false,
624
- checkedAll: false,
625
- checkrows: [],
626
- adjustables: [],
627
- f_plan_year: year + '',
628
- f_plan_month: moptions[new Date().getMonth()].value,
629
- f_effective_start_time: '', //计划有效起始时间
630
- f_effective_end_time: '', //计划有效结束时间
631
- checkboxModel: {},
632
- c_year_list: options,
633
- c_month_list: moptions,
634
- areas: this.areas(),
635
- checkstatus: this.checkstatus(),
636
- usertypes: this.usertypes(),
637
- userstates: this.userstates(),
638
- sqlname: '',
639
- f_check_results: [{label: '全部', value: ''}, {label: '正常', value: '正常'}, {label: '有隐患', value: '有隐患'}],
640
- creatPlanWay: '',
641
- sliceArea: [],
642
- cbcs:[],
643
- cbc:[],
644
- pcds:[],
645
- modal_user_type:'',
646
- modal_responsible_checker:'',
647
- modal_responsible_phone:'',
648
- modal_user_address:'',
649
- modal_base64_img:'',
650
- checkes: [],
651
- checkAll: false,
652
- showModal2:false,
653
- showModal3:false,
654
- f_remarks:'',
655
- progressbarWidth:'0',
656
- }
657
- },
658
- props: {
659
- style: {
660
- type: String,
661
- default: 'col-sm-2 form-group'
662
- },
663
- style2: {
664
- type: String,
665
- default: 'col-sm-4 form-group'
666
- },
667
- checkplan: { // 传入一条安检计划信息
668
- type: Object
669
- },
670
- additemshow: {
671
- type: Boolean,
672
- default: false
673
- }
674
- },
675
- ready() {
676
- // 获取分公司信息
677
- this.model.f_defect_content=this.f_defect_content
678
-
679
- //this.getfengongsi()
680
- this.model.chosenOrg = {id: 0}
681
- this.model.f_filialeids = this.$login.f.f_orgids
682
- this.model.f_filiale = this.$login.f.f_fengongsi
683
- this.model.f_OrgStr = this.$login.f.orgpathstr
684
- this.Mreadibook(`('${this.$login.f.orgid}')`)
685
- this.getAllMeterBook(`('${this.$login.f.orgid}')`)
686
- this.getAllGasproperties()
687
- this.getAllOutlets()
688
- },
689
- methods: {
690
- async blacklist(){
691
- if(!this.checkAll && this.checkes.length==0){
692
- Vue.showMessage("请先勾选你要拉黑的用户!")
693
- return
694
- }
695
- this.$showMessage("确定需要将选中用户在营收系统进行拉黑吗?",['confirm', 'cancel']).then((res)=>{
696
- if (res === 'confirm'){
697
- //this.showModal3=true
698
- let successCount=0
699
- console.log('是否全选', this.checkAll)
700
- console.log('当前选中用户', this.checkes)
701
- console.log('this.model----', this.model)
702
- new HttpResetClass().load('post','rs/logic/safe_getuser_to_blactlist', {
703
- data:{
704
- condition: this.model.condition.condition1,
705
- condition2: this.model.condition.condition2,
706
- switchCheckAll: true,
707
- checkAll: this.checkAll,
708
- param: this.checkes,
709
- columnName: 'f_userinfo_code',
710
- orderitem:' f_userinfo_code',
711
- type:'update'
712
- }
713
- }).then((res)=>{
714
- this.$showMessage("操作成功!本次选中用已标记为待拉黑状态,同步营收系统会存在延迟。")
715
- }).catch((msg)=>{
716
- this.$showMessage("网络异常请稍后再试!")
717
- })
718
-
719
- }
720
- })
721
-
722
- /*new HttpResetClass().load('post','API/Secheck/SetBlackList', {
723
- data:{
724
- id:'700002373',
725
- bh:'1511080819',
726
- black:true,
727
- blackMemo:'测试拉黑!!!'
728
- }
729
- }).then(res=>{
730
- if (result.data.code==200) {
731
- successCount += result.data.successcon
732
- this.progressbarWidth=Math.ceil((i+1)*100/(this.checkes.length))
733
- }
734
- console.log('拉黑返回结果----', res)
735
- }).catch(err=>{
736
- console.log('拉黑请求失败----', err)
737
- })*/
738
- },
739
- isChecked (v) {
740
- // 如果全选,不在的按选中算,否则,在的按选中算
741
- if (this.checkAll) {
742
- return this.checkes.indexOf(v) == -1
743
- } else {
744
- return this.checkes.indexOf(v) != -1
745
- }
746
- },
747
- setCheckAll () {
748
- this.checkAll = this.checkAll ? false : true
749
- // 全选改变后,清空选中数据
750
- this.checkes = []
751
- },
752
- setCheckes (id) {
753
- let index = this.checkes.indexOf(id)
754
- if (index < 0) {
755
- this.checkes.push(id)
756
- } else {
757
- this.checkes.splice(index, 1)
758
- }
759
- },
760
- //查询二维码
761
- searchInfo(val,address,userType,checkerName,checkerPhone){
762
- this.dialogVisible = true
763
- new HttpResetClass().load('post','rs/logic/QrcodeUtil', {
764
- data: {
765
- id:val
766
- }
767
- }).then(res=>{
768
- this.modal_user_type=userType
769
- this.modal_user_address=address
770
- this.modal_responsible_checker=checkerName
771
- this.modal_responsible_phone=checkerPhone
772
- this.modal_base64_img="data:image/jpg;base64,"+res.data.result
773
- })
774
-
775
- },
776
- //获取省市区列表
777
- getPcd(val){
778
- this.pcds = [{label:'全部',value:''}]
779
- new HttpResetClass().load("POST", `/rs/sql/safe_singleTable_OrderBy`,
780
- {data:{items:"*",tablename:"t_pcd",orderitem:"id",condition:`f_orgid in ${val}`}},
781
- {resolveMsg: null, rejectMsg: null}).then((pcdlist)=>{
782
- pcdlist.data.forEach((result)=>{
783
- this.pcds.push({label:result.f_pcd,value:result.f_pcd})
784
- })
785
- })
786
- },
787
- getmeterbook(val){
788
-
789
- //tag
790
- this.cbc=[]
791
- this.cbc.push({
792
- label:'全部',
793
- value:''
794
- })
795
- if (val==''){
796
-
797
- this.cbcs.forEach(res=>{
798
- this.cbc.push({
799
- label:res.f_book_name,
800
- value:res.id
801
- })
802
- })
803
- }else{
804
- this.cbcs.forEach(res=>{
805
- if (res.f_book_slice_area==val){
806
- this.cbc.push({
807
- label:res.f_book_name,
808
- value:res.id
809
- })
810
- }
811
- })
812
- }
813
- },
814
- Mreadibook(val){
815
- ////tag
816
- ////tag
817
- if (val){
818
- new HttpResetClass().load('POST',`/rs/sql/tel_singleTable_OrderBy`, {data: {
819
- items: 'name',
820
- tablename: 't_zone',
821
- condition: `parentid in ${val}`,
822
- orderitem: 'id'
823
- }}, {resolveMsg: null, rejectMsg: null}).then((res) => {
824
- this.sliceArea=[]
825
- this.sliceArea.push({
826
- label:'全部',
827
- value:''
828
- })
829
- res.data.forEach(ress=>{
830
- this.sliceArea.push({
831
- label:ress.name,
832
- value:ress.name
833
- })
834
- })
835
-
836
- })
837
- }
838
- },
839
- // 获取县域分公司内容
840
- getfengongsi() {
841
- let val = {
842
- source: 'this.getParentByType($organization$).getSpecialResByType($organization$)',
843
- userid: `${this.$login.f.id}`
844
- }
845
- let http = new HttpResetClass()
846
- http.load('POST', '/rs/search', {data: val}, {resolveMsg: null, rejectMsg: null}).then((res) => {
847
- res.data.forEach((item) => {
848
- this.orgstrs.push({label: item.name, value: item.id})
849
- })
850
- //tag
851
- })
852
- },
853
- // 县域分公司发生改变
854
- // orgstrchange(val){
855
- // if(val == undefined || val == ''){
856
- // return
857
- // }else {
858
- // this.checkersid = []
859
- // let gen = select(this,val)
860
- // return co(gen)
861
- // }
862
- // },
863
- getDefect(val) {
864
- if (val) {
865
- try {
866
- var defect = JSON.parse(val)
867
- return defect.result
868
- } catch (e) {
869
- //tag
870
- return '正常'
871
- }
872
- }
873
- return '正常'
874
- },
875
- checkerchange(val) {
876
- this.checkboxModel.f_checker = val.name
877
- this.checkboxModel.f_checker_id = val.id
878
- },
879
- search(args) {
880
- if (this.SafeCheckXZ && (args.model.f_check_start == '' || args.model.f_check_end == '')) {
881
- this.$showMessage('如果选择 已安检/未安检 选项,需要选择 安检起始时间!')
882
- return
883
- }
884
- this.checkes = []
885
- /*if (this.SafeCheckXZ == '未安检') {
886
- args.condition += " and ( f_last_check_date >= '" + args.model.f_check_end + "' or f_last_check_date <= '" + args.model.f_check_start + "' or f_last_check_date is null)"
887
- } else {
888
- if (args.model.f_check_start) {
889
- args.condition += " and f_last_check_date >= '" + args.model.f_check_start + "'"
890
- }
891
- if (args.model.f_check_end) {
892
- args.condition += " and f_last_check_date <= '" + args.model.f_check_end + "'"
893
- }
894
- }*/
895
- //args.condition += " and f_filialeid in " + (this.model.f_filialeids ? this.model.f_filialeids : `(${this.$login.f.orgid})`)
896
- let con = ' f_filialeid in ' + (this.model.f_filialeids ? this.model.f_filialeids : `(${this.$login.f.orgid}) `)
897
- con += args.model.f_check_start ? ` and f_offsite_time >= '${args.model.f_check_start}'` : ''
898
- con += args.model.f_check_end ? ` and f_offsite_time <= '${args.model.f_check_end}'` : ''
899
- if (this.SafeCheckXZ == '未入户') {
900
- con += ` and f_entry_status = '入户'`
901
- args.condition += ' and ruhuid is null'
902
- } else if (this.SafeCheckXZ == '已入户') {
903
- con += ` and f_entry_status = '入户'`
904
- args.condition += ' and ruhuid is not null'
905
- }
906
- // con += args.model.f_last_check_state ? ` and f_entry_status = '${args.model.f_last_check_state}'` : ''
907
- con += args.model.f_checker_id ? ` and f_checker_name in ${args.model.f_checker_id}` : ''
908
- let condition = {
909
- condition1: args.condition,
910
- condition2: con
911
- }
912
- //tag
913
- this.searchData.condition = condition
914
- return this.model.search(condition, args.model)
915
- },
916
- checkstatus() {
917
- return this.$appdata.getParam('安检状态') ? [{
918
- label: '全部',
919
- value: ''
920
- }, ...this.$appdata.getParam('安检状态')] : [{label: '全部', value: ''}]
921
- },
922
- usertypes() {
923
- return this.$appdata.getParam('用户类型') ? [{
924
- label: '全部',
925
- value: ''
926
- }, ...this.$appdata.getParam('用户类型')] : [{label: '全部', value: ''}]
927
- },
928
- userstates() {
929
- return this.$appdata.getParam('用户状态') ? [{
930
- label: '全部',
931
- value: ''
932
- }, ...this.$appdata.getParam('用户状态')] : [{label: '全部', value: ''}]
933
- },
934
- hiddenr() {
935
- this.$parent.showItem = !this.$parent.showItem
936
- },
937
- hidden() {
938
- this.criteriaShow = !this.criteriaShow
939
- },
940
- confirm() {
941
- if (!this.checkboxModel.f_plan_name) {
942
- this.$showMessage('请填写安检计划名称!')
943
- return
944
- }
945
- // if(this.f_effective_start_time == ''){
946
- // this.$showMessage('请选择有效起始日期!')
947
- // return
948
- // }
949
- // if(this.f_effective_end_time == ''){
950
- // this.$showMessage('请选择有效结束日期!')
951
- // return
952
- // }
953
- if (this.IsShare == '否') {
954
- if (!this.checkboxModel.f_checker_id) {
955
- this.$showMessage('请选择安检员!')
956
- return
957
- }
958
- }
959
- let gen = saveGen(this)
960
- return co(gen)
961
- },
962
- changeStates() {
963
- if (this.checkedAll) {//实现反选/
964
- this.checkrows = [];
965
- for (let i = 0; i < this.$refs.paged.model.rows.length; i++) {
966
- this.$set('$refs.paged.model.rows[' + i + '].checked', false)
967
- }
968
- } else {//实现全选
969
- for (let i = 0; i < this.$refs.paged.model.rows.length; i++) {
970
- this.$set('$refs.paged.model.rows[' + i + '].checked', true)
971
- }
972
- let _this = this
973
- let condition = this.$refs.paged.$refs.criteria.condition
974
- let url = this.model.url
975
- this.$resetpost(`${url}?pageSize=9999999`, {
976
- data: {
977
- condition: condition,
978
- groupitem: '',
979
- orderitem: 'f_residential_area',
980
- f_usertype: this.model.f_usertype,
981
- f_filialeids: this.model.f_filialeids,
982
- month: this.model.month,
983
- safeCycle: this.model.safeCycle,
984
- f_checktime_start: this.model.f_checktime_start,
985
- f_checktime_end: this.model.f_checktime_end,
986
- SafeCheckSX: this.model.SafeCheckSX,
987
- f_last_check_state: this.model.f_last_check_state
988
- },
989
- }, {resolveMsg: null, rejectMsg: null}, -1).then(
990
- (respanse) => {
991
- if (respanse.data.length >= 5000) {
992
- this.$showMessage("数据量太大,请重新选择")
993
- } else {
994
- _this.checkrows = []
995
- for (let j = 0; j < respanse.data.length; j++) {
996
- _this.checkrows.push(respanse.data[j])
997
- }
998
- //tag;
999
- }
1000
- })
1001
- }
1002
- },
1003
- addChecked(item) {
1004
- //tag;
1005
- if (!item.checked) {
1006
- this.checkrows.push(item);
1007
- //tag;
1008
- } else {
1009
- for (let i = 0; i < this.checkrows.length; i++) {
1010
- if (item.f_userinfo_id == this.checkrows[i].f_userinfo_id) {
1011
- this.checkrows.splice(i, 1)
1012
- }
1013
- }
1014
- }
1015
- },
1016
- ToshowModal() {
1017
- this.creatPlanWay = 'single'
1018
- if (this.checkrows.length > 0) {
1019
- this.showModal = true
1020
- } else {
1021
- this.$showMessage("请选择需要安检的用户!")
1022
- }
1023
- },
1024
- FiltrationPlan() {
1025
- if (this.model.rows.length == 0) {
1026
- this.$showMessage("暂无可生成的计划!")
1027
- return
1028
- }
1029
- this.creatPlanWay = 'filtration'
1030
- this.showModal = true
1031
- },
1032
- AllPlan() {
1033
- if (this.model.rows.length == 0) {
1034
- this.$showMessage("暂无可生成的计划!")
1035
- return
1036
- }
1037
- this.creatPlanWay = 'all'
1038
- this.showModal = true
1039
- },
1040
- cancel() {
1041
- this.showModal = false
1042
- },
1043
- areas() {
1044
- let rs = []
1045
- for (let i = 0; i < this.$login.f.f_allArea.length; i++) {
1046
- let temp = {
1047
- label: this.$login.f.f_allArea[i].label,
1048
- value: this.$login.f.f_allArea[i].label
1049
- }
1050
- rs.push(temp)
1051
- }
1052
- return [{label: '全部', value: ''}, ...rs]
1053
- },
1054
- initAdjustables() {
1055
- //tag
1056
- let arr = []
1057
- let filter = this.$login.f.f_orgids
1058
- this.$GetSaleParam.getAdjustable(filter).forEach((item) => {
1059
- let temp = {}
1060
- temp.label = `[${item.value.f_adjustable_id}]-${item.label}`
1061
- temp.value = `${item.value.id}`
1062
- arr.push(temp)
1063
- })
1064
- this.adjustables = [{label: '全部', value: ''}, ...arr]
1065
- },
1066
- getAllGasproperties(){
1067
- this.gasproperties=[{
1068
- label:'全部',
1069
- value:''
1070
- }]
1071
- new HttpResetClass().load('POST',`/rs/sql/tel_singleTable_GroupBy`, {data: {
1072
- items: 'f_gasproperties',
1073
- tablename: 't_userfiles',
1074
- condition: `1=1`,
1075
- groupitem: 'f_gasproperties'
1076
- }}, {resolveMsg: null, rejectMsg: null}).then((res) => {
1077
- res.data.forEach(ress=>{
1078
- this.gasproperties.push({
1079
- label:ress.f_gasproperties,
1080
- value:ress.f_gasproperties
1081
- })
1082
- })
1083
- })
1084
- },
1085
- getAllOutlets(){
1086
- this.userareas=[{
1087
- label:'全部',
1088
- value:''
1089
- }]
1090
- new HttpResetClass().load('POST',`/rs/sql/tel_singleTable_GroupBy`, {data: {
1091
- items: 'f_outlets',
1092
- tablename: 't_user_address',
1093
- condition: `1=1`,
1094
- groupitem: 'f_outlets'
1095
- }}, {resolveMsg: null, rejectMsg: null}).then((res) => {
1096
- res.data.forEach(ress=>{
1097
- this.userareas.push({
1098
- label:ress.f_outlets,
1099
- value:ress.f_outlets
1100
- })
1101
- })
1102
- })
1103
- },
1104
- getAllMeterBook(val){
1105
- ////tag
1106
- ////tag
1107
- this.cbcs=[]
1108
- if (val){
1109
- new HttpResetClass().load('POST',`/rs/sql/tel_singleTable_OrderBy`, {data: {
1110
- items: 'f_book_name,f_book_slice_area,id',
1111
- tablename: 't_meter_book',
1112
- condition: `f_filiale_id in ${val}`,
1113
- orderitem: 'id'
1114
- }}, {resolveMsg: null, rejectMsg: null}).then((res) => {
1115
- res.data.forEach(ress=>{
1116
- this.cbcs.push({
1117
- id:ress.id,
1118
- f_book_name:ress.f_book_name,
1119
- f_book_slice_area:ress.f_book_slice_area
1120
- })
1121
- })
1122
- this.cbc=[]
1123
- this.cbc.push({
1124
- label:'全部',
1125
- value:''
1126
- })
1127
- this.cbcs.forEach(res=>{
1128
- this.cbc.push({
1129
- label:res.f_book_name,
1130
- value:res.id
1131
- })
1132
- })
1133
- })
1134
- }
1135
- },
1136
- getRes(obj) {
1137
- this.model.f_filialeids = this.$login.convertToIn(obj.resids);
1138
- this.Mreadibook(this.model.f_filialeids)
1139
- this.getAllMeterBook(this.model.f_filialeids)
1140
- this.getPcd(this.model.f_filialeids)
1141
- }
1142
- },
1143
-
1144
- watch: {
1145
- 'model.f_usertype'(val) {
1146
- if (val == '民用') {
1147
- this.model.safeCycle = this.civil
1148
- } else if (val == '非民用') {
1149
- this.model.safeCycle = this.civilian
1150
- }
1151
- },
1152
- 'model.SafeCheckXZ'(val) {
1153
- this.model.SafeCheckSC = ''
1154
- if (val == '已安检') {
1155
- this.model.SafeCheckCQ = ''
1156
- this.model.SafeCheckSX = {
1157
- f_check_end: '', // 安检时间 查询起始条件
1158
- f_check_start: ''// 安检时间 查询终止条件
1159
- }
1160
- } else {
1161
- // 当使用筛选条件时,清空不需要的条件选项
1162
- this.model.f_issue_start = ''
1163
- this.model.f_issue_end = ''
1164
- this.$refs.paged.$refs.criteria.model.f_check_start = ''
1165
- this.$refs.paged.$refs.criteria.model.f_check_end = ''
1166
- this.$refs.paged.$refs.criteria.model.f_last_check_state = ''
1167
- this.model.month = ''
1168
- if (val == '应安检') {
1169
- this.model.SafeCheckSC = '否'
1170
-
1171
- this.model.f_issue_start = Util.toStartDateString()
1172
- this.model.f_issue_end = Util.toStandardDateString()
1173
- }
1174
- // this.model.f_checktime_start = ''
1175
- // this.model.f_checktime_end = ''
1176
- }
1177
- },
1178
- 'model.SafeCheckSC'(val) {
1179
- if (val == '') {
1180
- this.model.f_issue_start = ''
1181
- this.model.f_issue_end = ''
1182
- }
1183
- },
1184
- // 'checker'(val){
1185
- // //tag
1186
- // if(val){
1187
- // this.checkboxModel.f_checker = this.checker[0].name
1188
- // this.checkboxModel.f_checker_id = this.checker[0].id
1189
- // }
1190
- // },
1191
- 'model.rows'() {
1192
- // if (!this.checkedAll) {//实现反选/
1193
- // this.checkrows = [];
1194
- for (let i = 0; i < this.$refs.paged.model.rows.length; i++) {
1195
- var k = false
1196
- for (let j = 0; j < this.checkrows.length; j++) {
1197
- if (this.$refs.paged.model.rows[i].f_userinfo_id == this.checkrows[j].f_userinfo_id) {
1198
- this.$set('$refs.paged.model.rows[' + i + '].checked', true)
1199
- k = true
1200
- continue
1201
- }
1202
- }
1203
- if (!k) {
1204
- this.$set('$refs.paged.model.rows[' + i + '].checked', false)
1205
- }
1206
- }
1207
- // } else {//实现全选
1208
- // // this.checkboxModel = {};
1209
- // for (let i = 0; i < this.$refs.paged.model.rows.length; i++) {
1210
- // this.$set('$refs.paged.model.rows[' + i + '].checked', true)
1211
- // }
1212
- // }
1213
- }
1214
- },
1215
- computed: {
1216
- selected() {
1217
- return this.$refs.paged.$refs.grid.selected
1218
- }
1219
- }
1220
- }
1221
- </script>
1222
- <style scoped>
1223
- .newcolor {
1224
- color: red;
1225
- }
1226
-
1227
- .table th {
1228
- background-color: #f2f6fa;
1229
- color: black;
1230
- }
1231
- </style>
1
+ <template>
2
+ <div class="flex">
3
+ <criteria-paged :model="model" v-ref:paged>
4
+ <criteria partial='criteria' @condition-changed='$parent.search' v-ref:criteria>
5
+ <div novalidate class="form-horizontal select-overspread container-fluid auto" partial>
6
+ <div class="row" v-show="!$parent.$parent.$parent.showItem">
7
+ <div :class="$parent.$parent.style">
8
+ <label class="font_normal_body">用户编号</label>
9
+ <input style="width: 60%" type="text" class="input_search" v-model="model.f_userinfo_code"
10
+ id="f_userinfo_code"
11
+
12
+ placeholder="用户编号" condition="f_userinfo_code like '%{}%'">
13
+ </div>
14
+ <div :class="$parent.$parent.style">
15
+ <label class="font_normal_body">用户姓名</label>
16
+ <input style="width: 60%" type="text" class="input_search" v-model="model.f_user_name" id="f_user_name"
17
+ placeholder="用户姓名" condition="f_user_name like '%{}%'">
18
+ </div>
19
+ <div :class="$parent.$parent.style">
20
+ <label class="font_normal_body">小&emsp;&emsp;区</label>
21
+ <input style="width: 60%" type="text" class="input_search" v-model="model.f_residential_area"
22
+ id="f_residential_area"
23
+ placeholder="小区" condition="f_residential_area like '%{}%'">
24
+ </div>
25
+ <div :class="$parent.$parent.style">
26
+ <label class="font_normal_body">地&emsp;&emsp;址</label>
27
+ <input style="width: 60%" type="text" class="input_search" v-model="model.f_address" id="f_address"
28
+ placeholder="地址" condition="f_address like '%{}%'">
29
+ </div>
30
+ <div :class="$parent.$parent.style" style="width: auto;margin-top:8px;float: right">
31
+ <export-excel-safe :data="$parent.$parent.searchData"
32
+ :field="$parent.$parent.excelHeaders"
33
+ :choose-col="true"
34
+ sqlurl="rs/logic/SafeExportExcel" sql-name="根据安检员查询用户档案"
35
+ template-name='用户安检情况'></export-excel-safe>
36
+ <button type="button" class="button_search button_spacing" @click="search()">查询</button>
37
+ <button type="button" class="button_search button_spacing" @click="$parent.$parent.blacklist()">拉黑</button>
38
+ <div style="float: right" class="button_spacing"
39
+ :class="{'button_shrink_left':$parent.$parent.$parent.showItem,'button_shrink_right':!$parent.$parent.$parent.showItem}"
40
+ @click="$parent.$parent.hiddenr()"></div>
41
+ <div style="float: right" class="button_spacing"
42
+ :class="{'button_shrink_top':$parent.$parent.criteriaShow,'button_shrink_bottom':!$parent.$parent.criteriaShow}"
43
+ @click="$parent.$parent.hidden()">
44
+
45
+ </div>
46
+ </div>
47
+
48
+
49
+ </div>
50
+ <div class="row" v-show="!$parent.$parent.$parent.showItem">
51
+ <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
52
+ <label class="font_normal_body">用户类型</label>
53
+ <v-select id="f_usertype"
54
+ placeholder='用户类型'
55
+ class="select select_list"
56
+ :value.sync="model.f_usertype"
57
+ :value-single="true"
58
+ :options='$parent.$parent.usertypes'
59
+ v-model="model.f_usertype"
60
+ condition="f_user_type = '{}'"
61
+ close-on-select clear-button></v-select>
62
+ </div>
63
+ <!-- <div class="form-group col-sm-2" v-show="$parent.$parent.criteriaShow && !$parent.$parent.$parent.showItem"></div>-->
64
+
65
+ <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
66
+ <label class="font_normal_body" style="color: red;">安检筛选</label>
67
+ <v-select
68
+ placeholder='安检筛选'
69
+ :value-single="true"
70
+ class="select select_list"
71
+ :value.sync="$parent.$parent.SafeCheckXZ"
72
+ :options='$parent.$parent.SafeCheckXZs'
73
+ v-model="$parent.$parent.SafeCheckXZ"
74
+ close-on-select clear-button></v-select>
75
+ </div>
76
+ <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
77
+ <label class="font_normal_body">安检起始</label>
78
+ <datepicker
79
+ :value.sync="model.f_check_start"
80
+ placeholder='最后安检时间起始'
81
+ style="width: 60%"
82
+ :format="'yyyy-MM-dd 00:00:00'"
83
+ :show-rest-button="reset"
84
+ v-model="model.f_check_start">
85
+ </datepicker>
86
+ </div>
87
+ <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
88
+ <label class="font_normal_body">安检结束</label>
89
+ <datepicker
90
+ :value.sync="model.f_check_end"
91
+ placeholder='最后安检时间结束'
92
+ style="width: 60%"
93
+ :format="'yyyy-MM-dd 23:59:59'"
94
+ :show-rest-button="reset"
95
+ v-model="model.f_check_end">
96
+ </datepicker>
97
+ </div>
98
+
99
+ <!-- <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
100
+ <label class="font_normal_body">安检状态</label>
101
+ <v-select id="f_entry"
102
+ placeholder='安检状态'
103
+ class="select select_list"
104
+ :value.sync="model.f_last_check_state"
105
+ :value-single="true"
106
+ :options='$parent.$parent.checkstatus'
107
+ v-model="model.f_last_check_state"
108
+ condition="f_last_check_state = '{}'"
109
+ close-on-select clear-button></v-select>
110
+ </div>-->
111
+ <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
112
+ <label class="font_normal_body">隐患情况</label>
113
+ <v-select
114
+ placeholder='隐患情况'
115
+ class="select select_list"
116
+ :value-single="true"
117
+ v-model='model.f_check_result'
118
+ :value.sync="model.f_check_result"
119
+ :options='$parent.$parent.f_check_results'
120
+ condition="f_last_check_result like '%{}%'"
121
+ close-on-select clear-button></v-select>
122
+ </div>
123
+ <!-- <div class="form-group col-sm-2" v-show="$parent.$parent.criteriaShow && !$parent.$parent.$parent.showItem"></div>-->
124
+ </div>
125
+ <div class="row" v-show="!$parent.$parent.$parent.showItem">
126
+
127
+ <div class="col-sm-4 form-group" v-show="$parent.$parent.criteriaShow" style="margin: 0">
128
+ <role-selector-safe
129
+ role-name="安检员"
130
+ role-lable="安&nbsp;检&nbsp;员&nbsp;"
131
+ @re-res="$parent.$parent.getRes"
132
+ :value.sync="model.f_checker_id"
133
+ v-model="model.f_checker_id"
134
+ :value-multiple="true"
135
+ condition=" f_checker_name in {}">
136
+ </role-selector-safe>
137
+ </div>
138
+ <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
139
+ <label class="font_normal_body">片&emsp;&emsp;区</label>
140
+ <v-select class="select_list select"
141
+ placeholder='片区/管理站' style="width: 60%"
142
+ :value.sync="model.f_slice_area" v-model="model.f_slice_area"
143
+ :options='$parent.$parent.sliceArea'
144
+ filer-key="name"
145
+ close-on-select clear-button
146
+ condition="f_slice_area='{}'"
147
+ @change="$parent.$parent.getmeterbook(model.f_slice_area)"
148
+ :value-single="true">
149
+ </v-select>
150
+ </div>
151
+ <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
152
+ <label class="font_normal_body">抄&ensp;表&ensp;册</label>
153
+ <v-select class="select_list select"
154
+ placeholder='抄表册' style="width: 60%"
155
+ :value.sync="model.f_meter_book_num" v-model="model.f_meter_book_num"
156
+ :options='$parent.$parent.cbc'
157
+ filer-key="name"
158
+ close-on-select clear-button
159
+ condition="f_meter_book_num={}"
160
+ :value-single="true">
161
+ </v-select>
162
+ </div>
163
+ <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
164
+ <label class="font_normal_body">省&ensp;市&ensp;区</label>
165
+ <v-select class="select_list select"
166
+ placeholder='请选择' style="width: 60%"
167
+ :value.sync="model.f_pcd" v-model="model.f_pcd"
168
+ :options='$parent.$parent.pcds'
169
+ filer-key="name"
170
+ close-on-select clear-button
171
+ condition="f_pcd='{}'"
172
+ :value-single="true">
173
+ </v-select>
174
+ </div>
175
+ <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
176
+ <label class="font_normal_body">用户状态</label>
177
+ <v-select class="select_list select"
178
+ placeholder='用户状态' style="width: 60%"
179
+ :value.sync="model.f_user_state" v-model="model.f_user_state"
180
+ :options='$parent.$parent.userstates'
181
+ close-on-select clear-button
182
+ condition="f_user_state = '{}'"
183
+ :value-single="true">
184
+ </v-select>
185
+ </div>
186
+ <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
187
+ <label class="font_normal_body">用户性质</label>
188
+ <v-select class="select_list select"
189
+ placeholder='用户性质' style="width: 60%"
190
+ :value.sync="model.f_gasproperties" v-model="model.f_gasproperties"
191
+ :options='$parent.$parent.gasproperties'
192
+ close-on-select clear-button
193
+ condition="f_gasproperties = '{}'"
194
+ :value-single="true">
195
+ </v-select>
196
+ </div>
197
+ <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
198
+ <label class="font_normal_body">片区</label>
199
+ <v-select class="select_list select"
200
+ placeholder='片区' style="width: 60%"
201
+ :value.sync="model.f_outlets" v-model="model.f_outlets"
202
+ :options='$parent.$parent.userareas'
203
+ close-on-select clear-button
204
+ condition="f_outlets = '{}'"
205
+ :value-single="true">
206
+ </v-select>
207
+ </div>
208
+ </div>
209
+
210
+ <div class="row" v-show="$parent.$parent.$parent.showItem">
211
+ <div :class="$parent.$parent.style">
212
+ <label class="font_normal_body">用户编号</label>
213
+ <input style="width: 60%" type="text" class="input_search" v-model="model.f_userinfo_code"
214
+
215
+ placeholder="用户编号" condition="f_userinfo_code like '%{}%'">
216
+ </div>
217
+ <div :class="$parent.$parent.style">
218
+ <label class="font_normal_body">用户姓名</label>
219
+ <input style="width: 60%" type="text" class="input_search" v-model="model.f_user_name"
220
+ placeholder="用户姓名" condition="f_user_name like '%{}%'">
221
+ </div>
222
+ <div :class="$parent.$parent.style" style="width: auto;margin-top:8px;float: right">
223
+ <export-excel-safe :data="$parent.$parent.searchData"
224
+ :field="$parent.$parent.excelHeaders"
225
+ sqlurl="rs/logic/SafeExportExcel" sql-name="根据安检员查询用户档案"
226
+ template-name='用户安检情况'></export-excel-safe>
227
+ <button type="button" class="button_search button_spacing" @click="search()">查询</button>
228
+ <button type="button" class="button_search button_spacing" @click="$parent.$parent.blacklist()">拉黑</button>
229
+ <div style="float: right" class="button_spacing"
230
+ :class="{'button_shrink_left':$parent.$parent.$parent.showItem,'button_shrink_right':!$parent.$parent.$parent.showItem}"
231
+ @click="$parent.$parent.hiddenr()"></div>
232
+ <div style="float: right" class="button_spacing"
233
+ :class="{'button_shrink_top':$parent.$parent.criteriaShow,'button_shrink_bottom':!$parent.$parent.criteriaShow}"
234
+ @click="$parent.$parent.hidden()">
235
+
236
+ </div>
237
+ </div>
238
+
239
+ </div>
240
+ <div class="row" v-show="$parent.$parent.$parent.showItem">
241
+ <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
242
+ <label class="font_normal_body">小&emsp;&emsp;区</label>
243
+ <input style="width: 60%" type="text" class="input_search" v-model="model.f_residential_area"
244
+
245
+ placeholder="小区" condition="f_residential_area like '%{}%'">
246
+ </div>
247
+ <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
248
+ <label class="font_normal_body">地&emsp;&emsp;址</label>
249
+ <input style="width: 60%" type="text" class="input_search" v-model="model.f_address"
250
+
251
+ placeholder="地址" condition="f_address like '%{}%'">
252
+ </div>
253
+ <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
254
+ <label class="font_normal_body">用户类型</label>
255
+ <v-select
256
+ placeholder='用户类型'
257
+ class="select select_list"
258
+
259
+ :value.sync="model.f_usertype"
260
+ :value-single="true"
261
+ :options='$parent.$parent.usertypes'
262
+ v-model="model.f_usertype"
263
+ condition="f_user_type = '{}'"
264
+ close-on-select clear-button></v-select>
265
+ </div>
266
+ <!-- <div class="form-group col-sm-2" v-show="$parent.$parent.criteriaShow && !$parent.$parent.$parent.showItem"></div>-->
267
+
268
+ <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
269
+ <label class="font_normal_body" style="color: red;">安检筛选</label>
270
+ <v-select
271
+ placeholder='安检筛选'
272
+ :value-single="true"
273
+
274
+ class="select select_list"
275
+ :value.sync="$parent.$parent.SafeCheckXZ"
276
+ :options='$parent.$parent.SafeCheckXZs'
277
+ v-model="$parent.$parent.SafeCheckXZ"
278
+ close-on-select clear-button></v-select>
279
+ </div>
280
+
281
+ </div>
282
+ <div class="row" v-show="$parent.$parent.$parent.showItem">
283
+ <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
284
+ <label class="font_normal_body">安检起始</label>
285
+ <datepicker
286
+ :value.sync="model.f_check_start"
287
+ placeholder='最后安检时间起始'
288
+ :disabled-days-of-week="[]"
289
+ style="width: 60%"
290
+ :format="'yyyy-MM-dd'"
291
+ :show-rest-button="reset"
292
+ v-model="model.f_check_start">
293
+ </datepicker>
294
+ </div>
295
+ <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
296
+ <label class="font_normal_body">安检结束</label>
297
+ <datepicker
298
+ :value.sync="model.f_check_end"
299
+ placeholder='最后安检时间结束'
300
+ style="width: 60%"
301
+ :disabled-days-of-week="[]"
302
+ :format="'yyyy-MM-dd'"
303
+ :show-rest-button="reset"
304
+ v-model="model.f_check_end">
305
+ </datepicker>
306
+ </div>
307
+
308
+ <!-- <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
309
+ <label class="font_normal_body">安检状态</label>
310
+ <v-select
311
+ placeholder='安检状态'
312
+ class="select select_list"
313
+
314
+ :value.sync="model.f_last_check_state"
315
+ :value-single="true"
316
+ :options='$parent.$parent.checkstatus'
317
+ v-model="model.f_last_check_state"
318
+ condition="f_last_check_state = '{}'"
319
+ close-on-select clear-button></v-select>
320
+ </div>-->
321
+ <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
322
+ <label class="font_normal_body">隐患情况</label>
323
+ <v-select
324
+ placeholder='隐患情况'
325
+ class="select select_list"
326
+ :value-single="true"
327
+ v-model='model.f_check_result'
328
+ :value.sync="model.f_check_result"
329
+ :options='$parent.$parent.f_check_results'
330
+ condition="f_last_check_result like '%{}%'"
331
+ close-on-select clear-button></v-select>
332
+ </div>
333
+
334
+ </div>
335
+ <!--<div class="row" v-show="$parent.$parent.$parent.showItem">
336
+ <div :class="$parent.$parent.style" v-show="$parent.$parent.criteriaShow">
337
+ <label class="font_normal_body">公&emsp;&emsp;司</label>
338
+ <right-tree @re-res="$parent.$parent.getRes" :initresid="$parent.$parent.$login.f.orgid">
339
+ </right-tree>
340
+ </div>
341
+
342
+ </div>-->
343
+ </div>
344
+ </criteria>
345
+ <data-grid :model="model" partial="list" class="list_area table_sy" v-ref:grid>
346
+ <template partial='head'>
347
+ <tr>
348
+ <th><nobr><input type="checkbox" v-model="$parent.$parent.$parent.checkAll" @click.stop="()=>{return}" />全选</nobr></th>
349
+ <th>
350
+ <nobr>用户编号</nobr>
351
+ </th>
352
+ <th>
353
+ <nobr>用户名称</nobr>
354
+ </th>
355
+ <th>
356
+ <nobr>用户电话</nobr>
357
+ </th>
358
+ <th>
359
+ <nobr>用户表号</nobr>
360
+ </th>
361
+ <!-- <th>-->
362
+ <!-- <nobr>气表品牌</nobr>-->
363
+ <!-- </th>-->
364
+ <th>
365
+ <nobr>用户类型</nobr>
366
+ </th>
367
+ <!-- <th>-->
368
+ <!-- <nobr>壁挂炉</nobr>-->
369
+ <!-- </th>-->
370
+ <!-- <th>-->
371
+ <!-- <nobr>灶具</nobr>-->
372
+ <!-- </th>-->
373
+ <th>
374
+ <nobr>小区名称</nobr>
375
+ </th>
376
+ <th style="padding: 0 40px">
377
+ <nobr>地址</nobr>
378
+ </th>
379
+ <th>
380
+ <nobr>安检员</nobr>
381
+ </th>
382
+ <!-- <th>-->
383
+ <!-- <nobr>安检员备注</nobr>-->
384
+ <!-- </th>-->
385
+ <th>
386
+ <nobr>安检日期</nobr>
387
+ </th>
388
+ <th>
389
+ <nobr>安检状态</nobr>
390
+ </th>
391
+ <th>
392
+ <nobr>安检结果</nobr>
393
+ </th>
394
+ <th>
395
+ <nobr>二维码</nobr>
396
+ </th>
397
+ </tr>
398
+ </template>
399
+ <template partial='body'>
400
+ <td style="text-align: center;white-space:nowrap;"><input type="checkbox" @click="$event.cancelBubble=true" :checked="$parent.$parent.$parent.isChecked(row.f_userinfo_code)" @change="$parent.$parent.$parent.setCheckes(row.f_userinfo_code)"></input></td>
401
+ <td v-bind:class="{newcolor:row.code==1}" style="text-align: center;">{{ row.f_userinfo_code }}</td>
402
+ <td v-bind:class="{newcolor:row.code==1}" style="text-align: center;">{{ row.f_user_name }}</td>
403
+ <td v-bind:class="{newcolor:row.code==1}" style="text-align: center;">{{ row.f_user_phone }}</td>
404
+ <td v-bind:class="{newcolor:row.code==1}" style="text-align: center;">{{row.f_meternumber}}</td>
405
+ <!-- <td v-bind:class="{newcolor:row.code==1}" style="text-align: center;">{{row.f_meter_brand}}</td>-->
406
+ <td v-bind:class="{newcolor:row.code==1}" style="text-align: center">{{ row.f_user_type }}</td>
407
+ <!-- <td v-bind:class="{newcolor:row.code==1}" style="text-align: center">{{ row.f_safe_hasfurnace }}</td>-->
408
+ <!-- <td v-bind:class="{newcolor:row.code==1}" style="text-align: center">{{ row.f_safe_haskitchen }}</td>-->
409
+ <td v-bind:class="{newcolor:row.code==1}" style="text-align: center">{{ row.f_residential_area }}</td>
410
+ <td v-bind:class="{newcolor:row.code==1}" style="text-align: center">{{ row.f_address }}</td>
411
+ <td v-bind:class="{newcolor:row.code==1}" style="text-align: center">{{ row.f_checker_name }}</td>
412
+ <td v-bind:class="{newcolor:row.code==1}" style="text-align: center">{{ row.f_last_check_date }}</td>
413
+ <td v-bind:class="{newcolor:row.code==1}" style="text-align: center">{{ row.f_last_check_state }}</td>
414
+ <td v-bind:class="{newcolor:row.code==1}" style="text-align: center">
415
+ {{row.f_last_check_result1 }}
416
+ </td>
417
+ <td v-bind:class="{newcolor:row.code==1}" style="text-align: center">
418
+ <button class="button_spacing button_search-1" @click.stop='$parent.$parent.$parent.searchInfo(row.f_userinfo_code,row.f_address,row.f_user_type,row.f_address_detail,row.f_house_number)' >点击</button>
419
+ </td>
420
+ </template>
421
+ </data-grid>
422
+ </criteria-paged>
423
+ <modal :show.sync="dialogVisible" destroyOnClose={true} v-ref:modal v-if="dialogVisible">
424
+ <div slot="modal-header" class="modal-header">
425
+ <h4 class="modal-title" style="text-align: center">
426
+ 二维码
427
+ </h4>
428
+ </div>
429
+ <div slot="modal-body" class="modal-body" >
430
+ <div id="aa" style="margin-left: 115px">
431
+ <div id="bb">
432
+ <style id="style1">
433
+ #bb {
434
+ width: 302px;
435
+ height: 170px;
436
+ }
437
+ #bb .img{
438
+ width: 40px;
439
+ height: 40px;
440
+ }
441
+ #bb .td1{
442
+ text-align: left;
443
+ white-space: nowrap;
444
+ font-size: 12px;
445
+ font-weight: 900;
446
+ }
447
+ #bb .td2{
448
+ text-align: right;
449
+ font-size: 10px;
450
+ font-weight: 900;
451
+ }
452
+ #bb .td3{
453
+ text-align: center;
454
+ font-weight: 900;
455
+ }
456
+ #bb .baseImg{
457
+ width: 120px;
458
+ height: 120px;
459
+ float: right;
460
+ overflow:hidden;
461
+ }
462
+ #bb .span{
463
+ white-space: nowrap;
464
+ }
465
+ #bb .td0{
466
+ text-align: left;
467
+ width: 60px;
468
+ }
469
+ </style>
470
+ <table>
471
+ <tr>
472
+ <td class="td0">
473
+ <img class="img" src="../../../assets/wensu/1.jpg" alt="">
474
+ </td>
475
+ <td class="td0">
476
+ <img class="img" src="../../../assets/wensu/2.jpg" alt="">
477
+ </td>
478
+ <td class="td3">
479
+ <span class="span" style="font-size: 13px;font-weight: 900">温宿县曦隆燃气开发有限公司</span><br>
480
+ <span class="span" style="font-weight: 900">天然气入户安全检查专用标签</span>
481
+ </td>
482
+ </tr>
483
+ <tr>
484
+ <td class="td1" colspan="2">用&nbsp;户&nbsp;类&nbsp;型&nbsp;:&nbsp;{{modal_user_type}}</td>
485
+ <td colspan="3" rowspan="6"><img class="baseImg" :src="modal_base64_img" alt="">
486
+ </tr>
487
+ <tr><td class="td1" colspan="3">片区负责人&nbsp;:&nbsp;{{modal_responsible_checker}}</td></tr>
488
+ <tr><td class="td1" colspan="3">联&nbsp;系&nbsp;电&nbsp;话&nbsp;:&nbsp;{{modal_responsible_phone}}</td></tr>
489
+ <tr><td class="td1" style="font-size: 13px" colspan="3">燃气客服电话&nbsp;:&nbsp;0997-6150333</td></tr>
490
+ <tr><td class="td1" style="font-size: 13px" colspan="3">燃气报警电话&nbsp;:&nbsp;0997-4533119</td></tr>
491
+ <tr><td class="td1" colspan="3">地址&nbsp;:&nbsp;{{modal_user_address}}</td></tr>
492
+ <tr><td class="td2" colspan="5">曦隆燃气&nbsp;&nbsp;&nbsp;&nbsp;情系万家</td></tr>
493
+ </table>
494
+ </div>
495
+ </div>
496
+ </div>
497
+ <div slot="modal-footer" class="modal-footer">
498
+ <print-element class="btn btn-success width-80" id="aa" styleid='style1' top='1' left='1' width='100%' height='100%' v-ref:printelement>打印</print-element>
499
+ <button type="button" class="btn btn-success width-80" @click="dialogVisible = false">确认</button>
500
+ <button type="button" class="btn btn-success width-80" @click="dialogVisible = false">取消</button>
501
+ </div>
502
+ </modal>
503
+ <modal :show.sync="showModal2" :backdrop="false">
504
+ <div slot="modal-header" class="modal-header">
505
+ <h4 class="modal-title">
506
+ 批量拉黑
507
+ </h4>
508
+ </div>
509
+ <div slot="modal-body" class="modal-body">
510
+ <div v-if="true">
511
+ <div class="row" style="margin-top: 10px">
512
+ <label class="control-label font text-left" style="float:left;margin-left:20%;margin-top:5px">拉黑备注</label>
513
+ <div class="col-xs-8 col-md-8">
514
+ <textarea style="width: 60%; height: 100px" v-model="f_remarks"></textarea>
515
+ </div>
516
+ </div>
517
+ </div>
518
+ </div>
519
+ <div slot="modal-footer" class="modal-footer" style="text-align: center">
520
+ <button class="button_search" @click="blacklist">确认</button>
521
+ <button class="button_search" @click="showModal2=false">取消</button>
522
+ </div>
523
+ </modal>
524
+ <!-- <modal :show.sync="showModal3">
525
+ <div slot="modal-header" class="modal-header">
526
+ <h4 class="modal-title">
527
+ 转维修进度{{ progressbarWidth }}%
528
+ </h4>
529
+ </div>
530
+ <div slot="modal-body" class="modal-body">
531
+ <div class="progress">
532
+ <div class="progress-bar" role="progressbar" aria-valuenow="60"
533
+ aria-valuemin="0" aria-valuemax="100" :style="'width:'+ progressbarWidth+'%'">
534
+ &lt;!&ndash; <span class="sr-only">40% 完成</span>&ndash;&gt;
535
+ </div>
536
+ </div>
537
+ </div>
538
+ <div slot="modal-footer" class="modal-footer" style="text-align: center" v-show="false"></div>
539
+ </modal>-->
540
+ </div>
541
+
542
+ </template>
543
+
544
+ <script>
545
+ import {PagedList} from 'vue-client'
546
+ import {HttpResetClass} from 'vue-client'
547
+ import co from 'co'
548
+ import * as Util from '../../Util'
549
+ import Vue from 'vue'
550
+
551
+
552
+ // let select = function * (self,userid) {
553
+ // let http = new HttpResetClass()
554
+ // let getGasman = yield http.load('POST','/rs/search', {
555
+ // source: 'this.getChildByName($安检员$).getUsers()',
556
+ // userid: userid
557
+ // }, {resolveMsg: null, rejectMsg: null})
558
+ // //tag
559
+ // getGasman.data.forEach((checker)=>{
560
+ // self.checkersid.push({label:checker.name,value:checker.id})
561
+ // })
562
+ // self.checkersid.push({label:'全部',value:''})
563
+ // }
564
+
565
+
566
+ export default {
567
+ title: '用户安检情况',
568
+ data() {
569
+ let options = []
570
+ let year = (new Date()).getFullYear()
571
+ for (let i = year; i <= year + 3; i++)
572
+ options.push({label: i + '', value: i + ''})
573
+ let moptions = []
574
+ for (let i = 1; i <= 12; i++)
575
+ moptions.push({label: i + '', value: i + ''})
576
+
577
+ return {
578
+ dialogVisible: false,
579
+ searchData: {
580
+ condition: '1=1',
581
+ orderitem: "f_userinfo_code",
582
+ timetype: "dd",
583
+ f_defect_content: "CASE WHEN CHARINDEX( '\"result\":\"正常\"', tp.f_defect_content ) > 0 THEN '正常' ELSE replace(replace(replace( replace( RIGHT ( tp.f_defect_content, len( tp.f_defect_content ) - 26 ), substring('{}',2,1), '' ), substring('{}',1,1), '' ),']',''),'\"','') END"
584
+ },
585
+ excelHeaders: {
586
+ //用户编号 用户名称 用户电话 安检次数 用户类型 小区名称 地址 安检日期 安检状态 安检结果
587
+
588
+ 'f_userinfo_code': '用户编号',
589
+ 'f_user_name': '用户名称',
590
+ 'f_user_phone': '用户电话',
591
+ 'f_meternumber': '用户表号',
592
+ 'f_user_type': '用户类型',
593
+ 'f_checker_name': '安检员',
594
+ 'f_residential_area': '小区名称',
595
+ 'f_address': '地址',
596
+ 'f_last_check_date': '安检日期',
597
+ 'f_last_check_state': '安检状态',
598
+ 'f_last_check_result1': '安检结果'
599
+ },
600
+ model: new PagedList('rs/sql/根据安检员查询用户档案', 20, {
601
+ orderitem: "'f_last_check_date'",
602
+ timetype: "'dd'",
603
+ f_defect_content: 'this.f_defect_content'
604
+ }),
605
+ f_defect_content:"CASE WHEN CHARINDEX( '\"result\":\"正常\"', tp.f_defect_content ) > 0 THEN '无隐患' ELSE replace(replace(replace( replace( RIGHT ( tp.f_defect_content, len( tp.f_defect_content ) - 26 ), substring('{}',2,1), '' ), substring('{}',1,1), '' ),']',''),'\"','') END",
606
+ orgstrs: [{label: '全部', value: ''}],
607
+ checkersid: [],
608
+ gasproperties:[],
609
+ userareas:[],
610
+ SafeCheckXZ: '',
611
+ civil: '', //民用安检周期
612
+ civilian: '', //非民用安检周期
613
+ SafeCheckXZs: [{label: '全部', value: ''}, {label: '已入户', value: '已入户'}, {label: '未入户', value: '未入户'}], // 安检筛选选项
614
+ SafeCheckSXs: [{label: '是', value: '是'}, {label: '否', value: '否'}, {label: '全部', value: ''}],
615
+ // user_states:[{label: '全部', value: ''}, ...this.$appdata.getParam('用户状态')],
616
+ IsShares: [{label: '是', value: '是'}, {label: '否', value: '否'}],
617
+ IsShare: '否',
618
+ checker: {},
619
+ NoBuys: [{label: '是', value: '是'}, {label: '否', value: '否'}],
620
+ criteriaShow: false,
621
+ checkers: [],
622
+ chosenOrg: {id: 0},
623
+ showModal: false,
624
+ checkedAll: false,
625
+ checkrows: [],
626
+ adjustables: [],
627
+ f_plan_year: year + '',
628
+ f_plan_month: moptions[new Date().getMonth()].value,
629
+ f_effective_start_time: '', //计划有效起始时间
630
+ f_effective_end_time: '', //计划有效结束时间
631
+ checkboxModel: {},
632
+ c_year_list: options,
633
+ c_month_list: moptions,
634
+ areas: this.areas(),
635
+ checkstatus: this.checkstatus(),
636
+ usertypes: this.usertypes(),
637
+ userstates: this.userstates(),
638
+ sqlname: '',
639
+ f_check_results: [{label: '全部', value: ''}, {label: '正常', value: '正常'}, {label: '有隐患', value: '有隐患'}],
640
+ creatPlanWay: '',
641
+ sliceArea: [],
642
+ cbcs:[],
643
+ cbc:[],
644
+ pcds:[],
645
+ modal_user_type:'',
646
+ modal_responsible_checker:'',
647
+ modal_responsible_phone:'',
648
+ modal_user_address:'',
649
+ modal_base64_img:'',
650
+ checkes: [],
651
+ checkAll: false,
652
+ showModal2:false,
653
+ showModal3:false,
654
+ f_remarks:'',
655
+ progressbarWidth:'0',
656
+ }
657
+ },
658
+ props: {
659
+ style: {
660
+ type: String,
661
+ default: 'col-sm-2 form-group'
662
+ },
663
+ style2: {
664
+ type: String,
665
+ default: 'col-sm-4 form-group'
666
+ },
667
+ checkplan: { // 传入一条安检计划信息
668
+ type: Object
669
+ },
670
+ additemshow: {
671
+ type: Boolean,
672
+ default: false
673
+ }
674
+ },
675
+ ready() {
676
+ // 获取分公司信息
677
+ this.model.f_defect_content=this.f_defect_content
678
+
679
+ //this.getfengongsi()
680
+ this.model.chosenOrg = {id: 0}
681
+ this.model.f_filialeids = this.$login.f.f_orgids
682
+ this.model.f_filiale = this.$login.f.f_fengongsi
683
+ this.model.f_OrgStr = this.$login.f.orgpathstr
684
+ this.Mreadibook(`('${this.$login.f.orgid}')`)
685
+ this.getAllMeterBook(`('${this.$login.f.orgid}')`)
686
+ this.getAllGasproperties()
687
+ this.getAllOutlets()
688
+ },
689
+ methods: {
690
+ async blacklist(){
691
+ if(!this.checkAll && this.checkes.length==0){
692
+ Vue.showMessage("请先勾选你要拉黑的用户!")
693
+ return
694
+ }
695
+ this.$showMessage("确定需要将选中用户在营收系统进行拉黑吗?",['confirm', 'cancel']).then((res)=>{
696
+ if (res === 'confirm'){
697
+ //this.showModal3=true
698
+ let successCount=0
699
+ console.log('是否全选', this.checkAll)
700
+ console.log('当前选中用户', this.checkes)
701
+ console.log('this.model----', this.model)
702
+ new HttpResetClass().load('post','rs/logic/safe_getuser_to_blactlist', {
703
+ data:{
704
+ condition: this.model.condition.condition1,
705
+ condition2: this.model.condition.condition2,
706
+ switchCheckAll: true,
707
+ checkAll: this.checkAll,
708
+ param: this.checkes,
709
+ columnName: 'f_userinfo_code',
710
+ orderitem:' f_userinfo_code',
711
+ type:'update'
712
+ }
713
+ }).then((res)=>{
714
+ this.$showMessage("操作成功!本次选中用已标记为待拉黑状态,同步营收系统会存在延迟。")
715
+ }).catch((msg)=>{
716
+ this.$showMessage("网络异常请稍后再试!")
717
+ })
718
+
719
+ }
720
+ })
721
+
722
+ /*new HttpResetClass().load('post','API/Secheck/SetBlackList', {
723
+ data:{
724
+ id:'700002373',
725
+ bh:'1511080819',
726
+ black:true,
727
+ blackMemo:'测试拉黑!!!'
728
+ }
729
+ }).then(res=>{
730
+ if (result.data.code==200) {
731
+ successCount += result.data.successcon
732
+ this.progressbarWidth=Math.ceil((i+1)*100/(this.checkes.length))
733
+ }
734
+ console.log('拉黑返回结果----', res)
735
+ }).catch(err=>{
736
+ console.log('拉黑请求失败----', err)
737
+ })*/
738
+ },
739
+ isChecked (v) {
740
+ // 如果全选,不在的按选中算,否则,在的按选中算
741
+ if (this.checkAll) {
742
+ return this.checkes.indexOf(v) == -1
743
+ } else {
744
+ return this.checkes.indexOf(v) != -1
745
+ }
746
+ },
747
+ setCheckAll () {
748
+ this.checkAll = this.checkAll ? false : true
749
+ // 全选改变后,清空选中数据
750
+ this.checkes = []
751
+ },
752
+ setCheckes (id) {
753
+ let index = this.checkes.indexOf(id)
754
+ if (index < 0) {
755
+ this.checkes.push(id)
756
+ } else {
757
+ this.checkes.splice(index, 1)
758
+ }
759
+ },
760
+ //查询二维码
761
+ searchInfo(val,address,userType,checkerName,checkerPhone){
762
+ this.dialogVisible = true
763
+ new HttpResetClass().load('post','rs/logic/QrcodeUtil', {
764
+ data: {
765
+ id:val
766
+ }
767
+ }).then(res=>{
768
+ this.modal_user_type=userType
769
+ this.modal_user_address=address
770
+ this.modal_responsible_checker=checkerName
771
+ this.modal_responsible_phone=checkerPhone
772
+ this.modal_base64_img="data:image/jpg;base64,"+res.data.result
773
+ })
774
+
775
+ },
776
+ //获取省市区列表
777
+ getPcd(val){
778
+ this.pcds = [{label:'全部',value:''}]
779
+ new HttpResetClass().load("POST", `/rs/sql/safe_singleTable_OrderBy`,
780
+ {data:{items:"*",tablename:"t_pcd",orderitem:"id",condition:`f_orgid in ${val}`}},
781
+ {resolveMsg: null, rejectMsg: null}).then((pcdlist)=>{
782
+ pcdlist.data.forEach((result)=>{
783
+ this.pcds.push({label:result.f_pcd,value:result.f_pcd})
784
+ })
785
+ })
786
+ },
787
+ getmeterbook(val){
788
+
789
+ //tag
790
+ this.cbc=[]
791
+ this.cbc.push({
792
+ label:'全部',
793
+ value:''
794
+ })
795
+ if (val==''){
796
+
797
+ this.cbcs.forEach(res=>{
798
+ this.cbc.push({
799
+ label:res.f_book_name,
800
+ value:res.id
801
+ })
802
+ })
803
+ }else{
804
+ this.cbcs.forEach(res=>{
805
+ if (res.f_book_slice_area==val){
806
+ this.cbc.push({
807
+ label:res.f_book_name,
808
+ value:res.id
809
+ })
810
+ }
811
+ })
812
+ }
813
+ },
814
+ Mreadibook(val){
815
+ ////tag
816
+ ////tag
817
+ if (val){
818
+ new HttpResetClass().load('POST',`/rs/sql/tel_singleTable_OrderBy`, {data: {
819
+ items: 'name',
820
+ tablename: 't_zone',
821
+ condition: `parentid in ${val}`,
822
+ orderitem: 'id'
823
+ }}, {resolveMsg: null, rejectMsg: null}).then((res) => {
824
+ this.sliceArea=[]
825
+ this.sliceArea.push({
826
+ label:'全部',
827
+ value:''
828
+ })
829
+ res.data.forEach(ress=>{
830
+ this.sliceArea.push({
831
+ label:ress.name,
832
+ value:ress.name
833
+ })
834
+ })
835
+
836
+ })
837
+ }
838
+ },
839
+ // 获取县域分公司内容
840
+ getfengongsi() {
841
+ let val = {
842
+ source: 'this.getParentByType($organization$).getSpecialResByType($organization$)',
843
+ userid: `${this.$login.f.id}`
844
+ }
845
+ let http = new HttpResetClass()
846
+ http.load('POST', '/rs/search', {data: val}, {resolveMsg: null, rejectMsg: null}).then((res) => {
847
+ res.data.forEach((item) => {
848
+ this.orgstrs.push({label: item.name, value: item.id})
849
+ })
850
+ //tag
851
+ })
852
+ },
853
+ // 县域分公司发生改变
854
+ // orgstrchange(val){
855
+ // if(val == undefined || val == ''){
856
+ // return
857
+ // }else {
858
+ // this.checkersid = []
859
+ // let gen = select(this,val)
860
+ // return co(gen)
861
+ // }
862
+ // },
863
+ getDefect(val) {
864
+ if (val) {
865
+ try {
866
+ var defect = JSON.parse(val)
867
+ return defect.result
868
+ } catch (e) {
869
+ //tag
870
+ return '正常'
871
+ }
872
+ }
873
+ return '正常'
874
+ },
875
+ checkerchange(val) {
876
+ this.checkboxModel.f_checker = val.name
877
+ this.checkboxModel.f_checker_id = val.id
878
+ },
879
+ search(args) {
880
+ if (this.SafeCheckXZ && (args.model.f_check_start == '' || args.model.f_check_end == '')) {
881
+ this.$showMessage('如果选择 已安检/未安检 选项,需要选择 安检起始时间!')
882
+ return
883
+ }
884
+ this.checkes = []
885
+ /*if (this.SafeCheckXZ == '未安检') {
886
+ args.condition += " and ( f_last_check_date >= '" + args.model.f_check_end + "' or f_last_check_date <= '" + args.model.f_check_start + "' or f_last_check_date is null)"
887
+ } else {
888
+ if (args.model.f_check_start) {
889
+ args.condition += " and f_last_check_date >= '" + args.model.f_check_start + "'"
890
+ }
891
+ if (args.model.f_check_end) {
892
+ args.condition += " and f_last_check_date <= '" + args.model.f_check_end + "'"
893
+ }
894
+ }*/
895
+ //args.condition += " and f_filialeid in " + (this.model.f_filialeids ? this.model.f_filialeids : `(${this.$login.f.orgid})`)
896
+ let con = ' f_filialeid in ' + (this.model.f_filialeids ? this.model.f_filialeids : `(${this.$login.f.orgid}) `)
897
+ con += args.model.f_check_start ? ` and f_offsite_time >= '${args.model.f_check_start}'` : ''
898
+ con += args.model.f_check_end ? ` and f_offsite_time <= '${args.model.f_check_end}'` : ''
899
+ if (this.SafeCheckXZ == '未入户') {
900
+ con += ` and f_entry_status = '入户'`
901
+ args.condition += ' and ruhuid is null'
902
+ } else if (this.SafeCheckXZ == '已入户') {
903
+ con += ` and f_entry_status = '入户'`
904
+ args.condition += ' and ruhuid is not null'
905
+ }
906
+ // con += args.model.f_last_check_state ? ` and f_entry_status = '${args.model.f_last_check_state}'` : ''
907
+ con += args.model.f_checker_id ? ` and f_checker_name in ${args.model.f_checker_id}` : ''
908
+ let condition = {
909
+ condition1: args.condition,
910
+ condition2: con
911
+ }
912
+ //tag
913
+ this.searchData.condition = condition
914
+ return this.model.search(condition, args.model)
915
+ },
916
+ checkstatus() {
917
+ return this.$appdata.getParam('安检状态') ? [{
918
+ label: '全部',
919
+ value: ''
920
+ }, ...this.$appdata.getParam('安检状态')] : [{label: '全部', value: ''}]
921
+ },
922
+ usertypes() {
923
+ return this.$appdata.getParam('用户类型') ? [{
924
+ label: '全部',
925
+ value: ''
926
+ }, ...this.$appdata.getParam('用户类型')] : [{label: '全部', value: ''}]
927
+ },
928
+ userstates() {
929
+ return this.$appdata.getParam('用户状态') ? [{
930
+ label: '全部',
931
+ value: ''
932
+ }, ...this.$appdata.getParam('用户状态')] : [{label: '全部', value: ''}]
933
+ },
934
+ hiddenr() {
935
+ this.$parent.showItem = !this.$parent.showItem
936
+ },
937
+ hidden() {
938
+ this.criteriaShow = !this.criteriaShow
939
+ },
940
+ confirm() {
941
+ if (!this.checkboxModel.f_plan_name) {
942
+ this.$showMessage('请填写安检计划名称!')
943
+ return
944
+ }
945
+ // if(this.f_effective_start_time == ''){
946
+ // this.$showMessage('请选择有效起始日期!')
947
+ // return
948
+ // }
949
+ // if(this.f_effective_end_time == ''){
950
+ // this.$showMessage('请选择有效结束日期!')
951
+ // return
952
+ // }
953
+ if (this.IsShare == '否') {
954
+ if (!this.checkboxModel.f_checker_id) {
955
+ this.$showMessage('请选择安检员!')
956
+ return
957
+ }
958
+ }
959
+ let gen = saveGen(this)
960
+ return co(gen)
961
+ },
962
+ changeStates() {
963
+ if (this.checkedAll) {//实现反选/
964
+ this.checkrows = [];
965
+ for (let i = 0; i < this.$refs.paged.model.rows.length; i++) {
966
+ this.$set('$refs.paged.model.rows[' + i + '].checked', false)
967
+ }
968
+ } else {//实现全选
969
+ for (let i = 0; i < this.$refs.paged.model.rows.length; i++) {
970
+ this.$set('$refs.paged.model.rows[' + i + '].checked', true)
971
+ }
972
+ let _this = this
973
+ let condition = this.$refs.paged.$refs.criteria.condition
974
+ let url = this.model.url
975
+ this.$resetpost(`${url}?pageSize=9999999`, {
976
+ data: {
977
+ condition: condition,
978
+ groupitem: '',
979
+ orderitem: 'f_residential_area',
980
+ f_usertype: this.model.f_usertype,
981
+ f_filialeids: this.model.f_filialeids,
982
+ month: this.model.month,
983
+ safeCycle: this.model.safeCycle,
984
+ f_checktime_start: this.model.f_checktime_start,
985
+ f_checktime_end: this.model.f_checktime_end,
986
+ SafeCheckSX: this.model.SafeCheckSX,
987
+ f_last_check_state: this.model.f_last_check_state
988
+ },
989
+ }, {resolveMsg: null, rejectMsg: null}, -1).then(
990
+ (respanse) => {
991
+ if (respanse.data.length >= 5000) {
992
+ this.$showMessage("数据量太大,请重新选择")
993
+ } else {
994
+ _this.checkrows = []
995
+ for (let j = 0; j < respanse.data.length; j++) {
996
+ _this.checkrows.push(respanse.data[j])
997
+ }
998
+ //tag;
999
+ }
1000
+ })
1001
+ }
1002
+ },
1003
+ addChecked(item) {
1004
+ //tag;
1005
+ if (!item.checked) {
1006
+ this.checkrows.push(item);
1007
+ //tag;
1008
+ } else {
1009
+ for (let i = 0; i < this.checkrows.length; i++) {
1010
+ if (item.f_userinfo_id == this.checkrows[i].f_userinfo_id) {
1011
+ this.checkrows.splice(i, 1)
1012
+ }
1013
+ }
1014
+ }
1015
+ },
1016
+ ToshowModal() {
1017
+ this.creatPlanWay = 'single'
1018
+ if (this.checkrows.length > 0) {
1019
+ this.showModal = true
1020
+ } else {
1021
+ this.$showMessage("请选择需要安检的用户!")
1022
+ }
1023
+ },
1024
+ FiltrationPlan() {
1025
+ if (this.model.rows.length == 0) {
1026
+ this.$showMessage("暂无可生成的计划!")
1027
+ return
1028
+ }
1029
+ this.creatPlanWay = 'filtration'
1030
+ this.showModal = true
1031
+ },
1032
+ AllPlan() {
1033
+ if (this.model.rows.length == 0) {
1034
+ this.$showMessage("暂无可生成的计划!")
1035
+ return
1036
+ }
1037
+ this.creatPlanWay = 'all'
1038
+ this.showModal = true
1039
+ },
1040
+ cancel() {
1041
+ this.showModal = false
1042
+ },
1043
+ areas() {
1044
+ let rs = []
1045
+ for (let i = 0; i < this.$login.f.f_allArea.length; i++) {
1046
+ let temp = {
1047
+ label: this.$login.f.f_allArea[i].label,
1048
+ value: this.$login.f.f_allArea[i].label
1049
+ }
1050
+ rs.push(temp)
1051
+ }
1052
+ return [{label: '全部', value: ''}, ...rs]
1053
+ },
1054
+ initAdjustables() {
1055
+ //tag
1056
+ let arr = []
1057
+ let filter = this.$login.f.f_orgids
1058
+ this.$GetSaleParam.getAdjustable(filter).forEach((item) => {
1059
+ let temp = {}
1060
+ temp.label = `[${item.value.f_adjustable_id}]-${item.label}`
1061
+ temp.value = `${item.value.id}`
1062
+ arr.push(temp)
1063
+ })
1064
+ this.adjustables = [{label: '全部', value: ''}, ...arr]
1065
+ },
1066
+ getAllGasproperties(){
1067
+ this.gasproperties=[{
1068
+ label:'全部',
1069
+ value:''
1070
+ }]
1071
+ new HttpResetClass().load('POST',`/rs/sql/tel_singleTable_GroupBy`, {data: {
1072
+ items: 'f_gasproperties',
1073
+ tablename: 't_userfiles',
1074
+ condition: `1=1`,
1075
+ groupitem: 'f_gasproperties'
1076
+ }}, {resolveMsg: null, rejectMsg: null}).then((res) => {
1077
+ res.data.forEach(ress=>{
1078
+ this.gasproperties.push({
1079
+ label:ress.f_gasproperties,
1080
+ value:ress.f_gasproperties
1081
+ })
1082
+ })
1083
+ })
1084
+ },
1085
+ getAllOutlets(){
1086
+ this.userareas=[{
1087
+ label:'全部',
1088
+ value:''
1089
+ }]
1090
+ new HttpResetClass().load('POST',`/rs/sql/tel_singleTable_GroupBy`, {data: {
1091
+ items: 'f_outlets',
1092
+ tablename: 't_user_address',
1093
+ condition: `1=1`,
1094
+ groupitem: 'f_outlets'
1095
+ }}, {resolveMsg: null, rejectMsg: null}).then((res) => {
1096
+ res.data.forEach(ress=>{
1097
+ this.userareas.push({
1098
+ label:ress.f_outlets,
1099
+ value:ress.f_outlets
1100
+ })
1101
+ })
1102
+ })
1103
+ },
1104
+ getAllMeterBook(val){
1105
+ ////tag
1106
+ ////tag
1107
+ this.cbcs=[]
1108
+ if (val){
1109
+ new HttpResetClass().load('POST',`/rs/sql/tel_singleTable_OrderBy`, {data: {
1110
+ items: 'f_book_name,f_book_slice_area,id',
1111
+ tablename: 't_meter_book',
1112
+ condition: `f_filiale_id in ${val}`,
1113
+ orderitem: 'id'
1114
+ }}, {resolveMsg: null, rejectMsg: null}).then((res) => {
1115
+ res.data.forEach(ress=>{
1116
+ this.cbcs.push({
1117
+ id:ress.id,
1118
+ f_book_name:ress.f_book_name,
1119
+ f_book_slice_area:ress.f_book_slice_area
1120
+ })
1121
+ })
1122
+ this.cbc=[]
1123
+ this.cbc.push({
1124
+ label:'全部',
1125
+ value:''
1126
+ })
1127
+ this.cbcs.forEach(res=>{
1128
+ this.cbc.push({
1129
+ label:res.f_book_name,
1130
+ value:res.id
1131
+ })
1132
+ })
1133
+ })
1134
+ }
1135
+ },
1136
+ getRes(obj) {
1137
+ this.model.f_filialeids = this.$login.convertToIn(obj.resids);
1138
+ this.Mreadibook(this.model.f_filialeids)
1139
+ this.getAllMeterBook(this.model.f_filialeids)
1140
+ this.getPcd(this.model.f_filialeids)
1141
+ }
1142
+ },
1143
+
1144
+ watch: {
1145
+ 'model.f_usertype'(val) {
1146
+ if (val == '民用') {
1147
+ this.model.safeCycle = this.civil
1148
+ } else if (val == '非民用') {
1149
+ this.model.safeCycle = this.civilian
1150
+ }
1151
+ },
1152
+ 'model.SafeCheckXZ'(val) {
1153
+ this.model.SafeCheckSC = ''
1154
+ if (val == '已安检') {
1155
+ this.model.SafeCheckCQ = ''
1156
+ this.model.SafeCheckSX = {
1157
+ f_check_end: '', // 安检时间 查询起始条件
1158
+ f_check_start: ''// 安检时间 查询终止条件
1159
+ }
1160
+ } else {
1161
+ // 当使用筛选条件时,清空不需要的条件选项
1162
+ this.model.f_issue_start = ''
1163
+ this.model.f_issue_end = ''
1164
+ this.$refs.paged.$refs.criteria.model.f_check_start = ''
1165
+ this.$refs.paged.$refs.criteria.model.f_check_end = ''
1166
+ this.$refs.paged.$refs.criteria.model.f_last_check_state = ''
1167
+ this.model.month = ''
1168
+ if (val == '应安检') {
1169
+ this.model.SafeCheckSC = '否'
1170
+
1171
+ this.model.f_issue_start = Util.toStartDateString()
1172
+ this.model.f_issue_end = Util.toStandardDateString()
1173
+ }
1174
+ // this.model.f_checktime_start = ''
1175
+ // this.model.f_checktime_end = ''
1176
+ }
1177
+ },
1178
+ 'model.SafeCheckSC'(val) {
1179
+ if (val == '') {
1180
+ this.model.f_issue_start = ''
1181
+ this.model.f_issue_end = ''
1182
+ }
1183
+ },
1184
+ // 'checker'(val){
1185
+ // //tag
1186
+ // if(val){
1187
+ // this.checkboxModel.f_checker = this.checker[0].name
1188
+ // this.checkboxModel.f_checker_id = this.checker[0].id
1189
+ // }
1190
+ // },
1191
+ 'model.rows'() {
1192
+ // if (!this.checkedAll) {//实现反选/
1193
+ // this.checkrows = [];
1194
+ for (let i = 0; i < this.$refs.paged.model.rows.length; i++) {
1195
+ var k = false
1196
+ for (let j = 0; j < this.checkrows.length; j++) {
1197
+ if (this.$refs.paged.model.rows[i].f_userinfo_id == this.checkrows[j].f_userinfo_id) {
1198
+ this.$set('$refs.paged.model.rows[' + i + '].checked', true)
1199
+ k = true
1200
+ continue
1201
+ }
1202
+ }
1203
+ if (!k) {
1204
+ this.$set('$refs.paged.model.rows[' + i + '].checked', false)
1205
+ }
1206
+ }
1207
+ // } else {//实现全选
1208
+ // // this.checkboxModel = {};
1209
+ // for (let i = 0; i < this.$refs.paged.model.rows.length; i++) {
1210
+ // this.$set('$refs.paged.model.rows[' + i + '].checked', true)
1211
+ // }
1212
+ // }
1213
+ }
1214
+ },
1215
+ computed: {
1216
+ selected() {
1217
+ return this.$refs.paged.$refs.grid.selected
1218
+ }
1219
+ }
1220
+ }
1221
+ </script>
1222
+ <style scoped>
1223
+ .newcolor {
1224
+ color: red;
1225
+ }
1226
+
1227
+ .table th {
1228
+ background-color: #f2f6fa;
1229
+ color: black;
1230
+ }
1231
+ </style>