|
@@ -89,11 +89,8 @@ export default {
|
|
|
if (Object.keys(row).length) {
|
|
|
const queryItem = _.cloneDeep(row)
|
|
|
if (queryItem.children) delete queryItem.children
|
|
|
- this.ischeck = true
|
|
|
- this.checkDatas = []
|
|
|
this.queryItem = queryItem
|
|
|
- this.$refs.tree.setCheckedKeys([])
|
|
|
- this.queryTreeData(queryItem, '权限')
|
|
|
+ this.restDataRow(queryItem)
|
|
|
}
|
|
|
},
|
|
|
deep: true,
|
|
@@ -150,11 +147,11 @@ export default {
|
|
|
}
|
|
|
return alldata
|
|
|
},
|
|
|
- restDataRow () {
|
|
|
+ restDataRow (queryItem = this.queryItem) {
|
|
|
this.ischeck = true
|
|
|
this.checkDatas = []
|
|
|
this.$refs.tree.setCheckedKeys([])
|
|
|
- this.queryTreeData(this.queryItem, '权限')
|
|
|
+ this.queryTreeData(queryItem, '权限')
|
|
|
},
|
|
|
//高级查询-提交
|
|
|
advancedTable (refName) {
|
|
@@ -182,9 +179,6 @@ export default {
|
|
|
this.queryId = 6
|
|
|
}
|
|
|
this.sendCheckData('edit', [rowData])
|
|
|
- // this.$nextTick(() => {
|
|
|
- // this.restDataRow()
|
|
|
- // })
|
|
|
this.advancedDrawer = false
|
|
|
},
|
|
|
formatRowAuth (nstr, arr) {
|
|
@@ -370,10 +364,10 @@ export default {
|
|
|
}
|
|
|
querys.push(authorization(params))
|
|
|
}
|
|
|
- this.getAnscyData(querys)
|
|
|
+ this.getAnscyData(querys, types)
|
|
|
},
|
|
|
//获取异步数据
|
|
|
- async getAnscyData (allResult) {
|
|
|
+ async getAnscyData (allResult, types) {
|
|
|
if (!allResult.length) return
|
|
|
this.loading = true
|
|
|
const results = await Promise.allSettled(allResult)
|
|
@@ -382,6 +376,7 @@ export default {
|
|
|
if (status == 'fulfilled') {
|
|
|
const { code } = value
|
|
|
if (code == 0) {
|
|
|
+ if (types == 'edit') this.restDataRow()
|
|
|
this.$message.success('操作成功')
|
|
|
} else {
|
|
|
this.$message.error('操作失败')
|