Add field errors in login form
This commit is contained in:
parent
a0bc6e7e3a
commit
f0e97913d5
1 changed files with 2 additions and 0 deletions
|
@ -14,7 +14,9 @@
|
||||||
|
|
||||||
<form id='login_form' action="{% url 'login' %}" method="POST">
|
<form id='login_form' action="{% url 'login' %}" method="POST">
|
||||||
{% csrf_token %}
|
{% csrf_token %}
|
||||||
|
{{ form.username.errors }}
|
||||||
<input type="text" name="username" placeholder="{% trans 'Username' %}" autofocus />
|
<input type="text" name="username" placeholder="{% trans 'Username' %}" autofocus />
|
||||||
|
{{ form.password.errors }}
|
||||||
<input type="password" name="password" placeholder="{% trans 'Password' %}" />
|
<input type="password" name="password" placeholder="{% trans 'Password' %}" />
|
||||||
<input type="submit" value="{% trans 'Login' %}" />
|
<input type="submit" value="{% trans 'Login' %}" />
|
||||||
</form>
|
</form>
|
||||||
|
|
Loading…
Reference in a new issue