{% extends "base.html" %} {% load i18n static patient_tags %} {% block title %}{% trans "Dashboard" %} - {{ block.super }}{% endblock %} {% block content %}

{% trans "Dashboard" %}

{% trans "Welcome back" %}, {{ request.user.get_full_name }}

{% if LANGUAGE_CODE == 'ar' %}{{ request.tenant.name_ar }}{% else %}{{ request.tenant.name }}{% endif %}
{% include "includes/messages.html" %}
{% trans "Total Patients" %}
{{ stats.total_patients|default:0 }}
{% trans "Today's Appointments" %}
{{ stats.today_appointments|default:0 }}
{% trans "Patients in Queue" %}
{{ stats.queue_count|default:0 }}
{% trans "Active Employees" %}
{{ stats.active_employees|default:0 }}
{% trans "Today's Schedule" %}
{% trans "View Calendar" %}
{% if today_appointments %}
{% for apt in today_appointments|slice:":10" %} {% endfor %}
{% trans "Time" %} {% trans "Patient" %} {% trans "Service" %} {% trans "Provider" %} {% trans "Status" %}
{{ apt.start_time|time:"H:i" }} {% patient_name apt.patient %} {{ apt.service.name }} {{ apt.provider.first_name }} {{ apt.provider.last_name }} {{ apt.get_status_display }}
{% else %}

{% trans "No appointments scheduled for today." %}

{% endif %}
{% trans "Recent Encounters" %}
{% trans "View All" %}
{% if recent_encounters %} {% else %}

{% trans "No recent encounters." %}

{% endif %}
{% trans "Services Overview" %}
{% if service_stats %} {% for service in service_stats %}
{{ service.name }} {{ service.count }} {% trans "patients" %}
{% endfor %} {% else %}

{% trans "No service data available." %}

{% endif %}
{% trans "Pending Tasks" %}
{% if pending_referrals %}
{% trans "Pending Referrals" %} {{ pending_referrals }}
{% endif %} {% if unsigned_notes %}
{% trans "Unsigned Notes" %} {{ unsigned_notes }}
{% endif %} {% if pending_consents %}
{% trans "Pending Consents" %} {{ pending_consents }}
{% endif %} {% if not pending_referrals and not unsigned_notes and not pending_consents %}


{% trans "All tasks completed!" %}

{% endif %}
{% endblock %} {% block css %} {% endblock %}