{% extends "base.html" %} {% block title %}Operations KPI Dashboard{% endblock %} {% block header %}Operations KPI Dashboard{% endblock %} {% block content %}
Operations Performance

Operations KPI Dashboard

Every score can now be traced back to the employee, jobcard, assignment and workload formula used.
{{ filters.start_date.strftime('%d %b %Y') }} - {{ filters.end_date.strftime('%d %b %Y') }}{{ dashboard.totals.employees }} employees
Workload AnalyticsCapacity{% if current_user.has_perm('operations.kpi.master.manage') %}KPI Master{% endif %}
{% set t=dashboard.totals %}
{% for label,value,note in [('Employees',t.employees,'Scored employees'),('Average KPI',t.average_score ~ '%','Team average'),('Top Score',t.top_score ~ '%','Best performer'),('Above 90',t.employees_above_90,'Excellent'),('Below 60',t.employees_below_60,'Needs review')] %}
{{ label }}
{{ value }}
{{ note }}
{% endfor %}
KPI Formula
Current Weightage
Traceable to workload entries
{% for key,label in [('workload_achievement','Workload Achievement'),('on_time_completion','On-time Completion'),('capacity_utilisation','Capacity Utilisation'),('rework_control','Rework Control'),('qc_compliance','QC Compliance')] %}
{{ label }}
{{ dashboard.weights[key] }}%
{% endfor %}
Individual Performance

Employee KPI Scorecards

Open “View calculation” to see every jobcard and workload line.
{% for row in dashboard.rows %} {% set ring = '#16a34a' if row.score >= 90 else '#2563eb' if row.score >= 75 else '#d97706' if row.score >= 60 else '#dc2626' %}
{{ (row.name or 'U')[:2]|upper }}
{{ row.name }}
{{ row.designation or row.department or 'Operations' }} · {{ row.kpi_profile_name }}
{{ row.jobcard_count }} jobcards {{ row.assignment_count }} assignments{% if row.is_manager %} Manager · {{ row.team_size }} team{% endif %}
{{ row.score }}%
Final KPI
{% set metrics=[('Workload',row.workload_achievement_pct,row.kpi_weights.workload_achievement,row.weighted_components.workload_achievement,'blue'),('On-time',row.on_time_completion_pct,row.kpi_weights.on_time_completion,row.weighted_components.on_time_completion,'amber'),('Utilisation score',row.capacity_utilisation_score,row.kpi_weights.capacity_utilisation,row.weighted_components.capacity_utilisation,'purple'),('Rework control',row.rework_control_pct,row.kpi_weights.rework_control,row.weighted_components.rework_control,'red'),('QC compliance',row.qc_compliance_pct,row.kpi_weights.qc_compliance,row.weighted_components.qc_compliance,'green')] %} {% for title,actual,weight,earned,klass in metrics %}
{{ title }}
{{ actual }}%
Weight {{ weight }}%
Earned {{ earned }} / {{ weight }}
{% endfor %}
Assigned
{{ row.assigned_hours }} h
Completed
{{ row.completed_hours }} h
Capacity
{{ row.capacity_hours }} h
Actual utilisation
{{ row.capacity_utilisation_pct }}%
Remaining / Over
{% if row.over_capacity_hours > 0 %}+{{ row.over_capacity_hours }} h{% else %}{{ row.remaining_hours }} h{% endif %}
How this KPI is calculated: Workload = completed workload ÷ assigned workload. On-time = assignments completed within deadline ÷ completed assignments. Utilisation uses assigned workload against capacity, with 85–100% receiving the full utilisation component score. Rework and QC are calculated from the same assignments shown below.
{% for jc in row.jobcard_details %}
{% if jc.id %}{{ jc.code }}{% else %}{{ jc.code }}{% endif %}
{{ jc.client }} · {{ jc.status or '—' }}
{{ jc.hours }} h workload{{ jc.completed_assignments }}/{{ jc.assignments }} completed{{ jc.on_time_assignments }} on-time{% if jc.rework_hours > 0 %}{{ jc.rework_hours }} h rework{% endif %}
{% for d in jc.details %}{% endfor %}
AssignmentService / Workload MasterInputsFormulaEffortDeadline / CompletionKPI flags
#{{ d.assignment_id }}
{{ d.assignment_type }} · {{ d.assignment_status }}
{{ d.service }}
{{ d.application }} · {{ d.sow }} · {{ d.complexity }}{% if d.file_extension and d.file_extension != '-' %} · {{ d.file_extension }}{% endif %}
Qty: {{ d.quantity }} {{ d.unit_type }}
Base {{ d.base_quantity }} · {{ d.standard_minutes }} min/base
{{ d.calculation_rule }}
{{ d.calculated_hours }} h
{{ d.deadline.strftime('%d %b %Y %H:%M') if d.deadline else 'No deadline' }}
{{ d.completed_at.strftime('%d %b %Y %H:%M') if d.completed_at else 'Not completed' }}
{% if d.completed %}Completed{% else %}Open{% endif %}{% if d.completed and d.on_time %} On time{% elif d.completed %} Late{% endif %}{% if d.is_rework %} Rework{% endif %}{% if d.assignment_type == 'QC' %}
QC: {{ d.checklist_status or 'Pending' }}
{% endif %}
{% else %}
No workload entries found for this employee in the selected period.
{% endfor %}
{% else %}
No KPI data found for this period.
{% endfor %}
{% endblock %}