{% extends "base.html" %}

{% block extra_head %}
    <script type="text/javascript">
        $(function() {
            $("table").dataTable({"bPaginate": false, "aaSorting": []});
        });
    </script>
{% endblock %}

{% block title %}{{ site.domain }}: Site Map{% endblock %}

{% block nav_path %}<a href="{% url 'dmcm:root' %}">{{ site.domain }}</a> &rsaquo; Site Map{% endblock %}

{% block content %}
    <h1>Site Map</h1>
    <table>
        <thead>
            <tr><th>Page Title</th><th>Parent</th><th>Updated</th></tr>
        </thead>
        <tbody>
            {% for page in object_list %}
                <tr><td><a href="/{{ page.slug }}/">{{ page.title }}</a></td>
                    <td>{{ page.parent }}</td>
                    <td>{{ page.updated|date:"Y-m-d H:i" }}</td>
                </tr>
            {% endfor %}
        </tbody>
    </table>
    <br>
{% endblock %}

{% block footer %}{% endblock %}
