From 0dd879bc05be0e63a11dac93ec8134e7ac034c41 Mon Sep 17 00:00:00 2001 From: Moritz Bunkus Date: Fri, 14 Nov 2008 16:24:40 +0000 Subject: [PATCH] Zugangskontrolle mithilfe des Eintrags "acs" in der Benutzerkonfiguration wird nicht mehr benutzt. --- SL/Menu.pm | 26 +------------------------- SL/User.pm | 2 +- bin/mozilla/is.pl | 8 -------- 3 files changed, 2 insertions(+), 34 deletions(-) diff --git a/SL/Menu.pm b/SL/Menu.pm index 60d78dd27..81eedb1a8 100644 --- a/SL/Menu.pm +++ b/SL/Menu.pm @@ -264,33 +264,9 @@ sub access_control { @menu = grep { /^${menulevel}--/ } @{ $self->{ORDER} }; } - my @a = split(/;/, $myconfig->{acs}); - my $excl = (); - - # remove --AR, --AP from array - grep { ($a, $b) = split(/--/); s/--$a$//; } @a; - - map { $excl{$_} = 1 } @a; - - @a = (); - map { push @a, $_ unless $excl{$_} } (@menu); - $main::lxdebug->leave_sub(2); - return @a; -} - -sub generate_acl { - my ($self, $menulevel, $hash) = @_; - - my @items = $self->access_control(\%main::myconfig, $menulevel); - - $menulevel =~ s/[^A-Za-z_\/\.\+\-]/_/g; - $hash->{"access_" . lc($menulevel)} = 1 if ($menulevel); - - foreach my $item (@items) { - $self->generate_acl($item, $hash); #unless ($menulevel); - } + return @menu; } sub parse_access_string { diff --git a/SL/User.pm b/SL/User.pm index 44cd34ab7..805335a29 100644 --- a/SL/User.pm +++ b/SL/User.pm @@ -974,7 +974,7 @@ sub create_employee_entry { sub config_vars { $main::lxdebug->enter_sub(); - my @conf = qw(acs address admin businessnumber company countrycode + my @conf = qw(address admin businessnumber company countrycode currency dateformat dbconnect dbdriver dbhost dbport dboptions dbname dbuser dbpasswd email fax name numberformat password printer role sid signature stylesheet tel templates vclimit angebote diff --git a/bin/mozilla/is.pl b/bin/mozilla/is.pl index 857681543..68bfb0196 100644 --- a/bin/mozilla/is.pl +++ b/bin/mozilla/is.pl @@ -69,10 +69,6 @@ sub add { $form{jsscript} = "date"; - if ($myconfig{acs} =~ "AR--Add Sales Invoice" || $myconfig{acs} =~ "AR--AR") - { - $form->error("Access Denied"); - } &invoice_links; &prepare_invoice; &display_form; @@ -89,10 +85,6 @@ sub edit { $form->{javascript} = qq||; #/show hhistory button - if ($myconfig{acs} =~ "AR--Add Sales Invoice" || $myconfig{acs} =~ "AR--AR") - { - $form->error("Access Denied"); - } $edit = 1; if ($form->{print_and_post}) { $form->{action} = "print"; -- 2.20.1