Преглед на файлове

调整路由,添加稿件列表页面

reghao преди 4 години
родител
ревизия
74ac1d3518
променени са 3 файла, в които са добавени 29 реда и са изтрити 3 реда
  1. 5 3
      src/layout/studio.vue
  2. 9 0
      src/router/index.js
  3. 15 0
      src/views/studio/post.vue

+ 5 - 3
src/layout/studio.vue

@@ -35,7 +35,9 @@
         </v-list-item>
       </router-link>
       <v-divider />
+      <!-- TODO 具有特定角色才能查看 -->
       <div v-if="CheckPower.checkPower(this.$store.state.user.userInfo) == 'admin'">
+        <!--<div v-if="CheckPower.checkPower(this.$store.state.user.userInfo) == 'user'">-->
         <router-link v-for="item in adminList" :key="item.text" :to="item.link">
           <v-list-item
             link
@@ -131,10 +133,10 @@ export default {
     drawer: true,
     items: [
       { icon: 'mdi-application', text: '个人主页', link: '/studio' },
-      { icon: 'mdi-filmstrip-box-multiple', text: '稿件列表', link: '/studio/list' },
+      { icon: 'mdi-filmstrip-box-multiple', text: '稿件列表', link: '/studio/post' },
       { icon: 'mdi-upload', text: '投稿', link: '/studio/upload' },
-      { icon: 'mdi-database', text: '数据分析', link: '/studio/data' },
-      { icon: 'mdi-account-multiple', text: '粉丝管理', link: '/studio/fans' },
+      /* { icon: 'mdi-database', text: '数据分析', link: '/studio/data' },
+      { icon: 'mdi-account-multiple', text: '粉丝管理', link: '/studio/fans' },*/
       { icon: 'mdi-cash-usd', text: '付费会员', link: '/vip' },
       { icon: 'mdi-wrench', text: '自定义频道', link: '/user/setting' }
     ],

+ 9 - 0
src/router/index.js

@@ -112,6 +112,15 @@ const routes = [
           requireAuth: true
         }
       },
+      {
+        path: '/studio/post',
+        name: 'Post',
+        component: () => import('@/views/studio/post.vue'),
+        meta: {
+          title: '稿件列表',
+          requireAuth: true
+        }
+      },
       {
         path: '/studio/comment',
         name: 'Comment',

+ 15 - 0
src/views/studio/post.vue

@@ -0,0 +1,15 @@
+<template>
+  <div>
+    稿件列表
+  </div>
+</template>
+
+<script>
+export default {
+  name: 'UserList'
+}
+</script>
+
+<style>
+
+</style>