{ id => 'projectnr', width => 10, value => $locale->text('Project'), display => 0, },
{ id => 'sellprice', width => 15, value => $locale->text('Price'), display => !$is_delivery_order, },
{ id => 'sellprice_pg', width => 8, value => $locale->text('Pricegroup'), display => ($form->{type} =~ /^sales_/) && !$is_delivery_order, },
- { id => 'discount', width => 5, value => $locale->text('Discount'), display => ($form->{vc} eq 'customer') && !$is_delivery_order, },
+ { id => 'discount', width => 5, value => $locale->text('Discount'), display => !$is_delivery_order, },
{ id => 'linetotal', width => 10, value => $locale->text('Extended'), display => !$is_delivery_order, },
{ id => 'bin', width => 10, value => $locale->text('Bin'), display => 0, },
{ id => 'stock_in_out', width => 10, value => $stock_in_out_title, display => $is_delivery_order, },
$column_data{bin} = $form->{"bin_$i"};
if ($is_delivery_order) {
- # $column_data{stock_in_out} = $form->{"inventory_accno_$i"} ? calculate_stock_in_out($i) : ' ';
- # $main::lxdebug->dump(0, "debug", $form->{"inventory_accno_$i"});
- # meine debug-analyse war negativ (s.o.) - die variable war weder bei dienstleistung, erzeugnis noch ware gefüllt.
- # bitte korrigieren, falls ich hier falsch liege. jb 19.3.2009
-
$column_data{stock_in_out} = calculate_stock_in_out($i);
}
#($form->{"sellprice_$i"},$form->{"$pricegroup_old_$i"}) = split /--/, $form->{"sellprice_$i"};
- $form->{sellprice} += ($form->{"qty_$i"} * $form->{"sellprice_$i"});
- $form->{weight} += ($form->{"qty_$i"} * $form->{"weight_$i"});
+ $form->{sellprice} += ($form->{"qty_$i"} * $form->{"sellprice_$i"} / ($form->{"price_factor_$i"} || 1));
+ $form->{weight} += ($form->{"qty_$i"} * $form->{"weight_$i"} / ($form->{"price_factor_$i"} || 1));
$count++;
}
}