Changed Authentication
This commit is contained in:
@@ -0,0 +1,2 @@
|
||||
create table role_privileges (id bigint not null, privileges varchar(255) not null check (privileges in ('LIST_USERS','ADD_USERS','LIST_QUIZZ')), primary key (id, privileges));
|
||||
alter table if exists role_privileges add constraint FK7xfa4foqs58j7rhk6ex78hpf3 foreign key (id) references roles;
|
||||
@@ -73,4 +73,9 @@ div.welcome{
|
||||
color: #fff;
|
||||
font-size: 20px;
|
||||
font-style: italic;
|
||||
}
|
||||
table, th, td {
|
||||
border: 1px solid black;
|
||||
border-collapse: collapse;
|
||||
padding: 4px;
|
||||
}
|
||||
@@ -0,0 +1,25 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="fr" dir="ltr">
|
||||
<head>
|
||||
<div th:replace="~{html-head}"/>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div th:replace="~{header}"/>
|
||||
<main>
|
||||
|
||||
<div th:if="${param.success}">
|
||||
<div class="alert alert-success"> Votre mot de passe a été changé</div><br/>
|
||||
</div>
|
||||
<form
|
||||
method="post"
|
||||
role="form"
|
||||
th:action="@{/change-password/change}">
|
||||
<label for="new-password">Nouveau mot de passe :</label>
|
||||
<input type="password" id="new-password" name="new-password"/>
|
||||
<br/>
|
||||
<input id="connect" type="submit" value="Changer de mot de passe"/>
|
||||
</form>
|
||||
</main>
|
||||
</body>
|
||||
</html>
|
||||
@@ -14,6 +14,9 @@
|
||||
<div th:if="${param.logout}">
|
||||
<div class="alert alert-success"> You have been logged out.</div><br/>
|
||||
</div>
|
||||
<div th:if="${param.restricted}">
|
||||
<div class="alert alert-success"> Vous devez vous connecter pour vous accéder à cette page</div><br/>
|
||||
</div>
|
||||
|
||||
<form
|
||||
method="post"
|
||||
|
||||
+21
-5
@@ -9,19 +9,22 @@
|
||||
<main>
|
||||
|
||||
<div th:if="${param.success}">
|
||||
You have successfully registered our app!
|
||||
Utilisteurice ajouté·e avec succès !
|
||||
</div>
|
||||
<div th:if="${param.duplicate}">
|
||||
Le nom d'utilisateur·ice est déjà utilisé
|
||||
</div>
|
||||
<form
|
||||
method="post"
|
||||
role="form"
|
||||
th:action="@{/adduser/save}"
|
||||
th:object="${user}"
|
||||
th:action="@{/adduser}"
|
||||
th:object="${newuser}"
|
||||
>
|
||||
<label for="name">Name</label>
|
||||
<label for="name">Nom</label>
|
||||
<input
|
||||
id="name"
|
||||
name="name"
|
||||
placeholder="Enter pseudo"
|
||||
placeholder="Le pseudo"
|
||||
th:field="*{name}"
|
||||
type="text"
|
||||
/>
|
||||
@@ -40,6 +43,19 @@
|
||||
|
||||
<button class="btn btn-primary" type="submit">Register</button>
|
||||
</form>
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
<th>ID</th>
|
||||
<th>Pseudo</th>
|
||||
<th>Roles</th>
|
||||
</tr>
|
||||
<tr th:each="u : ${users}">
|
||||
<td th:text="${u.id}"></td>
|
||||
<td th:text="${u.pseudo}"></td>
|
||||
<td th:text="${u.roles}"></td>
|
||||
</tr>
|
||||
</table>
|
||||
</main>
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user