mirror of
https://github.com/inventree/InvenTree.git
synced 2025-08-14 15:41:10 +00:00
Implement filtering which accommodates new inheritable BOM feature
- Can no longer filter bom_items by sub_part - Adds get_used_in_filter() and get_used_in() for part model (returns a query of other part objects)
This commit is contained in:
@@ -133,11 +133,18 @@
|
||||
<td>{% decimal on_order %}</td>
|
||||
</tr>
|
||||
{% endif %}
|
||||
{% if required > 0 %}
|
||||
{% if required_build_order_quantity > 0 %}
|
||||
<tr>
|
||||
<td><span class='fas fa-clipboard-list'></span></td>
|
||||
<td>{% trans "Required for Orders" %}</td>
|
||||
<td>{% decimal required %}
|
||||
<td>{% trans "Required for Build Orders" %}</td>
|
||||
<td>{% decimal required_build_order_quantity %}
|
||||
</tr>
|
||||
{% endif %}
|
||||
{% if required_sales_order_quantity > 0 %}
|
||||
<tr>
|
||||
<td><span class='fas fa-clipboard-list'></span></td>
|
||||
<td>{% trans "Required for Sales Orders" %}</td>
|
||||
<td>{% decimal required_sales_order_quantity %}
|
||||
</tr>
|
||||
{% endif %}
|
||||
{% if allocated > 0 %}
|
||||
|
@@ -22,10 +22,14 @@
|
||||
{% block js_ready %}
|
||||
{{ block.super }}
|
||||
|
||||
loadUsedInTable('#used-table', {
|
||||
part_detail: true,
|
||||
part_id: {{ part.pk }}
|
||||
});
|
||||
loadSimplePartTable('#used-table',
|
||||
'{% url "api-part-list" %}',
|
||||
{
|
||||
params: {
|
||||
uses: {{ part.pk }},
|
||||
}
|
||||
}
|
||||
);
|
||||
|
||||
|
||||
{% endblock %}
|
Reference in New Issue
Block a user