From c46f1534497a6869e6769df17545bd7814f69af5 Mon Sep 17 00:00:00 2001 From: Oliver Date: Sat, 25 Feb 2023 09:56:13 +1100 Subject: [PATCH] Bug fix for build detail template (#4412) - Remove reference to old expand/collapse templates (which no longer exist) - Update tables to use javascript buttons --- InvenTree/build/templates/build/detail.html | 5 ----- InvenTree/templates/js/translated/build.js | 3 ++- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/InvenTree/build/templates/build/detail.html b/InvenTree/build/templates/build/detail.html index f7d57b8288..3b0585d0c0 100644 --- a/InvenTree/build/templates/build/detail.html +++ b/InvenTree/build/templates/build/detail.html @@ -281,11 +281,6 @@ - {% if build.has_tracked_bom_items %} - {% include "expand_rows.html" with label="outputs" %} - {% include "collapse_rows.html" with label="outputs" %} - {% endif %} - {% include "filter_list.html" with id='incompletebuilditems' %} {% endif %} diff --git a/InvenTree/templates/js/translated/build.js b/InvenTree/templates/js/translated/build.js index 36c175a640..4ccc44968c 100644 --- a/InvenTree/templates/js/translated/build.js +++ b/InvenTree/templates/js/translated/build.js @@ -1217,10 +1217,10 @@ function loadBuildOutputTable(build_info, options={}) { setupBuildOutputButtonCallbacks(); }, onLoadSuccess: function(rows) { - updateAllocationData(rows); updateTestResultData(rows); }, + buttons: constructExpandCollapseButtons(table), columns: [ { title: '', @@ -1713,6 +1713,7 @@ function loadBuildOutputAllocationTable(buildInfo, output, options={}) { detailFilter: function(index, row) { return allocatedQuantity(row) > 0; }, + buttons: constructExpandCollapseButtons(table), detailFormatter: function(index, row, element) { // Contruct an 'inner table' which shows which stock items have been allocated