Create accounts.html
Browse files- templates/accounts.html +102 -0
templates/accounts.html
ADDED
|
@@ -0,0 +1,102 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<!DOCTYPE html>
|
| 2 |
+
<html lang="fr">
|
| 3 |
+
<head>
|
| 4 |
+
<meta charset="UTF-8">
|
| 5 |
+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
| 6 |
+
<title>Liste des comptes générés</title>
|
| 7 |
+
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/css/bootstrap.min.css" rel="stylesheet">
|
| 8 |
+
<style>
|
| 9 |
+
body { background-color: #f5f5f5; }
|
| 10 |
+
.card { box-shadow: 0 4px 8px rgba(0,0,0,0.1); }
|
| 11 |
+
.username-cell {
|
| 12 |
+
max-width: 200px;
|
| 13 |
+
overflow: hidden;
|
| 14 |
+
text-overflow: ellipsis;
|
| 15 |
+
white-space: nowrap;
|
| 16 |
+
}
|
| 17 |
+
.pagination { margin-bottom: 0; }
|
| 18 |
+
</style>
|
| 19 |
+
<script src="{{ url_for('serve_js') }}"></script>
|
| 20 |
+
</head>
|
| 21 |
+
<body>
|
| 22 |
+
<div class="container mt-5">
|
| 23 |
+
<div class="row">
|
| 24 |
+
<div class="col-md-12 mb-4">
|
| 25 |
+
<div class="card">
|
| 26 |
+
<div class="card-header bg-primary text-white d-flex justify-content-between align-items-center">
|
| 27 |
+
<h3 class="mb-0">Liste des comptes générés</h3>
|
| 28 |
+
<a href="/" class="btn btn-light">Retour au générateur</a>
|
| 29 |
+
</div>
|
| 30 |
+
<div class="card-body">
|
| 31 |
+
<div class="alert alert-info">
|
| 32 |
+
Total des comptes générés: {{ total_accounts }}
|
| 33 |
+
</div>
|
| 34 |
+
|
| 35 |
+
<div class="table-responsive">
|
| 36 |
+
<table class="table table-striped table-hover">
|
| 37 |
+
<thead>
|
| 38 |
+
<tr>
|
| 39 |
+
<th>#</th>
|
| 40 |
+
<th>Nom d'utilisateur</th>
|
| 41 |
+
<th>Email</th>
|
| 42 |
+
<th>Mot de passe</th>
|
| 43 |
+
<th>Startup Rep</th>
|
| 44 |
+
<th>Date de création</th>
|
| 45 |
+
<th>Statut</th>
|
| 46 |
+
</tr>
|
| 47 |
+
</thead>
|
| 48 |
+
<tbody>
|
| 49 |
+
{% for account in accounts %}
|
| 50 |
+
<tr>
|
| 51 |
+
<td>{{ (page - 1) * 20 + loop.index }}</td>
|
| 52 |
+
<td class="username-cell" title="{{ account.username }}">{{ account.username }}</td>
|
| 53 |
+
<td>{{ account.email }}</td>
|
| 54 |
+
<td>{{ account.password }}</td>
|
| 55 |
+
<td>{% if account.is_startup_rep %}Oui{% else %}Non{% endif %}</td>
|
| 56 |
+
<td>{{ account.created_at }}</td>
|
| 57 |
+
<td>
|
| 58 |
+
{% if account.success %}
|
| 59 |
+
<span class="badge bg-success">Succès</span>
|
| 60 |
+
{% else %}
|
| 61 |
+
<span class="badge bg-danger">Échec</span>
|
| 62 |
+
{% endif %}
|
| 63 |
+
</td>
|
| 64 |
+
</tr>
|
| 65 |
+
{% endfor %}
|
| 66 |
+
</tbody>
|
| 67 |
+
</table>
|
| 68 |
+
</div>
|
| 69 |
+
|
| 70 |
+
{% if total_pages > 1 %}
|
| 71 |
+
<div class="d-flex justify-content-center mt-4">
|
| 72 |
+
<nav aria-label="Page navigation">
|
| 73 |
+
<ul class="pagination">
|
| 74 |
+
<li class="page-item {% if page == 1 %}disabled{% endif %}">
|
| 75 |
+
<a class="page-link" href="{{ url_for('view_accounts', page=page-1) if page > 1 else '#' }}">Précédent</a>
|
| 76 |
+
</li>
|
| 77 |
+
|
| 78 |
+
{% for p in range(1, total_pages + 1) %}
|
| 79 |
+
{% if p == page %}
|
| 80 |
+
<li class="page-item active"><span class="page-link">{{ p }}</span></li>
|
| 81 |
+
{% else %}
|
| 82 |
+
<li class="page-item"><a class="page-link" href="{{ url_for('view_accounts', page=p) }}">{{ p }}</a></li>
|
| 83 |
+
{% endif %}
|
| 84 |
+
{% endfor %}
|
| 85 |
+
|
| 86 |
+
<li class="page-item {% if page == total_pages %}disabled{% endif %}">
|
| 87 |
+
<a class="page-link" href="{{ url_for('view_accounts', page=page+1) if page < total_pages else '#' }}">Suivant</a>
|
| 88 |
+
</li>
|
| 89 |
+
</ul>
|
| 90 |
+
</nav>
|
| 91 |
+
</div>
|
| 92 |
+
{% endif %}
|
| 93 |
+
</div>
|
| 94 |
+
</div>
|
| 95 |
+
</div>
|
| 96 |
+
</div>
|
| 97 |
+
</div>
|
| 98 |
+
|
| 99 |
+
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/js/bootstrap.bundle.min.js"></script>
|
| 100 |
+
|
| 101 |
+
</body>
|
| 102 |
+
</html>
|