{% extends "layout.html" %}

{% block app_content %}

<h1>Welcome back, {{ current_user.first_name }}!</h1>

{% if events %}

<p>The following events are available for check-in:</p>
{% for e in events %}
<h5>{{ e.name }} <a class="btn btn-primary" href="{{ url_for('dashboard.checkin', event_id=e.id)
        }}">Check in</a></h5>
{% endfor %}
{% else %}
<p>There are no events available for check-in.</p>
{% endif %}

<hr/>

<p>For a list of upcoming events, take a look at our <a href="{{
                                                              url_for('main.events')
                                                              }}">events
                                                              listing</a>.
                                                          Otherwise, there's not
                                                          a whole lot here
                                                          unless you're an
                                                          officer!</p>
    
{% endblock app_content %}
