{% extends "report/inventree_order_report_base.html" %}

{% load i18n %}
{% load report %}
{% load barcode %}
{% load inventree_extras %}
{% load markdownify %}

{% block header_content %}

    <div class='header-right'>
        <h3>{% trans "Transfer Order" %} {{ prefix }}{{ reference }}</h3>
        {{ order.take_from.pathstring }} → {{ order.destination.pathstring }}
    </div>

{% endblock header_content %}

{% block page_content %}

<h3>{% trans "Line Items" %}</h3>

<table class='table table-striped table-condensed'>
    <thead>
        <tr>
            <th>{% trans "Part" %}</th>
            <th>{% trans "Reference" %}</th>
            <th>{% trans "Quantity" %}</th>
            <th>{% trans "Transferred" %}</th>
            <th>{% trans "Note" %}</th>
        </tr>
    </thead>
    <tbody>
        {% for line in lines.all %}
        <tr>
            <td>
                <div class='thumb-container'>
                    <img src='{% part_image line.part height=240 %}' alt='{% trans "Part image" %}' class='part-thumb'>
                </div>
                <div class='part-text'>
                    {{ line.part.full_name }}
                </div>
            </td>
            <td>{{ line.reference }}</td>
            <td>{% decimal line.quantity %}</td>
            <td>{% decimal line.transferred %}</td>
            <td>{{ line.notes }}</td>
        </tr>
        {% endfor %}
    </tbody>
</table>

{% endblock page_content %}
