erdkse / adminlte-3-vue

Vue 3.4.27 start-up project with AdminLTE 3.2.0 template
https://erdkse.com/projects/preview/adminlte-vue
MIT License
248 stars 115 forks source link

Dynamic sidebar menu #38

Closed donny26utama closed 2 years ago

donny26utama commented 2 years ago

Hello, it is me again. sorry if I have many requests from you. How I can make a dynamic sidebar menu depend on the user's permissions?

erdkse commented 2 years ago

You can generate this MENU property depending on user permissions

https://github.com/erdkse/adminlte-3-vue/blob/main/src/modules/main/menu-sidebar/menu-sidebar.ts#L22

donny26utama commented 2 years ago

How to set this menu depends on the user's permission? For example, an Admin will have a "User Management" menu and a basic User not have. Sorry if I have so many questions, I'm a new learning vue. What I want is to create a dashboard that has login/logout function, a sidebar menu depend on the user's permission, and a complete CRUD page, which lists page using pagination. can you help me? I would great to thanks to you.

erdkse commented 2 years ago

You need to fetch user permissions before creating the menu and create the menu according to these permissions - and unfortunately creating a sample data page is not on my roadmap - I advise you to follow some documentation and tutorials - It is pretty straightforward thing.

donny26utama commented 2 years ago

I have learned from tutorials, but what I learned and your repo has a different structure.