{% extends "base.html" %}{% load static %}
{% block title %} Edit Lineups {% endblock %}
{#{% block page_heading %}Edit Lineups{% endblock %}#}
{#{% block page_subheading %}{% endblock %}#}

{% block content %}
    {#    <div class="container overflow-scroll mx-0 px-0">#}
    {#        <div class="row flex-row flex-nowrap">#}
    {#            {% for event_data in contexts  %}#}
    {#                <div class="col border-start border-end">#}
    {#                    <div class = "border-bottom">#}
    {#                        <h4>{{ event_data.event.data.formatted_title }}</h4>#}
    {#                        <h6 class="text-muted" >{{ event_data.data.start_date }}</h6>#}
    {#                    </div>#}
    {#                    {% include 'teamsnap/lineup/widgets/lineup.html' with formset_lineup=event_data.formset_lineup formset_bench=event_data.formset_bench event_id=event_data.event.data.id  %}#}
    {#                </div>#}
    {#            {% endfor %}#}
    {#        </div>#}
    {#    </div>#}
    <div class="container overflow-scroll">
        <div class="row flex-row flex-nowrap">
            <table>
                <tbody>
                <tr class="align-top mx-1">
                    {% for event_data in contexts %}
                        <td class="px-1">
                            {% include "teamsnap/lineup/widgets/lineup.html" with event=event_data.event event_id=event_data.event.data.id formset=event_data.formset formset_startinglineup=event_data.formset_startinglineup formset_bench=event_data.formset_bench formset_out=event_data.formset_out formset_startingpositionalonly=event_data.formset_startingpositionalonly %}
                        </td>
                    {% endfor %}
                </tr>
                </tbody>
            </table>
        </div>
    </div>
    <script src="{% static 'js/Sortable.js' %}"></script>
<script src="{% static 'teamsnap/js/lineup-table.js' %}"></script>
{% endblock %}