From cf01759c58be2d925bd37e82822e71bed237f447 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=88=98=E4=BB=95=E4=BC=9F?= <499672082@qq.com> Date: Sun, 26 Jun 2022 12:23:49 +0800 Subject: [PATCH] BUG --- src/apps/AppDataScreening/orgList.vue | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/apps/AppDataScreening/orgList.vue b/src/apps/AppDataScreening/orgList.vue index 09cb41c5..4b1f9862 100644 --- a/src/apps/AppDataScreening/orgList.vue +++ b/src/apps/AppDataScreening/orgList.vue @@ -72,18 +72,18 @@ export default { this.treeList = this.allData.filter(e => !e.parentid) this.selectDeptPath = [{name: "可选范围", id: ''}] }, - itemClick({id, name}) { - let index = this.selectDeptPath.findIndex(e => e.id == id) + itemClick({id, name, corpId}) { + let index = this.selectDeptPath.findIndex(e => e.id == id && e.corpId == corpId) if (index == -1) { - this.selectDeptPath.push({name, id}) - this.getDeptsAndUsersByParent(id) + this.selectDeptPath.push({name, id, corpId}) + this.getDeptsAndUsersByParent(id, corpId) } }, - getDeptsAndUsersByParent(departmentId) { - this.treeList = this.allData.filter(e => e.parentid == departmentId) + getDeptsAndUsersByParent(departmentId, corpId) { + this.treeList = this.allData.filter(e => e.parentid == departmentId && e.corpId == corpId) this.userList = [] this.$http.post(`/app/wxcp/wxuser/listByDeptId`, null, { - params: {departmentId, status: 1} + params: {departmentId, status: 1, cip: corpId} }).then(res => { if (res?.data) { this.userList = res.data.map(e => ({...e, isChecked: this.isSelected(e.id)})) @@ -97,7 +97,7 @@ export default { } else { let length = this.selectDeptPath.length - index this.selectDeptPath.splice(index + 1, length) - this.getDeptsAndUsersByParent(row.id) + this.getDeptsAndUsersByParent(row.id, row.corpId) } }, itemCheck(row, kind) {