parent
ccb676071f
commit
f7ab45774b
@ -1,6 +1,4 @@ |
|||||||
<body> |
<!--<app-nav-menu></app-nav-menu>--> |
||||||
<!--<app-nav-menu></app-nav-menu>--> |
<div class="container"> |
||||||
<div class="container"> |
|
||||||
<router-outlet></router-outlet> |
<router-outlet></router-outlet> |
||||||
</div> |
</div> |
||||||
</body> |
|
||||||
|
@ -0,0 +1,5 @@ |
|||||||
|
export * from "./nav-menu.component"; |
||||||
|
export * from "./nav-menu-assistante/nav-menu-assistante.component"; |
||||||
|
export * from "./nav-menu-collaborateur/nav-menu-collaborateur.component"; |
||||||
|
export * from "./nav-menu-commercial/nav-menu-commercial.component"; |
||||||
|
export * from "./nav-menu-rh/nav-menu-rh.component"; |
@ -0,0 +1,9 @@ |
|||||||
|
<button mat-button [matMenuTriggerFor]="menuCollaborateurs"> |
||||||
|
<span>Collaborateurs</span> |
||||||
|
<mat-icon>more_vert</mat-icon> |
||||||
|
</button> |
||||||
|
<mat-menu #menuCollaborateurs="matMenu"> |
||||||
|
<button mat-menu-item>Liste des collaborateurs</button> |
||||||
|
<button mat-menu-item>Liste des EPs collaborateurs non signés</button> |
||||||
|
</mat-menu> |
||||||
|
<button mat-button>Liste des référents</button> |
@ -0,0 +1,8 @@ |
|||||||
|
import { Component } from "@angular/core"; |
||||||
|
|
||||||
|
|
||||||
|
@Component({ |
||||||
|
selector : "app-nav-menu-assistante", |
||||||
|
templateUrl : "./nav-menu-assistante.component.html" |
||||||
|
}) |
||||||
|
export class NavMenuAssistanteComponent {} |
@ -0,0 +1,2 @@ |
|||||||
|
<button mat-button>Liste des EP</button> |
||||||
|
<button mat-button>Liste des Formations</button> |
@ -0,0 +1,8 @@ |
|||||||
|
import { Component } from "@angular/core"; |
||||||
|
|
||||||
|
|
||||||
|
@Component({ |
||||||
|
selector : "app-nav-menu-collaborateur", |
||||||
|
templateUrl : "./nav-menu-collaborateur.component.html" |
||||||
|
}) |
||||||
|
export class NavMenuCollaborateurComponent {} |
@ -0,0 +1,10 @@ |
|||||||
|
<button mat-button [matMenuTriggerFor]="menuCollaborateurs"> |
||||||
|
<span>Collaborateurs</span> |
||||||
|
<mat-icon>more_vert</mat-icon> |
||||||
|
</button> |
||||||
|
<mat-menu #menuCollaborateurs="matMenu"> |
||||||
|
<button mat-menu-item>Liste de tous les collaborateurs</button> |
||||||
|
<button mat-menu-item>Liste des collaborateurs suivis</button> |
||||||
|
</mat-menu> |
||||||
|
<button mat-button>Liste des formations</button> |
||||||
|
<button mat-button>EP effectués</button> |
@ -0,0 +1,8 @@ |
|||||||
|
import { Component } from "@angular/core"; |
||||||
|
|
||||||
|
|
||||||
|
@Component({ |
||||||
|
selector : "app-nav-menu-commercial", |
||||||
|
templateUrl : "./nav-menu-commercial.component.html" |
||||||
|
}) |
||||||
|
export class NavMenuCommercialComponent {} |
@ -0,0 +1,16 @@ |
|||||||
|
<button mat-button [matMenuTriggerFor]="menuFormation"> |
||||||
|
<span>Formation</span> |
||||||
|
<mat-icon>more_vert</mat-icon> |
||||||
|
</button> |
||||||
|
<mat-menu #menuFormation="matMenu"> |
||||||
|
<button mat-menu-item>Ajouter une nouvelle formation</button> |
||||||
|
<button mat-menu-item>Liste des formations</button> |
||||||
|
</mat-menu> |
||||||
|
<button mat-button [matMenuTriggerFor]="menuDemande"> |
||||||
|
<span>Demande de formations</span> |
||||||
|
<mat-icon>more_vert</mat-icon> |
||||||
|
</button> |
||||||
|
<mat-menu #menuDemande="matMenu"> |
||||||
|
<button mat-menu-item>Créer une nouvelle demande de formation</button> |
||||||
|
<button mat-menu-item>Liste des demandes</button> |
||||||
|
</mat-menu> |
@ -0,0 +1,8 @@ |
|||||||
|
import { Component } from "@angular/core"; |
||||||
|
|
||||||
|
|
||||||
|
@Component({ |
||||||
|
selector : "app-nav-menu-rh", |
||||||
|
templateUrl : "./nav-menu-rh.component.html" |
||||||
|
}) |
||||||
|
export class NavMenuRHComponent {} |
@ -0,0 +1,23 @@ |
|||||||
|
<header> |
||||||
|
<mat-card> |
||||||
|
<!--Mettre l'icon APSIDE--> |
||||||
|
<img src="../../assets/img/logo.png"> |
||||||
|
<!--LIEN VERS HOME--> |
||||||
|
<button mat-button>Accueil</button> |
||||||
|
<!--RESTE MENU EN FONCTION DES ROLES--> |
||||||
|
<app-nav-menu-assistante *ngIf="this.keycloakService.isUserInRole(role.assistante)"></app-nav-menu-assistante> |
||||||
|
<app-nav-menu-collaborateur *ngIf="this.keycloakService.isUserInRole(role.collaborateur)"></app-nav-menu-collaborateur> |
||||||
|
<app-nav-menu-commercial *ngIf="this.keycloakService.isUserInRole(role.commercial)"></app-nav-menu-commercial> |
||||||
|
<app-nav-menu-rh *ngIf="this.keycloakService.isUserInRole(role.rh)"></app-nav-menu-rh> |
||||||
|
<!--METTRE QUELQUE CHOSE DE SIMILAIRE A SYGES--> |
||||||
|
<!--<button mat-button on-click="logout()"> logout </button>--> |
||||||
|
<button mat-button [matMenuTriggerFor]="menuMore"> |
||||||
|
<span>{{ keycloakService.getKeycloakInstance().profile.firstName }} {{ keycloakService.getKeycloakInstance().profile.lastName }}</span> |
||||||
|
<mat-icon>more_vert</mat-icon> |
||||||
|
</button> |
||||||
|
<mat-menu #menuMore="matMenu"> |
||||||
|
<button mat-menu-item on-click="logout()">Déconnexion</button> |
||||||
|
</mat-menu> |
||||||
|
</mat-card> |
||||||
|
|
||||||
|
</header> |
@ -0,0 +1,21 @@ |
|||||||
|
import { Component } from '@angular/core'; |
||||||
|
import { KeycloakService } from 'keycloak-angular'; |
||||||
|
|
||||||
|
import { Role } from '../utils/roles'; |
||||||
|
|
||||||
|
@Component({ |
||||||
|
selector: 'app-nav-menu', |
||||||
|
templateUrl: './nav-menu.component.html', |
||||||
|
}) |
||||||
|
export class NavMenuComponent { |
||||||
|
|
||||||
|
role = Role; |
||||||
|
constructor(public keycloakService : KeycloakService){} |
||||||
|
|
||||||
|
isExpanded = false; |
||||||
|
|
||||||
|
async logout() { |
||||||
|
await this.keycloakService.logout(); |
||||||
|
} |
||||||
|
|
||||||
|
} |
After Width: | Height: | Size: 16 KiB |
Before Width: | Height: | Size: 948 B After Width: | Height: | Size: 46 KiB |
Loading…
Reference in new issue