From 0a566c062dd5d0014772fb2e5af4edc4bd186756 Mon Sep 17 00:00:00 2001 From: Oliver Walters Date: Mon, 18 Jan 2021 21:36:37 +1100 Subject: [PATCH] Add click callback on item test tab --- InvenTree/stock/templates/stock/item_tests.html | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/InvenTree/stock/templates/stock/item_tests.html b/InvenTree/stock/templates/stock/item_tests.html index 11ab443d0c..e2ccf22037 100644 --- a/InvenTree/stock/templates/stock/item_tests.html +++ b/InvenTree/stock/templates/stock/item_tests.html @@ -50,14 +50,9 @@ function reloadTable() { //$("#test-result-table").bootstrapTable("refresh"); } -{% if item.part.has_test_report_templates %} +{% if item.has_test_reports %} $("#test-report").click(function() { - launchModalForm( - "{% url 'stock-item-test-report-select' item.id %}", - { - follow: true, - } - ); + printTestReports([{{ item.pk }}]); }); {% endif %}