X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=bin%2Fmozilla%2Fic.pl;h=c6714e6b4fd8bf8f92dce0a08d2633b06c100c3d;hb=061105807cbfb5b86b804e71db9509c996c93912;hp=215ec16ab1fdfdfbe33a5ca1b791a3e6209c3a52;hpb=ce67e845bb35f23ff5f6de98b8693418ab72e86d;p=kivitendo-erp.git diff --git a/bin/mozilla/ic.pl b/bin/mozilla/ic.pl index 215ec16ab..c6714e6b4 100644 --- a/bin/mozilla/ic.pl +++ b/bin/mozilla/ic.pl @@ -1273,7 +1273,7 @@ sub generate_report { my %subtotals = map { $_ => 0 } ('onhand', @subtotal_columns); my %totals = map { $_ => 0 } @subtotal_columns; my $idx = 0; - my $same_item = $form->{parts}[0]{ $form->{sort} } if (scalar @{ $form->{parts} }); + my $same_item = @{ $form->{parts} } ? $form->{parts}[0]{ $form->{sort} } : undef; my $defaults = AM->get_defaults(); @@ -1538,9 +1538,6 @@ sub form_header { $auth->assert('part_service_assembly_edit'); - # what does eur set here? why is it in namespace? - # call of get_accounting_method preserves format of $form->{eur}, which expects 1 or 0 - $form->{eur} = $::instance_conf->get_accounting_method eq 'cash' ? 1 : 0; # config dumps into namespace - yuck $form->{pg_keys} = sub { "$_[0]->{partsgroup}--$_[0]->{id}" }; $form->{description_area} = ($form->{rows} = $form->numtextrows($form->{description}, 40)) > 1; $form->{notes_rows} = max 4, $form->numtextrows($form->{notes}, 40), $form->numtextrows($form->{formel}, 40);