Browse Source

菜单过滤

lrf402788946 5 years ago
parent
commit
c59270cdbf
2 changed files with 2 additions and 1 deletions
  1. 1 0
      .gitignore
  2. 1 1
      src/layout/layout-part/top-menu.vue

+ 1 - 0
.gitignore

@@ -2,6 +2,7 @@
 node_modules
 /dist
 package-lock.json
+.history
 
 # local env files
 .env.local

+ 1 - 1
src/layout/layout-part/top-menu.vue

@@ -82,7 +82,7 @@ export default {
         //组合path:res.data内容都为栏目.所以,点击这些栏目显示的列表应该是信息列表,需要用栏目的id作为查询信息的parten_id查出不同栏目的信息
         for (const col of res.data) {
           if (col.type === 'content') col.path = `/info/detail?id=${col.content_id}`;
-          else if (item.type !== 'url') col.path = `/info/list/${col.id}`;
+          else if (col.type !== 'url') col.path = `/info/list/${col.id}`;
         }
         return res.data;
       }