mirror of
https://github.com/inventree/InvenTree.git
synced 2025-08-14 15:41:10 +00:00
Calculate quantity required for sales orders
- Cache data going to part detail view
This commit is contained in:
@@ -126,28 +126,6 @@
|
||||
<td>{% trans "In Stock" %}</td>
|
||||
<td>{% include "part/stock_count.html" %}</td>
|
||||
</tr>
|
||||
{% if not part.is_template %}
|
||||
{% if part.required_build_order_quantity > 0 %}
|
||||
<tr>
|
||||
<td><span class='fas fa-hand-holding'></span></td>
|
||||
<td>{% trans "Required for Build Orders" %}</td>
|
||||
<td>{% decimal part.required_build_order_quantity %}</td>
|
||||
</tr>
|
||||
{% endif %}
|
||||
{% if part.build_order_allocation_count > 0 %}
|
||||
<tr>
|
||||
<td><span class='fas fa-dolly'></span></td>
|
||||
<td>{% trans "Allocated to Build Orders" %}</td>
|
||||
<td>{% decimal part.build_order_allocation_count %}</td>
|
||||
</tr>
|
||||
{% endif %}
|
||||
{% if part.sales_order_allocation_count > 0 %}
|
||||
<tr>
|
||||
<td><span class='fas fa-dolly'></span></td>
|
||||
<td>{% trans "Allocated to Sales Orders" %}</td>
|
||||
<td>{% decimal part.sales_order_allocation_count %}</td>
|
||||
</tr>
|
||||
{% endif %}
|
||||
{% if part.on_order > 0 %}
|
||||
<tr>
|
||||
<td><span class='fas fa-shopping-cart'></span></td>
|
||||
@@ -155,7 +133,21 @@
|
||||
<td>{% decimal part.on_order %}</td>
|
||||
</tr>
|
||||
{% endif %}
|
||||
{% if required > 0 %}
|
||||
<tr>
|
||||
<td><span class='fas fa-clipboard-list'></span></td>
|
||||
<td>{% trans "Required for Orders" %}</td>
|
||||
<td>{% decimal required %}
|
||||
</tr>
|
||||
{% endif %}
|
||||
{% if allocated > 0 %}
|
||||
<tr>
|
||||
<td><span class='fas fa-dolly'></span></td>
|
||||
<td>{% trans "Allocated to Orders" %}</td>
|
||||
<td>{% decimal allocated %}</td>
|
||||
</tr>
|
||||
{% endif %}
|
||||
|
||||
{% if not part.is_template %}
|
||||
{% if part.assembly %}
|
||||
<tr>
|
||||
@@ -169,11 +161,11 @@
|
||||
<td>{% trans "Can Build" %}</td>
|
||||
<td>{% decimal part.can_build %}</td>
|
||||
</tr>
|
||||
{% if part.quantity_being_built > 0 %}
|
||||
{% if quantity_being_built > 0 %}
|
||||
<tr>
|
||||
<td></td>
|
||||
<td>{% trans "Underway" %}</td>
|
||||
<td>{% decimal part.quantity_being_built %}</td>
|
||||
<td>{% decimal quantity_being_built %}</td>
|
||||
</tr>
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
|
Reference in New Issue
Block a user