2023-11-02 12:15:10 +01:00
{% import "includes/macros" as macros %}
{% extends "base" %}
{% block content %}
<div class="max-w-screen-lg w-full">
2023-11-03 10:52:30 +01:00
<h1 class="h1">Ergo Challenges</h1>
{% if flash %}
2023-11-09 21:48:21 +01:00
{{ macros::alert(message=flash.1, type=flash.0, class="my-3") }}
{% endif %}
<div class="bg-blue-100 border-t-4 border-blue-500 rounded-b text-blue-900 px-4 py-3 shadow-md" role="alert">
<div class="flex">
<div class="py-1"><svg class="fill-current h-6 w-6 text-blue-500 mr-4" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 20"><path d="M10 20a10 10 0 1110-10 10 10 0 0110 10zm-1-9V7a1 1 0 012 0v4a1 1 0 01-2 0zm0 4a1 1 0 110-2 1 1 0 010 2z"/></svg></div>
<div>
<p class="font-bold">Ergo-Challenge?!?</p>
<p class="text-sm">
Du kannst zu jeder Zeit in der Woche rudern und dein Ergebnis hier hochladen. Wir freuen uns jedoch dienstags und donnerstags über jeden, der bei unseren gemeinsamen Trainings dabei ist. Alle Ergebnisse, die auf dieser Seite bis Sonntag 23:59 Uhr hochgeladen werden, finden am Montag Morgen den Weg ins Postfach der (Ister) Challenge Verantwortlichen.<br />
Die gesamten Ergebnisse findest du <a href="https://docs.google.com/spreadsheets/d/e/2PACX-1vR6b1VPpSOqBnYKrRA6hiHTr8wrQMNspMFoNUxIGRxWAI7Xm2QQoW3QP5k6xYVZ9OxBjRP-r011bNGw/pubhtml" target="_blank" style="text-decoration: underline;">hier</a>, falls sich ein Fehler eingeschlichen haben sollte bitte direkt den Verantwortlichen Kontakt aufnehmen: office@ergochallenge.at (Christian)<br />
<a href="https://cloud.rudernlinz.at/s/m7mPQdwSWscpaXT" target="_blank" style="text-decoration: underline;">Noch mehr Infos zur Ergo-Challenge findest du hier</a>
</p>
</div>
</div>
</div>
2023-11-02 12:58:50 +01:00
2023-11-02 12:15:10 +01:00
2023-11-03 10:52:30 +01:00
<div class="grid gap-3">
2023-11-04 19:33:36 +01:00
<details class="bg-white dark:bg-primary-900 text-black dark:text-white rounded-md p-2 mt-5 shadow">
2023-11-03 10:52:30 +01:00
<summary class="cursor-pointer">Deine Daten</summary>
<div class="pt-3">
<p>
2023-11-04 19:33:36 +01:00
Folgende Daten hat der Ruderassistent von dir. Wenn diese nicht mehr aktuell sind, bitte gewünschte Änderungen an Philipp melden (Tel. nr siehe Signal, oder an <a href="mailto:it@rudernlinz.at" class="text-primary-600 dark:text-primary-200 hover:text-primary-950 hover:dark:text-primary-300 underline" target="_blank">it@rudernlinz.at</a>).
2023-11-03 10:52:30 +01:00
<br /><br />
<ul>
<li>Geburtsdatum: {{ loggedin_user.dob }}</li>
<li>Gewicht: {{ loggedin_user.weight}} kg</li>
<li>Geschlecht: {{ loggedin_user.sex}}</li>
</ul>
</p>
</div>
</details>
2023-11-04 19:33:36 +01:00
<div class="bg-white dark:bg-primary-900 text-black dark:text-white rounded-md block shadow grid gap-3">
2023-11-03 10:52:30 +01:00
<h2 class="h2">Neuer Eintrag</h1>
<details class="p-2">
<summary class="cursor-pointer">Dirty Thirty</summary>
<div class="mt-3">
<form action="/ergo/thirty" class="grid gap-3" method="post" enctype="multipart/form-data">
<div>
2023-11-04 19:33:36 +01:00
<label for="user-thirty" class="text-sm text-gray-600 dark:text-gray-100">Ergo-Fahrer</label>
2023-11-03 10:52:30 +01:00
<select name="user" id="user-thirty" class="input rounded-md">
<option disabled="disabled">User auswählen</option>
{% for user in users %}
{% if user.id == loggedin_user.id %}
<option value="{{ user.id }}" selected="selected">{{ user.name }}</option>
{% else %}
<option value="{{ user.id }}">{{ user.name }}</option>
{% endif %}
{% endfor %}
</select>
</div>
2023-11-08 18:00:27 +01:00
{{ macros::input(label="Distanz [m]", name="result", required=true, type="number", class="input rounded-md") }}
2023-11-03 10:52:30 +01:00
<div>
2023-11-04 19:33:36 +01:00
<label for="file-thirty" class="text-sm text-gray-600 dark:text-gray-100">Ergebnis-Foto vom Ergo-Display</label>
2023-11-07 20:49:22 +01:00
<input type="file" id="file-thirty" name="proof" class="input rounded-md" accept="image/*">
2023-11-03 10:52:30 +01:00
</div>
<div class="text-end">
<input type="submit" value="Speichern" class="btn btn-primary btn-fw m-auto"/>
</div>
</form>
</div>
</details>
<details class="p-2">
<summary class="cursor-pointer">Dirty Dozen</summary>
<div class="mt-3">
<form action="/ergo/dozen" class="grid gap-3" method="post" enctype="multipart/form-data">
<div>
2023-11-04 19:33:36 +01:00
<label for="user-dozen" class="text-sm text-gray-600 dark:text-gray-100">Ergo-Fahrer</label>
2023-11-03 10:52:30 +01:00
<select name="user" id="user-dozen" class="input rounded-md">
<option disabled="disabled">User auswählen</option>
{% for user in users %}
{% if user.id == loggedin_user.id %}
<option value="{{ user.id }}" selected="selected">{{ user.name }}</option>
{% else %}
<option value="{{ user.id }}">{{ user.name }}</option>
{% endif %}
{% endfor %}
</select>
</div>
2023-11-08 18:02:32 +01:00
{{ macros::input(label="Zeit [hh:mm:ss.s] oder Distanz [m]", name="result", required=true, type="text", class="input rounded-md", pattern="(?:\d+:\d{2}:\d{2}\.\d+|\d{1,2}:\d{2}\.\d+|\d+(\.\d+)?)") }}
2023-11-02 12:15:10 +01:00
2023-11-03 10:52:30 +01:00
<div>
2023-11-04 19:33:36 +01:00
<label for="file-dozen" class="text-sm text-gray-600 dark:text-gray-100">Ergebnis-Foto vom Ergo-Display</label>
2023-11-07 20:49:22 +01:00
<input type="file" id="file-dozen" name="proof" class="input rounded-md" accept="image/*">
2023-11-03 10:52:30 +01:00
</div>
<div class="text-end">
<input type="submit" value="Speichern" class="btn btn-primary btn-fw m-auto"/>
</div>
</form>
</div>
</details>
</div>
2023-11-02 12:15:10 +01:00
2023-11-04 19:33:36 +01:00
<div class="bg-white dark:bg-primary-900 text-black dark:text-white rounded-md block shadow grid gap-3">
2023-11-03 10:52:30 +01:00
<h2 class="h2">Aktuelle Woche</h2>
<details class="p-2">
<summary class="cursor-pointer">Dirty Thirty <small class="text-gray-600">({{thirty | length}})</small></summary>
<div class="mt-3">
<ol>
{% for stat in thirty %}
<li><strong>{{ stat.name }}:</strong> {{ stat.result }}</li>
{% endfor %}
</ol>
</div>
</details>
2023-11-02 12:15:10 +01:00
2023-11-03 10:52:30 +01:00
<details class="p-2">
<summary class="cursor-pointer">Dirty Dozen <small class="text-gray-600">({{dozen | length}})</small></summary>
<div class="mt-3">
<ol>
{% for stat in dozen %}
<li><strong>{{ stat.name }}:</strong> {{ stat.result }}</li>
{% endfor %}
</ol>
</div>
</details>
</div>
</div>
2023-11-07 21:27:40 +01:00
{% if loggedin_user.is_admin %}
<div class="bg-white dark:bg-primary-900 text-black dark:text-white rounded-md block shadow grid gap-3">
<h2 class="h2">Update</h2>
<details class="p-2">
<summary class="cursor-pointer">Dirty Thirty <small class="text-gray-600">({{thirty | length}})</small></summary>
<div class="mt-3">
<ol>
{% for stat in thirty %}
<li>
<form action="/ergo/thirty/user/{{ stat.id }}/new" method="get">
{{ stat.name }}: <input type="text" value="{{stat.result}}" name="new" style="color: black;"/><input type="submit"/>
</form>
</li>
{% endfor %}
</ol>
</div>
</details>
<details class="p-2">
<summary class="cursor-pointer">Dirty Dozen <small class="text-gray-600">({{dozen | length}})</small></summary>
<div class="mt-3">
<ol>
{% for stat in dozen %}
2023-11-07 22:01:34 +01:00
<li>
<form action="/ergo/dozen/user/{{ stat.id }}/new" method="get">
{{ stat.name }}: <input type="text" value="{{stat.result}}" name="new" style="color: black;"/><input type="submit"/>
</form>
</li>
2023-11-07 21:27:40 +01:00
{% endfor %}
</ol>
</div>
</details>
</div>
</div>
{% endif %}
2023-11-02 12:15:10 +01:00
</div>
{% endblock content%}