templates: use <button> for buttons

(incidentally this fixes the cancel button behaviour)
This commit is contained in:
Frédéric Péters 2020-04-23 21:36:15 +02:00
parent 79871d20f0
commit 2c2c27dbd1
1 changed files with 3 additions and 3 deletions

View File

@ -7,16 +7,16 @@
personnels (token).
</p>
<p>
<input type="submit" name="{{ submit_name }}" value="{% trans "Login" %}"/>
<button name="{{ submit_name }}">{% trans "Login" %}</button>
{% if cancel %}
<input type="submit" name="cancel" value="{% trans 'Cancel' %}"/>
<button name="cancel">{% trans 'Cancel' %}</button>
{% endif %}
</div>
</form>
<script>
$(function() {
$('#csam-login img').on('click', function() {
$('#csam-login input[name={{submit_name}}]').click();
$('#csam-login button[name={{submit_name}}]').click();
});
});
</script>