{% extends "manage/manage_base.html" %}
{% load i18n %}

{% block left_slot %}
    <div class="navigation-left-title">
        {% trans "Delivery times" %}
    </div>

    {% for delivery_time in delivery_times %}
        <div>
            <a href="{% url lfs_manage_delivery_time delivery_time.id %}"
               class="selectable {% ifequal delivery_time.id current_id %}selected{% endifequal %}">
                {{delivery_time.name}}
            </a>
        </div>
    {% endfor %}
{% endblock %}

{% block content %}

    <div class="site-actions">
        <a class="add" 
           href="{% url lfs_add_delivery_time %}">{% trans 'Add Delivery Time' %}</a>
        
        <a class="delete confirmation-link"
           data="{% trans 'Delete?' %}"
           href="{% url lfs_delete_delivery_time delivery_time.id %}">{% trans 'Delete Delivery Time' %}</a>
    </div>

    <div id="manage-tabs">
        
        <ul>
            <li class="ui-tabs-nav-item"><a href="#data">{% trans 'Core data' %}</a></li>            
        </ul>

        <div id="data">
            <h2>{% trans 'Delivery Time' %}</h2>
            <form action="{% url lfs_manage_delivery_time delivery_time.id %}"
                  method="post"
                  enctype="multipart/form-data">
                {% include "manage/lfs_form.html" %}
                <input type="submit"
                       value="{% trans 'Save Delivery Time' %}">
            </form>
        </div>
    </div>    
{% endblock %}