Procházet zdrojové kódy

将 /bg/my/message 路由替换为 /bg/account/message

reghao před 3 měsíci
rodič
revize
cc8ec64267

+ 1 - 1
src/components/layout/NavBar.vue

@@ -311,7 +311,7 @@ export default {
       this.$router.push(path)
     },
     goToMessage() {
-      const path = '/bg/my/message'
+      const path = '/bg/account/message'
       if (this.$route.path === path) {
         this.$router.go(0)
         return

+ 1 - 1
src/components/layout/NavBarNoSearch.vue

@@ -155,7 +155,7 @@ export default {
       this.$router.push(path)
     },
     goToMessage() {
-      const path = '/bg/my/message'
+      const path = '/bg/account/message'
       if (this.$route.path === path) {
         this.$router.go(0)
         return

+ 9 - 0
src/router/background_account.js

@@ -6,6 +6,7 @@ const Background = () => import('views/admin/Background')
 // 用户后台主页
 const MyProfile = () => import('views/my/MyProfile')
 const MyRecord = () => import('views/my/MyRecord')
+const MyMessage = () => import('views/my/MyMessage')
 const MyOAuth = () => import('views/my/MyOAuth')
 
 export default {
@@ -33,6 +34,14 @@ export default {
       component: MyRecord,
       meta: { needAuth: true, roles: ['tnb_admin', 'tnb_user', 'tnb_disk'] }
     },
+    {
+      path: '/bg/account/message',
+      name: 'MyMessage',
+      title: '我的消息',
+      icon: 'el-icon-user',
+      component: MyMessage,
+      meta: { needAuth: true, roles: ['tnb_admin', 'tnb_user', 'tnb_disk'] }
+    },
     {
       path: '/bg/account/oauth',
       name: 'OAuth',

+ 0 - 9
src/router/background_my.js

@@ -6,7 +6,6 @@ const Background = () => import('views/admin/Background')
 // 用户后台主页
 const MyContact = () => import('views/my/MyContact')
 const MyRcmd = () => import('views/my/MyRcmd')
-const MyMessage = () => import('views/my/MyMessage')
 const MyVip = () => import('views/my/MyVip')
 const MyWallet = () => import('views/my/MyWallet')
 const MyDevice = () => import('views/my/MyDevice')
@@ -57,14 +56,6 @@ export default {
       component: MyWallet,
       meta: { needAuth: true, roles: ['tnb_user'] }
     },
-    {
-      path: '/bg/my/message',
-      name: 'MyMessage',
-      title: '我的消息',
-      icon: 'el-icon-user',
-      component: MyMessage,
-      meta: { needAuth: true, roles: ['tnb_user'] }
-    },
     {
       path: '/bg/my/rcmd',
       name: 'Rcmd',