forked from Ruderverein-Donau-Linz/rowt
add planned_trip functionality
This commit is contained in:
@ -27,6 +27,40 @@
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
|
||||
<h1>Hi</h1>
|
||||
<h1>Ausfahrten</h1>
|
||||
|
||||
{% for day in days %}
|
||||
<h2>{{ day.day }}</h2>
|
||||
|
||||
{% for planned_event in day.planned_events %}
|
||||
<h3>Planned event '{{ planned_event.name }}'</h3>
|
||||
Planned amount cox: {{ planned_event.planned_amount_cox }}<br />
|
||||
Allow guests: {{ planned_event.allow_guests }}<br />
|
||||
Planned starting time: {{ planned_event.planned_starting_time }}<br />
|
||||
Max people: {{ planned_event.max_people }}<br />
|
||||
Notes: {{ planned_event.notes }}<br />
|
||||
|
||||
{% if loggedin_user.is_admin %}
|
||||
<a href="/admin/planned-event/{{ planned_event.id }}/delete">DELETE</a>
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
|
||||
{% if loggedin_user.is_admin %}
|
||||
<h3>Add planned event</h3>
|
||||
<form action="/admin/planned-event" method="post">
|
||||
<input type="hidden" name="day" value="{{ day.day }}" />
|
||||
<input type="text" name="name" placeholder="name (e.g. USI)" />
|
||||
<input type="number" name="planned_amount_cox" placeholder="Anzahl Steuerleute" />
|
||||
Gäste <input type="checkbox" name="allow_guests" />
|
||||
<input type="text" name="planned_starting_time" placeholder="Startzeit" />
|
||||
<input type="number" name="max_people" placeholder="Anzahl Ruderer" />
|
||||
<input type="text" name="notes" placeholder="Anmerkungen" />
|
||||
|
||||
<input type="submit" />
|
||||
</form>
|
||||
{% endif %}
|
||||
|
||||
<hr/>
|
||||
{% endfor %}
|
||||
|
||||
{% endblock content %}
|
||||
|
Reference in New Issue
Block a user