X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;ds=sidebyside;f=bin%2Fmozilla%2Fcp.pl;h=d54137e72cc84125ae5ff798fb7024b7c87347f5;hb=7f683e50d6d550b307a1c97d071e894889039ff0;hp=49c7daea8e239b6cdb7962e7d53b58cdddf728c2;hpb=6354fe293411247831445f5eb9507409ad5f8e79;p=kivitendo-erp.git diff --git a/bin/mozilla/cp.pl b/bin/mozilla/cp.pl index 49c7daea8..d54137e72 100644 --- a/bin/mozilla/cp.pl +++ b/bin/mozilla/cp.pl @@ -58,6 +58,8 @@ sub payment { # setup customer/vendor selection for open invoices if ($form->{all_vc}) { + # Dieser Zweig funktioniert derzeit NIE. Ggf. ganz raus oder + # alle offenen Zahlungen wieder korrekt anzeigen. jb 12.10.2010 $form->all_vc(\%myconfig, $form->{vc}, $form->{ARAP}); } else { CP->get_openvc(\%myconfig, \%$form); @@ -66,22 +68,12 @@ sub payment { $form->{"select$form->{vc}"} = ""; if ($form->{"all_$form->{vc}"}) { + # s.o. jb 12.10.2010 $form->{"$form->{vc}_id"} = $form->{"all_$form->{vc}"}->[0]->{id}; map { $form->{"select$form->{vc}"} .= "$_->{name}--$_->{id}\n" } @{ $form->{"all_$form->{vc}"} }; } - # departments - if (@{ $form->{all_departments} || [] }) { - $form->{selectdepartment} = "\n"; - $form->{department} = "$form->{department}--$form->{department_id}"; - - map { - $form->{selectdepartment} .= - "$_->{description}--$_->{id}\n" - } (@{ $form->{all_departments} || [] }); - } - CP->paymentaccounts(\%myconfig, \%$form); $form->{selectaccount} = ""; @@ -95,6 +87,13 @@ sub payment { } @{ $form->{PR}{ $form->{ARAP} } }; # currencies + # oldcurrency ist zwar noch hier als fragment enthalten, wird aber bei + # der aktualisierung der form auch nicht mitübernommen. das konzept + # old_$FOO habe ich auch noch nicht verstanden ... + # Ok. Wenn currency übernommen werden, dann in callback-string über- + # geben und hier reinparsen, oder besser multibox oder html auslagern? + # Antwort: form->currency wird mit oldcurrency oder curr[0] überschrieben + # Wofür macht das Sinn? @curr = split(/:/, $form->{currencies}); chomp $curr[0]; $form->{defaultcurrency} = $form->{currency} = $form->{oldcurrency} = @@ -103,7 +102,6 @@ sub payment { $form->{selectcurrency} = ""; map { $form->{selectcurrency} .= "$_\n" } @curr; - $form->{media} = "screen"; &form_header; &form_footer; @@ -116,7 +114,7 @@ sub form_header { $auth->assert('cash'); - my ($vc, $vclabel, $allvc, $arap, $department, $exchangerate); + my ($vc, $vclabel, $allvc, $arap, $exchangerate); my ($jsscript, $button1, $button2, $onload); $vclabel = ucfirst $form->{vc}; @@ -157,8 +155,7 @@ sub form_header { |; } } - - foreach my $item ($form->{vc}, "account", "currency", $form->{ARAP}, "department") { + foreach my $item ($form->{vc}, "account", "currency", $form->{ARAP}) { $form->{"select$item"} =~ s/ selected//; $form->{"select$item"} =~ s/option>\Q$form->{$item}\E/option selected>$form->{$item}/; @@ -273,7 +270,6 @@ sub form_header { - $department | . $locale->text('Account') . qq| $form->{selectaccount} @@ -451,28 +447,6 @@ sub form_footer { $auth->assert('cash'); - my ($media, $format, $latex_templates); - - $form->{DF}{ $form->{format} } = "selected"; - $form->{OP}{ $form->{media} } = "selected"; - - $media = qq| - {OP}{screen}>| . $locale->text('Screen'); - - if ($myconfig{printer} && $latex_templates) { - $media .= qq| - {OP}{printer}>| - . $locale->text('Printer'); - } - if ($latex_templates) { - $media .= qq| - {OP}{queue}>| . $locale->text('Queue'); - $format .= qq| - {DF}{postscript}>| - . $locale->text('Postscript') . qq| - {DF}{pdf}>| . $locale->text('PDF'); - } - print qq| @@ -484,19 +458,8 @@ sub form_footer { |; - - if ($latex_templates) { - print qq| -|; - } - - print qq| -$format -$media - - + . $locale->text('Post') . qq|"> +