{% extends "dashboard.html" %}

{% block content %}
<article class="product">
    <p><a href="{% url 'storefront:customer-detail' customer.pk %}">&larr; Back</a></p>
    <header class="object__header">
        <h1>Update Customer</h1>
    </header>
    <section class="object__panel">
        <form class="panel__item" method="POST" action="{% url 'dashboard:customer-update' customer.pk %}">
            {% csrf_token %}
            {{form.as_p}}
            <p class="form__submit">
                <input class="action-button" type="submit" value="Save changes"> or <a href="{% url 'dashboard:customer-detail' customer.pk %}">cancel</a>
            </p>
        </form>
    </section>
</article>  
{% endblock %}
