mirror of
https://github.com/inventree/InvenTree
synced 2024-08-30 18:33:04 +00:00
Merge remote-tracking branch 'inventree/master' into build-fixes
# Conflicts: # InvenTree/locale/de/LC_MESSAGES/django.mo # InvenTree/locale/de/LC_MESSAGES/django.po # InvenTree/locale/en/LC_MESSAGES/django.po # InvenTree/locale/es/LC_MESSAGES/django.po # InvenTree/templates/js/bom.js
This commit is contained in:
commit
90cfb3496a
@ -131,6 +131,13 @@ class SupplierPartList(generics.ListCreateAPIView):
|
|||||||
if part is not None:
|
if part is not None:
|
||||||
queryset = queryset.filter(part=part)
|
queryset = queryset.filter(part=part)
|
||||||
|
|
||||||
|
# Filter by 'active' status of the part?
|
||||||
|
active = params.get('active', None)
|
||||||
|
|
||||||
|
if active is not None:
|
||||||
|
active = str2bool(active)
|
||||||
|
queryset = queryset.filter(part__active=active)
|
||||||
|
|
||||||
return queryset
|
return queryset
|
||||||
|
|
||||||
def get_serializer(self, *args, **kwargs):
|
def get_serializer(self, *args, **kwargs):
|
||||||
|
@ -34,6 +34,9 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<div class='filter-list' id='filter-list-supplier-part'>
|
||||||
|
<!-- Empty div (will be filled out with available BOM filters) -->
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
Binary file not shown.
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -461,8 +461,8 @@ class PartList(generics.ListCreateAPIView):
|
|||||||
else:
|
else:
|
||||||
queryset = queryset.exclude(pk__in=starred_parts)
|
queryset = queryset.exclude(pk__in=starred_parts)
|
||||||
|
|
||||||
# Cascade?
|
# Cascade? (Default = True)
|
||||||
cascade = str2bool(params.get('cascade', None))
|
cascade = str2bool(params.get('cascade', True))
|
||||||
|
|
||||||
# Does the user wish to filter by category?
|
# Does the user wish to filter by category?
|
||||||
cat_id = params.get('category', None)
|
cat_id = params.get('category', None)
|
||||||
|
@ -15,7 +15,7 @@
|
|||||||
<table class='table table-striped'>
|
<table class='table table-striped'>
|
||||||
<col width='25'>
|
<col width='25'>
|
||||||
<tr>
|
<tr>
|
||||||
<td></td>
|
<td><span class='fas fa-font'></span></td>
|
||||||
<td><b>{% trans "Part name" %}</b></td>
|
<td><b>{% trans "Part name" %}</b></td>
|
||||||
<td>{{ part.name }}</td>
|
<td>{{ part.name }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
@ -28,7 +28,7 @@
|
|||||||
{% endif %}
|
{% endif %}
|
||||||
{% if part.revision %}
|
{% if part.revision %}
|
||||||
<tr>
|
<tr>
|
||||||
<td></td>
|
<td><span class='fas fa-code-branch'></span></td>
|
||||||
<td><b>{% trans "Revision" %}</b></td>
|
<td><b>{% trans "Revision" %}</b></td>
|
||||||
<td>{{ part.revision }}</td>
|
<td>{{ part.revision }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
@ -132,7 +132,9 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class='col-sm-6'>
|
<div class='col-sm-6'>
|
||||||
<table class='table table-striped'>
|
<table class='table table-striped'>
|
||||||
|
<col width='25'>
|
||||||
<tr>
|
<tr>
|
||||||
|
<td><span class='fas fa-ghost'%></span></td>
|
||||||
<td><b>{% trans "Virtual" %}</b></td>
|
<td><b>{% trans "Virtual" %}</b></td>
|
||||||
<td>{% include "slide.html" with state=part.virtual field='virtual' %}</td>
|
<td>{% include "slide.html" with state=part.virtual field='virtual' %}</td>
|
||||||
{% if part.virtual %}
|
{% if part.virtual %}
|
||||||
@ -142,6 +144,7 @@
|
|||||||
{% endif %}
|
{% endif %}
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
|
<td><span class='fas fa-clone'></span></td>
|
||||||
<td><b>{% trans "Template" %}</b></td>
|
<td><b>{% trans "Template" %}</b></td>
|
||||||
<td>{% include "slide.html" with state=part.is_template field='is_template' %}</td>
|
<td>{% include "slide.html" with state=part.is_template field='is_template' %}</td>
|
||||||
{% if part.is_template %}
|
{% if part.is_template %}
|
||||||
@ -151,6 +154,7 @@
|
|||||||
{% endif %}
|
{% endif %}
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
|
<td><span class='fas fa-tools'></span></td>
|
||||||
<td><b>{% trans "Assembly" %}</b></td>
|
<td><b>{% trans "Assembly" %}</b></td>
|
||||||
<td>{% include "slide.html" with state=part.assembly field='assembly' %}</td>
|
<td>{% include "slide.html" with state=part.assembly field='assembly' %}</td>
|
||||||
{% if part.assembly %}
|
{% if part.assembly %}
|
||||||
@ -160,6 +164,7 @@
|
|||||||
{% endif %}
|
{% endif %}
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
|
<td><span class='fas fa-th'></span></td>
|
||||||
<td><b>{% trans "Component" %}</b></td>
|
<td><b>{% trans "Component" %}</b></td>
|
||||||
<td>{% include "slide.html" with state=part.component field='component' %}</td>
|
<td>{% include "slide.html" with state=part.component field='component' %}</td>
|
||||||
{% if part.component %}
|
{% if part.component %}
|
||||||
@ -169,6 +174,7 @@
|
|||||||
{% endif %}
|
{% endif %}
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
|
<td><span class='fas fa-directions'></span></td>
|
||||||
<td><b>{% trans "Trackable" %}</b></td>
|
<td><b>{% trans "Trackable" %}</b></td>
|
||||||
<td>{% include "slide.html" with state=part.trackable field='trackable' %}</td>
|
<td>{% include "slide.html" with state=part.trackable field='trackable' %}</td>
|
||||||
{% if part.trackable %}
|
{% if part.trackable %}
|
||||||
@ -178,6 +184,7 @@
|
|||||||
{% endif %}
|
{% endif %}
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
|
<td><span class='fas fa-shopping-cart'></span></td>
|
||||||
<td><b>{% trans "Purchaseable" %}</b></td>
|
<td><b>{% trans "Purchaseable" %}</b></td>
|
||||||
<td>{% include "slide.html" with state=part.purchaseable field='purchaseable' %}</td>
|
<td>{% include "slide.html" with state=part.purchaseable field='purchaseable' %}</td>
|
||||||
{% if part.purchaseable %}
|
{% if part.purchaseable %}
|
||||||
@ -187,6 +194,7 @@
|
|||||||
{% endif %}
|
{% endif %}
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
|
<td><span class='fas fa-dollar-sign'></span></td>
|
||||||
<td><b>{% trans "Salable" %}</b></td>
|
<td><b>{% trans "Salable" %}</b></td>
|
||||||
<td>{% include "slide.html" with state=part.salable field='salable' %}</td>
|
<td>{% include "slide.html" with state=part.salable field='salable' %}</td>
|
||||||
{% if part.salable %}
|
{% if part.salable %}
|
||||||
@ -196,6 +204,13 @@
|
|||||||
{% endif %}
|
{% endif %}
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
|
<td>
|
||||||
|
{% if part.active %}
|
||||||
|
<span class='fas fa-check-square'></span>
|
||||||
|
{% else %}
|
||||||
|
<span class='fas fa-times-square'></span>
|
||||||
|
{% endif %}
|
||||||
|
</td>
|
||||||
<td><b>{% trans "Active" %}</b></td>
|
<td><b>{% trans "Active" %}</b></td>
|
||||||
<td>{% include "slide.html" with state=part.active field='active' disabled=False %}</td>
|
<td>{% include "slide.html" with state=part.active field='active' disabled=False %}</td>
|
||||||
{% if part.active %}
|
{% if part.active %}
|
||||||
|
@ -16,11 +16,18 @@
|
|||||||
<hr>
|
<hr>
|
||||||
|
|
||||||
<div id='button-toolbar'>
|
<div id='button-toolbar'>
|
||||||
<div class='btn-group'>
|
<div class='button-toolbar container-fluid'>
|
||||||
|
<div class='btn-group' role='group'>
|
||||||
{% if part.is_template and part.active %}
|
{% if part.is_template and part.active %}
|
||||||
<button class='btn btn-success' id='new-variant' title='{% trans "Create new variant" %}'>{% trans "New Variant" %}</button>
|
<button class='btn btn-success' id='new-variant' title='{% trans "Create new variant" %}'>
|
||||||
|
<span class='fas fa-plus-circle'></span> {% trans "New Variant" %}
|
||||||
|
</button>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
</div>
|
</div>
|
||||||
|
<div class='filter-list' id='filter-list-variants'>
|
||||||
|
<!-- Empty div (will be filled out with available BOM filters) -->
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<table class='table table-striped table-condensed' id='variants-table' data-toolbar='#button-toolbar'>
|
<table class='table table-striped table-condensed' id='variants-table' data-toolbar='#button-toolbar'>
|
||||||
|
@ -2099,7 +2099,7 @@ class BomItemCreate(AjaxCreateView):
|
|||||||
model = BomItem
|
model = BomItem
|
||||||
form_class = part_forms.EditBomItemForm
|
form_class = part_forms.EditBomItemForm
|
||||||
ajax_template_name = 'modal_form.html'
|
ajax_template_name = 'modal_form.html'
|
||||||
ajax_form_title = _('Create BOM item')
|
ajax_form_title = _('Create BOM Item')
|
||||||
|
|
||||||
role_required = 'part.add'
|
role_required = 'part.add'
|
||||||
|
|
||||||
|
@ -247,7 +247,7 @@ InvenTree | {% trans "Stock Item" %} - {{ item }}
|
|||||||
{% endif %}
|
{% endif %}
|
||||||
{% if item.batch %}
|
{% if item.batch %}
|
||||||
<tr>
|
<tr>
|
||||||
<td></td>
|
<td><span class='fas fa-layer-group'></span></td>
|
||||||
<td>{% trans "Batch" %}</td>
|
<td>{% trans "Batch" %}</td>
|
||||||
<td>{{ item.batch }}</td>
|
<td>{{ item.batch }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
@ -261,7 +261,7 @@ InvenTree | {% trans "Stock Item" %} - {{ item }}
|
|||||||
{% endif %}
|
{% endif %}
|
||||||
{% if item.purchase_order %}
|
{% if item.purchase_order %}
|
||||||
<tr>
|
<tr>
|
||||||
<td></td>
|
<td><span class='fas fa-shopping-cart'></span></td>
|
||||||
<td>{% trans "Purchase Order" %}</td>
|
<td>{% trans "Purchase Order" %}</td>
|
||||||
<td><a href="{% url 'po-detail' item.purchase_order.id %}">{{ item.purchase_order }}</a></td>
|
<td><a href="{% url 'po-detail' item.purchase_order.id %}">{{ item.purchase_order }}</a></td>
|
||||||
</tr>
|
</tr>
|
||||||
|
@ -150,17 +150,31 @@ function loadBomTable(table, options) {
|
|||||||
var url = `/part/${row.sub_part}/`;
|
var url = `/part/${row.sub_part}/`;
|
||||||
var html = imageHoverIcon(row.sub_part_detail.thumbnail) + renderLink(row.sub_part_detail.full_name, url);
|
var html = imageHoverIcon(row.sub_part_detail.thumbnail) + renderLink(row.sub_part_detail.full_name, url);
|
||||||
|
|
||||||
if (row.sub_part_detail.trackable) {
|
var sub_part = row.sub_part_detail;
|
||||||
html += `<span title='{% trans "Trackable part" %}' class='fas fa-directions label-right'></span>`;
|
|
||||||
|
if (sub_part.trackable) {
|
||||||
|
html += makeIconBadge('fa-directions', '{% trans "Trackable part" %}');
|
||||||
|
}
|
||||||
|
|
||||||
|
if (sub_part.virtual) {
|
||||||
|
html += makeIconBadge('fa-ghost', '{% trans "Virtual part" %}');
|
||||||
|
}
|
||||||
|
|
||||||
|
if (sub_part.is_template) {
|
||||||
|
html += makeIconBadge('fa-clone', '{% trans "Templat part" %}');
|
||||||
}
|
}
|
||||||
|
|
||||||
// Display an extra icon if this part is an assembly
|
// Display an extra icon if this part is an assembly
|
||||||
if (row.sub_part_detail.assembly) {
|
if (sub_part.assembly) {
|
||||||
var text = `<span title='{% trans "Open subassembly" %}' class='fas fa-stream label-right'></span>`;
|
var text = `<span title='{% trans "Open subassembly" %}' class='fas fa-stream label-right'></span>`;
|
||||||
|
|
||||||
html += renderLink(text, `/part/${row.sub_part}/bom/`);
|
html += renderLink(text, `/part/${row.sub_part}/bom/`);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!sub_part.active) {
|
||||||
|
html += `<span class='label label-warning label-right'>{% trans "Inactive" %}</span>`;
|
||||||
|
}
|
||||||
|
|
||||||
return html;
|
return html;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -110,7 +110,7 @@ function loadSupplierPartTable(table, url, options) {
|
|||||||
// Query parameters
|
// Query parameters
|
||||||
var params = options.params || {};
|
var params = options.params || {};
|
||||||
|
|
||||||
// Load 'user' filters
|
// Load filters
|
||||||
var filters = loadTableFilters("supplier-part");
|
var filters = loadTableFilters("supplier-part");
|
||||||
|
|
||||||
for (var key in params) {
|
for (var key in params) {
|
||||||
@ -122,6 +122,7 @@ function loadSupplierPartTable(table, url, options) {
|
|||||||
$(table).inventreeTable({
|
$(table).inventreeTable({
|
||||||
url: url,
|
url: url,
|
||||||
method: 'get',
|
method: 'get',
|
||||||
|
original: params,
|
||||||
queryParams: filters,
|
queryParams: filters,
|
||||||
name: 'supplierparts',
|
name: 'supplierparts',
|
||||||
groupBy: false,
|
groupBy: false,
|
||||||
@ -135,6 +136,7 @@ function loadSupplierPartTable(table, url, options) {
|
|||||||
sortable: true,
|
sortable: true,
|
||||||
field: 'part_detail.full_name',
|
field: 'part_detail.full_name',
|
||||||
title: '{% trans "Part" %}',
|
title: '{% trans "Part" %}',
|
||||||
|
switchable: false,
|
||||||
formatter: function(value, row, index, field) {
|
formatter: function(value, row, index, field) {
|
||||||
|
|
||||||
var url = `/part/${row.part}/`;
|
var url = `/part/${row.part}/`;
|
||||||
|
@ -61,13 +61,22 @@ function toggleStar(options) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
function loadPartVariantTable(table, partId, options) {
|
function loadPartVariantTable(table, partId, options={}) {
|
||||||
/* Load part variant table
|
/* Load part variant table
|
||||||
*/
|
*/
|
||||||
|
|
||||||
var params = {
|
var params = options.params || {};
|
||||||
ancestor: partId,
|
|
||||||
};
|
params.ancestor = partId;
|
||||||
|
|
||||||
|
// Load filters
|
||||||
|
var filters = loadTableFilters("variants");
|
||||||
|
|
||||||
|
for (var key in params) {
|
||||||
|
filters[key] = params[key];
|
||||||
|
}
|
||||||
|
|
||||||
|
setupFilterList("variants", $(table));
|
||||||
|
|
||||||
var cols = [
|
var cols = [
|
||||||
{
|
{
|
||||||
@ -104,16 +113,36 @@ function loadPartVariantTable(table, partId, options) {
|
|||||||
html += imageHoverIcon(row.thumbnail);
|
html += imageHoverIcon(row.thumbnail);
|
||||||
html += renderLink(name, `/part/${row.pk}/`);
|
html += renderLink(name, `/part/${row.pk}/`);
|
||||||
|
|
||||||
|
if (row.trackable) {
|
||||||
|
html += makeIconBadge('fa-directions', '{% trans "Trackable part" %}');
|
||||||
|
}
|
||||||
|
|
||||||
|
if (row.virtual) {
|
||||||
|
html += makeIconBadge('fa-ghost', '{% trans "Virtual part" %}');
|
||||||
|
}
|
||||||
|
|
||||||
|
if (row.is_template) {
|
||||||
|
html += makeIconBadge('fa-clone', '{% trans "Template part" %}');
|
||||||
|
}
|
||||||
|
|
||||||
|
if (row.assembly) {
|
||||||
|
html += makeIconBadge('fa-tools', '{% trans "Assembled part" %}');
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!row.active) {
|
||||||
|
html += `<span class='label label-warning label-right'>{% trans "Inactive" %}</span>`;
|
||||||
|
}
|
||||||
|
|
||||||
return html;
|
return html;
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
field: 'IPN',
|
field: 'IPN',
|
||||||
title: '{% trans 'IPN' %}',
|
title: '{% trans "IPN" %}',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
field: 'revision',
|
field: 'revision',
|
||||||
title: '{% trans 'Revision' %}',
|
title: '{% trans "Revision" %}',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
field: 'description',
|
field: 'description',
|
||||||
@ -133,7 +162,7 @@ function loadPartVariantTable(table, partId, options) {
|
|||||||
name: 'partvariants',
|
name: 'partvariants',
|
||||||
showColumns: true,
|
showColumns: true,
|
||||||
original: params,
|
original: params,
|
||||||
queryParams: params,
|
queryParams: filters,
|
||||||
formatNoMatches: function() { return "{% trans "No variants found" %}"; },
|
formatNoMatches: function() { return "{% trans "No variants found" %}"; },
|
||||||
columns: cols,
|
columns: cols,
|
||||||
treeEnable: true,
|
treeEnable: true,
|
||||||
@ -272,7 +301,7 @@ function loadPartTable(table, url, options={}) {
|
|||||||
if (options.checkbox) {
|
if (options.checkbox) {
|
||||||
columns.push({
|
columns.push({
|
||||||
checkbox: true,
|
checkbox: true,
|
||||||
title: '{% trans 'Select' %}',
|
title: '{% trans "Select" %}',
|
||||||
searchable: false,
|
searchable: false,
|
||||||
switchable: false,
|
switchable: false,
|
||||||
});
|
});
|
||||||
@ -286,8 +315,9 @@ function loadPartTable(table, url, options={}) {
|
|||||||
|
|
||||||
columns.push({
|
columns.push({
|
||||||
field: 'name',
|
field: 'name',
|
||||||
title: '{% trans 'Part' %}',
|
title: '{% trans "Part" %}',
|
||||||
sortable: true,
|
sortable: true,
|
||||||
|
switchable: false,
|
||||||
formatter: function(value, row, index, field) {
|
formatter: function(value, row, index, field) {
|
||||||
|
|
||||||
var name = '';
|
var name = '';
|
||||||
@ -310,20 +340,29 @@ function loadPartTable(table, url, options={}) {
|
|||||||
|
|
||||||
var display = imageHoverIcon(row.thumbnail) + renderLink(name, '/part/' + row.pk + '/');
|
var display = imageHoverIcon(row.thumbnail) + renderLink(name, '/part/' + row.pk + '/');
|
||||||
|
|
||||||
|
if (row.trackable) {
|
||||||
|
display += makeIconBadge('fa-directions', '{% trans "Trackable part" %}');
|
||||||
|
}
|
||||||
|
|
||||||
|
if (row.virtual) {
|
||||||
|
display += makeIconBadge('fa-ghost', '{% trans "Virtual part" %}');
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
if (row.is_template) {
|
if (row.is_template) {
|
||||||
display += `<span class='fas fa-clone label-right' title='{% trans "Template part" %}'></span>`;
|
display += makeIconBadge('fa-clone', '{% trans "Template part" %}');
|
||||||
}
|
}
|
||||||
|
|
||||||
if (row.assembly) {
|
if (row.assembly) {
|
||||||
display += `<span class='fas fa-tools label-right' title='{% trans "Assembled part" %}'></span>`;
|
display += makeIconBadge('fa-tools', '{% trans "Assembled part" %}');
|
||||||
}
|
}
|
||||||
|
|
||||||
if (row.starred) {
|
if (row.starred) {
|
||||||
display += `<span class='fas fa-star label-right' title='{% trans "Starred part" %}'></span>`;
|
display += makeIconBadge('fa-star', '{% trans "Starred part" %}');
|
||||||
}
|
}
|
||||||
|
|
||||||
if (row.salable) {
|
if (row.salable) {
|
||||||
display += `<span class='fas fa-dollar-sign label-right' title='{% trans "Salable part" %}'></span>`;
|
display += makeIconBadge('fa-dollar-sign', title='{% trans "Salable part" %}');
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@ -342,7 +381,7 @@ function loadPartTable(table, url, options={}) {
|
|||||||
columns.push({
|
columns.push({
|
||||||
sortable: true,
|
sortable: true,
|
||||||
field: 'description',
|
field: 'description',
|
||||||
title: '{% trans 'Description' %}',
|
title: '{% trans "Description" %}',
|
||||||
formatter: function(value, row, index, field) {
|
formatter: function(value, row, index, field) {
|
||||||
|
|
||||||
if (row.is_template) {
|
if (row.is_template) {
|
||||||
@ -356,7 +395,7 @@ function loadPartTable(table, url, options={}) {
|
|||||||
columns.push({
|
columns.push({
|
||||||
sortable: true,
|
sortable: true,
|
||||||
field: 'category_detail',
|
field: 'category_detail',
|
||||||
title: '{% trans 'Category' %}',
|
title: '{% trans "Category" %}',
|
||||||
formatter: function(value, row, index, field) {
|
formatter: function(value, row, index, field) {
|
||||||
if (row.category) {
|
if (row.category) {
|
||||||
return renderLink(value.pathstring, "/part/category/" + row.category + "/");
|
return renderLink(value.pathstring, "/part/category/" + row.category + "/");
|
||||||
|
@ -11,6 +11,28 @@ function getAvailableTableFilters(tableKey) {
|
|||||||
|
|
||||||
tableKey = tableKey.toLowerCase();
|
tableKey = tableKey.toLowerCase();
|
||||||
|
|
||||||
|
// Filters for "variant" table
|
||||||
|
if (tableKey == "variants") {
|
||||||
|
return {
|
||||||
|
active: {
|
||||||
|
type: 'bool',
|
||||||
|
title: '{% trans "Active" %}',
|
||||||
|
},
|
||||||
|
template: {
|
||||||
|
type: 'bool',
|
||||||
|
title: '{% trans "Template" %}',
|
||||||
|
},
|
||||||
|
virtual: {
|
||||||
|
type: 'bool',
|
||||||
|
title: '{% trans "Virtual" %}',
|
||||||
|
},
|
||||||
|
trackable: {
|
||||||
|
type: 'bool',
|
||||||
|
title: '{% trans "Trackable" %}',
|
||||||
|
},
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
// Filters for Bill of Materials table
|
// Filters for Bill of Materials table
|
||||||
if (tableKey == "bom") {
|
if (tableKey == "bom") {
|
||||||
return {
|
return {
|
||||||
@ -194,6 +216,15 @@ function getAvailableTableFilters(tableKey) {
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (tableKey == 'supplier-part') {
|
||||||
|
return {
|
||||||
|
active: {
|
||||||
|
type: 'bool',
|
||||||
|
title: '{% trans "Active parts" %}',
|
||||||
|
}
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
// Filters for the "Parts" table
|
// Filters for the "Parts" table
|
||||||
if (tableKey == "parts") {
|
if (tableKey == "parts") {
|
||||||
return {
|
return {
|
||||||
|
Loading…
Reference in New Issue
Block a user