{% load i18n %}
{% load static %}
{% load humanize %}
{% load structures %}

<div class="modal-header">
    <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
    <h4 class="modal-title">{{ structure }}</h4>
</div>

<div class="modal-body">
    {% detail_title structure %}
    <br>

    <!-- Nav tabs -->
    <ul class="nav nav-tabs" role="tablist">
        <li role="presentation" class="active">
            <a href="#tab-poco-general" aria-controls="modules" role="tab" data-toggle="tab">
                {% translate "General" %}
            </a>
        </li>
        <li role="presentation">
            <a href="#tab-poco-reinforcement" aria-controls="access" role="tab" data-toggle="tab">
                {% translate "Reinforcement Time" %}
            </a>
        </li>
        <li role="presentation">
            <a href="#tab-poco-settings" aria-controls="settings" role="tab" data-toggle="tab">
                {% translate "Tax Rates & Access" %}
            </a>
        </li>
    </ul>

    <!-- Tab panes -->
    <div class="tab-content">
        <div role="tabpanel" class="tab-pane active" id="tab-poco-general">
            {% include "structures/modals/tab_general_detail.html" %}
        </div>

        <div role="tabpanel" class="tab-pane" id="tab-poco-reinforcement">
            <ul class="list-group">
                {% list_item _("Earliest") details.reinforce_exit_start_str %}
                {% list_item _("Latest") details.reinforce_exit_end_str %}
            </ul>
        </div>

        <div role="tabpanel" class="tab-pane" id="tab-poco-settings">
            <ul class="list-group">
                {% list_tax_item _("Corporation members") details.corporation_tax_rate True %}
                {% list_tax_item _("Alliance members") details.alliance_tax_rate details.allow_alliance_access %}
                {% list_tax_item _("Terrible standing") details.terrible_standing_tax_rate details.standing_level_access_map.TERRIBLE %}
                {% list_tax_item _("Bad standing") details.bad_standing_tax_rate details.standing_level_access_map.BAD %}
                {% list_tax_item _("Neutral standing") details.neutral_standing_tax_rate details.standing_level_access_map.NEUTRAL %}
                {% list_tax_item _("Good standing") details.good_standing_tax_rate details.standing_level_access_map.GOOD %}
                {% list_tax_item _("Excellent standing") details.excellent_standing_tax_rate details.standing_level_access_map.EXCELLENT %}
            </ul>
        </div>
    </div>

    <p class="text-muted">Last updated {{ last_updated|naturaltime|default:"?" }}</p>
</div>
