{% extends "base.html" %} {% block title %}{{ 'Invoices' if doc_type == 'invoice' else 'Cotizaciones' }} — MarineInvoice Pro{% endblock %} {% block extra_css %} {% endblock %} {% block content %} {% set is_invoice = doc_type == 'invoice' %} {% set page_title = 'Invoices' if is_invoice else 'Cotizaciones' %} {% set icon = '📄' if is_invoice else '📋' %}

{{ icon }} {{ page_title }}

{{ 'Gestión de facturas' if is_invoice else 'Gestión de cotizaciones' }}

{% if docs %} {% for doc in docs %} {% set comp = doc.company %} {% set client = doc.client %}

{{ doc.number }} {% if doc.status == 'draft' %}Borrador {% elif doc.status == 'sent' %}Enviado {% elif doc.status == 'paid' %}Pagado {% elif doc.status == 'accepted' %}Aceptado {% elif doc.status == 'rejected' %}Rechazado {% elif doc.status == 'cancelled' %}Cancelado {% endif %} {{ doc.language|upper }} {% if doc.pdf_path %}💾 PDF{% endif %}

{{ comp.name if comp }} → {{ client.name if client }}{% if client and client.yacht_name %} ⛵{{ client.yacht_name }}{% endif %} · {{ doc.date }}

${{ "%.2f"|format(doc.total) }}

{% if doc.doc_type == 'invoice' and doc.status not in ['paid','cancelled'] %} {% endif %} {% if doc.pdf_path %} ⬇️ {% endif %} {% if doc.status == 'draft' or doc.status == 'sent' %} {% if is_invoice %} {% else %} {% endif %} {% endif %}
{% endfor %} {% else %}
{{ icon }}

No hay {{ page_title }}

Crea {{ 'tu primer invoice' if is_invoice else 'tu primera cotización' }}

{% endif %} {% endblock %} {% block scripts %} {% endblock %}