added ApplicationController and Application enum #119
@ -46,11 +46,12 @@ public class ApplicationsController {
|
||||
|
||||
authorizedApps.add(Applications.Login);
|
||||
authorizedApps.add(Applications.Profile);
|
||||
authorizedApps.add(Applications.Msg);
|
||||
authorizedApps.add(Applications.Forum);
|
||||
authorizedApps.add(Applications.Rdv);
|
||||
|
||||
if (posterRole == Role.Student || posterRole == Role.Admin) return authorizedApps;
|
||||
if (posterRole == Role.Teacher || posterRole == Role.Student || posterRole == Role.Admin){
|
||||
authorizedApps.add(Applications.Msg);
|
||||
authorizedApps.add(Applications.Forum);
|
||||
authorizedApps.add(Applications.Rdv);
|
||||
Maxime marked this conversation as resolved
Outdated
|
||||
}
|
||||
|
||||
if (posterRole == Role.Teacher || posterRole == Role.Secretary || posterRole == Role.Admin) authorizedApps.add(Applications.ManageCourses);
|
||||
|
||||
@ -58,5 +59,4 @@ public class ApplicationsController {
|
||||
|
||||
return authorizedApps;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user
cette ligne est un peut bizzare dans le sens ou si il est admin il va retourner direct et par récupérer les autres... Aussi de base msg forum et rdv c'est que pour les student et profs. Si c'est chiant pourquoi pas laisser msg et forum mais rdv c'est spécifique aux profs et etudiants ^^
petit mistake oui bien vu !