Docs
Menu Permissions
Menu Permissions
Learn how to control Dashboard navigation permissions in BuouNext. This guide covers configuring access levels, managing user roles, and customizing the navigation menu to ensure that users have the appropriate permissions to access different sections of the Dashboard.
In some scenarios, you need to control the permissions of nav in certain scenarios. We support this function. Now let me introduce how to use it.
Introduction
In Project Structure, we introduce de project structure,like this
├── config # BuouNext configuration folder
│ ├── dashboard # Configuration for dashboard mainNav,sidebarNav
│ ├── docs # Configuration for docs mainNav,sidebarNav
│ ├── marketing # Configuration for marketing mainNav,sidebarNav
│ ├── site # Configuration for BuouNext (site metadata, description, author, etc.)
│ ├── subscriptions # Configuration for subscriptions
In dashboard, we can use UserRole or Other Permissions to control our dashboard nav by using disabled
sidebarNav: [
{
title: "Posts",
href: "/dashboard",
icon: "post",
},
{
title: "Statistic",
href: "/dashboard/statistic",
icon: "statistic",
disabled: !isPermission,
},
],