Revision 63a8dae2
Von Moritz Bunkus vor mehr als 11 Jahren hinzugefügt
SL/Menu.pm | ||
---|---|---|
42 | 42 |
sub new { |
43 | 43 |
$main::lxdebug->enter_sub(); |
44 | 44 |
|
45 |
my ($type, $menufile) = @_; |
|
45 |
my ($type, @menufiles) = @_; |
|
46 |
my $self = bless {}, $type; |
|
46 | 47 |
|
47 |
my $self = {}; |
|
48 |
my $inifile = Inifile->new($menufile); |
|
48 |
my @order; |
|
49 | 49 |
|
50 |
map { $self->{$_} = $inifile->{$_} } keys %{ $inifile }; |
|
50 |
foreach my $menufile (grep { -f } @menufiles) { |
|
51 |
my $inifile = Inifile->new($menufile); |
|
51 | 52 |
|
52 |
bless $self, $type; |
|
53 |
push @order, @{ delete($inifile->{ORDER}) || [] }; |
|
54 |
$self->{$_} = $inifile->{$_} for keys %{ $inifile }; |
|
55 |
} |
|
56 |
|
|
57 |
$self->{ORDER} = \@order; |
|
53 | 58 |
|
54 | 59 |
$self->set_access(); |
55 | 60 |
|
Auch abrufbar als: Unified diff
CRM-Menü automatisch einlesen, falls es existiert
Siehe #2328.