Dashboard
{%- comment -%} =============== THIS IS WHERE THE SWAPPER WILL LIVE =============== {%- endcomment -%}
Resources
Live Events
{% assign completedCourseFound = false %}
{% if courses.enrolled.any? %}
{% for course in courses.enrolled %}
{% if course.progress == 100 %}
{% assign completedCourseFound = true %}
{% endif %}
{% endfor %}
{% endif %}
{% if completedCourseFound %}
Completed
{% endif %}
{%- comment -%} =============== THIS IS WHERE THE PRODUCT FILTER WILL LIVE =============== {%- endcomment -%}
{% include "filter_by_product", page: 'Dashboard' %}
{% assign ipCourseFound = false %}
{% if courses.enrolled.any? %}
{% for course in courses.enrolled %}
{% if course.progress > 0 and course.progress < 100 %}
{% assign ipCourseFound = true %}
{% endif %}
{% endfor %}
{% endif %}
{% if ipCourseFound %}
{% include "courses_index_in_prog", outerClass: "dashboard-courses-index" %}
{% endif %}
{%- comment -%} {% if courses.enrolled.any? %}
{% include "courses_index", outerClass: "dashboard-courses-index" %}
{% else %}
{% capture message %}
{% t shared.zero_state.courses.index,
key: current_school.course_vocabulary
%}
{% endcapture %}
{% include "courses_zero_state", message: message %}
{% endif %} {%- endcomment -%}
{% include "training_events_index" %}
{% assign completedCourseFound = false %}
{% if courses.enrolled.any? %}
{% for course in courses.enrolled %}
{% if course.progress == 100 %}
{% assign completedCourseFound = true %}
{% endif %}
{% endfor %}
{% endif %}
{% if completedCourseFound %}
{% include "courses_index_completed", outerClass: "dashboard-courses-index" %}
{% endif %}