{% extends "base_page.html" %} {% block title %}Monthly Attendance Control{% endblock %} {% block page_title %}Monthly Attendance Control{% endblock %} {% block content %}
Filter Options
Attendance Records {{ data.total_items }} found
Showing only weekdays (Monday-Friday)
{% if data.total_items > 0 %} {% if data.total_items > data.per_page %}
Total Employees Found: {{ data.total_items }}
Previous Page {{ data.current_page }} of {{ data.total_pages }} Next
{% endif %} {% if data.logs %}
{% for day in data.headers %} {% set day_date = data.current_year ~ '-' ~ '%02d'|format(current_selection.month) ~ '-' ~ '%02d'|format(day) %} {% set day_obj = day_date|string|str_to_date %} {% set is_week_start = day_obj.weekday() == 0 %} {% endfor %} {% for log in data.logs %} {% for day in data.headers %} {% set status_index = loop.index0 %} {% set status = log.days[status_index] %} {% set day_date = data.current_year ~ '-' ~ '%02d'|format(current_selection.month) ~ '-' ~ '%02d'|format(day) %} {% set day_obj = day_date|string|str_to_date %} {% set is_week_start = day_obj.weekday() == 0 %} {% endfor %} {% endfor %}
Employee
{{ day }}
{{ day_obj.strftime('%a') }}
{% if log.photo_path %} {{ log.name }} Photo {% else %}
{{ log.name[0].upper() }}
{% endif %} {{ log.name }}
{% if day_obj.weekday() >= 5 %} {% elif status == 'T' %} {% elif status == 'E' %} {% elif status == 'D' %} {% elif status == 'N' %} {% else %} {% endif %}
{% else %}
No Data Found

{% if current_selection.search %} No employees found matching "{{ current_selection.search }}" for {{ data.month_name }} {{ data.current_year }}. {% else %} No attendance data found for {{ data.month_name }} {{ data.current_year }}. {% endif %}

{% endif %} {% if data.total_items > data.per_page %}
Total Employees Found: {{ data.total_items }}
Previous Page {{ data.current_page }} of {{ data.total_pages }} Next
{% endif %}
{% endif %} {% endblock %}