2016-08-08 18:22:53 +00:00
{% extends 'schedule_base.html' %}
2017-02-08 22:34:24 +00:00
{% load dateutils %}
2016-08-04 21:03:39 +00:00
2016-08-08 18:22:53 +00:00
{% block schedule_content %}
2017-02-08 22:34:24 +00:00
< div class = "btn-group" >
2017-02-11 17:24:26 +00:00
< button type = "button" class = "btn btn-default dropdown-toggle" data-toggle = "dropdown" aria-haspopup = "true" aria-expanded = "false" >
2017-02-08 22:34:24 +00:00
Day: {% if urlyear %}{% get_weekday urlyear urlmonth urlday %}{% else %}All{% endif %} < span class = "caret" > < / span >
< / button >
< ul class = "dropdown-menu list-group" >
< a href = "{% url 'schedule_index' camp_slug=camp.slug %}{% if location and eventtype %}?location={{ location.slug }}&type={{ eventtype.slug }}{% elif location and not eventtype %}?location={{ location.slug }}{% elif eventtype and not location %}?type={{ eventtype.slug }}{% endif %}" class = "list-group-item{% if not urlyear %} active{% endif %}" >
All
< / a >
{% for day in camp.camp_days %}
{% with month_padded=day.lower.date|date:"m" day_padded=day.lower.date|date:"d" %}
{% url 'schedule_day' camp_slug=camp.slug year=day.lower.date.year month=month_padded day=day_padded as baseurl %}
< a href = "{{ baseurl }}{% if location and eventtype %}?location={{ location.slug }}&type={{ eventtype.slug }}{% elif location and not eventtype %}?location={{ location.slug }}{% elif eventtype and not location %}?type={{ eventtype.slug }}{% endif %}" class = "list-group-item{% if urlyear and urlyear|add:" 0 " = = day . lower . date . year and urlmonth = = month_padded and urlday = = day_padded % } active { % endif % } " >
{{ day.lower.date|date:"l" }}
< / a >
2017-01-23 22:58:41 +00:00
{% endwith %}
{% endfor %}
2017-02-08 22:34:24 +00:00
< / ul >
2017-01-23 22:58:41 +00:00
< / div >
2016-08-04 21:03:39 +00:00
2017-02-08 22:34:24 +00:00
< div class = "btn-group" >
2017-02-11 17:24:26 +00:00
< button type = "button" class = "btn btn-default dropdown-toggle" data-toggle = "dropdown" aria-haspopup = "true" aria-expanded = "false" >
2017-02-08 22:34:24 +00:00
Type: {% if eventtype %}< span style = "color: {{ eventtype.color }};" class = "glyphicon glyphicon-filter" aria-hidden = "true" > < / span > {% endif %}{% if eventtype %}{{ eventtype.name }}{% else %}All{% endif %} < span class = "caret" > < / span >
< / button >
< ul class = "dropdown-menu list-group" >
{% if not urlyear %}
{% url 'schedule_index' camp_slug=camp.slug as baseurl %}
{% else %}
{% url 'schedule_day' camp_slug=camp.slug year=urlyear month=urlmonth day=urlday as baseurl %}
{% endif %}
< a href = "{{ baseurl }}{% if location %}?location={{ location.slug }}{% endif %}" class = "list-group-item{% if not eventtype %} active{% endif %}" >
< span style = "color: {{ event_type.color }}" class = "glyphicon glyphicon-filter" aria-hidden = "true" > < / span > All
< / a >
{% for event_type in camp.event_types %}
{% if not urlyear %}
{% url 'schedule_index' camp_slug=camp.slug as baseurl %}
{% else %}
{% url 'schedule_day' camp_slug=camp.slug year=urlyear month=urlmonth day=urlday as baseurl %}
{% endif %}
< a href = "{{ baseurl }}?type={{ event_type.slug }}{% if location %}&location={{ location.slug }}{% endif %}" class = "list-group-item{% if eventtype and eventtype == event_type %} active{% endif %}" >
< span style = "color: {{ event_type.color }}" class = "glyphicon glyphicon-filter" aria-hidden = "true" > < / span > {{ event_type.name }}
< / a >
{% endfor %}
< / ul >
< / div >
2016-08-04 21:03:39 +00:00
2017-02-08 22:34:24 +00:00
< div class = "btn-group" >
2017-02-11 17:24:26 +00:00
< button type = "button" class = "btn btn-default dropdown-toggle" data-toggle = "dropdown" aria-haspopup = "true" aria-expanded = "false" >
2017-02-08 22:34:24 +00:00
Location: {% if location %}{{ location.name }}{% else %}All{% endif %} < span class = "caret" > < / span >
< / button >
< ul class = "dropdown-menu list-group" >
{% if not urlyear %}
< a href = "{% url 'schedule_index' camp_slug=camp.slug %}{% if eventtype %}?type={{ eventtype.slug }}{% endif %}" class = "list-group-item{% if not location %} active{% endif %}" > All< / a >
{% else %}
< a href = "{% url 'schedule_day' camp_slug=camp.slug year=urlyear month=urlmonth day=urlday %}{% if eventtype %}?type={{ eventtype.slug }}{% endif %}" class = "list-group-item{% if not location %} active{% endif %}" > All< / a >
{% endif %}
{% for loc in camp.event_locations %}
2017-01-23 22:58:41 +00:00
{% if not urlyear %}
2017-02-08 22:34:24 +00:00
< a href = "{% url 'schedule_index' camp_slug=camp.slug %}?location={{ loc.slug }}{% if eventtype %}&type={{ eventtype.slug }}{% endif %}" class = "list-group-item{% if location and location == loc%} active{% endif %}" > {{ loc.name }}< / a >
2017-01-23 22:58:41 +00:00
{% else %}
2017-02-08 22:34:24 +00:00
< a href = "{% url 'schedule_day' camp_slug=camp.slug year=urlyear month=urlmonth day=urlday %}?location={{ loc.slug }}{% if eventtype %}&type={{ eventtype.slug }}{% endif %}" class = "list-group-item{% if location and location == loc%} active{% endif %}" > {{ loc.name }}< / a >
2017-01-23 22:58:41 +00:00
{% endif %}
2017-02-08 22:34:24 +00:00
{% endfor %}
< / ul >
2017-01-23 22:58:41 +00:00
< / div >
2017-01-23 17:57:30 +00:00
< hr / >
2016-08-04 21:03:39 +00:00
{% block program_content %}
2016-08-08 18:22:53 +00:00
{% endblock program_content %}
2016-08-04 21:03:39 +00:00
2016-08-08 18:22:53 +00:00
{% endblock schedule_content %}