{% extends "layouts/source_user_base.html" %} {% load i18n %} {% block title %}{% trans "My Complaints" %} - {{ source.name_en }}{% endblock %} {% block content %}

{% trans "My Complaints" %} {{ complaints_count }}

{% trans "View all complaints from your source" %}

{% if source_user.can_create_complaints %} {% trans "Create Complaint" %} {% endif %}
{% for complaint in complaints %} {% empty %} {% endfor %}
{% trans "ID" %} {% trans "Title" %} {% trans "Patient" %} {% trans "Category" %} {% trans "Status" %} {% trans "Priority" %} {% trans "Assigned To" %} {% trans "Created" %} {% trans "Actions" %}
{{ complaint.id|slice:":8" }} {{ complaint.title|truncatewords:8 }} {% if complaint.patient %} {{ complaint.patient.get_full_name }}
{% trans "MRN" %}: {{ complaint.patient.mrn }} {% else %} {% trans "Not specified" %} {% endif %}
{{ complaint.get_category_display }} {% if complaint.status == 'open' %} {% trans "Open" %} {% elif complaint.status == 'in_progress' %} {% trans "In Progress" %} {% elif complaint.status == 'resolved' %} {% trans "Resolved" %} {% else %} {% trans "Closed" %} {% endif %} {% if complaint.priority == 'high' %} {% trans "High" %} {% elif complaint.priority == 'medium' %} {% trans "Medium" %} {% else %} {% trans "Low" %} {% endif %} {% if complaint.assigned_to %} {{ complaint.assigned_to.get_full_name }} {% else %} {% trans "Unassigned" %} {% endif %} {{ complaint.created_at|date:"Y-m-d" }}

{% trans "No complaints found for your source." %}

{% if source_user.can_create_complaints %} {% trans "Create Complaint" %} {% endif %}
{% if complaints.has_other_pages %} {% endif %}
{% endblock %}