1- < div >
2- < table >
3- < tr >
4- < th > Nom</ th >
5- < th > Prénom</ th >
6- < th > Action</ th >
7- </ tr >
8- < tr *ngFor ="let u of utilisateur ">
9- < td > {{u.nomUtilisateur}}</ td >
10- < td > {{u.prenomUtilisateur}}</ td >
11- < td > < button (click) ="deleteUtilisateur(u.idUtilisateur) "> Delete</ button >
12- < button (click) ="editUtilisateur(u) "> Editer</ button >
13- </ td >
14- </ tr >
15- </ table >
16- </ div >
1+ <!-- Formulaire d'ajout début-->
2+ < br >
3+ < br >
4+ < br >
5+ < div class ="container-fluid mt--7 ">
6+ < div class ="col-xl-12 order-xl-1 ">
7+ < div class ="card bg-secondary shadow ">
8+ < div class ="card-header bg-white border-0 ">
9+ < div class ="row align-items-center ">
10+ < div class ="col-8 ">
11+ < h3 class ="mb-0 "> Créer un compte</ h3 >
12+ </ div >
13+ </ div >
14+ </ div >
15+ < div class ="card-body ">
16+ < form (ngSubmit) ="saveUtilisateur() ">
17+ < h6 class ="heading-small text-muted mb-4 "> Informations des utilisateurs</ h6 >
18+ < div class ="pl-lg-4 ">
19+ < div class ="row ">
20+ < div class ="col-lg-6 ">
21+ < div class ="form-group ">
22+ < label class ="form-control-label " for ="input-first-name "> Nom</ label >
23+ < input type ="text " [(ngModel)] ="utilisateur.nomUtilisateur " name ="nomUtilisateur "
24+ id ="input-first-name " class ="form-control form-control-alternative "
25+ placeholder ="First name " value ="Lucky ">
26+ </ div >
27+ </ div >
28+ < div class ="col-lg-6 ">
29+ < div class ="form-group "> < label class ="form-control-label "
30+ for ="input-last-name "> Prénom</ label > < input type ="text "
31+ [(ngModel)] ="utilisateur.prenomUtilisateur " name ="prenomUtilisateur "
32+ id ="input-last-name " class ="form-control form-control-alternative "
33+ placeholder ="Last name " value ="Luck "> </ div >
34+ </ div >
35+ < div class ="col-lg-6 ">
36+ < div class ="form-group "> < label class ="form-control-label " for ="input-email "> Email
37+ address</ label > < input type ="email " [(ngModel)] ="utilisateur.emailUtilisateur "
38+ name ="emailUtilisateur " id ="input-email "
39+ class ="
form-control form-control-alternative "
placeholder ="
[email protected] "
> 40+ </ div >
41+ </ div >
42+ < div class ="col-lg-6 ">
43+ < div class ="form-group "> < label class ="form-control-label " for ="input-date "> Date de
44+ naissance</ label > < input type ="date "
45+ [(ngModel)] ="utilisateur.dateNaissanceUtilisateur "
46+ name ="dateNaissanceUtilisateur " id ="input-date "
47+ class ="form-control form-control-alternative "> </ div >
48+ </ div >
49+ </ div >
50+ < div class ="row ">
51+ < div class ="col-lg-6 ">
52+ < div class ="form-group "> < label class ="form-control-label "
53+ for ="input-username "> Username</ label > < input type ="text "
54+ [(ngModel)] ="utilisateur.username " name ="username " id ="input-username "
55+ class ="form-control form-control-alternative " placeholder ="Username "
56+ value ="your username "> </ div >
57+ </ div >
58+ < div class ="col-lg-6 ">
59+ < div class ="form-group "> < label class ="form-control-label "
60+ for ="input-password "> Password</ label > < input type ="text "
61+ [(ngModel)] ="utilisateur.password " name ="password " id ="input-password "
62+ class ="form-control form-control-alternative " placeholder ="your password ">
63+ </ div >
64+ </ div >
65+ </ div >
66+ < div class ="row ">
67+ < div class ="col-lg-6 ">
68+ < div class ="form-group "> < label class ="form-control-label "
69+ for ="input-password "> Role</ label > < select
70+ class ="form-control form-control-alternative " multiple name ="roles "
71+ [(ngModel)] ="utilisateur.roles ">
72+ < option *ngFor ="let r of roles " [ngValue] ="r "> {{r.libelle}}</ option >
73+ </ select > </ div >
74+ </ div >
75+ </ div >
76+ < div > < button class ="btn btn-danger "> Ajouter</ button > </ div >
77+ </ div >
78+ </ form >
79+ </ div >
80+ </ div >
81+ </ div >
82+ </ div >
83+ <!--Formulaire d'ajout fin-->
84+ <!--Table d'affichage des données début-->
85+ < div class ="container-fluid mt--7 ">
86+ < div class ="row ">
87+ < div class ="col ">
88+ < div class ="card shadow ">
89+ < div class ="card-header border-0 ">
90+ < h3 class ="mb-0 "> Users list</ h3 >
91+ </ div >
92+ < div class ="table-responsive ">
93+ < table class ="table align-items-center table-flush ">
94+ < thead class ="thead-light ">
95+ < tr >
96+ < th scope ="col "> Firstname</ th >
97+ < th scope ="col "> Last name</ th >
98+ < th scope ="col "> Username</ th >
99+ < th scope ="col "> Password</ th >
100+ < th scope ="col "> Date of birth</ th >
101+ < th scope ="col "> Rule</ th >
102+ < th style ="text-align: center; " scope ="col "> Action</ th >
103+ </ tr >
104+ </ thead >
105+ < tbody >
106+ < tr *ngFor ="let u of utilisateur ">
107+ < td > {{u.nomUtilisateur}}</ td >
108+ < td > {{u.prenomUtilisateur}}</ td >
109+ < td > {{u.username}}</ td >
110+ < td > {{u.password}}</ td >
111+ < td > {{u.dateNaissance}}</ td >
112+ < td >
113+ < p style ="margin: 0px; " *ngFor ="let r of u.roles "> {{r.libelle}}</ p >
114+ </ td >
115+ < td > < button (click) ="deleteUtilisateur(u.idUtilisateur) "> Delete</ button >
116+ < button (click) ="editUtilisateur(u) "> Edit</ button >
117+ </ td >
118+ </ tbody >
119+ </ table >
120+ </ div >
121+ </ div >
122+ </ div >
123+ </ div >
124+ </ div >
125+ <!--Table d'affichage des données fin-->
0 commit comments