From: Sven Schöling Date: Thu, 30 Aug 2012 08:34:50 +0000 (+0200) Subject: menuitem entfernt X-Git-Tag: release-3.0.0beta1~216 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=62d7ed6effa438e4ede167f80fbfe8ca19bae0cd;p=kivitendo-erp.git menuitem entfernt --- diff --git a/bin/mozilla/menu.pl b/bin/mozilla/menu.pl index 3f439db89..f6066e740 100644 --- a/bin/mozilla/menu.pl +++ b/bin/mozilla/menu.pl @@ -113,7 +113,19 @@ sub section_menu { $label = $::locale->text($label); - menuitem($menuitem); + $menuitem->{module} ||= $::form->{script}; + $menuitem->{action} ||= "section_menu"; + $menuitem->{target} ||= "main_window"; + $menuitem->{href} ||= "$item->{module}?action=$item->{action}"; + + # add other params + foreach my $key (keys %$item) { + next if $key =~ /target|module|action|href/; + $menuitem->{href} .= "&" . $::form->escape($key, 1) . "="; + my ($value, $conf) = split(/=/, $item->{$key}, 2); + $value = $::myconfig{$value} . "/$conf" if ($conf); + $item->{href} .= $::form->escape($value, 1); + } my $anchor = $menuitem->{href}; @@ -143,28 +155,6 @@ sub section_menu { return @items; } -sub menuitem { - my ($item, $name) = @_; - - $item->{module} ||= $::form->{script}; - $item->{action} ||= "section_menu"; - $item->{target} ||= "main_window"; - $item->{href} ||= "$item->{module}?action=$item->{action}"; - - # add other params - foreach my $key (keys %$item) { - next if $key =~ /target|module|action|href/; - $item->{href} .= "&" . $::form->escape($key, 1) . "="; - my ($value, $conf) = split(/=/, $item->{$key}, 2); - $value = $::myconfig{$value} . "/$conf" if ($conf); - $item->{href} .= $::form->escape($value, 1); - } - -# my $str = ""; -# -# return $str; -} - sub make_item { my %params = @_; $params{a} ||= '';