X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=bin%2Fmozilla%2Fcp.pl;h=51624331ca34e9127607be5aa77908157e41b5f2;hb=9d60642b51924a3fc44a0108777f0611ae19fb30;hp=c7e9a9b3d5deccbe6431b83bceb11f5bac60600a;hpb=510ca0b00027e4d1d0016da5f327ecd78b3b5425;p=kivitendo-erp.git diff --git a/bin/mozilla/cp.pl b/bin/mozilla/cp.pl index c7e9a9b3d..51624331c 100644 --- a/bin/mozilla/cp.pl +++ b/bin/mozilla/cp.pl @@ -32,13 +32,17 @@ #====================================================================== use SL::CP; -use SL::OP; use SL::IS; use SL::IR; +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 @@ -46,6 +50,10 @@ require "bin/mozilla/common.pl"; sub payment { $lxdebug->enter_sub(); + $auth->assert('cash'); + + my (@curr); + $form->{ARAP} = ($form->{type} eq 'receipt') ? "AR" : "AP"; $form->{arap} = lc $form->{ARAP}; @@ -65,14 +73,14 @@ sub payment { } # departments - if (@{ $form->{all_departments} }) { + if (@{ $form->{all_departments} || [] }) { $form->{selectdepartment} = "