You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

55 lines
2.0 KiB

  1. {% extends "base.html" %}
  2. {% load widget_tweaks %}
  3. {% block content %}
  4. <section class="hero container has-text-centered">
  5. <div class="columns hero-body">
  6. <div class="column is-4 is-offset-4">
  7. <div class="box has-text-left">
  8. {% if form.errors %}
  9. <p>Your username and password didn't match. Please try again.</p>
  10. {% endif %} {% if next %} {% if user.is_authenticated %}
  11. <p>Your account doesn't have access to this page. To proceed, please login with an account that has access.</p>
  12. {% else %}
  13. <p>Please login to see this page.</p>
  14. {% endif %} {% endif %}
  15. <form method="post" action="{% url 'login' %}">
  16. {% csrf_token %}
  17. <div class="field ">
  18. <label class="label">Username</label>
  19. <div class="control has-icons-left has-icons-right">
  20. {{ form.username|add_class:"input" }}
  21. <span class="icon is-small is-left">
  22. <i class="fas fa-user"></i>
  23. </span>
  24. <span class="icon is-small is-right">
  25. <i class="fas fa-check"></i>
  26. </span>
  27. </div>
  28. </div>
  29. <div class="field">
  30. <label class="label">Password</label>
  31. <div class="control has-icons-left has-icons-right">
  32. {{ form.password|add_class:"input"}}
  33. <span class="icon is-small is-left">
  34. <i class="fas fa-lock"></i>
  35. </span>
  36. <span class="icon is-small is-right">
  37. <i class="fas fa-check"></i>
  38. </span>
  39. </div>
  40. </div>
  41. <div class="field">
  42. <label class="checkbox">
  43. <input type="checkbox"> Remember me
  44. </label>
  45. </div>
  46. <input class="button is-block is-primary is-middle is-fullwidth" type="submit" value="Login" />
  47. <input type="hidden" name="next" value="{{ next }}" />
  48. </form>
  49. </div>
  50. </div>
  51. </div>
  52. </section>
  53. {% endblock %}