{% extends 'base.html' %} {% block title %}{{ order.order_number }}{% endblock %} {% block page_title %}{{ order.order_number }}{% endblock %} {% block topbar_actions %}
{% endblock %} {% block content %}| Embarcación | {{ order.vessel_name }} |
| Sistema | {{ order.system_name or '—' }} |
| Scope | {{ order.scope or '—' }} |
| Tipo | {{ order.work_type or '—' }} |
| Facturación | {% if order.billing_type == 'lump_sum' %} 💰 A todo costo {% elif order.billing_type == 'labor_only' %} 🔧 Solo M.O. {% else %} 📋 M.O. + Materiales {% endif %} |
| Técnico | {{ order.technician or '—' }} |
| Asignado a |
📨 {{ order.assigned_to }}
{% if order.assigned_by %} por {{ order.assigned_by }}{% endif %} |
| Fecha inicio | {{ order.start_date or '—' }} |
| Fecha fin | {{ order.end_date or '—' }} |
| H. Motor inicio | {{ order.engine_hours_start or '—' }} |
| Estado | {{ order.status.replace('_',' ') }} |
| Horas Trabajadas | {{ order.labor_hours or 0 }} h |
| Tarifa M.O. | ${{ order.labor_rate or 0 }}/h |
| Costo M.O. | ${{ "%.2f"|format(order.total_labor_cost or 0) }} |
| Costo Repuestos | ${{ "%.2f"|format(order.total_parts_cost or 0) }} |
| TOTAL | ${{ "%.2f"|format((order.total_labor_cost or 0) + (order.total_parts_cost or 0)) }} |
| Equipo | S/N | Trabajo Realizado | Notas | Horas | Costo M.O. | {% if order.status != 'completed' %}{% endif %} |
|---|---|---|---|---|---|---|
| {{ e.equip_name or '—' }} {{ e.make or '' }} {{ e.model or '' }} |
{{ e.serial_number or '—' }} | {{ e.description or '—' }} | {{ e.notes or '—' }} | {{ e.labor_hours or 0 }} h | ${{ "%.2f"|format((e.labor_hours or 0) * (e.labor_rate or 0)) }} | {% if order.status != 'completed' %}{% endif %} |
| TOTAL MANO DE OBRA | {{ wo_equipment|sum(attribute='labor_hours') or 0 }} h | ${{ "%.2f"|format(wo_equipment|sum(attribute='labor_cost') or 0) }} | {% if order.status != 'completed' %}{% endif %} | |||
Sin equipos agregados.
{% endif %}Sin fotos aún. Agrega evidencia fotográfica del trabajo.
{% endif %}| Repuesto | Descripción | Cantidad | Precio Unit. | Total |
|---|---|---|---|---|
| {{ p.part_name or '—' }}{% if p.part_number %} ({{ p.part_number }}){% endif %} | {{ p.description or '' }} | {{ p.quantity }} | ${{ "%.2f"|format(p.unit_cost) }} | ${{ "%.2f"|format(p.total_cost) }} |
Sin repuestos registrados.
{% endif %}| Fecha | Destinatario | Idioma | Estado | Enviado por | |
|---|---|---|---|---|---|
| {{ e.sent_at[:16] }} |
{{ e.to_name or '—' }}
{{ e.to_email }}
|
{{ e.lang.upper() }} |
{% if e.status == 'sent' %}
✅ Enviado
{% else %}
❌ Fallido
{% if e.error_msg %}
{{ e.error_msg[:80] }}{% if e.error_msg|length > 80 %}...{% endif %}
{% endif %}
{% endif %}
|
{{ e.sent_by or '—' }} | {% if e.pdf_filename %} 📄 {% else %}—{% endif %} |