{% extends "base.html" %} {% block title %}Team Dashboard | Crystal Nexus{% endblock %} {% block header %}Team Dashboard{% endblock %} {% block content %}
Team under {{ current_user.name }} • {{ team_count }} member(s)
Team Structure Dashboard
{% if not team_rows %}
No team members assigned under you.
{% else %} {% if totals %}
Team Leads
{{ totals.kpi.lead_total }}
Team Clients (linked)
{{ totals.kpi.clients }}
Distinct clients from team leads
Verified Payments
{{ totals.kpi.payments.get('Verified', 0) }}
Pending: {{ totals.kpi.payments.get('Pending', 0) }} • Rejected: {{ totals.kpi.payments.get('Rejected', 0) }}
Outstanding (Quotes)
{{ totals.kpi.outstanding }}
{% endif %}
Team Members
{{ team_count }} member(s)
{% for r in team_rows %} {% endfor %}
User Leads Clients Verified Pending Rejected Outstanding
{{ r.user.name }} {{ r.user.email }}
{{ r.leads }} {{ r.clients }} {{ r.verified }} {{ r.pending }} {{ r.rejected }} {{ r.outstanding }}
• Clients = distinct Lead.client_id from leads owned by the user
• Outstanding = total quote amount (created by user) minus non-rejected collections
• Payments totals are based on payment_collections.created_by_id
{% endif %} {% endblock %}