Laravel Vue SPA: Roles and Permissions

preview_player
Показать описание
How to protect your SPA routes, both from the front-end and the back-end? So you need to show/hide menu items and buttons, but also secure API endpoints with Gates.

Рекомендации по теме
Комментарии
Автор

When ever I was searching for solution, there is a video from laravel daily.
Thank you ❤️

ajithlal
Автор

I don''t know PHP, but your code looks really clean.

alexrd
Автор

Cloning your repositories on daily basis as soon as new video gets uploaded. Thanks a lot. Enjoying VUE tutorials

nabeelyousafpasha
Автор

for my SPA i used Vuex and mixin file that was imported globaly in app.js file. In mixin file i defined my own function "can(permission_name)" that return true if user has that permission.I fetch all permission from backend in my global component with the name "App.vue" and save all permissions to my Vuex store. Then at the backend simply I used "permission middelware" in "_construct()" of each controller.

salahuddinayubi
Автор

Its like another advance level of laravel tutorial . I suscribed . Even if i still dont get the point because my known not into here yet .

amrullahdev
Автор

I get the idea to experiment roles and permission on a vue & laravel spa by this way. But that video is not enough for starter or intermediate programmers. Can you please make a in depth video on that topic?!?
That would be life saving video, I'm struggling on that roles and permission when it comes to vue and laravel spa, for many days. 😪😪😪
Thankyou for your informative video ❤️🧡

zubayerhossain
Автор

How we can manage user permissions and roles when we have vue app separate from the backend. I use spatie permissions for user roles and permissions from the backend.

SanjayaPrasanna
Автор

How about permissions for a specific Posts?

I know it can be done with momentum/lock but don’t want to remodel everything to laravel/data.

Can you point me in a direction or do you know any other package?

erikjandelange
Автор

Man thats awesome, recently had to do an spa with a backend in laravel and the authorization portion of it felt really rigid since I was handling a predefined set of roles and a middlewares to treat authorization, this is completely reusable

guillermocava
Автор

Do you have in separated react like this?

lotkutv
Автор

How to define the services/ability.js file? Help me please!

engr.anowarulislam
Автор

Guys PLZ pay attention that this video is bit old and VUE CASL is now at v5 and has different initialization file.

mohammadrezaarab
Автор

Hi, Can you provide full video for this??
I already customised roles-permission in backend as laravel.

rupakgupta
Автор

Please explain this " <div v-if="can('create', 'Post')">" can() accept 2 prams but you use only permission name (1 param). How its work ?

Thank you.

AbdullahAlMamun-xuls
Автор

Although this tutorial is excellent, I would want to see Spatie package roles and permissions with gate similar to this for APIs.

kfihnzz
Автор

hi sir, its great tutorial.
How to implementation in vue 3 or vuetify

hieronabit
Автор

Thanks For the tutorial, I have tried to use same concept in my application but in mine every user have only one role inside the AuthGate i used return in_array($user->role->id, $roles); but it keeps giving me 403 error. What Can i Do to fix this ?

taoufiqerroudani
Автор

Can i use global mixin $can to replace casl vue, is that make my role and permission dynamic

amasuoamasuo
Автор

this is abit complicated to understand at first glance. But looks a great soluution

mukangangugi
Автор

Sir, did u use vuetify or just css bootstrap in this project? The ui looks so neat and clean.

surojmaharjan