From: Jan Büren Date: Mon, 14 Jun 2021 10:41:51 +0000 (+0200) Subject: ShippedQty: Fallunterschied für Einkauf/Verkauf gesetzt X-Git-Tag: kivitendo-mebil_0.1-0~9^2~175 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=867a69bcc3730b4a3f0be8e2221f21e16eb89960;p=kivitendo-erp.git ShippedQty: Fallunterschied für Einkauf/Verkauf gesetzt --- diff --git a/SL/Helper/ShippedQty.pm b/SL/Helper/ShippedQty.pm index b23e4fa45..3ad46197e 100644 --- a/SL/Helper/ShippedQty.pm +++ b/SL/Helper/ShippedQty.pm @@ -432,7 +432,9 @@ include a bulk mode to speed up multiple objects. =item C -Creates a new helper object. PARAMS may include: +Creates a new helper object, $::form->{type} is mandatory. + +PARAMS may include: =over 4 @@ -472,6 +474,7 @@ than this modules provides. See C for the returned format. + =back =item C diff --git a/t/helper/shipped_qty.t b/t/helper/shipped_qty.t index c300bb5d4..7b3bc3afc 100644 --- a/t/helper/shipped_qty.t +++ b/t/helper/shipped_qty.t @@ -63,6 +63,7 @@ my %default_transfer_params = ( wh => $wh, bin => $bin1, unit => 'Stck'); note("testing purchases, no fill_up"); +$::form->{type} = 'purchase_order'; my $purchase_order = create_purchase_order( save => 1, orderitems => [ create_order_item(part => $part1, qty => 11), @@ -135,6 +136,7 @@ is($purchase_orderitem_part2->shipped_qty(require_stock_out => 1), 11, "OrderIte note('testing sales, no fill_up'); +$::form->{type} = 'sales_order'; my $sales_order = create_sales_order( save => 1, orderitems => [ create_order_item(part => $part1, qty => 5),