2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-07-01 11:10:54 +00:00

Adds a button to quickly "pass" a test

This commit is contained in:
Oliver
2022-02-16 17:16:17 +11:00
parent 6c32f5c60d
commit 0f0325daba
2 changed files with 26 additions and 0 deletions

View File

@ -311,6 +311,27 @@
});
});
$('#test-result-table').on('click', '.button-test-tick', function() {
var button = $(this);
var test_name = button.attr('pk');
inventreePut(
'{% url "api-stock-test-result-list" %}',
{
test: test_name,
result: true,
stock_item: {{ item.pk }},
},
{
method: 'POST',
success: function(response) {
reloadTable();
}
}
);
})
$("#test-result-table").on('click', '.button-test-add', function() {
var button = $(this);