2
0
Fork 0

Remove backup stuff from shift detail page

This commit is contained in:
Luca 2023-05-07 23:05:28 +02:00
parent 8bd09a22ae
commit 0bfda856d8
1 changed files with 0 additions and 39 deletions

View File

@ -67,43 +67,4 @@
{% endfor %}
<button class="button is-link" type="submit">Hinzufügen</button>
</form>
<hr>
{% if shift.teambackup_set.all.count %}
<h5 class="subtitle">Backup-Teammitglied(er)</h5>
<div class="columns">
{% for member in shift.teambackup_set.all %}
<div class="column is-one-quarter">
<div class="box is-flex is-align-items-center is-justify-content-space-between">
<span class="is-size-4">{{ member.name }}</span>
<a class="button is-danger is-small" href="{% url 'signage:work_remove' member.pk %}">entfernen</a>
</div>
</div>
{% endfor %}
</div>
{% endif %}
<h5 class="subtitle">Backup-Teammitglied eintragen</h5>
<form action="{% url 'signage:work_add' shift.pk %}?redir={{ request.path }}" method="post">
{% csrf_token %}
{% for field in backup_form %}
<div class="field">
{% if field.widget_type == 'checkbox' %}
<div class="control">
<label class="checkbox" for="{{ field.id_for_label }}">{{ field }} {{ field.label }}</label>
</div>
{% else %}
<label class="label" for="{{ field.id_for_label }}">{{ field.label }}</label>
<div class="control">
{{ field }}
</div>
{% endif %}
{% for error in field.errors %}
<p class="help is-danger">{{ error }}</p>
{% endfor %}
{% if field.help_text %}
<p class="help">{{ field.help_text }}</p>
{% endif %}
</div>
{% endfor %}
<button class="button is-link" type="submit">Team hinzufügen</button>
</form>
{% endblock %}