{% extends "base.html" %} {% block title %}Case Details - Vera Medical CRM{% endblock %} {% block content %}

Case Details

Case #{{ case['file_case_id'] or case['record_id'] }}

Case Information

Record ID

{{ case['record_id'] }}

File Case ID

{{ case['file_case_id'] or 'N/A' }}

Assessment Type

{{ case['assessment_type'] or 'N/A' }}

Status

{% if case['file_close_date'] %} Closed {% else %} Active {% endif %}

File Open Date

{{ case['file_open_date']|format_date }}

File Close Date

{{ case['file_close_date']|format_date }}

Date of Loss

{{ case['date_of_loss']|format_date }}

Client File #

{{ case['client_file_number'] or 'N/A' }}

{% if case['case_notes'] %}

Case Notes

{{ case['case_notes'] }}

{% endif %}
{% if claimant %}

Claimant Information

Full Name

{{ claimant['title'] or '' }} {{ claimant['first_name'] }} {{ claimant['last_name'] }}

Date of Birth

{{ claimant['date_of_birth']|format_date }}

{% if claimant['gender'] %}

Gender

{{ claimant['gender'] }}

{% endif %}

Email

{{ claimant['email'] or 'N/A' }}

Address

{{ claimant['address'] or 'N/A' }}
{{ claimant['city'] }}, {{ claimant['province'] }} {{ claimant['postal_code'] }}

Home Phone

{{ claimant['home_phone']|format_phone }}

Cell Phone

{{ claimant['cel_phone']|format_phone }}

{% if name_history and name_history|length > 0 %}

Last Name History

{{ name_history|length }} change(s)
{% for change in name_history %}
{{ change['old_last_name'] }} {{ change['new_last_name'] }}
{{ change['changed_date']|format_date }} {% if change['changed_by'] %} {{ change['changed_by'] }} {% endif %}
{% if change['notes'] %}

{{ change['notes'] }}

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

Appointments ({{ appointments|length }})

Add Appointment
{% if appointments %}
{% for appointment in appointments %}

{% if appointment['appointment_date'] %} {{ appointment['appointment_date']|format_date }} {% else %} Date Not Set {% endif %}

{% if appointment['appointment_time'] %}

{{ appointment['appointment_time'] }}

{% endif %} {% if appointment['reference'] %}

Reference: {{ appointment['reference'] }}

{% endif %}
{% if appointment['assessment_type'] %} {{ appointment['assessment_type'] }} {% endif %}
{% if appointment['doctor_name'] %}

Doctor

{{ appointment['doctor_name'] }}

{% endif %} {% if appointment['service_code'] %}

Service Code

{{ appointment['service_code'] }}

{% endif %} {% if appointment['date_confirmed'] %}

Date Confirmed

{{ appointment['date_confirmed']|format_date }}

{% endif %} {% if appointment['date_received'] %}

Date Received

{{ appointment['date_received']|format_date }}

{% endif %} {% if appointment['date_released'] %}

Date Released

{{ appointment['date_released']|format_date }}

{% endif %}
{% if appointment['notes'] %}

Appointment Notes

{{ appointment['notes'] }}

{% endif %}
Status: {% if appointment['status'] == 'cancelled' %} Cancelled {% elif appointment['status'] == 'completed' %} Completed {% else %} {{ appointment['status']|capitalize }} {% endif %}
View Edit {% if appointment['status'] != 'cancelled' %}
{% endif %}
{% endfor %}
{% else %}

No appointments scheduled for this case

Click the button above or below to add an appointment

Add First Appointment
{% endif %}

Reports ({{ (reports|length if reports else 0) + (case_reports|length if case_reports else 0) }})

{% if (reports and reports|length > 0) or (case_reports and case_reports|length > 0) %}
{% if case_reports %} {% for report in case_reports %}

{{ report['file_name'] }}

{% if report['report_type'] %}
Type: {{ report['report_type'] }}
{% endif %} {% if report['report_date'] %}
Date: {{ report['report_date']|format_date }}
{% endif %}
Status: {% if report['status'] == 'final' %} Final {% elif report['status'] == 'sent' %} Sent {% else %} Draft {% endif %}
Uploaded: {{ report['uploaded_at']|format_datetime if report['uploaded_at'] else 'N/A' }}
{% if report['notes'] %}

{{ report['notes'] }}

{% endif %}
{% endfor %} {% endif %} {% if reports %} {% for report in reports %}

{{ report['report_title'] }}

Type: {{ report['report_type'] or 'N/A' }}
Date: {{ report['report_date']|format_date if report['report_date'] else 'N/A' }}
Status: {% if report['status'] == 'final' %} Final {% elif report['status'] == 'sent' %} Sent {% else %} Draft {% endif %}
{% if report['form_template'] %}
Template: {{ report['form_template'] }}
{% endif %}
{% if report['description'] %}

{{ report['description'] }}

{% endif %}
{% if report['form_html_content'] %} {% endif %} {% if report['file_path'] %} {% endif %}
{% endfor %} {% endif %}
{% else %}

No reports for this case

{% endif %}

Invoices ({{ invoices|length }})

{% if invoices %}
{% for invoice in invoices %}

{{ invoice['invoice_number'] }}

{% if invoice['status'] == 'paid' %} Paid {% elif invoice['status'] == 'sent' %} Sent {% elif invoice['status'] == 'overdue' %} Overdue {% elif invoice['status'] == 'draft' %} Draft {% endif %}
Invoice Date: {{ invoice['invoice_date'] }}
Service Date: {{ invoice['service_date'] or 'N/A' }}
Service Code: {{ invoice['service_code'] or 'N/A' }}
Amount: ${{ "%.2f"|format(invoice['total_amount']) }} CAD
{% if invoice['appointment_id'] %} {% endif %}
{% if invoice['notes'] %}

Notes: {{ invoice['notes'] }}

{% endif %}
{% endfor %}
{% else %}

No invoices for this case

Create an invoice from an appointment or manually

{% endif %}
{% if client %}

Client

{{ client['company_name'] }}

{{ client['city'] }}, {{ client['province'] }}

{% endif %} {% if client_contact %}

Adjuster

{{ client_contact['first_name'] }} {{ client_contact['last_name'] }}

{% if client_contact['title'] %}

{{ client_contact['title'] }}

{% endif %} {% if client_contact['phone'] %}

{{ client_contact['phone']|format_phone }}

{% endif %}
{% endif %} {% if lawyer_firm %}

Law Firm

{{ lawyer_firm['firm_name'] }}

{{ lawyer_firm['city'] }}, {{ lawyer_firm['province'] }}

{% if lawyer_firm['phone'] %}

{{ lawyer_firm['phone']|format_phone }}

{% endif %}
{% if lawyer_contact %}

Attorney

{{ lawyer_contact['first_name'] }} {{ lawyer_contact['last_name'] }}

{% endif %}
{% endif %}
{% endblock %}