X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=bin%2Fmozilla%2Fcp.pl;h=d341ffdfc89855cc80c9f3f9e5b8622b32fad9b8;hb=ea2e84cc75e2879141eea5e957439936280682bf;hp=d8890a10e95effad6be614cf9346da022226d164;hpb=4dbb09950c9f5596646537c12d991c99086fe7c1;p=kivitendo-erp.git diff --git a/bin/mozilla/cp.pl b/bin/mozilla/cp.pl index d8890a10e..d341ffdfc 100644 --- a/bin/mozilla/cp.pl +++ b/bin/mozilla/cp.pl @@ -31,22 +31,30 @@ # #====================================================================== - use SL::CP; use SL::OP; use SL::IS; use SL::IR; -require "$form->{path}/arap.pl"; +use strict ("vars", "subs"); +#use warnings; + +require "bin/mozilla/arap.pl"; +require "bin/mozilla/common.pl"; + +our ($form, %myconfig, $lxdebug, $locale, $auth); 1; -# end of main +# end of main sub payment { $lxdebug->enter_sub(); - + $auth->assert('cash'); + + my (@curr); + $form->{ARAP} = ($form->{type} eq 'receipt') ? "AR" : "AP"; $form->{arap} = lc $form->{ARAP}; @@ -58,18 +66,22 @@ sub payment { } $form->{"select$form->{vc}"} = ""; - + if ($form->{"all_$form->{vc}"}) { $form->{"$form->{vc}_id"} = $form->{"all_$form->{vc}"}->[0]->{id}; - map { $form->{"select$form->{vc}"} .= "