解决了 Bug 半月放在每月上面 14877
解决了 Bug 部门和人员选择好之后 删除部门右侧的人员会清空 应该只删除掉删除的部门下的人员 14878 解决了 Bug 新增报错 14874pull/11/head
parent
c4a4559043
commit
4d527d0522
|
@ -1058,7 +1058,37 @@ export default {
|
||||||
},
|
},
|
||||||
// 移除选中项时触发的事件
|
// 移除选中项时触发的事件
|
||||||
handleRemove(selectedItems) {
|
handleRemove(selectedItems) {
|
||||||
this.form.USER_ID = []
|
console.log(this.form.USER_ID)
|
||||||
|
const currentUserId = this.form.USER_ID
|
||||||
|
requestFN(
|
||||||
|
'/user/listUserByCorp',
|
||||||
|
{
|
||||||
|
DEPARTMENT_ID: selectedItems.id
|
||||||
|
}
|
||||||
|
).then((data) => {
|
||||||
|
const userList = data.userList
|
||||||
|
if (userList) {
|
||||||
|
for (let i = 0; i < userList.length; i++) {
|
||||||
|
for (let j = 0; j < this.form.USER_ID.length; j++) {
|
||||||
|
if (userList[i].USER_ID === this.form.USER_ID[j]) {
|
||||||
|
for (let k = 0; k < currentUserId.length; k++) {
|
||||||
|
if (this.form.USER_ID[j] === currentUserId[k]) {
|
||||||
|
console.log(this.form.USER_ID[j])
|
||||||
|
currentUserId.splice(k, 1)
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
this.listLoading = false
|
||||||
|
// this.peopleList = data.userList
|
||||||
|
}).catch((e) => {
|
||||||
|
this.listLoading = false
|
||||||
|
})
|
||||||
|
this.form.USER_ID = currentUserId
|
||||||
// 移除选中项时同时移除全部子节点
|
// 移除选中项时同时移除全部子节点
|
||||||
if (this.form.INVOLVING_CORPS_DEPART_ID.includes(selectedItems.id)) {
|
if (this.form.INVOLVING_CORPS_DEPART_ID.includes(selectedItems.id)) {
|
||||||
this.form.INVOLVING_CORPS_DEPART_ID.splice(this.form.INVOLVING_CORPS_DEPART_ID.indexOf(selectedItems.id), 1)
|
this.form.INVOLVING_CORPS_DEPART_ID.splice(this.form.INVOLVING_CORPS_DEPART_ID.indexOf(selectedItems.id), 1)
|
||||||
|
|
|
@ -104,7 +104,8 @@ export default {
|
||||||
rules: {
|
rules: {
|
||||||
FIRE_REGION_NAME: [{ required: true, message: '消防区域不为空', trigger: 'blur' }],
|
FIRE_REGION_NAME: [{ required: true, message: '消防区域不为空', trigger: 'blur' }],
|
||||||
DEPARTMENT_ID: [{ required: true, message: '负责部门不为空', trigger: 'blur' }],
|
DEPARTMENT_ID: [{ required: true, message: '负责部门不为空', trigger: 'blur' }],
|
||||||
FIRE_REGION_CODE: [{ required: true, message: '区域编码不为空', trigger: 'blur' }]
|
FIRE_REGION_CODE: [{ required: true, message: '区域编码不为空', trigger: 'blur' }],
|
||||||
|
PHOTO_UPLOAD_METHOD: [{ required: true, message: '区域编码不为空', trigger: 'blur' }]
|
||||||
},
|
},
|
||||||
formLabelWidth: '120px',
|
formLabelWidth: '120px',
|
||||||
OTHERLEVELID: '',
|
OTHERLEVELID: '',
|
||||||
|
|
Loading…
Reference in New Issue