{% extends 'base.html' %}

{% load bootstrap_toolkit %}
{% load guardian_tags %}

{% block content %}

    <div class='row'>
        <div class='span7'>
            <div class='lesser-hero-unit hero-unit lesser-hero-unit'>
                <h3>{{ package.file }}</h3>

                <div class='span3'>

                </div>
                <h3>{{ project }}</h3>
                <dl class='dl-horizontal dl-unwrapped-horizontal'>
                    <dt>project</dt>
                    <dd><a href="{% url 'projects:show' project.id %}">{{ project }}</a></dd>
                    <dt>mounting point</dt>
                    <dd>{{ project.file_system }}</dd>
                    <dt>last deployment</dt>
                    <dd>???</dd>
                </dl>
                <dl class='dl-horizontal dl-unwrapped-horizontal'>
                    <dt></dt>
                    <dd>
                        {% if can_upload %}
                            <a class='btn' title='Upload' href='{% url 'projects:upload' project.id %}'><i class='icon-upload'></i>Upload</a>
                        {% endif %}
                        <a class='btn' href="{% url 'projects:index' %}">Back</a>
                    </dd>
                </dl>
            </div>
        </div>
        <div class='span5'>
            {% include 'projects/_list.html' with project=project packages=packages %}
        </div>
    </div>
    <div class='row'>
        <div class='span7'>
            {% include 'tree/tree.html' with name='project content' files=files unfolded=True uid='projectContents' %}
        </div>
        <div id='actions-content' class='span5'>

        </div>
    </div>
    <script type="text/javascript">
{#        $(function() {#}
{#            console.log('{{ path }}');#}
{#            $('.tree').find(' > ul > li').each(function() {#}
{#                var t = $(this).find(' > .folder > .name');#}
{#                t.each(function(index) {#}
{#                   console.log($(this));#}
{#                });#}
{#            });#}
{#        });#}
    </script>
{% endblock %}
