don't persist form state in firefox

Fixes shelves not being disabled in dropdowns.
See https://stackoverflow.com/questions/5985839/bug-with-firefox-disabled-attribute-of-input-not-resetting-when-refreshing
This commit is contained in:
Hugh Rundle 2021-11-20 19:04:51 +11:00
parent 4b6f5c9f51
commit b406a03533
No known key found for this signature in database
GPG key ID: CD23D6039184286B
2 changed files with 2 additions and 2 deletions

View file

@ -32,7 +32,7 @@
{% elif shelf.editable %}
<form name="shelve" action="/shelve/" method="post">
<form name="shelve" action="/shelve/" method="post" autocomplete="off">
{% csrf_token %}
<input type="hidden" name="book" value="{{ active_shelf.book.id }}">
<button class="button {{ class }}" name="shelf" type="submit" value="{{ shelf.identifier }}" {% if shelf in book.shelf_set.all %} disabled {% endif %}>

View file

@ -1,6 +1,6 @@
{% load utilities %}
{% if fallback_url %}
<form name="fallback_form_{{ 0|uuid }}" method="GET" action="{{ fallback_url }}">
<form name="fallback_form_{{ 0|uuid }}" method="GET" action="{{ fallback_url }}" autocomplete="off">
{% endif %}
<button
{% if not fallback_url %}