Commit 592ed335 by LJM

bug

parent c0a127c8
Showing with 7 additions and 2 deletions
...@@ -361,9 +361,14 @@ export default { ...@@ -361,9 +361,14 @@ export default {
if (res.code === 0) { if (res.code === 0) {
const overviewItem = res.data.data.find(item => item.name === "概况"); const overviewItem = res.data.data.find(item => item.name === "概况");
const menuData = res.data.data.filter(item => item.name !== "概况"); const menuData = res.data.data.filter(item => item.name !== "概况");
this.index_home = overviewItem; this.index_home = overviewItem;
this.menuData = menuData; const filteredData = menuData.filter(item => item.checked || (item.children && item.children.some(child => child.checked))).map(item => {
if (item.children && item.children.length > 0) {
item.children = item.children.filter(child => child.checked);
}
return item;
});
this.menuData = filteredData;
} else { } else {
this.$message({ this.$message({
message: res.msg, message: res.msg,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment