{% extends 'base.html' %}

{% block navbar %}
    {% with events_tab="active" %}
        {{ block.super }}
    {% endwith %}
{% endblock %}

{% block page_heading %}
Events
{% endblock %}

{% block content %}
    <ul class="list-group">
        {% for event in events%}
            {% if event.teamsnap_event.is_game %}
            <li class="list-group-item">
            <h6>{{ event.away_team|default_if_none:"" }} vs. {{ event.home_team|default_if_none:"" }}</h6>
            {{ event.start|date:"l, F j, Y g:i A" }} <br>
            {{ event.venue.name }} <br>
            <a href="{% url 'event' event_id=event.id %}">Edit Lineup...</a>
            </li>
            {% endif %}
        {% endfor %}
    </ul>
{% endblock %}
</html>