twig
This commit is contained in:
46
crud/vue/index.twig
Normal file
46
crud/vue/index.twig
Normal file
@@ -0,0 +1,46 @@
|
||||
|
||||
<!DOCTYPE html>
|
||||
<html lang="fr">
|
||||
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<link rel="stylesheet" href="style/style.css" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Liste des utilisateurs</title>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div>
|
||||
<h1>Liste des utilisateurs</h1>
|
||||
<table>
|
||||
<thead>
|
||||
<th>ID</th>
|
||||
<th>Login</th>
|
||||
<th>Nom</th>
|
||||
<th>Prenom</th>
|
||||
<th>Rôle</th>
|
||||
<th>Actions</th>
|
||||
</thead>
|
||||
<tbody>
|
||||
{# afficher les utilisateurs #}
|
||||
{% for user in users %}
|
||||
<tr>
|
||||
<td>{{ user.id }}</td>
|
||||
<td>{{ user.login }}</td>
|
||||
<td>{{ user.lastname }}</td>
|
||||
<td>{{ user.firstname }}</td>
|
||||
<td>{{ user.role }}</td>
|
||||
<td>
|
||||
<button onclick="window.location.href='details.php?id={{ user.id }}'">Voir</button>
|
||||
<button onclick="window.location.href='edit.php?id= {{ user.id }}'">Modifier</button>
|
||||
<button onclick="window.location.href='delete.php?id= {{ user.id }}'">Supprimer</button>
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
<button onclick="window.location.href='add.php'">Ajouter</button>
|
||||
</div>
|
||||
</body>
|
||||
|
||||
</html>
|
||||
Reference in New Issue
Block a user