{% extends 'base.html' %} {% load static %} {% block title %}Donor Details - {{ donor.full_name }}{% endblock %} {% block extra_css %} {% endblock %} {% block content %}

Donor Details {{ donor.full_name }} ({{ donor.donor_id }})

Donor Information

{{ donor.full_name }}

{{ donor.donor_id }}

Blood Group: {{ donor.blood_group.display_name }}
Age: {{ donor.age }} years
Gender: {{ donor.get_gender_display }}
Weight: {{ donor.weight }} kg
Height: {{ donor.height }} cm
Status: {% if donor.status == 'active' %} {{ donor.get_status_display }} {% elif donor.status == 'deferred' %} {{ donor.get_status_display }} {% elif donor.status == 'permanently_deferred' %} {{ donor.get_status_display }} {% else %} {{ donor.get_status_display }} {% endif %}
Donor Type: {{ donor.get_donor_type_display }}

Contact Information
Phone: {{ donor.phone }}
Email: {{ donor.email|default:"Not provided" }}
Address: {{ donor.address }}

Emergency Contact
Name: {{ donor.emergency_contact_name }}
Phone: {{ donor.emergency_contact_phone }}
{% if donor.notes %}
Notes

{{ donor.notes }}

{% endif %}

Donation Statistics

TOTAL DONATIONS

{{ donor.total_donations }}

LAST DONATION

{% if donor.last_donation_date %} {{ donor.last_donation_date|date:"M d, Y" }} {% else %} Never {% endif %}

NEXT ELIGIBLE

{{ donor.next_eligible_date|date:"M d, Y" }}

ELIGIBILITY

{% if donor.is_eligible_for_donation %}Eligible{% else %}Not Eligible{% endif %}

Donation History

{% if donor.is_eligible_for_donation %} New Donation {% endif %}
{% if blood_units %}
{% for unit in blood_units %} {% endfor %}
Unit Number Component Collection Date Volume (ml) Status Expiry Date Location Actions
{{ unit.unit_number }} {{ unit.component.get_name_display }} {{ unit.collection_date|date:"M d, Y H:i" }} {{ unit.volume_ml }} {% if unit.status == 'available' %} {{ unit.get_status_display }} {% elif unit.status == 'expired' %} {{ unit.get_status_display }} {% elif unit.status == 'transfused' %} {{ unit.get_status_display }} {% else %} {{ unit.get_status_display }} {% endif %} {{ unit.expiry_date|date:"M d, Y" }} {% if unit.days_to_expiry <= 3 and unit.status == 'available' %} Expiring Soon {% endif %} {{ unit.location }}
{% else %}
No Donation History

This donor has not made any donations yet.

{% if donor.is_eligible_for_donation %} Start First Donation {% endif %}
{% endif %}
Back to Donors
{% if donor.is_eligible_for_donation %} Check Eligibility {% endif %} Edit Donor
{% endblock %} {% block extra_js %} {% endblock %}