safecheck-client 3.0.33-98 → 3.0.33-99
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
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"name": "safecheck-client",
|
3
3
|
"//": "主分支版本别乱升,测试包的版本直接发包(建议使用1.XX.XX-XXX格式作为测试包,不要频繁升级第三位版本号),别提交版本号。切了分支切记把主分支版本升了,保证主分支始终是最高版本!!!!!",
|
4
|
-
"version": "3.0.33-
|
4
|
+
"version": "3.0.33-99",
|
5
5
|
"description": "安检模块 前端组件",
|
6
6
|
"author": "丁新 <417755458@qq.com>",
|
7
7
|
"license": "ISC",
|
@@ -0,0 +1,373 @@
|
|
1
|
+
<template>
|
2
|
+
<div>
|
3
|
+
<criteria-paged :model="model" v-ref:paged>
|
4
|
+
<criteria partial='criteria' @condition-changed='$parent.selfSearch' v-ref:criteria>
|
5
|
+
<div partial>
|
6
|
+
<div class="row">
|
7
|
+
<label class="form-group font_normal_body"><b>计划信息</b></label>
|
8
|
+
<div class="form-group col-sm-1" v-show="false">
|
9
|
+
<!--隐藏条件-->
|
10
|
+
<input type="text" class="input_search" v-model="model.f_plan_id"
|
11
|
+
style="width: 95%" placeholder="计划id" condition=" i.f_plan_id='{}'">
|
12
|
+
</div>
|
13
|
+
<div class="form-group col-sm-1" >
|
14
|
+
<input type="text" class="input_search" v-model="model.f_userinfo_code"
|
15
|
+
style="width: 95%" placeholder="客户编号" condition="i.f_userinfo_code='{}'">
|
16
|
+
</div>
|
17
|
+
<div class="form-group col-sm-1" >
|
18
|
+
<input type="text" class="input_search" v-model="model.f_user_name"
|
19
|
+
style="width: 95%" placeholder="客户名称" condition="i.f_user_name like '%{}%'">
|
20
|
+
</div>
|
21
|
+
<div class="form-group col-sm-1" >
|
22
|
+
<input type="text" class="input_search" v-model="model.f_address"
|
23
|
+
style="width: 95%" placeholder="客户地址" condition="i.f_address like '%{}%'">
|
24
|
+
</div>
|
25
|
+
<!--<div class="form-group col-sm-1" >
|
26
|
+
<v-select :width="'95%'"
|
27
|
+
class="select select_list"
|
28
|
+
:value.sync="$parent.$parent.f_state"
|
29
|
+
v-model="$parent.$parent.f_state"
|
30
|
+
:options='$parent.$parent.checkState'
|
31
|
+
placeholder='安检状态'
|
32
|
+
close-on-select
|
33
|
+
value-single
|
34
|
+
>
|
35
|
+
</v-select>
|
36
|
+
</div>-->
|
37
|
+
<div class="form-group col-sm-3" >
|
38
|
+
<button class="button_new" style="margin-right: 10px" @click="$parent.$parent.showUserCondition()">更多条件</button>
|
39
|
+
<button class="button_search" style="margin-right: 10px" @click="search()">查询</button>
|
40
|
+
<!-- <button class="button_search" style="margin-right: 10px" @click="clear()">清除</button>-->
|
41
|
+
<!-- <export-excel-safe :data="$parent.$parent.exportParameter"-->
|
42
|
+
<!-- :field="$parent.$parent.exportExcelField"-->
|
43
|
+
<!-- style="margin-left: 0px"-->
|
44
|
+
<!-- sqlurl="rs/logic/SafeExportExcel" sql-name="planItem"-->
|
45
|
+
<!-- :template-name="$parent.$parent.selectplan.f_plan_name + '安检计划导出'" :choose-col="true">-->
|
46
|
+
<!-- </export-excel-safe>-->
|
47
|
+
<export-excel-old :data="$parent.$parent.exportParameter"
|
48
|
+
:field="$parent.$parent.exportExcelField"
|
49
|
+
progress="safeGetExportProgress"
|
50
|
+
sqlurl="rs/logic/SafeExportExcel" sql-name="planItem" :template-name="$parent.$parent.selectplan.f_plan_name + '安检计划导出'"></export-excel-old>
|
51
|
+
</div>
|
52
|
+
<div class="form-group col-sm-2 safe_p">
|
53
|
+
<label class="font_normal_body" :title="$parent.$parent.selectplan.f_plan_name">{{$parent.$parent.selectplan.f_plan_name?'当前选中 : '+$parent.$parent.selectplan.f_plan_name:''}}</label>
|
54
|
+
</div>
|
55
|
+
<div class="form-group col-sm-2" style="float: right">
|
56
|
+
<button class="button_search" style="margin-right: 10px" @click="$parent.$parent.showplanModal()">计划调整</button>
|
57
|
+
<button class="button_search" style="margin-right: 10px" @click="$parent.$parent.delPlanItem()" v-show="$parent.$parent.isdelete">移出计划</button>
|
58
|
+
</div>
|
59
|
+
<modal :show.sync="$parent.$parent.showCondtion" v-ref:modal :width="'50%'" :backdrop="false">
|
60
|
+
<div slot="modal-header" class="modal-header">
|
61
|
+
<h4 class="modal-title">
|
62
|
+
计划内用户查询条件
|
63
|
+
</h4>
|
64
|
+
</div>
|
65
|
+
<div slot="modal-body" class="modal-body">
|
66
|
+
<div class="row">
|
67
|
+
<div class="form-group col-sm-4" >
|
68
|
+
<label class="font_normal_body">是否已检:</label>
|
69
|
+
<v-select
|
70
|
+
class="select select_list"
|
71
|
+
:value.sync="model.f_state"
|
72
|
+
v-model="model.f_state"
|
73
|
+
:options='$parent.$parent.checkState'
|
74
|
+
@change="$parent.$parent.checkStateChange(model.f_state)"
|
75
|
+
placeholder='请选择'
|
76
|
+
condition="i.f_state='{}'"
|
77
|
+
close-on-select
|
78
|
+
value-single
|
79
|
+
>
|
80
|
+
</v-select>
|
81
|
+
</div>
|
82
|
+
<div class="form-group col-sm-4" >
|
83
|
+
<label class="font_normal_body">安检结果:</label>
|
84
|
+
<v-select
|
85
|
+
class="select select_list"
|
86
|
+
:value.sync="model.f_check_state"
|
87
|
+
v-model="model.f_check_state"
|
88
|
+
:options='$parent.$parent.checkResults'
|
89
|
+
placeholder='请选择'
|
90
|
+
condition="i.f_last_check_state='{}'"
|
91
|
+
close-on-select
|
92
|
+
value-single
|
93
|
+
>
|
94
|
+
</v-select>
|
95
|
+
</div>
|
96
|
+
<div class="form-group col-sm-4" >
|
97
|
+
<label class="font_normal_body">安检起始:</label>
|
98
|
+
<datepicker
|
99
|
+
placeholder='请选择'
|
100
|
+
style="width:60%"
|
101
|
+
:disabled-days-of-week="[]"
|
102
|
+
:format="'yyyy-MM-dd'"
|
103
|
+
:show-rest-button="reset"
|
104
|
+
:value.sync="model.f_startfile_time"
|
105
|
+
v-model="model.f_startfile_time"
|
106
|
+
condition="i.f_last_check_date >='{} 00:00:00'">
|
107
|
+
</datepicker>
|
108
|
+
</div>
|
109
|
+
<div class="form-group col-sm-4" >
|
110
|
+
<label class="font_normal_body">安检截止:</label>
|
111
|
+
<datepicker
|
112
|
+
placeholder='请选择'
|
113
|
+
:disabled-days-of-week="[]"
|
114
|
+
style="width:60%"
|
115
|
+
:format="'yyyy-MM-dd'"
|
116
|
+
:show-rest-button="reset"
|
117
|
+
:value.sync="model.f_endfile_time"
|
118
|
+
v-model="model.f_endfile_time"
|
119
|
+
condition="i.f_last_check_date <='{} 00:00:00'">
|
120
|
+
</datepicker>
|
121
|
+
</div>
|
122
|
+
</div>
|
123
|
+
</div>
|
124
|
+
<div slot="modal-footer" class="modal-footer" style="text-align: center">
|
125
|
+
<button class="button_search" style="margin-right: 15px" @click="search()">查询</button>
|
126
|
+
<button class="button_search" @click="$parent.$parent.cancel">取消</button>
|
127
|
+
</div>
|
128
|
+
</modal>
|
129
|
+
</div>
|
130
|
+
</div>
|
131
|
+
</criteria>
|
132
|
+
<data-grid :model="model" partial='list' class="table_sy">
|
133
|
+
|
134
|
+
<template partial='head'>
|
135
|
+
<tr>
|
136
|
+
<th><nobr><input type="checkbox" onClick="event.cancelBubble = true" :checked="$parent.$parent.$parent.checkAll" @change="$parent.$parent.$parent.setCheckAll()"/> 全选</nobr></th>
|
137
|
+
<th><nobr>用户编号</nobr></th>
|
138
|
+
<th><nobr>用户名称</nobr></th>
|
139
|
+
<th><nobr>用户电话</nobr></th>
|
140
|
+
<th><nobr>用户类型</nobr></th>
|
141
|
+
<th><nobr>小区名称</nobr></th>
|
142
|
+
<th><nobr>安检状态</nobr></th>
|
143
|
+
<th><nobr>地址</nobr></th>
|
144
|
+
</tr>
|
145
|
+
</template>
|
146
|
+
<template partial='body'>
|
147
|
+
<td style="text-align: center;white-space:nowrap;"><input type="checkbox" onClick="event.cancelBubble = true" :checked="$parent.$parent.$parent.isChecked(row.f_check_item_id)" @change="$parent.$parent.$parent.setCheckes(row.f_check_item_id)" /></td>
|
148
|
+
<td style="text-align: center"><nobr>{{row.f_userinfo_code}}</nobr></td>
|
149
|
+
<td style="text-align: center"><nobr>{{row.f_user_name}}</nobr></td>
|
150
|
+
<td style="text-align: center"><nobr>{{row.f_user_phone}}</nobr></td>
|
151
|
+
<td style="text-align: center"><nobr>{{row.f_user_type}}</nobr></td>
|
152
|
+
<td style="text-align: center"><nobr>{{row.f_residential_area}}</nobr></td>
|
153
|
+
<td style="text-align: center"><nobr>{{row.f_state==='已检'?row.f_last_check_state:'未检'}}</nobr></td>
|
154
|
+
<td style="text-align: center"><nobr>{{row.f_address}}</nobr></td>
|
155
|
+
</template>
|
156
|
+
</data-grid>
|
157
|
+
</criteria-paged>
|
158
|
+
<modal :show.sync="showPlanModal" v-ref:modalp>
|
159
|
+
<div slot="modal-header" class="modal-header">
|
160
|
+
<h4 class="modal-title">
|
161
|
+
计划内用户调整
|
162
|
+
</h4>
|
163
|
+
</div>
|
164
|
+
<div slot="modal-body" class="modal-body">
|
165
|
+
<plan-chooser :f.sync="userlogin.orgid" v-ref:chooser></plan-chooser>
|
166
|
+
</div>
|
167
|
+
<div slot="modal-footer" class="modal-footer" style="text-align: center">
|
168
|
+
<button class="button_search" style="margin-right: 15px" @click="dragtoOtherPlanIteem">确认</button>
|
169
|
+
<button class="button_search" @click="cancel">取消</button>
|
170
|
+
</div>
|
171
|
+
</modal>
|
172
|
+
</div>
|
173
|
+
</template>
|
174
|
+
|
175
|
+
<script>
|
176
|
+
import {HttpResetClass, PagedList} from "vue-client";
|
177
|
+
import Vue from "vue";
|
178
|
+
|
179
|
+
export default {
|
180
|
+
name: "PlanManage",
|
181
|
+
title: '计划管理',
|
182
|
+
data() {
|
183
|
+
return {
|
184
|
+
model:new PagedList('/rs/sql/planItem', 100, {}),
|
185
|
+
isdelete:this.$login.r ? this.$login.r.includes("安检计划删除"):false,
|
186
|
+
a:'1',
|
187
|
+
opt:[{label:"测试",value:"测试"}],
|
188
|
+
showCondtion:false,
|
189
|
+
checkAll:false,
|
190
|
+
checkes:[],
|
191
|
+
checkResults:[{label:'到访不遇',value:'到访不遇'},{label:'拒检',value:'拒检'},{label:'入户',value:'入户'}],
|
192
|
+
checkState:[{label:'全部',value:''},{label:'未检',value:'未检'},{label:'已检',value:'已检'}],
|
193
|
+
showPlanModal:false,
|
194
|
+
exportExcelField: {
|
195
|
+
'f_userinfo_code':'用户编号',
|
196
|
+
'f_user_name':'用户名称',
|
197
|
+
'f_user_type':'用户类型',
|
198
|
+
'f_residential_area':'小区名称',
|
199
|
+
'f_state':'安检状态',
|
200
|
+
'f_address':'地址',
|
201
|
+
'f_user_phone':'用户电话',
|
202
|
+
'f_newfile_date':'建档日期'
|
203
|
+
}
|
204
|
+
}
|
205
|
+
},
|
206
|
+
props:["selectplan","userlogin"],
|
207
|
+
ready(){
|
208
|
+
|
209
|
+
},
|
210
|
+
computed:{
|
211
|
+
exportParameter(){
|
212
|
+
// excel 导出条件拼接
|
213
|
+
return {
|
214
|
+
condition: this.$refs.paged.model.condition,
|
215
|
+
groupName: this.groupNameForSql
|
216
|
+
}
|
217
|
+
}
|
218
|
+
},
|
219
|
+
methods:{
|
220
|
+
clear(){
|
221
|
+
this.model.f_plan_id = '';
|
222
|
+
this.model.f_userinfo_code = '';
|
223
|
+
this.model.f_user_name = '';
|
224
|
+
this.model.f_address='';
|
225
|
+
|
226
|
+
},
|
227
|
+
//将某个计划下的一项拖到另一个计划
|
228
|
+
async dragtoOtherPlanIteem() {
|
229
|
+
//tag)
|
230
|
+
|
231
|
+
if (!this.$refs.modalp.$children[0].selectedRow.id) {
|
232
|
+
this.$showMessage("请选择需要调整到那个计划中!")
|
233
|
+
return
|
234
|
+
}
|
235
|
+
this.$parent.isSend=true
|
236
|
+
try{
|
237
|
+
let res=await new HttpResetClass().load("POST", "/rs/logic/UpCheckPlanItem", {
|
238
|
+
data:{
|
239
|
+
f_operator:this.userlogin.name,
|
240
|
+
f_plan_id:this.$refs.modalp.$children[0].selectedRow.id,
|
241
|
+
condition:this.model.condition,
|
242
|
+
switchCheckAll:true,
|
243
|
+
checkAll:this.checkAll,
|
244
|
+
param:this.checkes,
|
245
|
+
columnName: "i.id"
|
246
|
+
}
|
247
|
+
}, {resolveMsg: null, rejectMsg: null})
|
248
|
+
this.$parent.isSend=false
|
249
|
+
if(res.data.code==200){
|
250
|
+
this.$showMessage("更换安检计划成功!")
|
251
|
+
this.$parent.refreshPlan()
|
252
|
+
}else{
|
253
|
+
this.$showMessage("更换安检计划失败!")
|
254
|
+
}
|
255
|
+
}catch (e) {
|
256
|
+
this.$parent.isSend=false
|
257
|
+
this.$showMessage("更换安检计划失败!")
|
258
|
+
}
|
259
|
+
},
|
260
|
+
showplanModal(){
|
261
|
+
if(!this.selectplan || !this.selectplan.id){
|
262
|
+
this.$showMessage("请先打开一个计划再进行操作")
|
263
|
+
return
|
264
|
+
}
|
265
|
+
if(!this.checkAll && this.checkes.length==0){
|
266
|
+
this.$showMessage("请先在计划中勾选你要调整的用户!")
|
267
|
+
return
|
268
|
+
}
|
269
|
+
this.showPlanModal=true
|
270
|
+
},
|
271
|
+
showUserCondition(){
|
272
|
+
this.showCondtion=true
|
273
|
+
},
|
274
|
+
isChecked(v) {
|
275
|
+
// 如果全选,不在的按选中算,否则,在的按选中算
|
276
|
+
if (this.checkAll) {
|
277
|
+
return this.checkes.indexOf(v) == -1
|
278
|
+
} else {
|
279
|
+
return this.checkes.indexOf(v) != -1
|
280
|
+
}
|
281
|
+
},
|
282
|
+
setCheckAll() {
|
283
|
+
this.checkAll=this.checkAll?false:true;
|
284
|
+
// 全选改变后,清空选中数据
|
285
|
+
this.checkes = []
|
286
|
+
},
|
287
|
+
setCheckes(id) {
|
288
|
+
let index=this.checkes.indexOf(id)
|
289
|
+
if(index<0){
|
290
|
+
this.checkes.push(id)
|
291
|
+
}else{
|
292
|
+
this.checkes.splice(index,1)
|
293
|
+
}
|
294
|
+
},
|
295
|
+
cancel(){
|
296
|
+
this.showCondtion=false
|
297
|
+
this.showPlanModal=false
|
298
|
+
},
|
299
|
+
selfSearch (args) {
|
300
|
+
if(!this.selectplan.id){
|
301
|
+
this.$showMessage("请先选择一个计划!")
|
302
|
+
return
|
303
|
+
}
|
304
|
+
this.cancel()
|
305
|
+
this.checkes=[]
|
306
|
+
this.checkAll=false
|
307
|
+
args.condition+= ` and i.f_state!= '作废'`
|
308
|
+
this.model.search(args.condition, args.model, args.condValue)
|
309
|
+
},
|
310
|
+
checkStateChange(val){
|
311
|
+
if(val=='未检'){
|
312
|
+
this.checkResults=[]
|
313
|
+
this.$refs.paged.$refs.criteria.model.f_check_state=''
|
314
|
+
}else{
|
315
|
+
this.checkResults=[{label:'到访不遇',value:'到访不遇'},{label:'拒检',value:'拒检'},{label:'入户',value:'入户'}]
|
316
|
+
}
|
317
|
+
},
|
318
|
+
//修改计划项状态为作废
|
319
|
+
async delPlanItem() {
|
320
|
+
if(!this.selectplan || !this.selectplan.id){
|
321
|
+
this.$showMessage("请先打开一个计划再进行操作")
|
322
|
+
return
|
323
|
+
}
|
324
|
+
if(!this.checkAll && this.checkes.length==0){
|
325
|
+
this.$showMessage("请先在计划中勾选你要作废的用户!")
|
326
|
+
return
|
327
|
+
}
|
328
|
+
this.$showMessage("此操作无法撤回,确定要执行作废安检单操作吗?",['confirm','cancel']).then((button)=>{
|
329
|
+
if(button=='confirm'){
|
330
|
+
let resu=new HttpResetClass().load("POST", "/rs/logic/UpCheckPlanItemState", {
|
331
|
+
data: {
|
332
|
+
f_operator:this.userlogin.name,
|
333
|
+
condition:this.model.condition,
|
334
|
+
switchCheckAll:true,
|
335
|
+
checkAll:this.checkAll,
|
336
|
+
param:this.checkes,
|
337
|
+
columnName: "i.id"
|
338
|
+
}
|
339
|
+
}, {resolveMsg: null, rejectMsg: null}).then((resu)=>{
|
340
|
+
|
341
|
+
//tag)
|
342
|
+
if(resu.data.code==200){
|
343
|
+
this.$showMessage("移除安检单成功! 成功移除:"+resu.data.res.up+"条"+(resu.data.res.noup>0?"有"+resu.data.res.noup+"条已经不是 ‘未检’ 状态!":""))
|
344
|
+
//this.checkes=[]
|
345
|
+
//this.checkAll=false
|
346
|
+
this.$parent.refresh()
|
347
|
+
}else{
|
348
|
+
this.$showMessage("取消安检计划失败!")
|
349
|
+
}
|
350
|
+
})
|
351
|
+
}
|
352
|
+
})
|
353
|
+
}
|
354
|
+
},
|
355
|
+
watch:{
|
356
|
+
'selectplan.id' (){
|
357
|
+
//tag
|
358
|
+
if(this.selectplan.id){
|
359
|
+
this.$refs.paged.$refs.criteria.model.f_plan_id=this.selectplan.id
|
360
|
+
this.$refs.paged.$refs.criteria.search()
|
361
|
+
}
|
362
|
+
}
|
363
|
+
}
|
364
|
+
}
|
365
|
+
</script>
|
366
|
+
|
367
|
+
<style scoped>
|
368
|
+
.safe_p{
|
369
|
+
white-space: nowrap;
|
370
|
+
overflow: hidden;
|
371
|
+
text-overflow: ellipsis;
|
372
|
+
}
|
373
|
+
</style>
|
@@ -1,17 +1,18 @@
|
|
1
|
-
// 分公司特殊组件页面注册
|
2
|
-
import Vue from "vue";
|
3
|
-
|
4
|
-
//手机特殊目录注册到该文件中
|
5
|
-
let specialComp = {
|
6
|
-
'defect-list-weixiu': (resolve) => { require(['./pc/DefectListWeixiu'], resolve) },
|
7
|
-
'defect-paper-weixiu': (resolve) => { require(['./pc/DefectPaperWeiXiu'], resolve) },
|
8
|
-
'new-check-paper': (resolve) => { require(['./pc/NewCheckpaper'], resolve) },
|
9
|
-
'paper-main': (resolve) => { require(['./pc/PaperList'], resolve) },
|
10
|
-
'check-search-user':(resolve) => {require(['./pc/CheckSearchUser'], resolve)},
|
11
|
-
'role-selector-safe':(resolve) => {require(['./pc/RoleSelector.vue'], resolve)}
|
12
|
-
}
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
1
|
+
// 分公司特殊组件页面注册
|
2
|
+
import Vue from "vue";
|
3
|
+
|
4
|
+
//手机特殊目录注册到该文件中
|
5
|
+
let specialComp = {
|
6
|
+
'defect-list-weixiu': (resolve) => { require(['./pc/DefectListWeixiu'], resolve) },
|
7
|
+
'defect-paper-weixiu': (resolve) => { require(['./pc/DefectPaperWeiXiu'], resolve) },
|
8
|
+
'new-check-paper': (resolve) => { require(['./pc/NewCheckpaper'], resolve) },
|
9
|
+
'paper-main': (resolve) => { require(['./pc/PaperList'], resolve) },
|
10
|
+
'check-search-user':(resolve) => {require(['./pc/CheckSearchUser'], resolve)},
|
11
|
+
'role-selector-safe':(resolve) => {require(['./pc/RoleSelector.vue'], resolve)},
|
12
|
+
'check-plan-list':(resolve) => {require(['./pc/checkPlanList'], resolve)}
|
13
|
+
}
|
14
|
+
exports.specialComp = specialComp
|
15
|
+
|
16
|
+
|
17
|
+
|
18
|
+
|