Moar icons + custom password change views

This commit is contained in:
Gabriel Augendre 2019-03-05 07:45:08 +01:00
parent cd21bddad9
commit bd6dfe570e
5 changed files with 25 additions and 4 deletions

View file

@ -45,13 +45,13 @@ if DEBUG:
# Application definition
INSTALLED_APPS = [
'map',
'django.contrib.admin',
'django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.messages',
'django.contrib.staticfiles',
'map',
'crispy_forms',
]

View file

@ -8,7 +8,7 @@
<form method="post">
{% csrf_token %}
{{ form|crispy }}
<button type="submit" class="btn btn-primary">Login</button>
<a href="{% url 'signup' %}" class="btn btn-secondary">I don't have an account</a>
<button type="submit" class="btn btn-primary"><i class="fas fa-sign-in-alt"></i> Login</button>
<a href="{% url 'signup' %}" class="btn btn-secondary"><i class="fas fa-user-plus"></i> I don't have an account</a>
</form>
{% endblock %}

View file

@ -0,0 +1,12 @@
{% extends 'map/base.html' %}
{% load crispy_forms_filters %}
{% block title %}Password change successful{% endblock %}
{% block h1 %}Password change successful{% endblock %}
{% block content %}
<div class="alert alert-info">
Your password was changed.
</div>
<a href="{% url 'map' %}" class="btn btn-primary"><i class="fas fa-map-marked-alt"></i> Go to map</a>
{% endblock %}

View file

@ -0,0 +1,9 @@
{% extends 'map/base_change.html' %}
{% load crispy_forms_filters %}
{% block title %}Change your password{% endblock %}
{% block h1 %}Change your password{% endblock %}
{% block form-buttons %}
<button type="submit" class="btn btn-primary"><i class="fas fa-key"></i> Save</button>
{% endblock %}

View file

@ -41,7 +41,7 @@
{% csrf_token %}
{{ form|crispy }}
{% block form-buttons %}
<button type="submit" class="btn btn-primary">Save</button>
<button type="submit" class="btn btn-primary"><i class="fas fa-user-plus"></i> Save</button>
{% endblock %}
</form>
{% endif %}