{% extends "layouts/base.html" %} {% load i18n %} {% load static %} {% block title %}{% trans "Review Import Summary" %} - PX360{% endblock %} {% block content %}

{% trans "Review Import Summary" %}

{{ hospital.name }}

{% if errors %}

{% trans "Import Errors" %} ({{ errors|length }})

{% for error in errors %}

{{ error }}

{% endfor %}
{% endif %}
{% csrf_token %}

{% trans "Total Records" %}

{{ total_count|default:"0" }}

{% trans "New Patients" %}

{{ new_count|default:"0" }}

{% trans "Will be created" %}

{% trans "Existing Patients" %}

{{ existing_count|default:"0" }}

{% trans "Will be updated" %}

{% trans "With Mobile" %}

{{ has_mobile|default:"0" }}

{% if missing_mobile > 0 %}

{{ missing_mobile }} {% trans "missing mobile" %}

{% else %}

{% trans "All have mobile" %}

{% endif %}

{% trans "Visit Types" %}

{% for visit_type, count in visit_types %}
{% if visit_type == "EMERGENCY" or visit_type == "Emergency" %} {% elif visit_type == "INPATIENT" or visit_type == "Inpatient" %} {% elif visit_type == "OUTPATIENT" or visit_type == "Outpatient" %} {% else %} {% endif %} {{ visit_type }}
{{ count }}
{% empty %}

{% trans "No visit type data available" %}

{% endfor %}

{% trans "Sample Preview" %}

{% trans "Showing" %} {{ sample_count }} {% trans "of" %} {{ total_count }}
{% for patient in sample_patients %} {% empty %} {% endfor %}
{% trans "File Number" %} {% trans "Patient Name" %} {% trans "Visit Type" %} {% trans "Status" %}
{{ patient.file_number }}
{{ patient.patient_name }}
{% if patient.visit_type == 'EMERGENCY' %} {{ patient.visit_type|default:"-" }} {% elif patient.visit_type == 'INPATIENT' %} {{ patient.visit_type|default:"-" }} {% elif patient.visit_type %} {{ patient.visit_type }} {% else %} - {% endif %} {% if patient.exists %} {% trans "Exists" %} {% else %} {% trans "New" %} {% endif %}

{% trans "No patients found in import data." %}

{% if total_count > sample_count %}

... {% trans "and" %} {{ total_count|add:"-"|add:sample_count }} {% trans "more records" %}

{% endif %}

{% trans "Ready to Import" %}

{% trans "All" %} {{ total_count }} {% trans "records will be processed. New patients will be created and existing ones updated." %}

{% endblock %}