{% extends "layout.html" %}
{% load crispy_forms_tags %}

{% block title %}Login{% endblock %}

{% block body %}

{% if user.username %}

<div class="text-center col-md-4" >
    <form method="post" class="form-group">{% csrf_token %}
        {{ form|crispy }}

        <button type="submit" class="btn btn-lg btn-primary btn-block">Change Password</button>
    </form>

</div>

{% else %}

<script>
            window.location.replace("/logout");
        </script>

{% endif %}

</form>

{% endblock %}
