{% extends "base.html" %} {% block contenido %}
{{ _("Comparativo de Ofertas") }}

{% if purchase_request %}{{ _("Solicitud de Compra:") }} {{ purchase_request.document_no or purchase_request.id }} ·{% else %} {{ _("Comparativo legacy sin Solicitud de Compra reconstruible") }} ·{% endif %} {{ _("Orden base:") }} {{ base_order.document_no or base_order.id }} · {{ _("Ofertas participantes: %(count)s", count=orders|length) }} {% if selected_round %} · {{ _("Ronda %(number)s (%(status)s)", number=selected_round.round_number, status=selected_round.status) }}{% endif %}

{% if rounds %}
{{ _("Histórico de rondas:") }} {% for round in rounds %} {{ _("Ronda %(number)s", number=round.round_number) }} · {{ round.status }} {% endfor %}
{{ _("Abrir nueva ronda") }}

{{ _("Seleccione explícitamente las órdenes que participarán. La ronda actual quedará cerrada e inmutable.") }}

{% for order in candidate_orders %}
{% endfor %}
{% endif %}
{% for order in orders %} {% endfor %} {% for row in comparison_rows %} {% for order in orders %} {% set offer = row.offers[order.id] %} {% endfor %} {% else %} {% endfor %}
{{ _("Comparación de líneas entre órdenes de compra participantes.") }}
{{ _("Artículo") }} {{ order.supplier_name or order.document_no or order.id }}{{ order.document_no or order.id }}
{{ row.item.item_name or row.item.item_code }}{{ row.item.item_code }} · {{ row.item.qty }} {{ row.item.uom or "" }} {% if offer %}{{ offer.rate or "0" }}{{ offer.qty }} · {{ offer.amount or "0" }}{% else %}{{ _("Sin cobertura") }}{% endif %}
{{ _("Las órdenes no tienen líneas para comparar.") }}
{% endblock %}