{% extends "base.html" %} {% block title %}Exception Edit Invoice{% endblock %} {% block header %}Exception Edit Invoice{% endblock %} {% block content %}
Controlled Post-Issue Exception

{{ invoice.invoice_no }}

Edit only invoice presentation rows. Invoice subtotal, Quote and PI remain unchanged.
This invoice has already entered a statutory/accounting integration.
Saving here does not cancel, regenerate or overwrite the existing IRN or Tally voucher. After saving, update the affected systems manually and mark reconciliation completed below.
Required Subtotal
{{ invoice.currency or 'INR' }} {{ indian_amount(invoice.subtotal|float) }}
IRN
{{ 'Generated' if invoice.irn or invoice.einvoice_status == 'Generated' else 'Not Generated' }}
Tally
{{ invoice.tally_sync_status or 'Pending' }}
Exception Edits
{{ invoice.manual_item_edit_count or 0 }}
{% for item in items %} {% endfor %}
ServiceItem NameDescriptionQtyRateAmount
{{ indian_amount(item.amount|float) }}
Editor Total
{{ invoice.currency or 'INR' }} {{ indian_amount(invoice_items_subtotal|float) }}

{% if invoice.manual_item_edit_count %}
Manual Reconciliation
{% if invoice.manual_irn_reconciliation_status %}
IRN / E-Invoice
{% if invoice.manual_irn_reconciliation_status == 'Pending' %} Pending manual update
{% else %} Completed {% if invoice.manual_irn_reconciled_at %}
{{ invoice.manual_irn_reconciled_at.strftime('%d-%m-%Y %H:%M') }}
{% endif %} {% endif %}
{% endif %} {% if invoice.manual_tally_reconciliation_status %}
Tally
{% if invoice.manual_tally_reconciliation_status == 'Pending' %} Pending manual update
{% else %} Completed {% if invoice.manual_tally_reconciled_at %}
{{ invoice.manual_tally_reconciled_at.strftime('%d-%m-%Y %H:%M') }}
{% endif %} {% endif %}
{% endif %}
{% endif %} {% if audit_logs %}
Exception Edit History
{% for log in audit_logs %}
{{ log.edited_by.name if log.edited_by else 'User' }}
{{ log.reason }}
{{ log.created_at.strftime('%d-%m-%Y %H:%M') if log.created_at else '' }}
{% endfor %}
{% endif %}
{% endblock %}