From 0f8e17971f351aa65d42984dddb78b6a91144e3b Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jan=20B=C3=BCren?= Date: Wed, 29 Dec 2010 12:38:42 +0100 Subject: [PATCH] =?utf8?q?Bugfix=20f=C3=BCr=201398:=20Ruft=20man=20sich=20?= =?utf8?q?das=20Lagerjournal=20auf,=20in=20dem=20ja=20eine=20Spalte=20fuer?= =?utf8?q?=20Projektnummern=20vorgesehen=20ist,=20bleibt=20diese=20Spalte?= =?utf8?q?=20jedoch=20immer=20leer,=20auch=20wenn=20in=20dem=20jeweiligen?= =?utf8?q?=20Lieferschein=20zur=20Auslagerung=20eine=20Projektnummer=20sta?= =?utf8?q?nd.?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Hintergrund: project_id oder globalproject_id wurde nicht an $request und $transfer übergeben. Falls project_id_$i definiert ist, nimm die, ansonsten globalproject_id --- SL/DO.pm | 1 + bin/mozilla/do.pl | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/SL/DO.pm b/SL/DO.pm index d657cca5c..fe2318cc8 100644 --- a/SL/DO.pm +++ b/SL/DO.pm @@ -1053,6 +1053,7 @@ sub transfer_in_out { 'oe_id' => $form->{id}, 'shippingdate' => 'current_date', 'transfer_type' => $params{direction} eq 'in' ? 'stock' : 'shipped', + 'project_id' => $request->{project_id}, }; } diff --git a/bin/mozilla/do.pl b/bin/mozilla/do.pl index 8299a1abf..796118a12 100644 --- a/bin/mozilla/do.pl +++ b/bin/mozilla/do.pl @@ -1310,6 +1310,7 @@ sub transfer_out { foreach my $request (@{ DO->unpack_stock_information('packed' => $form->{"stock_out_$i"}) }) { $request->{parts_id} = $form->{"id_$i"}; $request->{base_qty} = $request->{qty} * $units->{$request->{unit}}->{factor} / $base_unit_factor; + $request->{project_id} = $form->{"project_id_$i"} ? $form->{"project_id_$i"} : $form->{globalproject_id}; my $map_key = join '--', ($form->{"id_$i"}, @{$request}{qw(warehouse_id bin_id chargenumber bestbefore)}); @@ -1383,7 +1384,6 @@ sub transfer_out { ::end_of_request(); } } - DO->transfer_in_out('direction' => 'out', 'requests' => \@all_requests); -- 2.20.1