diff --git a/src/layouts/navbar/index.vue b/src/layouts/navbar/index.vue index bd80cae..3298561 100644 --- a/src/layouts/navbar/index.vue +++ b/src/layouts/navbar/index.vue @@ -54,7 +54,7 @@ export default { { icon: "el-icon-collection", index: "/achievement/list", - title: "成绩管理" + title: "成绩管理", }, { icon: "el-icon-news", @@ -102,7 +102,9 @@ export default { for (let i in this.actives) { if (actives[i].includes(this.$route.name)) this.active = `/${i}/list`; } - this.active = this.$route.path; + let arr=this.$route.path.split("/"); + let name = `/${arr[1]}/list` + this.active = name; } }, created() { diff --git a/src/pages/achievement/show/index.vue b/src/pages/achievement/show/index.vue index c4f6b5f..1c137c5 100644 --- a/src/pages/achievement/show/index.vue +++ b/src/pages/achievement/show/index.vue @@ -316,8 +316,8 @@ export default {