Closed rogargon closed 10 months ago
For instance, to fully block admins from creating Routes, beyond hiding the menu option it is possible to add a Guard to the route. You can use as inspiration: https://github.com/UdL-EPS-SoftArch/mycircular/blob/main/src/app/login-basic/adminLoggedIn.guard.ts
However, note that this guard should do the reverse, to check that the user is not in the role Admin.
I´ve been searching about canActivate and, have found that these method have been deprecated and now have to use canActivateFn
Closed by #21
For instance, to fully block admins from creating Routes, beyond hiding the menu option it is possible to add a Guard to the route. You can use as inspiration: https://github.com/UdL-EPS-SoftArch/mycircular/blob/main/src/app/login-basic/adminLoggedIn.guard.ts
However, note that this guard should do the reverse, to check that the user is not in the role Admin.