modified: templates/admin_giveaways.html modified: templates/user_dashboard.html modified: templates/user_giveaways.html
75 lines
3.0 KiB
HTML
75 lines
3.0 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="en">
|
|
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
<title>Admin - Giveaways</title>
|
|
<link href="https://stackpath.bootstrapcdn.com/bootstrap/4.5.2/css/bootstrap.min.css" rel="stylesheet">
|
|
<style>
|
|
th a {
|
|
color: inherit;
|
|
text-decoration: none;
|
|
}
|
|
</style>
|
|
</head>
|
|
|
|
<body>
|
|
<nav class="navbar navbar-expand-lg navbar-dark bg-dark">
|
|
<a class="navbar-brand" href="#">Multus Bot - Admin Giveaways</a>
|
|
<div class="collapse navbar-collapse" id="navbarNav">
|
|
<ul class="navbar-nav ml-auto">
|
|
<li class="nav-item">
|
|
<a class="nav-link" href="{{ url_for('admin_dashboard') }}">Admin Dashboard</a>
|
|
</li>
|
|
<li class="nav-item">
|
|
<a class="nav-link" href="{{ url_for('logout') }}">Logout</a>
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
</nav>
|
|
|
|
<div class="container mt-5">
|
|
<h1 class="text-center">Giveaways Management</h1>
|
|
<table class="table table-bordered table-hover mt-4">
|
|
<thead class="thead-dark">
|
|
<tr>
|
|
<th><a href="{{ url_for('admin_giveaways', sort='id', order='asc' if sort_field == 'id' and order == 'desc' else 'desc') }}">ID</a></th>
|
|
<th><a href="{{ url_for('admin_giveaways', sort='platform', order='asc' if sort_field == 'platform' and order == 'desc' else 'desc') }}">Platform</a></th>
|
|
<th><a href="{{ url_for('admin_giveaways', sort='name', order='asc' if sort_field == 'name' and order == 'desc' else 'desc') }}">Name</a></th>
|
|
<th>Game Key</th>
|
|
<th>Winner Discord ID</th>
|
|
<th>Active</th>
|
|
<th>Actions</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
{% for giveaway in giveaways %}
|
|
<tr>
|
|
<td>{{ giveaway.id }}</td>
|
|
<td>{{ giveaway.platform }}</td>
|
|
<td>{{ giveaway.name }}</td>
|
|
<td>{{ giveaway.game_key }}</td>
|
|
<td>{{ giveaway.winner_dc_id or 'Not Assigned' }}</td>
|
|
<td>
|
|
{% if giveaway.aktiv %}
|
|
<span class="badge badge-success">Active</span>
|
|
{% else %}
|
|
<span class="badge badge-danger">Inactive</span>
|
|
{% endif %}
|
|
</td>
|
|
<td>
|
|
<a href="{{ url_for('edit_giveaway', giveaway_id=giveaway.id) }}" class="btn btn-primary btn-sm">Edit</a>
|
|
</td>
|
|
</tr>
|
|
{% endfor %}
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
|
|
<script src="https://code.jquery.com/jquery-3.5.1.slim.min.js"></script>
|
|
<script src="https://cdn.jsdelivr.net/npm/bootstrap@4.5.2/dist/js/bootstrap.bundle.min.js"></script>
|
|
</body>
|
|
|
|
</html>
|