优化目录移除时默认目录的选择
This commit is contained in:
@@ -132,6 +132,7 @@ export default {
|
||||
url:`/api/platform/catalog/del`,
|
||||
params: {
|
||||
id: id,
|
||||
platformId: this.platformId,
|
||||
}
|
||||
})
|
||||
.then((res) => {
|
||||
@@ -139,8 +140,8 @@ export default {
|
||||
console.log("移除成功")
|
||||
node.parent.loaded = false
|
||||
node.parent.expand();
|
||||
if(this.defaultCatalogId === id) {
|
||||
this.defaultCatalogId = this.platformId;
|
||||
if (res.data.data) {
|
||||
this.defaultCatalogId = res.data.data;
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user