From 7e6c5fae625dbfe18ed2fdd998202be349ddbe4e Mon Sep 17 00:00:00 2001 From: Oliver Walters Date: Tue, 19 Nov 2019 10:39:40 +1100 Subject: [PATCH] Display units in part table --- InvenTree/InvenTree/static/script/inventree/part.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/InvenTree/InvenTree/static/script/inventree/part.js b/InvenTree/InvenTree/static/script/inventree/part.js index 0904c22a0d..8ad934760b 100644 --- a/InvenTree/InvenTree/static/script/inventree/part.js +++ b/InvenTree/InvenTree/static/script/inventree/part.js @@ -183,6 +183,11 @@ function loadPartTable(table, url, options={}) { sortable: true, formatter: function(value, row, index, field) { if (value) { + + if (row.units) { + value += ' ' + row.units + ''; + } + return renderLink(value, '/part/' + row.pk + '/stock/'); } else {