| | |
| | | methods: { |
| | | empower() { |
| | | batchAddSave(this.checkAll.oid, this.checkAll.id, this.ParentList).then(res => { |
| | | console.log(res) |
| | | if(res.data.data.code === 200){ |
| | | this.$message.success(res.data.data.msg) |
| | | // console.log(res.data) |
| | | if(res.data.code === 200){ |
| | | this.$message.success(res.data.msg) |
| | | this.dialogVisible=false; |
| | | } |
| | | }) |
| | | }, |
| | | //分类授权多选回调 |
| | | checkChange(row, checked) { |
| | | console.log('row',row) |
| | | // this.ParentList=[] |
| | | // console.log('row',row) |
| | | if (checked) { |
| | | if (!row.parentId) { |
| | | const parentRecord = { |
| | |
| | | } |
| | | } |
| | | } |
| | | console.log(this.ParentList); |
| | | console.log('this.ParentList',this.ParentList); |
| | | }, |
| | | //分类授权 |
| | | classifyHandler(row) { |
| | |
| | | children: [] |
| | | }; |
| | | //当前已选择数据回填 |
| | | if (!record.attributes.selected) { |
| | | if (record.attributes.selected == 'true') { |
| | | NumberList.push(record.value); |
| | | } |
| | | if (parent) { |
| | | const existingChild = parent.children.find(child => child.label === record.label); |
| | | if (existingChild) { |
| | | record.value = existingChild.value; // 使用已存在的子节点的value值 |
| | | const stingChild = parent.children.find(child => child.label === record.label); |
| | | if (stingChild) { |
| | | record.value = stingChild.value; // 使用已存在的子节点的value值 |
| | | } else { |
| | | parent.children.push(record); |
| | | value++; |
| | | } |
| | | } else { |
| | | const existingRecord = List.find(item => item.label === record.label); |
| | | if (existingRecord) { |
| | | record.value = existingRecord.value; // 使用已存在的顶层节点的value值 |
| | | const stingRecord = List.find(item => item.label === record.label); |
| | | if (stingRecord) { |
| | | record.value = stingRecord.value; // 使用已存在的顶层节点的value值 |
| | | } else { |
| | | List.push(record); |
| | | value++; |
| | |
| | | }, |
| | | async getDataList() { |
| | | this.loading = true; |
| | | console.log(this.search); |
| | | const {pageSize, currentPage} = this.page; |
| | | const conditions = {}; |
| | | if (Object.keys(this.search).length > 0) { |
| | |
| | | } |
| | | const response = await getSysInfoList(pageSize, currentPage, conditions); |
| | | if (response.status === 200) { |
| | | console.log(response); |
| | | // console.log(response); |
| | | this.loading = false; |
| | | const data = response.data.data; |
| | | this.data = data.records; |
| | |
| | | }).then(async () => { |
| | | const response = await sysInfoDel(param) |
| | | if (response.status === 200) { |
| | | console.log(response) |
| | | // console.log(response) |
| | | this.$message({ |
| | | type: 'success', |
| | | message: '删除成功!' |