mirror of
https://github.com/inventree/InvenTree.git
synced 2025-04-30 04:26:44 +00:00
Adds filter for "assigned stock" view on customer page
This commit is contained in:
parent
0a21512329
commit
46aeafb5da
@ -169,10 +169,10 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class='panel-content'>
|
<div class='panel-content'>
|
||||||
<div id='assigned-stock-button-toolbar'>
|
<div id='assigned-stock-button-toolbar'>
|
||||||
{% include "filter_list.html" with id="stock" %}
|
{% include "filter_list.html" with id="customerstock" %}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<table class='table table-striped table-condensed' id='assigned-stock-table' data-toolbar='#bassigned-stock-utton-toolbar'></table>
|
<table class='table table-striped table-condensed' id='assigned-stock-table' data-toolbar='#assigned-stock-button-toolbar'></table>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -225,6 +225,7 @@
|
|||||||
},
|
},
|
||||||
url: "{% url 'api-stock-list' %}",
|
url: "{% url 'api-stock-list' %}",
|
||||||
filterKey: "customerstock",
|
filterKey: "customerstock",
|
||||||
|
filterTarget: '#filter-list-customerstock',
|
||||||
});
|
});
|
||||||
|
|
||||||
{% if company.is_customer %}
|
{% if company.is_customer %}
|
||||||
|
@ -1468,7 +1468,7 @@ function loadStockTable(table, options) {
|
|||||||
|
|
||||||
var params = options.params || {};
|
var params = options.params || {};
|
||||||
|
|
||||||
var filterListElement = options.filterList || '#filter-list-stock';
|
var filterTarget = options.filterTarget || '#filter-list-stock';
|
||||||
|
|
||||||
var filters = {};
|
var filters = {};
|
||||||
|
|
||||||
@ -1484,7 +1484,7 @@ function loadStockTable(table, options) {
|
|||||||
original[k] = params[k];
|
original[k] = params[k];
|
||||||
}
|
}
|
||||||
|
|
||||||
setupFilterList(filterKey, table, filterListElement);
|
setupFilterList(filterKey, table, filterTarget);
|
||||||
|
|
||||||
// Override the default values, or add new ones
|
// Override the default values, or add new ones
|
||||||
for (var key in params) {
|
for (var key in params) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user