{% extends "base.html" %}{% set active="dashboard" %}{% block title %}My Health Portal{% endblock %}{% block page_title %}My Health Portal{% endblock %} {% block content %}
Patient Portal

Hello, {{ patient.name.split()[0] if patient else session.user_name }} ๐Ÿ‘‹

{% if upcoming %}

Next appointment: {{ upcoming[0].appointment_datetime[:10] }} at {{ upcoming[0].appointment_datetime[11:16] }} with {{ upcoming[0].doctor_name }}.

{% else %}

No upcoming appointments scheduled.

{% endif %}
Upcoming
{{ stats.upcoming }}
๐Ÿ“…
Completed Visits
{{ stats.completed }}
โœ…
Total Appointments
{{ stats.total }}
๐Ÿ—“
๐Ÿ“… Upcoming Appointments
{% if upcoming %} {% for a in upcoming %}
{{ a.appointment_datetime[5:7] }}
{{ a.appointment_datetime[8:10] }}
{{ a.doctor_name }}
{{ a.specialization or '' }}
๐Ÿ• {{ a.appointment_datetime[11:16] }}{% if a.service_name %} ยท {{ a.service_name }}{% endif %}
{% endfor %} {% else %}
๐Ÿ“ญ

No upcoming appointments.

{% endif %}
๐Ÿ‘ค My Profile
{% for label, val in [('Full Name', patient.name),('Date of Birth', patient.dob or 'โ€”'),('Gender', patient.gender or 'โ€”'),('Email', patient.email),('Phone', patient.phone or 'โ€”'),('Insurance', patient.insurance_provider or 'โ€”')] %}
{{ label }}{{ val }}
{% endfor %}
๐Ÿ“‹ Visit History
{% if past %}
{% for a in past %}{% endfor %}
DateDoctorServiceStatusDiagnosisPrescriptionsFollow-up
{{ a.appointment_datetime[:10] }}{{ a.doctor_name }} {{ a.service_name or 'โ€”' }} {{ a.status }} {{ a.diagnosis or 'โ€”' }}{{ a.prescriptions or 'โ€”' }} {{ a.follow_up_date or 'โ€”' }}
{% else %}
๐Ÿฅ

No past visits on record.

{% endif %}
{% endblock %}