From d8f03450e7564f8a790ce514fa98330aa8535229 Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Sun, 12 Jul 2015 00:40:12 +0200 Subject: make menu creation for sys channel work --- mod/mitem.php | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) (limited to 'mod/mitem.php') diff --git a/mod/mitem.php b/mod/mitem.php index c4c293d1e..e3341f5de 100644 --- a/mod/mitem.php +++ b/mod/mitem.php @@ -44,9 +44,6 @@ function mitem_post(&$a) { if(! $a->data['menu']) return; - - $channel = $a->get_channel(); - if(!$_REQUEST['mitem_desc'] || !$_REQUEST['mitem_link']) { notice( t('Unable to create element.') . EOL); return; @@ -90,9 +87,6 @@ function mitem_post(&$a) { } - - - } @@ -155,6 +149,7 @@ function mitem_content(&$a) { $create = replace_macros(get_markup_template('mitemedit.tpl'), array( '$menu_id' => $a->data['menu']['menu_id'], + '$action' => 'mitem/' . $a->data['menu']['menu_id'] . (($a->is_sys) ? '?f=&sys=1' : ''), '$permissions' => t('Menu Item Permissions'), '$permdesc' => t("\x28click to open/close\x29"), '$aclselect' => populate_acl($perm_defaults,false), -- cgit v1.2.3 From f81874ca49a4a414b359a488b82fd4c274b24472 Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Sun, 12 Jul 2015 01:04:57 +0200 Subject: fix sys channel menu in a morre standard way --- mod/mitem.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'mod/mitem.php') diff --git a/mod/mitem.php b/mod/mitem.php index e3341f5de..ee2de1cf8 100644 --- a/mod/mitem.php +++ b/mod/mitem.php @@ -149,7 +149,6 @@ function mitem_content(&$a) { $create = replace_macros(get_markup_template('mitemedit.tpl'), array( '$menu_id' => $a->data['menu']['menu_id'], - '$action' => 'mitem/' . $a->data['menu']['menu_id'] . (($a->is_sys) ? '?f=&sys=1' : ''), '$permissions' => t('Menu Item Permissions'), '$permdesc' => t("\x28click to open/close\x29"), '$aclselect' => populate_acl($perm_defaults,false), @@ -162,7 +161,8 @@ function mitem_content(&$a) { '$submit_more' => t('Submit and continue'), '$display' => $display, '$lockstate' => $lockstate, - '$menu_names' => $menu_names + '$menu_names' => $menu_names, + '$sys' => $a->is_sys )); $o .= replace_macros(get_markup_template('mitemlist.tpl'),array( -- cgit v1.2.3 From 04c794da107751674c82e39ce45ee1fad726a987 Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Sun, 12 Jul 2015 01:12:20 +0200 Subject: whitespace and comment out info again --- mod/mitem.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'mod/mitem.php') diff --git a/mod/mitem.php b/mod/mitem.php index ee2de1cf8..bc93165ac 100644 --- a/mod/mitem.php +++ b/mod/mitem.php @@ -162,7 +162,7 @@ function mitem_content(&$a) { '$display' => $display, '$lockstate' => $lockstate, '$menu_names' => $menu_names, - '$sys' => $a->is_sys + '$sys' => $a->is_sys )); $o .= replace_macros(get_markup_template('mitemlist.tpl'),array( -- cgit v1.2.3