diff --git a/src/components/NoticeDropdown/index.vue b/src/components/NoticeDropdown/index.vue index 8b172959..dcf4b93c 100644 --- a/src/components/NoticeDropdown/index.vue +++ b/src/components/NoticeDropdown/index.vue @@ -149,7 +149,7 @@ function handleReadNotice(id: string) { // 查看更多 function handleViewMoreNotice() { - router.push({ path: "/myNotice" }); + router.push({ name: "MyNotice" }); } // 全部已读 diff --git a/src/router/index.ts b/src/router/index.ts index 37c39b23..57058ee4 100644 --- a/src/router/index.ts +++ b/src/router/index.ts @@ -59,7 +59,7 @@ export const constantRoutes: RouteRecordRaw[] = [ meta: { title: "个人中心", icon: "user", hidden: true }, }, { - path: "myNotice", + path: "my-notice", name: "MyNotice", component: () => import("@/views/system/notice/components/MyNotice.vue"), meta: { title: "我的通知", icon: "user", hidden: true },