Fix add more checkbox in login and search form

This commit is contained in:
Edgar P. Burkhart 2023-04-20 10:17:40 +02:00
parent 751ddba463
commit c77b88c2f7
Signed by: edpibu
GPG key ID: 9833D3C5A25BD227
3 changed files with 29 additions and 24 deletions

View file

@ -21,27 +21,27 @@
</tr>
{% endfor %}
</tbody>
<tfoot class="buttons">
<tr>
<td colspan="2">
<label for="addmore">{% translate "Add another" %}</label>
<input type="checkbox"
name="addmore"
id="addmore"
{% if form.instance.adding %}checked{% endif %} />
</td>
</tr>
<tr>
<td colspan="2">
{% block buttons %}
<tfoot>
{% block buttons %}
<tr>
<td colspan="2">
<label for="addmore">{% translate "Add another" %}</label>
<input type="checkbox"
name="addmore"
id="addmore"
{% if form.instance.adding %}checked{% endif %} />
</td>
</tr>
<tr class="buttons">
<td colspan="2">
{% if not form.instance.adding %}
<a class="del" href="{{ form.instance.get_delete_url }}">{% translate "Delete" %}</a>
{% endif %}
<input type="reset" value="{% translate "Reset" %}" />
<input type="submit" value="{% translate "Save" %}" />
{% endblock %}
</td>
</tr>
</td>
</tr>
{% endblock %}
</tfoot>
</table>
{% endblock %}

View file

@ -1,9 +1,11 @@
{% extends "main/form/base.html" %}
{% load i18n %}
{% block buttons %}
<div class="buttons">
<input hidden value="{{ next }}" name="next" />
<input type="reset" />
<input type="submit" value="{% translate "Log in" %}" />
</div>
<tr class="buttons">
<td colspan="2">
<input hidden value="{{ next }}" name="next" />
<input type="reset" />
<input type="submit" value="{% translate "Log in" %}" />
</td>
</tr>
{% endblock %}

View file

@ -1,7 +1,10 @@
{% extends "main/form/base.html" %}
{% load i18n %}
{% block buttons %}
<div class="buttons">
<input type="submit" value="{% translate "Search" %}" />
</div>
<tr class="buttons">
<td colspan="2">
<input type="reset" />
<input type="submit" value="{% translate "Search" %}" />
</td>
</tr>
{% endblock %}