<div hx-get="{{ insert_tag('env::request') }}" hx-headers='{"VR-Ajax": "WaBookedModule"}' hx-trigger="updateWaBooking from:body" class="{{ class }} content-wrapper block"{{ cssID }}{% if style is defined and style is not empty %} style="{{ style }}"{% endif %}>

    {% block content %}
        {% if days is defined and days|length %}
            <div class="list">
                {% for day,bookings in days %}
                    <h3 class="toggler-dis">{{ day|date('d.m.Y') }}</h3>
                    <div class="accordion-dis">
                        <div class="bookings">
                            {% for booking in bookings %}
                                <div class="row">
                                    <div class="flex align-items-center">
                                        <div class="full half-500 third-900 time">
                                            <span class="title">Uhrzeit</span>
                                            {{ booking.slot.time|date('H:i') }}
                                        </div>
                                        <div class="full half-500 fourth-900 behaelter">
                                            <span class="title">Gebuchte Behälterkapazität</span>
                                            {{ booking.behaelter }}
                                        </div>
                                        <div class="full two-third-500 fourth-900 rebsorten">
                                            <span class="title">Anliefernde Sorten</span>
                                            {{ booking.sorte|join(', ') }}
                                        </div>
                                        <div class="full third-500 sixth-900 align-right action">
                                            <a hx-get="/_ajax/vr_wa/v1/slot?do=delete&id={{ booking.id }}" hx-target="body" hx-swap="beforeend" href="javascript:;" class="button error">Löschen</a>
                                            <a hx-get="/_ajax/vr_wa/v1/slot?do=booking&id={{ booking.id }}" hx-target="body" hx-swap="beforeend" href="javascript:;" class="button">Anzeigen</a>
                                        </div>
                                    </div>
                                </div>
                            {% endfor %}
                        </div>
                    </div>
                {% endfor %}
            </div>
        {% endif %}
    {% endblock %}

</div>