{# Product name + code #}
{{ f.name }}
{{ f.code }}
{% if not f.has_bom %}
No BOM
{% else %}
{{ f.eff_label }}
{% endif %}
{# Qty produced #}
Qty Produced:
{{ f.produced_qty|floatformat:4|intcomma }}
units
{% if f.has_bom %}
{# Cost rows #}
| Actual Cost |
Rs. {{ f.actual_cost|floatformat:2|intcomma }}
|
| BOM Std Cost |
Rs. {{ f.std_cost|floatformat:2|intcomma }} |
| Per Unit (actual) |
Rs. {{ f.actual_unit_cost|floatformat:4 }} |
| Per Unit (BOM std) |
Rs. {{ f.std_unit_cost|floatformat:4 }} |
| Variance |
{% if f.variance > 0 %}+{% endif %}Rs. {{ f.variance|floatformat:2|intcomma }}
({% if f.variance_pct > 0 %}+{% endif %}{{ f.variance_pct|floatformat:2 }}%)
|
| Cost Share |
{{ f.cost_share|floatformat:2 }}% of dept
|
{# Efficiency bar #}
Efficiency
{{ f.efficiency|floatformat:1 }}%
{% with eff_w=f.efficiency %}
{% endwith %}
0%
100% (BOM std)
{# BOM breakdown — collapsible #}
BOM detail
| Raw Material |
Qty/Unit |
Avg Rate |
Std Cost |
{% for bl in f.bom_lines %}
{{ bl.raw_name }}
{{ bl.raw_code }}
|
{{ bl.qty_per_unit|floatformat:4 }} |
{{ bl.avg_unit_cost|floatformat:4 }} |
{{ bl.std_cost|floatformat:4 }} |
{% empty %}
| No BOM lines. |
{% endfor %}
| Total Std Cost / Unit |
{{ f.bom_unit_cost|floatformat:4 }} |
{% else %}
{# No BOM #}
Is product ka BOM define nahi hua — cost allocation nahi ho sakti.
{% endif %}