mirror of
https://github.com/inventree/InvenTree.git
synced 2025-06-15 11:35:41 +00:00
Improvements for stock item test result table
This commit is contained in:
@ -468,11 +468,7 @@ function formatDate(row) {
|
|||||||
var html = row.date;
|
var html = row.date;
|
||||||
|
|
||||||
if (row.user_detail) {
|
if (row.user_detail) {
|
||||||
html += `<span class='badge'>${row.user_detail.username}</span>`;
|
html += `<span class='badge badge-right rounded-pill bg-secondary'>${row.user_detail.username}</span>`;
|
||||||
}
|
|
||||||
|
|
||||||
if (row.attachment) {
|
|
||||||
html += `<a href='${row.attachment}'><span class='fas fa-file-alt float-right'></span></a>`;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return html;
|
return html;
|
||||||
@ -553,6 +549,15 @@ function loadStockTestResultsTable(table, options) {
|
|||||||
{
|
{
|
||||||
field: 'value',
|
field: 'value',
|
||||||
title: '{% trans "Value" %}',
|
title: '{% trans "Value" %}',
|
||||||
|
formatter: function(value, row) {
|
||||||
|
var html = value;
|
||||||
|
|
||||||
|
if (row.attachment) {
|
||||||
|
html += `<a href='${row.attachment}'><span class='fas fa-file-alt float-right'></span></a>`;
|
||||||
|
}
|
||||||
|
|
||||||
|
return html;
|
||||||
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
field: 'notes',
|
field: 'notes',
|
||||||
|
Reference in New Issue
Block a user