{% extends "layout_report.html" %}
{% load static %}
{% load app_filters %}
{% load humanize %}
{% load tz %}
{% block content %}
{{ block.super }}
Receiver
Class
Group
Item
Trans Date
Reference/Status
Consumed
{% regroup rw_list by line as line_list %}
{% for line in line_list %}
Line: {{ line.grouper }}
{% if qstr.sort_by == 'reference' %}
{% regroup line.list by reference as job_list %}
{% for job in job_list %}
{% for txn in job.list %}
{{ txn.receiver }}
{{ txn.receiver.inv_class_id }}
{{ txn.receiver.group_id }}
{{ txn.receiver.item.name }}
{{ txn.transaction_date | date:"m/d/y" }}
{{ txn.reference }}/{{ txn.job_status }}
{{ txn.consumed | floatformat:'0' | intcomma }}
{% endfor %}
Total Consumed for Job:
{{ job.list | item_total_consumed | floatformat:'0' | intcomma }}
{% endfor %}
{% else %}
{% regroup line.list by receiver.group_id as group_list %}
{% for group in group_list %}
{% for txn in group.list %}
{{ txn.receiver }}
{{ txn.receiver.inv_class_id }}
{{ txn.receiver.group_id }}
{{ txn.receiver.item.name }}
{{ txn.transaction_date | date:"m/d/y" }}
{{ txn.reference }}/{{ txn.job_status }}
{{ txn.consumed | floatformat:'0' | intcomma }}
{% endfor %}
Total Consumed for Group:
{{ group.list | item_total_consumed | floatformat:'0' | intcomma }}
{% endfor %}
{% endif %}
Total Consumed for Line: {{ line.grouper }}
{{ line.list | item_total_consumed | floatformat:'0' | intcomma }}
{% endfor %}
{% endblock content %}
{% block body_scripts %}
{{ block.super }}
{% endblock body_scripts %}