Merge pull request #1305 from SchrodingersGat/incorrect-login-fix

Add message if username / password combo is rejected
This commit is contained in:
Oliver 2021-02-17 07:37:08 +11:00 committed by GitHub
commit d2c9f759b1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 2249 additions and 1612 deletions

View File

@ -30,7 +30,7 @@
border-radius: 15px;
padding: 20px;
padding-bottom: 35px;
background-color: rgba(50, 50, 50, 0.5);
background-color: rgba(50, 50, 50, 0.75);
}
.login-header {

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -21,6 +21,12 @@
<script type='text/javascript' src="{% static 'fontawesome/js/brands.js' %}"></script>
<script type='text/javascript' src="{% static 'fontawesome/js/fontawesome.js' %}"></script>
<style>
.login-error {
color: #F88;
}
</style>
<title>
InvenTree
</title>
@ -55,7 +61,7 @@
<div class='input-group-addon'>
<span class='fas fa-user'></span>
</div>
<input type="text" name="username" autofocus autocapitalize="none" autocomplete="username" maxlength="150" class="textinput textInput form-control" required id="id_username">
<input type="text" name="username" autofocus autocapitalize="none" autocomplete="username" maxlength="150" class="textinput textInput form-control" required id="id_username" placeholder='{% trans "Enter username" %}'>
</div>
</div>
</div>
@ -67,10 +73,16 @@
<div class='input-group-addon'>
<span class='fas fa-key'></span>
</div>
<input type="password" name="password" autocomplete="current-password" class="textinput textInput form-control" required id="id_password">
<input type="password" name="password" autocomplete="current-password" class="textinput textInput form-control" required id="id_password" placeholder='{% trans "Enter password" %}'>
</div>
</div>
</div>
{% if form.errors %}
<div class='login-error'>
<b>{% trans "Username / password combination is incorrect" %}</b>
</div>
{% endif %}
<hr>