{% extends "base.html" %} {% block title %}{{ order.order_number }}{% endblock %} {% block page_title %}{{ order.order_number }}{% endblock %} {% block page_subtitle %}{{ order.customer.name }} — {{ order.get_status_display }}{% endblock %} {% block content %} {% include "partials/breadcrumb.html" %}
{% if can_edit %} Edit Order {% endif %} Back to Orders

Customer Details

Name:
{{ order.customer.name }}
Mobile:
{{ order.customer.mobile_number }}
WhatsApp:
{{ order.customer.whatsapp_number|default:"—" }}
Alternate:
{{ order.customer.alternate_number|default:"—" }}
Address:
{{ order.customer.address|default:"—" }}

Order Info

Order Date:
{{ order.order_date|date:"d M Y" }}
Status:
{{ order.get_status_display }}
Expected Delivery:
{{ order.expected_delivery_date|date:"d M Y" }}
Payment Mode:
{{ order.get_payment_mode_display }}
Created:
{{ order.created_at|date:"d M Y, H:i" }}
Remarks:
{{ order.remarks|default:"—" }}

Order Items

{% for line in order.line_items.all %} {% endfor %}
ItemQtyUnit PriceLine Total
{{ line.item.item_name }} {{ line.quantity }} ₹{{ line.manual_price }} ₹{{ line.line_total }}

Subtotal

₹{{ order.subtotal }}

Discount

₹{{ order.discount_amount }}

Grand Total

₹{{ order.grand_total }}

Balance

₹{{ order.balance_amount }}

Payments

{% if can_manage_payments %} Add Payment {% endif %}

Grand Total

₹{{ order.grand_total }}

Total Paid

₹{{ order.total_paid }}

Balance

₹{{ order.balance_amount }}

Payment Status: {{ order.get_payment_status_display }}

{% if payments %}
{% for p in payments %} {% endfor %}
Payment #AmountModeDateReceived By
{{ p.payment_number }} ₹{{ p.amount_paid }} {{ p.get_payment_mode_display }} {{ p.payment_date|date:"d M Y" }} {{ p.received_by.get_full_name|default:p.received_by.username|default:"—" }}
{% else %}

No payments recorded yet.

{% endif %}

Invoice

{% if latest_bill %}
Bill Number:
{{ latest_bill.bill_number }}
Generated:
{{ latest_bill.generated_at|date:"d M Y, H:i" }}
WhatsApp Sent:
{% if latest_bill.sent_on_whatsapp %}Yes{% else %}No{% endif %}
{% else %}

No invoice generated yet.

{% endif %}
{% if can_manage_billing and not latest_bill %} Generate Invoice {% endif %} {% if latest_bill and can_view_billing %} Preview Invoice Download Invoice {% endif %}

Before-Cleaning Photos

{% if before_photos %}
{% for photo in before_photos %}
{{ photo.get_photo_type_display }}

{{ photo.get_photo_type_display }}

{{ photo.uploaded_at|date:"d M Y, H:i" }}

{% endfor %}
{% else %}

No before-cleaning photos uploaded yet.

{% endif %}

After-Cleaning Photos

{% if after_photos %}
{% for photo in after_photos %}
{{ photo.get_photo_type_display }}

{{ photo.get_photo_type_display }}

{{ photo.uploaded_at|date:"d M Y, H:i" }}

{% endfor %}
{% else %}

No after-cleaning photos uploaded yet.

{% endif %}
{% if can_view_ai %}

AI Damage Detection

AI assisted comparison of before and after cleaning photos. Manual verification recommended for any possible visible difference.

Upload After Cleaning Photos Generate AI Damage Report {% if ai_reports %} View AI Reports {% endif %}
{% if ai_reports %}

Latest AI Assisted Comparison Reports

{% for report in ai_reports %} {% endfor %}
Photo Type Similarity Status Difference Actions
{{ report.before_photo.get_photo_type_display|default:"—" }} {{ report.similarity_score }}% {% if report.status == 'no_damage' %} No Damage Detected {% elif report.status == 'possible_damage' %} Possible Damage {% else %} Manual Verification {% endif %} {% if report.difference_image %} Difference preview {% else %}—{% endif %} View Report
{% endif %}
{% endif %} {% if related_logs %}

Related Activity

{% endif %} {% endblock %}