mirror of https://github.com/me50/kukemuna.git
61 lines
2.4 KiB
HTML
61 lines
2.4 KiB
HTML
<!DOCTYPE html>
|
|
|
|
<html lang="en">
|
|
<head>
|
|
<link href="https://fonts.googleapis.com/css2?family=Montserrat:wght@500&display=swap" rel="stylesheet">
|
|
<link href="/static/styles.css" rel="stylesheet">
|
|
<title>Birthdays</title>
|
|
</head>
|
|
<body>
|
|
<div class="header">
|
|
<h1>Birthdays</h1>
|
|
</div>
|
|
<div class="container">
|
|
<div class="section">
|
|
|
|
<h2>Add a Birthday</h2>
|
|
<!-- Create a form for users to submit a name, a day, and a month -->
|
|
<form action="/" method="POST">
|
|
<input autocomplete="off" autofocus name="name" placeholder="Name" type="text">
|
|
<input autocomplete="off" autofocus name="day" placeholder="Day" type="number">
|
|
<input autocomplete="off" autofocus name="month" placeholder="Month" type="number">
|
|
<input type="submit" value="Add Birthday">
|
|
</form>
|
|
</div>
|
|
|
|
<div class="section">
|
|
|
|
<h2>All Birthdays</h2>
|
|
<table>
|
|
<thead>
|
|
<tr>
|
|
<th>Name</th>
|
|
<th>Birthday</th>
|
|
<th>
|
|
<form action="/remove_all" method="POST">
|
|
<input type="submit" value="Remove all">
|
|
</form>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
<!-- TODO: Loop through the database entries to display them in this table -->
|
|
{% for bday in bdays %}
|
|
<tr>
|
|
<td>{{ bday.name }}</td>
|
|
<td>{{ bday.day }}.{{ bday.month }}</td>
|
|
<td>
|
|
<form action="/remove" method="POST">
|
|
<input type="hidden" name="id" value="{{ bday.id }}">
|
|
<input type="submit" value="Remove">
|
|
</form>
|
|
</td>
|
|
</tr>
|
|
{% endfor %}
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
</body>
|
|
</html>
|