-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Closed
Description
问题: 路由配置时, 如何设置某个菜单的子菜单全部是隐藏菜单?
描述:
消息中心 (1级菜单)
├── 消息管理 (2级菜单)
│ ├── 发布消息 (3级隐藏菜单)
│ ├── 查看消息消息 (3级隐藏菜单)
代码结构
views
├── msgcenter
│ ├── msg
│ │ ├── index.vue
│ │ ├── msgview
│ │ │ ├── index.vue
│ │ ├── msgedit
│ │ │ ├── index.vue
│ ├── template
如上图所示, “消息管理” 下级显示了2个菜单, 我希望:
- 点击 “消息管理” 进入
views/msgcenter/msg/index.vue
- “发布消息” 和 “查看消息” 菜单隐藏起来,不在左侧菜单显示出来
- 在任意页面,点击 “发布消息” 按钮,跳转到
views/msgcenter/msg/msgview/index.vue
- 在任意页面,点击 “查看消息” 按钮,跳转到
views/msgcenter/msg/msgedit/index.vue
- 左侧菜单能正常显示 消息中心和消息管理,且消息管理能点击后跳转到 步骤1 中的地址。
自己做过的一些尝试:
- “发布消息” 和 “查看消息” 加了hideInMenu: true后,程序会按照这个方式显示。“消息管理” 无法点击

Metadata
Metadata
Assignees
Labels
No labels