2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-06-18 13:05:42 +00:00

Stock transfer same location (#4757)

* Allow stock items to be transferred into the same location

* Add new code when moving into same location

* Update unit test

* Further unit test fixes
This commit is contained in:
Oliver
2023-05-05 12:55:31 +10:00
committed by GitHub
parent e7317522a6
commit c45e66935a
4 changed files with 20 additions and 13 deletions

View File

@ -2648,13 +2648,13 @@ function loadStockTrackingTable(table, options) {
field: 'deltas',
title: '{% trans "Details" %}',
formatter: function(details, row) {
var html = `<table class='table table-condensed' id='tracking-table-${row.pk}'>`;
if (!details) {
html += '</table>';
return html;
if (!details || !Object.keys(details).length) {
return `<small><em>{% trans "No changes" %}</em></small>`;
}
let html = `<table class='table table-condensed' id='tracking-table-${row.pk}'>`;
// Part information
if (details.part) {
html += `<tr><th>{% trans "Part" %}</th><td>`;