{% extends 'luxuryadmin/base.html' %}
{% load staticfiles %}
{% load thumbnail %}
{% load icanhaz %}
{% load widget_tweaks %}
{% block admin_content %}

    <ul id="adminBreadcrumbs">
        <li><a href="{% url luxuryadmin:collection %}" title="">Admin</a></li>
        <li><a href="{% url luxuryadmin:pages %}" title="">Manage pages</a></li>
        <li>{% if page %}{{ page.title }}{% else %}Add new page{% endif %}</li>
    </ul>
    {% include 'luxuryadmin/snippets/nav.html' with on='pages' %}
    <h1>{% if page %}Edit page - &#91;{{ page.title }}&#93;{% else %}Add new page{% endif %}</h1>
    <div class="adminPageWrapper">
            <form method="POST" class="itemForm"
            {% if page %}
                action="{% url luxuryadmin:page page=page.id %}"
            {% else %}
                action="{% url luxuryadmin:page %}"
            {% endif %}
            class="itemForm page">
			<div class="actions top">
				<input type="submit" value="save page"/>
			</div>
            <div id="infoForm">
                {% csrf_token %}
                <fieldset class="">
                    <legend>Page details</legend>
                    {{ form.as_p }}
                </fieldset>
            </div>
            <div class="actions">
                <input type="submit" value="save page"/>
            </div>
        </form>
    </div>
{% endblock %}