From 71eff037f1b2da6a2a2e3a392a6332648d805a6a Mon Sep 17 00:00:00 2001 From: "Martin Helmling martin.helmling@octosoft.eu" Date: Mon, 28 Oct 2019 15:27:38 +0100 Subject: [PATCH] Inventory Helper: Mehr Info zum Alloc-Fehler MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Nun werden an die Exception noch zwei weitere Parameter zur Auswertung übergeben: - accessor: Bei wem tritt der Fehler auf - allocations: Parameter die zu diesem Fehler geführt haben zu #9457 und #10417 --- SL/Helper/Inventory.pm | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/SL/Helper/Inventory.pm b/SL/Helper/Inventory.pm index 4da9bb798..17a7d98c0 100644 --- a/SL/Helper/Inventory.pm +++ b/SL/Helper/Inventory.pm @@ -282,8 +282,11 @@ sub check_constraints { warehouse_id => t8('Warehouses'), chargenumber => t8('Chargenumbers'), ); + my @allocs = grep { !$whitelist{$_->$accessor} } @$allocations; die SL::X::Inventory::Allocation->new( - error => 'allocation constraints failure', + accessor => $accessor, + allocations => \@allocs, + error => 'allocation constraints failure', msg => t8("Allocations didn't pass constraints for #1",$error_constraints{$_}), ); } -- 2.20.1