safecheck-client 3.0.33-5 → 3.0.33-51

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