safecheck-client 3.0.33-51 → 3.0.33-54
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.
- package/package.json +1 -1
- package/src/components/rongcheng/DefectPaper.vue +676 -676
- package/src/components/rongcheng/PhoneUpUserinfo.vue +1202 -1191
- package/src/components/rongcheng/SafecheckOrderV.vue +2524 -2524
@@ -1,676 +1,676 @@
|
|
1
|
-
<template>
|
2
|
-
<div>
|
3
|
-
<criteria-paged :model="model" v-ref:paged>
|
4
|
-
<criteria partial='criteria' class="search_area" @condition-changed='$parent.search' v-ref:criteria>
|
5
|
-
<div novalidate class="form-horizontal select-overspread container-fluid auto" partial>
|
6
|
-
<div class="row">
|
7
|
-
<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-2 form-group':!$parent.$parent.$parent.showItem}">
|
8
|
-
<label class="font_normal_body">安检计划</label>
|
9
|
-
<input type="text" class="input_search" v-model="$parent.$parent.f_check_plan.f_plan_name"
|
10
|
-
@click="$parent.$parent.showChooser"
|
11
|
-
style="width: 60%" placeholder="安检计划" readonly="readonly">
|
12
|
-
</div>
|
13
|
-
<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-2 form-group':!$parent.$parent.$parent.showItem}">
|
14
|
-
<label class="font_normal_body">存在隐患</label>
|
15
|
-
<v-select style="width:60% "
|
16
|
-
class="select select_list"
|
17
|
-
:value.sync="model.f_has_defect"
|
18
|
-
v-model="model.f_has_defect"
|
19
|
-
:options='$parent.$parent.hasDefectOptions'
|
20
|
-
:placeholder='model.f_has_defect'
|
21
|
-
condition="f_has_defect = '{}'"
|
22
|
-
close-on-select>
|
23
|
-
</v-select>
|
24
|
-
</div>
|
25
|
-
<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-2 form-group':!$parent.$parent.$parent.showItem}">
|
26
|
-
<label class="font_normal_body">用户类型</label>
|
27
|
-
<v-select style="width:60% "
|
28
|
-
class="select select_list"
|
29
|
-
:value.sync="model.f_check_type"
|
30
|
-
v-model="model.f_check_type"
|
31
|
-
:options='$parent.$parent.userTypes'
|
32
|
-
placeholder='用户类型'
|
33
|
-
condition="f_check_type = '{}'"
|
34
|
-
close-on-select>
|
35
|
-
</v-select>
|
36
|
-
</div>
|
37
|
-
<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-2 form-group':!$parent.$parent.$parent.showItem}">
|
38
|
-
<label class="font_normal_body">用户地址</label>
|
39
|
-
<input type="text" class="input_search" v-model="model.f_address" id="f_address" style="width:60%;"
|
40
|
-
placeholder="用户地址" condition="f_address like '%{}%'">
|
41
|
-
</div>
|
42
|
-
<div :class="{'col-sm-6':$parent.$parent.$parent.showItem,'col-sm-4':!$parent.$parent.$parent.showItem}" style="float: right;padding-bottom:5px">
|
43
|
-
<div class="span" style="float: right;margin-top: 8px">
|
44
|
-
<export-excel-safe :data="{condition: $parent.$parent.model.condition,f_filialeids:$parent.$parent.model.f_filialeids,f_defect_content:$parent.$parent.model.f_defect_content}"
|
45
|
-
:field="$parent.$parent.getfield"
|
46
|
-
sqlurl="rs/logic/SafeExportExcel" sql-name="GetCheckPaperByDefectToExcel" template-name='安检计划明细' :choose-col="true"></export-excel-safe>
|
47
|
-
<button class="button_search button_spacing" @click="$parent.$parent.showChooser1">转维修</button>
|
48
|
-
<button class="button_search button_spacing" @click="$parent.$parent.showChooser2">整改</button>
|
49
|
-
<button class="button_search button_spacing" @click="search">查询</button>
|
50
|
-
<div style="float: right" class="button_spacing"
|
51
|
-
:class="{'button_shrink_left':$parent.$parent.$parent.showItem,'button_shrink_right':!$parent.$parent.$parent.showItem}"
|
52
|
-
@click="$parent.$parent.hiddenr()"></div>
|
53
|
-
<div style="float: right" class="button_spacing"
|
54
|
-
:class="{'button_shrink_top':$parent.$parent.criteriaShow,'button_shrink_bottom':!$parent.$parent.criteriaShow}"
|
55
|
-
@click="$parent.$parent.hidden()"></div>
|
56
|
-
</div>
|
57
|
-
</div>
|
58
|
-
<!--<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-3':!$parent.$parent.$parent.showItem}" v-if="!$parent.$parent.$parent.showItem">
|
59
|
-
<label class="font_normal_body">用户名称</label>
|
60
|
-
<input type="text" class="input_search" v-model="model.f_user_name" id="f_user_name" style="width:60%;"
|
61
|
-
placeholder="用户名称" condition="f_user_name like '{}%'">
|
62
|
-
</div>-->
|
63
|
-
<!--<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-3':!$parent.$parent.$parent.showItem}" v-if="!$parent.$parent.$parent.showItem">
|
64
|
-
<label class="font_normal_body">起始时间</label>
|
65
|
-
<datepicker
|
66
|
-
placeholder='起始时间' style="width:60%"
|
67
|
-
:disabled-days-of-week="[]"
|
68
|
-
:format="'yyyy-MM-dd'"
|
69
|
-
:show-rest-button="reset"
|
70
|
-
:value.sync="model.f_start_time"
|
71
|
-
v-model="model.f_start_time"
|
72
|
-
condition="f_offsite_time >= '{} 00:00:00'">
|
73
|
-
</datepicker>
|
74
|
-
</div>-->
|
75
|
-
|
76
|
-
</div>
|
77
|
-
<!-- <div class="row">
|
78
|
-
<div :class="{'col-sm-7':$parent.$parent.$parent.showItem,'col-sm-7':!$parent.$parent.$parent.showItem}" style="float: right;padding-bottom:5px">
|
79
|
-
<div class="span" style="float: right;margin-top: 8px">
|
80
|
-
<export-excel-safe :data="{condition: $parent.$parent.model.condition,f_filialeids:$parent.$parent.model.f_filialeids}"
|
81
|
-
:field="$parent.$parent.getfield"
|
82
|
-
sqlurl="rs/logic/SafeExportExcel" sql-name="GetCheckPaperByDefectToExcel" template-name='安检计划明细' :choose-col="true"></export-excel-safe>
|
83
|
-
<button class="button_search button_spacing" @click="$parent.$parent.showChooser1">转维修</button>
|
84
|
-
<button class="button_search button_spacing" @click="$parent.$parent.showChooser2">整改</button>
|
85
|
-
<button class="button_search button_spacing" @click="search">查询</button>
|
86
|
-
<div style="float: right" class="button_spacing"
|
87
|
-
:class="{'button_shrink_left':$parent.$parent.$parent.showItem,'button_shrink_right':!$parent.$parent.$parent.showItem}"
|
88
|
-
@click="$parent.$parent.hiddenr()"></div>
|
89
|
-
<div style="float: right" class="button_spacing"
|
90
|
-
:class="{'button_shrink_top':$parent.$parent.criteriaShow,'button_shrink_bottom':!$parent.$parent.criteriaShow}"
|
91
|
-
@click="$parent.$parent.hidden()"></div>
|
92
|
-
</div>
|
93
|
-
</div>
|
94
|
-
</div>-->
|
95
|
-
<div class="row" v-if="$parent.$parent.criteriaShow">
|
96
|
-
<div :class="{'col-sm-6':$parent.$parent.$parent.showItem,'col-sm-4':!$parent.$parent.$parent.showItem}">
|
97
|
-
<role-selector-safe
|
98
|
-
:left-width="'60%'"
|
99
|
-
:right-width="'60%'"
|
100
|
-
role-name="安检员"
|
101
|
-
role-lable="安 检 员"
|
102
|
-
@re-res="$parent.$parent.getRes"
|
103
|
-
:value.sync="model.f_checker_id"
|
104
|
-
v-model="model.f_checker_id"
|
105
|
-
condition="f_checker_name = '{}'">
|
106
|
-
</role-selector-safe>
|
107
|
-
</div>
|
108
|
-
<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-2 form-group':!$parent.$parent.$parent.showItem}">
|
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_start_time"
|
116
|
-
v-model="model.f_start_time"
|
117
|
-
condition="f_offsite_time >= '{} 00:00:00'">
|
118
|
-
</datepicker>
|
119
|
-
</div>
|
120
|
-
<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-2 form-group':!$parent.$parent.$parent.showItem}">
|
121
|
-
<label class="font_normal_body">结束时间</label>
|
122
|
-
<datepicker
|
123
|
-
placeholder='结束时间' style="width:60%"
|
124
|
-
:disabled-days-of-week="[]"
|
125
|
-
:format="'yyyy-MM-dd'"
|
126
|
-
:show-rest-button="reset"
|
127
|
-
:value.sync="model.f_end_time"
|
128
|
-
v-model="model.f_end_time"
|
129
|
-
condition="f_offsite_time <= '{} 23:59:59'">
|
130
|
-
</datepicker>
|
131
|
-
</div>
|
132
|
-
<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-2 form-group':!$parent.$parent.$parent.showItem}">
|
133
|
-
<label class="font_normal_body">隐患级别</label>
|
134
|
-
<v-select style="width:60% "
|
135
|
-
class="select select_list"
|
136
|
-
:value.sync="$parent.$parent.defectLeave"
|
137
|
-
v-model="$parent.$parent.defectLeave"
|
138
|
-
:options='$parent.$parent.defectLeaveList'
|
139
|
-
placeholder='隐患级别'
|
140
|
-
condition="f_street = '{}'"
|
141
|
-
close-on-select>
|
142
|
-
</v-select>
|
143
|
-
</div>
|
144
|
-
<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-2 form-group':!$parent.$parent.$parent.showItem}">
|
145
|
-
<label class="font_normal_body">隐患类型</label>
|
146
|
-
<v-select style="width:60% "
|
147
|
-
class="select select_list"
|
148
|
-
:value.sync="$parent.$parent.defectType"
|
149
|
-
v-model="$parent.$parent.defectType"
|
150
|
-
:options='$parent.$parent.getdefectType'
|
151
|
-
placeholder='隐患类型'
|
152
|
-
condition="f_street = '{}'"
|
153
|
-
:multiple="true">
|
154
|
-
</v-select>
|
155
|
-
</div>
|
156
|
-
<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-2 form-group':!$parent.$parent.$parent.showItem}">
|
157
|
-
<label class="font_normal_body">所属区域</label>
|
158
|
-
<v-select style="width:60% "
|
159
|
-
class="select select_list"
|
160
|
-
:value.sync="model.f_street"
|
161
|
-
v-model="model.f_street"
|
162
|
-
:options='$parent.$parent.streets'
|
163
|
-
placeholder='所属区域'
|
164
|
-
condition="f_street = '{}'"
|
165
|
-
close-on-select>
|
166
|
-
</v-select>
|
167
|
-
</div>
|
168
|
-
<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-2 form-group':!$parent.$parent.$parent.showItem}">
|
169
|
-
<label class="font_normal_body">小 区 域</label>
|
170
|
-
<input type="text" class="input_search" v-model="model.f_small_area" id="f_small_area " style="width:60%;"
|
171
|
-
placeholder="小区域 " condition="f_small_area like '%{}%'">
|
172
|
-
</div>
|
173
|
-
<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-2 form-group':!$parent.$parent.$parent.showItem}">
|
174
|
-
<label class="font_normal_body">用户编号</label>
|
175
|
-
<input type="text" class="input_search" v-model="model.f_userinfo_code" id="f_userinfo_code" style="width:60%;"
|
176
|
-
placeholder="用户编号" condition="f_userinfo_code like '{}%'">
|
177
|
-
</div>
|
178
|
-
<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-2 form-group':!$parent.$parent.$parent.showItem}">
|
179
|
-
<label class="font_normal_body">用户名称</label>
|
180
|
-
<input type="text" class="input_search" v-model="model.f_user_name" id="f_user_name" style="width:60%;"
|
181
|
-
placeholder="用户名称" condition="f_user_name like '{}%'">
|
182
|
-
</div>
|
183
|
-
|
184
|
-
<!--<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-3':!$parent.$parent.$parent.showItem}">
|
185
|
-
<label class="font_normal_body">用户类型</label>
|
186
|
-
<v-select style="width:60% "
|
187
|
-
class="select select_list"
|
188
|
-
:value.sync="model.f_check_type"
|
189
|
-
v-model="model.f_check_type"
|
190
|
-
:options='$parent.$parent.userTypes'
|
191
|
-
placeholder='用户类型'
|
192
|
-
condition="f_check_type = '{}'"
|
193
|
-
close-on-select>
|
194
|
-
</v-select>
|
195
|
-
</div>-->
|
196
|
-
<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-2 form-group':!$parent.$parent.$parent.showItem}">
|
197
|
-
<label class="font_normal_body">维修情况</label>
|
198
|
-
<v-select style="width:60% "
|
199
|
-
class="select select_list"
|
200
|
-
:value.sync="model.f_repaired"
|
201
|
-
v-model="model.f_repaired"
|
202
|
-
:options='$parent.$parent.weixiuTypes'
|
203
|
-
placeholder='维修情况'
|
204
|
-
condition="{}"
|
205
|
-
close-on-select>
|
206
|
-
</v-select>
|
207
|
-
</div>
|
208
|
-
<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-2 form-group':!$parent.$parent.$parent.showItem}">
|
209
|
-
<label class="font_normal_body">整改情况</label>
|
210
|
-
<v-select style="width:60% "
|
211
|
-
class="select select_list"
|
212
|
-
:value.sync="model.f_rectificationed"
|
213
|
-
v-model="model.f_rectificationed"
|
214
|
-
:options='$parent.$parent.zhenggaicondition'
|
215
|
-
placeholder='整改情况'
|
216
|
-
condition="{}"
|
217
|
-
close-on-select>
|
218
|
-
</v-select>
|
219
|
-
</div>
|
220
|
-
|
221
|
-
|
222
|
-
</div>
|
223
|
-
</div>
|
224
|
-
</criteria>
|
225
|
-
<data-grid :model="model" partial='list' v-ref:grid class="list_area table_sy">
|
226
|
-
<template partial='head'>
|
227
|
-
<tr>
|
228
|
-
<th><nobr><input type="checkbox" v-model="$parent.$parent.$parent.checkAll"/> 全选</nobr></th>
|
229
|
-
<th><nobr>入户状态</nobr></th>
|
230
|
-
<th><nobr>用户名</nobr></th>
|
231
|
-
<th><nobr>用户地址</nobr></th>
|
232
|
-
<th><nobr>安检时间</nobr></th>
|
233
|
-
<th><nobr>安检员</nobr></th>
|
234
|
-
<th><nobr>隐患内容</nobr></th>
|
235
|
-
<th><nobr>是否有隐患</nobr></th>
|
236
|
-
<th><nobr>维修情况</nobr></th>
|
237
|
-
<th><nobr>整改情况</nobr></th>
|
238
|
-
<th><nobr>隐患数</nobr></th>
|
239
|
-
<th><nobr>一级隐患数</nobr></th>
|
240
|
-
<th><nobr>二级隐患数</nobr></th>
|
241
|
-
<th><nobr>三级隐患数</nobr></th>
|
242
|
-
<th><nobr>其他隐患数</nobr></th>
|
243
|
-
</tr>
|
244
|
-
</template>
|
245
|
-
<template partial='body'><!-- @checked="isChecked(row.id)" $parent.$parent.$parent.isChecked(row.id)-->
|
246
|
-
<td style="text-align: center;white-space:nowrap;"><input type="checkbox" onClick="event.cancelBubble = true" :checked="$parent.$parent.$parent.isChecked(row.id)" @change="$parent.$parent.$parent.setCheckes(row.id)" /></td>
|
247
|
-
<td style="text-align: center;white-space:nowrap;">{{row.f_entry_status}}</td>
|
248
|
-
<td style="text-align: center;white-space:nowrap;">{{row.f_user_name}}</td>
|
249
|
-
<td style="text-align: center;white-space:nowrap;">{{row.f_address}}</td>
|
250
|
-
<td style="text-align: center;white-space:nowrap;">{{row.f_offsite_time}}</td>
|
251
|
-
<td style="text-align: center;white-space:nowrap;">{{row.f_checker_name}}</td>
|
252
|
-
<td style="text-align: center;white-space:nowrap;">{{row.f_defect_content.substring(26).replaceAll('{','').replaceAll('}','').replaceAll(']','').replaceAll('"','')}}</td>
|
253
|
-
<td style="text-align: center;white-space:nowrap;">{{row.f_has_defect}}</td>
|
254
|
-
<td style="text-align: center;white-space:nowrap;">{{row.f_repaired}}</td>
|
255
|
-
<td style="text-align: center;white-space:nowrap;">{{row.f_rectificationed ? row.f_rectificationed : ( row.f_is_repair == '已处理' ? '整改完成' : '' )}}</td>
|
256
|
-
<td style="text-align: center;white-space:nowrap;">{{row.f_defect_count}}</td>
|
257
|
-
<td style="text-align: center;white-space:nowrap;">{{row.f_fist_count}}</td>
|
258
|
-
<td style="text-align: center;white-space:nowrap;">{{row.f_second_count}}</td>
|
259
|
-
<td style="text-align: center;white-space:nowrap;">{{row.f_third_count}}</td>
|
260
|
-
<td style="text-align: center;white-space:nowrap;">{{row.f_other_count}}</td>
|
261
|
-
</template>
|
262
|
-
<template partial="foot">
|
263
|
-
<td style="text-align: center"><span><b>合计:</b></span></td>
|
264
|
-
<td style="text-align: center"></td>
|
265
|
-
<td style="text-align: center"></td>
|
266
|
-
<td style="text-align: center"></td>
|
267
|
-
<td style="text-align: center"></td>
|
268
|
-
<td style="text-align: center"></td>
|
269
|
-
<td style="text-align: center"></td>
|
270
|
-
<td style="text-align: center"></td>
|
271
|
-
<td style="text-align: center"></td>
|
272
|
-
<td style="text-align: center"></td>
|
273
|
-
<td style="text-align: center">{{model.sums.f_defect_count}}</td>
|
274
|
-
<td style="text-align: center">{{model.sums.f_fist_count}}</td>
|
275
|
-
<td style="text-align: center">{{model.sums.f_second_count}}</td>
|
276
|
-
<td style="text-align: center">{{model.sums.f_third_count}}</td>
|
277
|
-
<td style="text-align: center">{{model.sums.f_other_count}}</td>
|
278
|
-
</template>
|
279
|
-
</data-grid>
|
280
|
-
</criteria-paged>
|
281
|
-
|
282
|
-
<modal :show.sync="showModal" v-ref:modal>
|
283
|
-
<div slot="modal-header" class="modal-header">
|
284
|
-
<h4 class="modal-title">
|
285
|
-
选择计划
|
286
|
-
</h4>
|
287
|
-
</div>
|
288
|
-
<div slot="modal-body" class="modal-body">
|
289
|
-
<plan-chooser :f.sync="this.$login.f" v-ref:chooser></plan-chooser>
|
290
|
-
</div>
|
291
|
-
<div slot="modal-footer" class="modal-footer" style="text-align: center">
|
292
|
-
<button class="button_search" @click="ok">确认</button>
|
293
|
-
<button class="button_search" @click="cancel">取消</button>
|
294
|
-
</div>
|
295
|
-
</modal>
|
296
|
-
<modal :show.sync="showModal1" >
|
297
|
-
<div slot="modal-header" class="modal-header">
|
298
|
-
<h4 class="modal-title">
|
299
|
-
转维修
|
300
|
-
</h4>
|
301
|
-
</div>
|
302
|
-
<div slot="modal-body" class="modal-body">
|
303
|
-
<div v-if="true">
|
304
|
-
|
305
|
-
<div class="row" style="margin-top: 10px">
|
306
|
-
<label for="f_repair" class="control-label font text-left" style="float:left;margin-left:20%;margin-top:5px">故障类型</label>
|
307
|
-
<div class="col-xs-8 col-md-8">
|
308
|
-
<v-select :value.sync="faultCategory" :value-single="true" v-model="faultCategory"
|
309
|
-
:options='faultCategoryOption' placeholder='故障类型'
|
310
|
-
close-on-select>
|
311
|
-
</v-select>
|
312
|
-
</div>
|
313
|
-
</div>
|
314
|
-
<div class="row" style="margin-top: 10px">
|
315
|
-
<label for="f_repair" class="control-label font text-left" style="float:left;margin-left:20%;margin-top:5px">处理级别</label>
|
316
|
-
<div class="col-xs-8 col-md-8">
|
317
|
-
<v-select :value.sync="processingLevel" :value-single="true" v-model="processingLevel"
|
318
|
-
:options='processingLevelOption' placeholder='处理级别'
|
319
|
-
close-on-select>
|
320
|
-
</v-select>
|
321
|
-
</div>
|
322
|
-
</div>
|
323
|
-
|
324
|
-
<div class="row" style="margin-top: 10px">
|
325
|
-
<label class="control-label font text-left" style="float:left;margin-left:20%;margin-top:5px">备 注</label>
|
326
|
-
<div class="col-xs-8 col-md-8">
|
327
|
-
<textarea style="width: 60%; height: 100px" v-model="remarks"></textarea>
|
328
|
-
</div>
|
329
|
-
|
330
|
-
</div>
|
331
|
-
|
332
|
-
</div>
|
333
|
-
</div>
|
334
|
-
<div slot="modal-footer" class="modal-footer" style="text-align: center">
|
335
|
-
<button class="button_search" @click="ok1">确认</button>
|
336
|
-
<button class="button_search" @click="cancel1">取消</button>
|
337
|
-
</div>
|
338
|
-
</modal>
|
339
|
-
<modal :show.sync="showModal2">
|
340
|
-
<div slot="modal-header" class="modal-header">
|
341
|
-
<h4 class="modal-title">
|
342
|
-
隐患整改派发
|
343
|
-
</h4>
|
344
|
-
</div>
|
345
|
-
<div slot="modal-body" class="modal-body">
|
346
|
-
<div v-if="true">
|
347
|
-
<div class="row" style="margin-top: 10px">
|
348
|
-
<label class="control-label font text-left" style="float:left;margin-left:20%;margin-top:5px">整改人员</label>
|
349
|
-
<div class="col-xs-8 col-md-8">
|
350
|
-
<v-select :value.sync="rectify" :value-single="true" v-model="rectify"
|
351
|
-
:options='rectifys' placeholder='隐患整改员'
|
352
|
-
close-on-select>
|
353
|
-
</v-select>
|
354
|
-
</div>
|
355
|
-
</div>
|
356
|
-
<div class="row" style="margin-top: 10px">
|
357
|
-
<label class="control-label font text-left" style="float:left;margin-left:20%;margin-top:5px">当前部门</label>
|
358
|
-
<div class="col-xs-8 col-md-8">
|
359
|
-
<input type="text" class="input_search" style="width: 60%;" v-model="department" disabled/>
|
360
|
-
</div>
|
361
|
-
</div>
|
362
|
-
<div class="row" style="margin-top: 10px">
|
363
|
-
<label class="control-label font text-left" style="float:left;margin-left:20%;margin-top:5px">备 注</label>
|
364
|
-
<div class="col-xs-8 col-md-8">
|
365
|
-
<textarea style="width: 60%; height: 100px" v-model="cremarks"></textarea>
|
366
|
-
</div>
|
367
|
-
</div>
|
368
|
-
</div>
|
369
|
-
</div>
|
370
|
-
<div slot="modal-footer" class="modal-footer" style="text-align: center">
|
371
|
-
<button class="button_search" @click="rectification">确认</button>
|
372
|
-
<button class="button_search" @click="cancel1">取消</button>
|
373
|
-
</div>
|
374
|
-
</modal>
|
375
|
-
</div>
|
376
|
-
</template>
|
377
|
-
<script>
|
378
|
-
import {PagedList} from 'vue-client'
|
379
|
-
import HttpResetClass from "vue-client/src/plugins/HttpResetClass";
|
380
|
-
import * as Util from '../Util'
|
381
|
-
import {toStartDateString} from '../Util'
|
382
|
-
|
383
|
-
export default {
|
384
|
-
title: '隐患查询',
|
385
|
-
data() {
|
386
|
-
let model = new PagedList('rs/sql/GetCheckPaperByDefect', 20, {
|
387
|
-
f_filialeids: 'this.f_filialeids',f_defect_content: 'this.f_defect_content'
|
388
|
-
},{f_defect_count: '', f_fist_count: '', f_second_count: '',f_third_count: '',f_other_count:''})
|
389
|
-
model.f_filialeids = '(' + this.$login.f.orgid + ')'
|
390
|
-
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"
|
391
|
-
return {
|
392
|
-
hasDefectOptions: [{label: '全部', value: ''}, {label: '有隐患', value: '有隐患'}, {label: '无隐患', value: '无隐患'}],
|
393
|
-
f: this.$login.f,
|
394
|
-
model: model,
|
395
|
-
criteriaShow: false,
|
396
|
-
showModal: false,
|
397
|
-
showModal1:false,
|
398
|
-
showModal2:false,
|
399
|
-
f_check_plan: {f_plan_name: '', id: ''},
|
400
|
-
sumsmodel: {},
|
401
|
-
all: false,
|
402
|
-
fields: {},
|
403
|
-
streets:[],
|
404
|
-
zhenggaicondition:[{label:'全部',value:''},{label: '已派整改单', value: 'f_rectificationed=\'已派整改单\''}, {label: '整改完成', value: 'f_rectificationed=\'整改完成\''}, {label: '未派整改单', value: 'f_rectificationed is null'}],
|
405
|
-
weixiuTypes:[{label:'全部',value:''},{label: '已派维修单', value: 'f_repaired=\'已派维修单\''}, {label: '维修完成', value: 'f_repaired=\'维修完成\''}, {label: '未派发维修', value: 'f_repaired is null'}],
|
406
|
-
modelval: [],
|
407
|
-
defectType:[],
|
408
|
-
userTypes:[{label: '民用', value: '民用'}, {label: '非民用', value: '非民用'}],
|
409
|
-
defectLeave:'',
|
410
|
-
defectLeaveList:[{label:'全部',value:''},{label:'一级隐患',value:'一级隐患'},{label:'二级隐患',value:'二级隐患'},{label:'三级隐患',value:'三级隐患'},{label: '其他隐患'}],
|
411
|
-
thead: '',
|
412
|
-
headData: ['入户状态','用户名','用户电话','用户地址','安检时间','安检员','计划名','是否有隐患','隐患数','一级隐患数','一级隐患','二级隐患数','二级隐患','三级隐患数','三级隐患','其他隐患','隐患内容'],
|
413
|
-
bodyData: ['f_entry_status','f_user_name','f_user_phone','f_address','f_offsite_time','f_checker_name','f_plan_name','f_has_defect','f_defect_count','f_fist_count','f_fist_content','f_second_count','f_second_content','f_third_count','f_third_content','f_other_count','f_defect_content'],
|
414
|
-
checkAll:false,
|
415
|
-
checkes:[],
|
416
|
-
faultCategory:'安检隐患',
|
417
|
-
processingLevel:"普通",
|
418
|
-
department:this.$login.f.f_department_name,
|
419
|
-
dep:[],
|
420
|
-
faultCategoryOption:[{label: '民用', value: '民用'}, {label: '工商', value: '工商'}],
|
421
|
-
processingLevelOption:[{label: '普通', value: '普通'}, {label: '加急', value: '加急'}, {label: '紧急', value: '紧急'}],
|
422
|
-
remarks:"",
|
423
|
-
cremarks:"",
|
424
|
-
rectifys:[],
|
425
|
-
rectify:''
|
426
|
-
|
427
|
-
}
|
428
|
-
},
|
429
|
-
methods: {
|
430
|
-
isChecked(v) {
|
431
|
-
// 如果全选,不在的按选中算,否则,在的按选中算
|
432
|
-
if (this.checkAll) {
|
433
|
-
return this.checkes.indexOf(v) == -1
|
434
|
-
} else {
|
435
|
-
return this.checkes.indexOf(v) != -1
|
436
|
-
}
|
437
|
-
},
|
438
|
-
setCheckAll() {
|
439
|
-
this.checkAll=this.checkAll?false:true;
|
440
|
-
// 全选改变后,清空选中数据
|
441
|
-
this.checkes = []
|
442
|
-
},
|
443
|
-
setCheckes(id) {
|
444
|
-
let index=this.checkes.indexOf(id)
|
445
|
-
if(index<0){
|
446
|
-
this.checkes.push(id)
|
447
|
-
}else{
|
448
|
-
this.checkes.splice(index,1)
|
449
|
-
}
|
450
|
-
},
|
451
|
-
hiddenr() {
|
452
|
-
this.$parent.showItem = !this.$parent.showItem
|
453
|
-
},
|
454
|
-
hidden() {
|
455
|
-
this.criteriaShow = !this.criteriaShow
|
456
|
-
},
|
457
|
-
search(args) {
|
458
|
-
if (this.f_check_plan.f_plan_name) {
|
459
|
-
args.condition += ` and f_check_plan_id = '${this.f_check_plan.id}'`
|
460
|
-
}
|
461
|
-
if(this.defectLeave){
|
462
|
-
if(this.defectLeave=='一级隐患'){
|
463
|
-
args.condition += ` and f_fist_count > 0`
|
464
|
-
}
|
465
|
-
if(this.defectLeave=='二级隐患'){
|
466
|
-
args.condition += ` and f_second_count > 0`
|
467
|
-
}
|
468
|
-
if(this.defectLeave=='三级隐患'){
|
469
|
-
args.condition += ` and f_third_count > 0`
|
470
|
-
}
|
471
|
-
if(this.defectLeave=='其他隐患'){
|
472
|
-
args.condition += ` and f_other_count > 0`
|
473
|
-
}
|
474
|
-
}
|
475
|
-
if(this.defectType.length>0){
|
476
|
-
args.condition += ` and (`
|
477
|
-
for(let sqlstr=0;sqlstr<this.defectType.length;sqlstr++){
|
478
|
-
//tag
|
479
|
-
//tag
|
480
|
-
args.condition += ` f_defect_content like '%${this.defectType[sqlstr]}%'`
|
481
|
-
if(sqlstr<this.defectType.length-1){
|
482
|
-
args.condition +=' or'
|
483
|
-
}
|
484
|
-
}
|
485
|
-
args.condition += ` )`
|
486
|
-
}
|
487
|
-
/*if(this.defectType.length>0){
|
488
|
-
for(let sqlstr in this.defectType){
|
489
|
-
args.condition += ` and f_defect_content like '%${this.defectType[sqlstr]}%'`
|
490
|
-
}
|
491
|
-
}*/
|
492
|
-
this.model.search(args.condition, args.model)
|
493
|
-
this.checkAll=false;
|
494
|
-
// 全选改变后,清空选中数据
|
495
|
-
this.checkes = []
|
496
|
-
//tag)
|
497
|
-
//tag)
|
498
|
-
},
|
499
|
-
getRes(obj) {
|
500
|
-
this.model.f_filialeids = this.$login.convertToIn(obj.resids);
|
501
|
-
//tag
|
502
|
-
},
|
503
|
-
showChooser() {
|
504
|
-
this.showModal = true
|
505
|
-
},
|
506
|
-
showChooser1() {
|
507
|
-
this.showModal1 = true
|
508
|
-
},
|
509
|
-
showChooser2() {
|
510
|
-
this.showModal2 = true
|
511
|
-
},
|
512
|
-
getYHZG(){
|
513
|
-
new HttpResetClass().load('POST', '/rs/search', {
|
514
|
-
source: 'this.getParentByType($department$).getAllChildrens().where(row.getAttributes().get($rolestr$).indexOf($整改人员$) != -1))',
|
515
|
-
userid: this.$login.f.id
|
516
|
-
}, {resolveMsg: null, rejectMsg: null}).then((res)=>{
|
517
|
-
//tag+"---id")
|
518
|
-
res.data.forEach((resRow)=>{
|
519
|
-
this.rectifys.push({label:resRow.name,value:resRow.name})
|
520
|
-
})
|
521
|
-
|
522
|
-
})
|
523
|
-
|
524
|
-
},
|
525
|
-
//进行整改
|
526
|
-
rectification(){
|
527
|
-
|
528
|
-
this.$showMessage('确定要整改当前选中用户吗?!', ['confirm', 'cancel']).then((msg)=>{
|
529
|
-
if(msg=='confirm'){
|
530
|
-
if (this.checkAll || this.checkes.length>0) {
|
531
|
-
this.$resetpost(`/rs/logic/UploadRectification`,
|
532
|
-
{
|
533
|
-
condition:this.model.params.condition,
|
534
|
-
f_filialeids:this.model.params.f_filialeids,
|
535
|
-
switchCheckAll:true,
|
536
|
-
checkAll:this.checkAll,
|
537
|
-
param:this.checkes,
|
538
|
-
columnName:'id',
|
539
|
-
processingLevel:this.processingLevel,
|
540
|
-
faultCategory:this.faultCategory,
|
541
|
-
remarks:this.cremarks,
|
542
|
-
deps:this.$login.f.deps,
|
543
|
-
f_attendant: this.$login.f.name,
|
544
|
-
loginUser:{name:this.$login.f.name,ename:this.$login.f.ename},
|
545
|
-
repairman:this.rectify
|
546
|
-
},{resolveMsg: null, rejectMsg: null}).then((res) => {
|
547
|
-
if(res.data.code=200){
|
548
|
-
this.$showMessage('本次成功派发'+res.data.successcon+'个整改单!'+`其中${res.data.nohidden}个不需要隐患整改,${res.data.repeatCount}个已经派发过隐患整改单`)
|
549
|
-
this.checkAll=false;
|
550
|
-
// 全选改变后,清空选中数据
|
551
|
-
this.checkes = []
|
552
|
-
}
|
553
|
-
})
|
554
|
-
}else{
|
555
|
-
this.$showMessage("请勾选用户后进行整改!")
|
556
|
-
}
|
557
|
-
}
|
558
|
-
})
|
559
|
-
},
|
560
|
-
ok() {
|
561
|
-
//tag)
|
562
|
-
this.showModal = false
|
563
|
-
if (this.$refs.modal.$children[0].selectedRow.id) {
|
564
|
-
this.f_check_plan = this.$refs.modal.$children[0].selectedRow
|
565
|
-
}
|
566
|
-
},
|
567
|
-
cancel() {
|
568
|
-
this.showModal = false
|
569
|
-
this.f_check_plan = {f_plan_name: '', id: ''}
|
570
|
-
},
|
571
|
-
ok1() {
|
572
|
-
if (this.checkAll || this.checkes.length>0) {
|
573
|
-
this.$resetpost(`/rs/logic/SafeToRepair`,
|
574
|
-
{
|
575
|
-
condition:this.model.params.condition,
|
576
|
-
f_filialeids:this.model.params.f_filialeids,
|
577
|
-
switchCheckAll:true,
|
578
|
-
checkAll:this.checkAll,
|
579
|
-
param:this.checkes,
|
580
|
-
columnName:'id',
|
581
|
-
processingLevel:this.processingLevel,
|
582
|
-
faultCategory:this.faultCategory,
|
583
|
-
remarks:this.remarks
|
584
|
-
},{resolveMsg: null, rejectMsg: null}).then((res) => {
|
585
|
-
if(res.data.code=200){
|
586
|
-
this.$showMessage("本次成功派发"+res.data.successcon+"个维修单!"+`其中${res.data.nohidden}个不需要维修,${res.data.repeatCount}个已经派发过维修`)
|
587
|
-
this.checkAll=val;
|
588
|
-
// 全选改变后,清空选中数据
|
589
|
-
this.checkes = []
|
590
|
-
}
|
591
|
-
})
|
592
|
-
}else{
|
593
|
-
this.$showMessage("请勾选隐患进行转维修!")
|
594
|
-
}
|
595
|
-
this.showModal1 = false
|
596
|
-
},
|
597
|
-
cancel1() {
|
598
|
-
this.showModal1 = false
|
599
|
-
this.showModal2 = false
|
600
|
-
},
|
601
|
-
async initstreets(){
|
602
|
-
this.streetslist = []
|
603
|
-
let HttpReset = new HttpResetClass()
|
604
|
-
let req = await HttpReset.load('POST', 'rs/sql/address_singleTableOrderBy', {
|
605
|
-
data: {
|
606
|
-
items: '*',
|
607
|
-
tablename: 't_street',
|
608
|
-
orderitem: 'id',
|
609
|
-
condition: `f_orgid = '${this.$login.f.orgid}'`
|
610
|
-
}
|
611
|
-
}, {resolveMsg: null, rejectMsg: '获取地址失败!'})
|
612
|
-
let redata = []
|
613
|
-
req.data.forEach((row, n) => {
|
614
|
-
redata[n] = {
|
615
|
-
label: row.f_street,
|
616
|
-
value: row.f_street,
|
617
|
-
data:row,
|
618
|
-
id:row.id
|
619
|
-
}
|
620
|
-
})
|
621
|
-
this.streets=redata
|
622
|
-
}
|
623
|
-
},
|
624
|
-
ready() {
|
625
|
-
//tag)
|
626
|
-
this.$refs.paged.$refs.criteria.model.f_has_defect = '有隐患'
|
627
|
-
this.$refs.paged.$refs.criteria.model.f_start_time = Util.toStartDateString()
|
628
|
-
this.initstreets()
|
629
|
-
this.getYHZG()
|
630
|
-
},
|
631
|
-
watch:{
|
632
|
-
'checkAll'(val){
|
633
|
-
this.checkAll=val;
|
634
|
-
// 全选改变后,清空选中数据
|
635
|
-
this.checkes = []
|
636
|
-
},
|
637
|
-
'model.rows.length'() {
|
638
|
-
//tag
|
639
|
-
// 如果查询无结果,将合计置为0
|
640
|
-
if(this.model.rows.length < 1){
|
641
|
-
this.model.sums.f_defect_count = 0
|
642
|
-
this.model.sums.f_fist_count = 0
|
643
|
-
this.model.sums.f_second_count = 0
|
644
|
-
this.model.sums.f_third_count = 0
|
645
|
-
}
|
646
|
-
}
|
647
|
-
},
|
648
|
-
computed: {
|
649
|
-
getdefectType(){
|
650
|
-
this.defectType=[]
|
651
|
-
return [... this.$appdata.getParam(this.defectLeave)]
|
652
|
-
},
|
653
|
-
selected() {
|
654
|
-
return this.$refs.paged.$refs.grid.selected
|
655
|
-
},
|
656
|
-
getfield(){
|
657
|
-
//tag
|
658
|
-
let data = {}
|
659
|
-
this.bodyData.forEach((value, index)=>{
|
660
|
-
data[this.bodyData[index]] = this.headData[index]
|
661
|
-
})
|
662
|
-
//合计字段打印
|
663
|
-
this.tfoot = `<tr><th colspan=${this.modelval.length}>全表汇总信息: `
|
664
|
-
if(this.sumsmodel){
|
665
|
-
Object.keys(this.sumsmodel).forEach((key) => {
|
666
|
-
this.tfoot += this.fields[key] + '合计: ' + `<font color="blue">${this.sumsmodel[key]} </font>`
|
667
|
-
})
|
668
|
-
}else{
|
669
|
-
this.tfoot += '暂无'
|
670
|
-
}
|
671
|
-
this.tfoot += '</th></tr>'
|
672
|
-
return data
|
673
|
-
}
|
674
|
-
}
|
675
|
-
}
|
676
|
-
</script>
|
1
|
+
<template>
|
2
|
+
<div>
|
3
|
+
<criteria-paged :model="model" v-ref:paged>
|
4
|
+
<criteria partial='criteria' class="search_area" @condition-changed='$parent.search' v-ref:criteria>
|
5
|
+
<div novalidate class="form-horizontal select-overspread container-fluid auto" partial>
|
6
|
+
<div class="row">
|
7
|
+
<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-2 form-group':!$parent.$parent.$parent.showItem}">
|
8
|
+
<label class="font_normal_body">安检计划</label>
|
9
|
+
<input type="text" class="input_search" v-model="$parent.$parent.f_check_plan.f_plan_name"
|
10
|
+
@click="$parent.$parent.showChooser"
|
11
|
+
style="width: 60%" placeholder="安检计划" readonly="readonly">
|
12
|
+
</div>
|
13
|
+
<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-2 form-group':!$parent.$parent.$parent.showItem}">
|
14
|
+
<label class="font_normal_body">存在隐患</label>
|
15
|
+
<v-select style="width:60% "
|
16
|
+
class="select select_list"
|
17
|
+
:value.sync="model.f_has_defect"
|
18
|
+
v-model="model.f_has_defect"
|
19
|
+
:options='$parent.$parent.hasDefectOptions'
|
20
|
+
:placeholder='model.f_has_defect'
|
21
|
+
condition="f_has_defect = '{}'"
|
22
|
+
close-on-select>
|
23
|
+
</v-select>
|
24
|
+
</div>
|
25
|
+
<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-2 form-group':!$parent.$parent.$parent.showItem}">
|
26
|
+
<label class="font_normal_body">用户类型</label>
|
27
|
+
<v-select style="width:60% "
|
28
|
+
class="select select_list"
|
29
|
+
:value.sync="model.f_check_type"
|
30
|
+
v-model="model.f_check_type"
|
31
|
+
:options='$parent.$parent.userTypes'
|
32
|
+
placeholder='用户类型'
|
33
|
+
condition="f_check_type = '{}'"
|
34
|
+
close-on-select>
|
35
|
+
</v-select>
|
36
|
+
</div>
|
37
|
+
<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-2 form-group':!$parent.$parent.$parent.showItem}">
|
38
|
+
<label class="font_normal_body">用户地址</label>
|
39
|
+
<input type="text" class="input_search" v-model="model.f_address" id="f_address" style="width:60%;"
|
40
|
+
placeholder="用户地址" condition="f_address like '%{}%'">
|
41
|
+
</div>
|
42
|
+
<div :class="{'col-sm-6':$parent.$parent.$parent.showItem,'col-sm-4':!$parent.$parent.$parent.showItem}" style="float: right;padding-bottom:5px">
|
43
|
+
<div class="span" style="float: right;margin-top: 8px">
|
44
|
+
<export-excel-safe :data="{condition: $parent.$parent.model.condition,f_filialeids:$parent.$parent.model.f_filialeids,f_defect_content:$parent.$parent.model.f_defect_content}"
|
45
|
+
:field="$parent.$parent.getfield"
|
46
|
+
sqlurl="rs/logic/SafeExportExcel" sql-name="GetCheckPaperByDefectToExcel" template-name='安检计划明细' :choose-col="true"></export-excel-safe>
|
47
|
+
<button class="button_search button_spacing" @click="$parent.$parent.showChooser1">转维修</button>
|
48
|
+
<button class="button_search button_spacing" @click="$parent.$parent.showChooser2">整改</button>
|
49
|
+
<button class="button_search button_spacing" @click="search">查询</button>
|
50
|
+
<div style="float: right" class="button_spacing"
|
51
|
+
:class="{'button_shrink_left':$parent.$parent.$parent.showItem,'button_shrink_right':!$parent.$parent.$parent.showItem}"
|
52
|
+
@click="$parent.$parent.hiddenr()"></div>
|
53
|
+
<div style="float: right" class="button_spacing"
|
54
|
+
:class="{'button_shrink_top':$parent.$parent.criteriaShow,'button_shrink_bottom':!$parent.$parent.criteriaShow}"
|
55
|
+
@click="$parent.$parent.hidden()"></div>
|
56
|
+
</div>
|
57
|
+
</div>
|
58
|
+
<!--<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-3':!$parent.$parent.$parent.showItem}" v-if="!$parent.$parent.$parent.showItem">
|
59
|
+
<label class="font_normal_body">用户名称</label>
|
60
|
+
<input type="text" class="input_search" v-model="model.f_user_name" id="f_user_name" style="width:60%;"
|
61
|
+
placeholder="用户名称" condition="f_user_name like '{}%'">
|
62
|
+
</div>-->
|
63
|
+
<!--<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-3':!$parent.$parent.$parent.showItem}" v-if="!$parent.$parent.$parent.showItem">
|
64
|
+
<label class="font_normal_body">起始时间</label>
|
65
|
+
<datepicker
|
66
|
+
placeholder='起始时间' style="width:60%"
|
67
|
+
:disabled-days-of-week="[]"
|
68
|
+
:format="'yyyy-MM-dd'"
|
69
|
+
:show-rest-button="reset"
|
70
|
+
:value.sync="model.f_start_time"
|
71
|
+
v-model="model.f_start_time"
|
72
|
+
condition="f_offsite_time >= '{} 00:00:00'">
|
73
|
+
</datepicker>
|
74
|
+
</div>-->
|
75
|
+
|
76
|
+
</div>
|
77
|
+
<!-- <div class="row">
|
78
|
+
<div :class="{'col-sm-7':$parent.$parent.$parent.showItem,'col-sm-7':!$parent.$parent.$parent.showItem}" style="float: right;padding-bottom:5px">
|
79
|
+
<div class="span" style="float: right;margin-top: 8px">
|
80
|
+
<export-excel-safe :data="{condition: $parent.$parent.model.condition,f_filialeids:$parent.$parent.model.f_filialeids}"
|
81
|
+
:field="$parent.$parent.getfield"
|
82
|
+
sqlurl="rs/logic/SafeExportExcel" sql-name="GetCheckPaperByDefectToExcel" template-name='安检计划明细' :choose-col="true"></export-excel-safe>
|
83
|
+
<button class="button_search button_spacing" @click="$parent.$parent.showChooser1">转维修</button>
|
84
|
+
<button class="button_search button_spacing" @click="$parent.$parent.showChooser2">整改</button>
|
85
|
+
<button class="button_search button_spacing" @click="search">查询</button>
|
86
|
+
<div style="float: right" class="button_spacing"
|
87
|
+
:class="{'button_shrink_left':$parent.$parent.$parent.showItem,'button_shrink_right':!$parent.$parent.$parent.showItem}"
|
88
|
+
@click="$parent.$parent.hiddenr()"></div>
|
89
|
+
<div style="float: right" class="button_spacing"
|
90
|
+
:class="{'button_shrink_top':$parent.$parent.criteriaShow,'button_shrink_bottom':!$parent.$parent.criteriaShow}"
|
91
|
+
@click="$parent.$parent.hidden()"></div>
|
92
|
+
</div>
|
93
|
+
</div>
|
94
|
+
</div>-->
|
95
|
+
<div class="row" v-if="$parent.$parent.criteriaShow">
|
96
|
+
<div :class="{'col-sm-6':$parent.$parent.$parent.showItem,'col-sm-4':!$parent.$parent.$parent.showItem}">
|
97
|
+
<role-selector-safe
|
98
|
+
:left-width="'60%'"
|
99
|
+
:right-width="'60%'"
|
100
|
+
role-name="安检员"
|
101
|
+
role-lable="安 检 员"
|
102
|
+
@re-res="$parent.$parent.getRes"
|
103
|
+
:value.sync="model.f_checker_id"
|
104
|
+
v-model="model.f_checker_id"
|
105
|
+
condition="f_checker_name = '{}'">
|
106
|
+
</role-selector-safe>
|
107
|
+
</div>
|
108
|
+
<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-2 form-group':!$parent.$parent.$parent.showItem}">
|
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_start_time"
|
116
|
+
v-model="model.f_start_time"
|
117
|
+
condition="f_offsite_time >= '{} 00:00:00'">
|
118
|
+
</datepicker>
|
119
|
+
</div>
|
120
|
+
<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-2 form-group':!$parent.$parent.$parent.showItem}">
|
121
|
+
<label class="font_normal_body">结束时间</label>
|
122
|
+
<datepicker
|
123
|
+
placeholder='结束时间' style="width:60%"
|
124
|
+
:disabled-days-of-week="[]"
|
125
|
+
:format="'yyyy-MM-dd'"
|
126
|
+
:show-rest-button="reset"
|
127
|
+
:value.sync="model.f_end_time"
|
128
|
+
v-model="model.f_end_time"
|
129
|
+
condition="f_offsite_time <= '{} 23:59:59'">
|
130
|
+
</datepicker>
|
131
|
+
</div>
|
132
|
+
<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-2 form-group':!$parent.$parent.$parent.showItem}">
|
133
|
+
<label class="font_normal_body">隐患级别</label>
|
134
|
+
<v-select style="width:60% "
|
135
|
+
class="select select_list"
|
136
|
+
:value.sync="$parent.$parent.defectLeave"
|
137
|
+
v-model="$parent.$parent.defectLeave"
|
138
|
+
:options='$parent.$parent.defectLeaveList'
|
139
|
+
placeholder='隐患级别'
|
140
|
+
condition="f_street = '{}'"
|
141
|
+
close-on-select>
|
142
|
+
</v-select>
|
143
|
+
</div>
|
144
|
+
<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-2 form-group':!$parent.$parent.$parent.showItem}">
|
145
|
+
<label class="font_normal_body">隐患类型</label>
|
146
|
+
<v-select style="width:60% "
|
147
|
+
class="select select_list"
|
148
|
+
:value.sync="$parent.$parent.defectType"
|
149
|
+
v-model="$parent.$parent.defectType"
|
150
|
+
:options='$parent.$parent.getdefectType'
|
151
|
+
placeholder='隐患类型'
|
152
|
+
condition="f_street = '{}'"
|
153
|
+
:multiple="true">
|
154
|
+
</v-select>
|
155
|
+
</div>
|
156
|
+
<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-2 form-group':!$parent.$parent.$parent.showItem}">
|
157
|
+
<label class="font_normal_body">所属区域</label>
|
158
|
+
<v-select style="width:60% "
|
159
|
+
class="select select_list"
|
160
|
+
:value.sync="model.f_street"
|
161
|
+
v-model="model.f_street"
|
162
|
+
:options='$parent.$parent.streets'
|
163
|
+
placeholder='所属区域'
|
164
|
+
condition="f_street = '{}'"
|
165
|
+
close-on-select>
|
166
|
+
</v-select>
|
167
|
+
</div>
|
168
|
+
<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-2 form-group':!$parent.$parent.$parent.showItem}">
|
169
|
+
<label class="font_normal_body">小 区 域</label>
|
170
|
+
<input type="text" class="input_search" v-model="model.f_small_area" id="f_small_area " style="width:60%;"
|
171
|
+
placeholder="小区域 " condition="f_small_area like '%{}%'">
|
172
|
+
</div>
|
173
|
+
<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-2 form-group':!$parent.$parent.$parent.showItem}">
|
174
|
+
<label class="font_normal_body">用户编号</label>
|
175
|
+
<input type="text" class="input_search" v-model="model.f_userinfo_code" id="f_userinfo_code" style="width:60%;"
|
176
|
+
placeholder="用户编号" condition="f_userinfo_code like '{}%'">
|
177
|
+
</div>
|
178
|
+
<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-2 form-group':!$parent.$parent.$parent.showItem}">
|
179
|
+
<label class="font_normal_body">用户名称</label>
|
180
|
+
<input type="text" class="input_search" v-model="model.f_user_name" id="f_user_name" style="width:60%;"
|
181
|
+
placeholder="用户名称" condition="f_user_name like '{}%'">
|
182
|
+
</div>
|
183
|
+
|
184
|
+
<!--<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-3':!$parent.$parent.$parent.showItem}">
|
185
|
+
<label class="font_normal_body">用户类型</label>
|
186
|
+
<v-select style="width:60% "
|
187
|
+
class="select select_list"
|
188
|
+
:value.sync="model.f_check_type"
|
189
|
+
v-model="model.f_check_type"
|
190
|
+
:options='$parent.$parent.userTypes'
|
191
|
+
placeholder='用户类型'
|
192
|
+
condition="f_check_type = '{}'"
|
193
|
+
close-on-select>
|
194
|
+
</v-select>
|
195
|
+
</div>-->
|
196
|
+
<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-2 form-group':!$parent.$parent.$parent.showItem}">
|
197
|
+
<label class="font_normal_body">维修情况</label>
|
198
|
+
<v-select style="width:60% "
|
199
|
+
class="select select_list"
|
200
|
+
:value.sync="model.f_repaired"
|
201
|
+
v-model="model.f_repaired"
|
202
|
+
:options='$parent.$parent.weixiuTypes'
|
203
|
+
placeholder='维修情况'
|
204
|
+
condition="{}"
|
205
|
+
close-on-select>
|
206
|
+
</v-select>
|
207
|
+
</div>
|
208
|
+
<div :class="{'col-sm-3 form-group':$parent.$parent.$parent.showItem,'col-sm-2 form-group':!$parent.$parent.$parent.showItem}">
|
209
|
+
<label class="font_normal_body">整改情况</label>
|
210
|
+
<v-select style="width:60% "
|
211
|
+
class="select select_list"
|
212
|
+
:value.sync="model.f_rectificationed"
|
213
|
+
v-model="model.f_rectificationed"
|
214
|
+
:options='$parent.$parent.zhenggaicondition'
|
215
|
+
placeholder='整改情况'
|
216
|
+
condition="{}"
|
217
|
+
close-on-select>
|
218
|
+
</v-select>
|
219
|
+
</div>
|
220
|
+
|
221
|
+
|
222
|
+
</div>
|
223
|
+
</div>
|
224
|
+
</criteria>
|
225
|
+
<data-grid :model="model" partial='list' v-ref:grid class="list_area table_sy">
|
226
|
+
<template partial='head'>
|
227
|
+
<tr>
|
228
|
+
<th><nobr><input type="checkbox" v-model="$parent.$parent.$parent.checkAll"/> 全选</nobr></th>
|
229
|
+
<th><nobr>入户状态</nobr></th>
|
230
|
+
<th><nobr>用户名</nobr></th>
|
231
|
+
<th><nobr>用户地址</nobr></th>
|
232
|
+
<th><nobr>安检时间</nobr></th>
|
233
|
+
<th><nobr>安检员</nobr></th>
|
234
|
+
<th><nobr>隐患内容</nobr></th>
|
235
|
+
<th><nobr>是否有隐患</nobr></th>
|
236
|
+
<th><nobr>维修情况</nobr></th>
|
237
|
+
<th><nobr>整改情况</nobr></th>
|
238
|
+
<th><nobr>隐患数</nobr></th>
|
239
|
+
<th><nobr>一级隐患数</nobr></th>
|
240
|
+
<th><nobr>二级隐患数</nobr></th>
|
241
|
+
<th><nobr>三级隐患数</nobr></th>
|
242
|
+
<th><nobr>其他隐患数</nobr></th>
|
243
|
+
</tr>
|
244
|
+
</template>
|
245
|
+
<template partial='body'><!-- @checked="isChecked(row.id)" $parent.$parent.$parent.isChecked(row.id)-->
|
246
|
+
<td style="text-align: center;white-space:nowrap;"><input type="checkbox" onClick="event.cancelBubble = true" :checked="$parent.$parent.$parent.isChecked(row.id)" @change="$parent.$parent.$parent.setCheckes(row.id)" /></td>
|
247
|
+
<td style="text-align: center;white-space:nowrap;">{{row.f_entry_status}}</td>
|
248
|
+
<td style="text-align: center;white-space:nowrap;">{{row.f_user_name}}</td>
|
249
|
+
<td style="text-align: center;white-space:nowrap;">{{row.f_address}}</td>
|
250
|
+
<td style="text-align: center;white-space:nowrap;">{{row.f_offsite_time}}</td>
|
251
|
+
<td style="text-align: center;white-space:nowrap;">{{row.f_checker_name}}</td>
|
252
|
+
<td style="text-align: center;white-space:nowrap;">{{row.f_defect_content.substring(26).replaceAll('{','').replaceAll('}','').replaceAll(']','').replaceAll('"','')}}</td>
|
253
|
+
<td style="text-align: center;white-space:nowrap;">{{row.f_has_defect}}</td>
|
254
|
+
<td style="text-align: center;white-space:nowrap;">{{row.f_repaired}}</td>
|
255
|
+
<td style="text-align: center;white-space:nowrap;">{{row.f_rectificationed ? row.f_rectificationed : ( row.f_is_repair == '已处理' ? '整改完成' : '' )}}</td>
|
256
|
+
<td style="text-align: center;white-space:nowrap;">{{row.f_defect_count}}</td>
|
257
|
+
<td style="text-align: center;white-space:nowrap;">{{row.f_fist_count}}</td>
|
258
|
+
<td style="text-align: center;white-space:nowrap;">{{row.f_second_count}}</td>
|
259
|
+
<td style="text-align: center;white-space:nowrap;">{{row.f_third_count}}</td>
|
260
|
+
<td style="text-align: center;white-space:nowrap;">{{row.f_other_count}}</td>
|
261
|
+
</template>
|
262
|
+
<template partial="foot">
|
263
|
+
<td style="text-align: center"><span><b>合计:</b></span></td>
|
264
|
+
<td style="text-align: center"></td>
|
265
|
+
<td style="text-align: center"></td>
|
266
|
+
<td style="text-align: center"></td>
|
267
|
+
<td style="text-align: center"></td>
|
268
|
+
<td style="text-align: center"></td>
|
269
|
+
<td style="text-align: center"></td>
|
270
|
+
<td style="text-align: center"></td>
|
271
|
+
<td style="text-align: center"></td>
|
272
|
+
<td style="text-align: center"></td>
|
273
|
+
<td style="text-align: center">{{model.sums.f_defect_count}}</td>
|
274
|
+
<td style="text-align: center">{{model.sums.f_fist_count}}</td>
|
275
|
+
<td style="text-align: center">{{model.sums.f_second_count}}</td>
|
276
|
+
<td style="text-align: center">{{model.sums.f_third_count}}</td>
|
277
|
+
<td style="text-align: center">{{model.sums.f_other_count}}</td>
|
278
|
+
</template>
|
279
|
+
</data-grid>
|
280
|
+
</criteria-paged>
|
281
|
+
|
282
|
+
<modal :show.sync="showModal" v-ref:modal>
|
283
|
+
<div slot="modal-header" class="modal-header">
|
284
|
+
<h4 class="modal-title">
|
285
|
+
选择计划
|
286
|
+
</h4>
|
287
|
+
</div>
|
288
|
+
<div slot="modal-body" class="modal-body">
|
289
|
+
<plan-chooser :f.sync="this.$login.f" v-ref:chooser></plan-chooser>
|
290
|
+
</div>
|
291
|
+
<div slot="modal-footer" class="modal-footer" style="text-align: center">
|
292
|
+
<button class="button_search" @click="ok">确认</button>
|
293
|
+
<button class="button_search" @click="cancel">取消</button>
|
294
|
+
</div>
|
295
|
+
</modal>
|
296
|
+
<modal :show.sync="showModal1" >
|
297
|
+
<div slot="modal-header" class="modal-header">
|
298
|
+
<h4 class="modal-title">
|
299
|
+
转维修
|
300
|
+
</h4>
|
301
|
+
</div>
|
302
|
+
<div slot="modal-body" class="modal-body">
|
303
|
+
<div v-if="true">
|
304
|
+
|
305
|
+
<div class="row" style="margin-top: 10px">
|
306
|
+
<label for="f_repair" class="control-label font text-left" style="float:left;margin-left:20%;margin-top:5px">故障类型</label>
|
307
|
+
<div class="col-xs-8 col-md-8">
|
308
|
+
<v-select :value.sync="faultCategory" :value-single="true" v-model="faultCategory"
|
309
|
+
:options='faultCategoryOption' placeholder='故障类型'
|
310
|
+
close-on-select>
|
311
|
+
</v-select>
|
312
|
+
</div>
|
313
|
+
</div>
|
314
|
+
<div class="row" style="margin-top: 10px">
|
315
|
+
<label for="f_repair" class="control-label font text-left" style="float:left;margin-left:20%;margin-top:5px">处理级别</label>
|
316
|
+
<div class="col-xs-8 col-md-8">
|
317
|
+
<v-select :value.sync="processingLevel" :value-single="true" v-model="processingLevel"
|
318
|
+
:options='processingLevelOption' placeholder='处理级别'
|
319
|
+
close-on-select>
|
320
|
+
</v-select>
|
321
|
+
</div>
|
322
|
+
</div>
|
323
|
+
|
324
|
+
<div class="row" style="margin-top: 10px">
|
325
|
+
<label class="control-label font text-left" style="float:left;margin-left:20%;margin-top:5px">备 注</label>
|
326
|
+
<div class="col-xs-8 col-md-8">
|
327
|
+
<textarea style="width: 60%; height: 100px" v-model="remarks"></textarea>
|
328
|
+
</div>
|
329
|
+
|
330
|
+
</div>
|
331
|
+
|
332
|
+
</div>
|
333
|
+
</div>
|
334
|
+
<div slot="modal-footer" class="modal-footer" style="text-align: center">
|
335
|
+
<button class="button_search" @click="ok1">确认</button>
|
336
|
+
<button class="button_search" @click="cancel1">取消</button>
|
337
|
+
</div>
|
338
|
+
</modal>
|
339
|
+
<modal :show.sync="showModal2">
|
340
|
+
<div slot="modal-header" class="modal-header">
|
341
|
+
<h4 class="modal-title">
|
342
|
+
隐患整改派发
|
343
|
+
</h4>
|
344
|
+
</div>
|
345
|
+
<div slot="modal-body" class="modal-body">
|
346
|
+
<div v-if="true">
|
347
|
+
<div class="row" style="margin-top: 10px">
|
348
|
+
<label class="control-label font text-left" style="float:left;margin-left:20%;margin-top:5px">整改人员</label>
|
349
|
+
<div class="col-xs-8 col-md-8">
|
350
|
+
<v-select :value.sync="rectify" :value-single="true" v-model="rectify"
|
351
|
+
:options='rectifys' placeholder='隐患整改员'
|
352
|
+
close-on-select>
|
353
|
+
</v-select>
|
354
|
+
</div>
|
355
|
+
</div>
|
356
|
+
<div class="row" style="margin-top: 10px">
|
357
|
+
<label class="control-label font text-left" style="float:left;margin-left:20%;margin-top:5px">当前部门</label>
|
358
|
+
<div class="col-xs-8 col-md-8">
|
359
|
+
<input type="text" class="input_search" style="width: 60%;" v-model="department" disabled/>
|
360
|
+
</div>
|
361
|
+
</div>
|
362
|
+
<div class="row" style="margin-top: 10px">
|
363
|
+
<label class="control-label font text-left" style="float:left;margin-left:20%;margin-top:5px">备 注</label>
|
364
|
+
<div class="col-xs-8 col-md-8">
|
365
|
+
<textarea style="width: 60%; height: 100px" v-model="cremarks"></textarea>
|
366
|
+
</div>
|
367
|
+
</div>
|
368
|
+
</div>
|
369
|
+
</div>
|
370
|
+
<div slot="modal-footer" class="modal-footer" style="text-align: center">
|
371
|
+
<button class="button_search" @click="rectification">确认</button>
|
372
|
+
<button class="button_search" @click="cancel1">取消</button>
|
373
|
+
</div>
|
374
|
+
</modal>
|
375
|
+
</div>
|
376
|
+
</template>
|
377
|
+
<script>
|
378
|
+
import {PagedList} from 'vue-client'
|
379
|
+
import HttpResetClass from "vue-client/src/plugins/HttpResetClass";
|
380
|
+
import * as Util from '../Util'
|
381
|
+
import {toStartDateString} from '../Util'
|
382
|
+
|
383
|
+
export default {
|
384
|
+
title: '隐患查询',
|
385
|
+
data() {
|
386
|
+
let model = new PagedList('rs/sql/GetCheckPaperByDefect', 20, {
|
387
|
+
f_filialeids: 'this.f_filialeids',f_defect_content: 'this.f_defect_content'
|
388
|
+
},{f_defect_count: '', f_fist_count: '', f_second_count: '',f_third_count: '',f_other_count:''})
|
389
|
+
model.f_filialeids = '(' + this.$login.f.orgid + ')'
|
390
|
+
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"
|
391
|
+
return {
|
392
|
+
hasDefectOptions: [{label: '全部', value: ''}, {label: '有隐患', value: '有隐患'}, {label: '无隐患', value: '无隐患'}],
|
393
|
+
f: this.$login.f,
|
394
|
+
model: model,
|
395
|
+
criteriaShow: false,
|
396
|
+
showModal: false,
|
397
|
+
showModal1:false,
|
398
|
+
showModal2:false,
|
399
|
+
f_check_plan: {f_plan_name: '', id: ''},
|
400
|
+
sumsmodel: {},
|
401
|
+
all: false,
|
402
|
+
fields: {},
|
403
|
+
streets:[],
|
404
|
+
zhenggaicondition:[{label:'全部',value:''},{label: '已派整改单', value: 'f_rectificationed=\'已派整改单\''}, {label: '整改完成', value: 'f_rectificationed=\'整改完成\''}, {label: '未派整改单', value: 'f_rectificationed is null'}],
|
405
|
+
weixiuTypes:[{label:'全部',value:''},{label: '已派维修单', value: 'f_repaired=\'已派维修单\''}, {label: '维修完成', value: 'f_repaired=\'维修完成\''}, {label: '未派发维修', value: 'f_repaired is null'}],
|
406
|
+
modelval: [],
|
407
|
+
defectType:[],
|
408
|
+
userTypes:[{label: '民用', value: '民用'}, {label: '非民用', value: '非民用'}],
|
409
|
+
defectLeave:'',
|
410
|
+
defectLeaveList:[{label:'全部',value:''},{label:'一级隐患',value:'一级隐患'},{label:'二级隐患',value:'二级隐患'},{label:'三级隐患',value:'三级隐患'},{label: '其他隐患',value:'其他隐患'}],
|
411
|
+
thead: '',
|
412
|
+
headData: ['入户状态','用户名','用户电话','用户地址','安检时间','安检员','计划名','是否有隐患','隐患数','一级隐患数','一级隐患','二级隐患数','二级隐患','三级隐患数','三级隐患','其他隐患','隐患内容'],
|
413
|
+
bodyData: ['f_entry_status','f_user_name','f_user_phone','f_address','f_offsite_time','f_checker_name','f_plan_name','f_has_defect','f_defect_count','f_fist_count','f_fist_content','f_second_count','f_second_content','f_third_count','f_third_content','f_other_count','f_defect_content'],
|
414
|
+
checkAll:false,
|
415
|
+
checkes:[],
|
416
|
+
faultCategory:'安检隐患',
|
417
|
+
processingLevel:"普通",
|
418
|
+
department:this.$login.f.f_department_name,
|
419
|
+
dep:[],
|
420
|
+
faultCategoryOption:[{label: '民用', value: '民用'}, {label: '工商', value: '工商'}],
|
421
|
+
processingLevelOption:[{label: '普通', value: '普通'}, {label: '加急', value: '加急'}, {label: '紧急', value: '紧急'}],
|
422
|
+
remarks:"",
|
423
|
+
cremarks:"",
|
424
|
+
rectifys:[],
|
425
|
+
rectify:''
|
426
|
+
|
427
|
+
}
|
428
|
+
},
|
429
|
+
methods: {
|
430
|
+
isChecked(v) {
|
431
|
+
// 如果全选,不在的按选中算,否则,在的按选中算
|
432
|
+
if (this.checkAll) {
|
433
|
+
return this.checkes.indexOf(v) == -1
|
434
|
+
} else {
|
435
|
+
return this.checkes.indexOf(v) != -1
|
436
|
+
}
|
437
|
+
},
|
438
|
+
setCheckAll() {
|
439
|
+
this.checkAll=this.checkAll?false:true;
|
440
|
+
// 全选改变后,清空选中数据
|
441
|
+
this.checkes = []
|
442
|
+
},
|
443
|
+
setCheckes(id) {
|
444
|
+
let index=this.checkes.indexOf(id)
|
445
|
+
if(index<0){
|
446
|
+
this.checkes.push(id)
|
447
|
+
}else{
|
448
|
+
this.checkes.splice(index,1)
|
449
|
+
}
|
450
|
+
},
|
451
|
+
hiddenr() {
|
452
|
+
this.$parent.showItem = !this.$parent.showItem
|
453
|
+
},
|
454
|
+
hidden() {
|
455
|
+
this.criteriaShow = !this.criteriaShow
|
456
|
+
},
|
457
|
+
search(args) {
|
458
|
+
if (this.f_check_plan.f_plan_name) {
|
459
|
+
args.condition += ` and f_check_plan_id = '${this.f_check_plan.id}'`
|
460
|
+
}
|
461
|
+
if(this.defectLeave){
|
462
|
+
if(this.defectLeave=='一级隐患'){
|
463
|
+
args.condition += ` and f_fist_count > 0`
|
464
|
+
}
|
465
|
+
if(this.defectLeave=='二级隐患'){
|
466
|
+
args.condition += ` and f_second_count > 0`
|
467
|
+
}
|
468
|
+
if(this.defectLeave=='三级隐患'){
|
469
|
+
args.condition += ` and f_third_count > 0`
|
470
|
+
}
|
471
|
+
if(this.defectLeave=='其他隐患'){
|
472
|
+
args.condition += ` and f_other_count > 0`
|
473
|
+
}
|
474
|
+
}
|
475
|
+
if(this.defectType.length>0){
|
476
|
+
args.condition += ` and (`
|
477
|
+
for(let sqlstr=0;sqlstr<this.defectType.length;sqlstr++){
|
478
|
+
//tag
|
479
|
+
//tag
|
480
|
+
args.condition += ` f_defect_content like '%${this.defectType[sqlstr]}%'`
|
481
|
+
if(sqlstr<this.defectType.length-1){
|
482
|
+
args.condition +=' or'
|
483
|
+
}
|
484
|
+
}
|
485
|
+
args.condition += ` )`
|
486
|
+
}
|
487
|
+
/*if(this.defectType.length>0){
|
488
|
+
for(let sqlstr in this.defectType){
|
489
|
+
args.condition += ` and f_defect_content like '%${this.defectType[sqlstr]}%'`
|
490
|
+
}
|
491
|
+
}*/
|
492
|
+
this.model.search(args.condition, args.model)
|
493
|
+
this.checkAll=false;
|
494
|
+
// 全选改变后,清空选中数据
|
495
|
+
this.checkes = []
|
496
|
+
//tag)
|
497
|
+
//tag)
|
498
|
+
},
|
499
|
+
getRes(obj) {
|
500
|
+
this.model.f_filialeids = this.$login.convertToIn(obj.resids);
|
501
|
+
//tag
|
502
|
+
},
|
503
|
+
showChooser() {
|
504
|
+
this.showModal = true
|
505
|
+
},
|
506
|
+
showChooser1() {
|
507
|
+
this.showModal1 = true
|
508
|
+
},
|
509
|
+
showChooser2() {
|
510
|
+
this.showModal2 = true
|
511
|
+
},
|
512
|
+
getYHZG(){
|
513
|
+
new HttpResetClass().load('POST', '/rs/search', {
|
514
|
+
source: 'this.getParentByType($department$).getAllChildrens().where(row.getAttributes().get($rolestr$).indexOf($整改人员$) != -1))',
|
515
|
+
userid: this.$login.f.id
|
516
|
+
}, {resolveMsg: null, rejectMsg: null}).then((res)=>{
|
517
|
+
//tag+"---id")
|
518
|
+
res.data.forEach((resRow)=>{
|
519
|
+
this.rectifys.push({label:resRow.name,value:resRow.name})
|
520
|
+
})
|
521
|
+
|
522
|
+
})
|
523
|
+
|
524
|
+
},
|
525
|
+
//进行整改
|
526
|
+
rectification(){
|
527
|
+
|
528
|
+
this.$showMessage('确定要整改当前选中用户吗?!', ['confirm', 'cancel']).then((msg)=>{
|
529
|
+
if(msg=='confirm'){
|
530
|
+
if (this.checkAll || this.checkes.length>0) {
|
531
|
+
this.$resetpost(`/rs/logic/UploadRectification`,
|
532
|
+
{
|
533
|
+
condition:this.model.params.condition,
|
534
|
+
f_filialeids:this.model.params.f_filialeids,
|
535
|
+
switchCheckAll:true,
|
536
|
+
checkAll:this.checkAll,
|
537
|
+
param:this.checkes,
|
538
|
+
columnName:'id',
|
539
|
+
processingLevel:this.processingLevel,
|
540
|
+
faultCategory:this.faultCategory,
|
541
|
+
remarks:this.cremarks,
|
542
|
+
deps:this.$login.f.deps,
|
543
|
+
f_attendant: this.$login.f.name,
|
544
|
+
loginUser:{name:this.$login.f.name,ename:this.$login.f.ename},
|
545
|
+
repairman:this.rectify
|
546
|
+
},{resolveMsg: null, rejectMsg: null}).then((res) => {
|
547
|
+
if(res.data.code=200){
|
548
|
+
this.$showMessage('本次成功派发'+res.data.successcon+'个整改单!'+`其中${res.data.nohidden}个不需要隐患整改,${res.data.repeatCount}个已经派发过隐患整改单`)
|
549
|
+
this.checkAll=false;
|
550
|
+
// 全选改变后,清空选中数据
|
551
|
+
this.checkes = []
|
552
|
+
}
|
553
|
+
})
|
554
|
+
}else{
|
555
|
+
this.$showMessage("请勾选用户后进行整改!")
|
556
|
+
}
|
557
|
+
}
|
558
|
+
})
|
559
|
+
},
|
560
|
+
ok() {
|
561
|
+
//tag)
|
562
|
+
this.showModal = false
|
563
|
+
if (this.$refs.modal.$children[0].selectedRow.id) {
|
564
|
+
this.f_check_plan = this.$refs.modal.$children[0].selectedRow
|
565
|
+
}
|
566
|
+
},
|
567
|
+
cancel() {
|
568
|
+
this.showModal = false
|
569
|
+
this.f_check_plan = {f_plan_name: '', id: ''}
|
570
|
+
},
|
571
|
+
ok1() {
|
572
|
+
if (this.checkAll || this.checkes.length>0) {
|
573
|
+
this.$resetpost(`/rs/logic/SafeToRepair`,
|
574
|
+
{
|
575
|
+
condition:this.model.params.condition,
|
576
|
+
f_filialeids:this.model.params.f_filialeids,
|
577
|
+
switchCheckAll:true,
|
578
|
+
checkAll:this.checkAll,
|
579
|
+
param:this.checkes,
|
580
|
+
columnName:'id',
|
581
|
+
processingLevel:this.processingLevel,
|
582
|
+
faultCategory:this.faultCategory,
|
583
|
+
remarks:this.remarks
|
584
|
+
},{resolveMsg: null, rejectMsg: null}).then((res) => {
|
585
|
+
if(res.data.code=200){
|
586
|
+
this.$showMessage("本次成功派发"+res.data.successcon+"个维修单!"+`其中${res.data.nohidden}个不需要维修,${res.data.repeatCount}个已经派发过维修`)
|
587
|
+
this.checkAll=val;
|
588
|
+
// 全选改变后,清空选中数据
|
589
|
+
this.checkes = []
|
590
|
+
}
|
591
|
+
})
|
592
|
+
}else{
|
593
|
+
this.$showMessage("请勾选隐患进行转维修!")
|
594
|
+
}
|
595
|
+
this.showModal1 = false
|
596
|
+
},
|
597
|
+
cancel1() {
|
598
|
+
this.showModal1 = false
|
599
|
+
this.showModal2 = false
|
600
|
+
},
|
601
|
+
async initstreets(){
|
602
|
+
this.streetslist = []
|
603
|
+
let HttpReset = new HttpResetClass()
|
604
|
+
let req = await HttpReset.load('POST', 'rs/sql/address_singleTableOrderBy', {
|
605
|
+
data: {
|
606
|
+
items: '*',
|
607
|
+
tablename: 't_street',
|
608
|
+
orderitem: 'id',
|
609
|
+
condition: `f_orgid = '${this.$login.f.orgid}'`
|
610
|
+
}
|
611
|
+
}, {resolveMsg: null, rejectMsg: '获取地址失败!'})
|
612
|
+
let redata = []
|
613
|
+
req.data.forEach((row, n) => {
|
614
|
+
redata[n] = {
|
615
|
+
label: row.f_street,
|
616
|
+
value: row.f_street,
|
617
|
+
data:row,
|
618
|
+
id:row.id
|
619
|
+
}
|
620
|
+
})
|
621
|
+
this.streets=redata
|
622
|
+
}
|
623
|
+
},
|
624
|
+
ready() {
|
625
|
+
//tag)
|
626
|
+
this.$refs.paged.$refs.criteria.model.f_has_defect = '有隐患'
|
627
|
+
this.$refs.paged.$refs.criteria.model.f_start_time = Util.toStartDateString()
|
628
|
+
this.initstreets()
|
629
|
+
this.getYHZG()
|
630
|
+
},
|
631
|
+
watch:{
|
632
|
+
'checkAll'(val){
|
633
|
+
this.checkAll=val;
|
634
|
+
// 全选改变后,清空选中数据
|
635
|
+
this.checkes = []
|
636
|
+
},
|
637
|
+
'model.rows.length'() {
|
638
|
+
//tag
|
639
|
+
// 如果查询无结果,将合计置为0
|
640
|
+
if(this.model.rows.length < 1){
|
641
|
+
this.model.sums.f_defect_count = 0
|
642
|
+
this.model.sums.f_fist_count = 0
|
643
|
+
this.model.sums.f_second_count = 0
|
644
|
+
this.model.sums.f_third_count = 0
|
645
|
+
}
|
646
|
+
}
|
647
|
+
},
|
648
|
+
computed: {
|
649
|
+
getdefectType(){
|
650
|
+
this.defectType=[]
|
651
|
+
return [... this.$appdata.getParam(this.defectLeave)]
|
652
|
+
},
|
653
|
+
selected() {
|
654
|
+
return this.$refs.paged.$refs.grid.selected
|
655
|
+
},
|
656
|
+
getfield(){
|
657
|
+
//tag
|
658
|
+
let data = {}
|
659
|
+
this.bodyData.forEach((value, index)=>{
|
660
|
+
data[this.bodyData[index]] = this.headData[index]
|
661
|
+
})
|
662
|
+
//合计字段打印
|
663
|
+
this.tfoot = `<tr><th colspan=${this.modelval.length}>全表汇总信息: `
|
664
|
+
if(this.sumsmodel){
|
665
|
+
Object.keys(this.sumsmodel).forEach((key) => {
|
666
|
+
this.tfoot += this.fields[key] + '合计: ' + `<font color="blue">${this.sumsmodel[key]} </font>`
|
667
|
+
})
|
668
|
+
}else{
|
669
|
+
this.tfoot += '暂无'
|
670
|
+
}
|
671
|
+
this.tfoot += '</th></tr>'
|
672
|
+
return data
|
673
|
+
}
|
674
|
+
}
|
675
|
+
}
|
676
|
+
</script>
|