From c7d390e4949b28c28c95375bfe4523de05af7808 Mon Sep 17 00:00:00 2001 From: Zach Copley Date: Wed, 3 Mar 2010 12:18:20 -0800 Subject: Add class="admin" to the content div of admin panels for styling --- lib/adminpanelaction.php | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'lib/adminpanelaction.php') diff --git a/lib/adminpanelaction.php b/lib/adminpanelaction.php index 536d97cdf..9ea4fe206 100644 --- a/lib/adminpanelaction.php +++ b/lib/adminpanelaction.php @@ -171,6 +171,24 @@ class AdminPanelAction extends Action $this->showForm(); } + /** + * Show content block. Overrided just to add a special class + * to the content div to allow styling. + * + * @return nothing + */ + function showContentBlock() + { + $this->elementStart('div', array('id' => 'content', 'class' => 'admin')); + $this->showPageTitle(); + $this->showPageNoticeBlock(); + $this->elementStart('div', array('id' => 'content_inner')); + // show the actual content (forms, lists, whatever) + $this->showContent(); + $this->elementEnd('div'); + $this->elementEnd('div'); + } + /** * show human-readable instructions for the page, or * a success/failure on save. -- cgit v1.2.3 From ef6bf8f331175374af6889df82927b3cf6757b8a Mon Sep 17 00:00:00 2001 From: Sarven Capadisli Date: Wed, 3 Mar 2010 15:42:34 -0500 Subject: Removed aside container from output for the admin panel sections --- lib/adminpanelaction.php | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'lib/adminpanelaction.php') diff --git a/lib/adminpanelaction.php b/lib/adminpanelaction.php index 9ea4fe206..1d9c42563 100644 --- a/lib/adminpanelaction.php +++ b/lib/adminpanelaction.php @@ -189,6 +189,16 @@ class AdminPanelAction extends Action $this->elementEnd('div'); } + /** + * There is no data for aside, so, we don't output + * + * @return nothing + */ + function showAside() + { + + } + /** * show human-readable instructions for the page, or * a success/failure on save. -- cgit v1.2.3 From 337b1aaaa16bde80b42a9902ebeb299f8f13a226 Mon Sep 17 00:00:00 2001 From: Zach Copley Date: Wed, 3 Mar 2010 14:32:14 -0800 Subject: Site-wide notice text admin panel --- lib/adminpanelaction.php | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) (limited to 'lib/adminpanelaction.php') diff --git a/lib/adminpanelaction.php b/lib/adminpanelaction.php index 1d9c42563..eb622871e 100644 --- a/lib/adminpanelaction.php +++ b/lib/adminpanelaction.php @@ -173,7 +173,7 @@ class AdminPanelAction extends Action /** * Show content block. Overrided just to add a special class - * to the content div to allow styling. + * to the content div to allow styling. * * @return nothing */ @@ -358,22 +358,27 @@ class AdminPanelNav extends Widget if (AdminPanelAction::canAdmin('user')) { $this->out->menuItem(common_local_url('useradminpanel'), _('User'), - _('User configuration'), $action_name == 'useradminpanel', 'nav_design_admin_panel'); + _('User configuration'), $action_name == 'useradminpanel', 'nav_user_admin_panel'); } if (AdminPanelAction::canAdmin('access')) { $this->out->menuItem(common_local_url('accessadminpanel'), _('Access'), - _('Access configuration'), $action_name == 'accessadminpanel', 'nav_design_admin_panel'); + _('Access configuration'), $action_name == 'accessadminpanel', 'nav_access_admin_panel'); } if (AdminPanelAction::canAdmin('paths')) { $this->out->menuItem(common_local_url('pathsadminpanel'), _('Paths'), - _('Paths configuration'), $action_name == 'pathsadminpanel', 'nav_design_admin_panel'); + _('Paths configuration'), $action_name == 'pathsadminpanel', 'nav_paths_admin_panel'); } if (AdminPanelAction::canAdmin('sessions')) { $this->out->menuItem(common_local_url('sessionsadminpanel'), _('Sessions'), - _('Sessions configuration'), $action_name == 'sessionsadminpanel', 'nav_design_admin_panel'); + _('Sessions configuration'), $action_name == 'sessionsadminpanel', 'nav_sessions_admin_panel'); + } + + if (AdminPanelAction::canAdmin('sitenotice')) { + $this->out->menuItem(common_local_url('sitenoticeadminpanel'), _('Site notice'), + _('Edit site notice'), $action_name == 'sitenoticeadminpanel', 'nav_sitenotice_admin_panel'); } Event::handle('EndAdminPanelNav', array($this)); -- cgit v1.2.3 From 61de37ec7bfb620288d3bc3b1fcdfb66725f0f99 Mon Sep 17 00:00:00 2001 From: Zach Copley Date: Wed, 3 Mar 2010 16:47:27 -0800 Subject: Move snapshot configuration to its own admin panel Turn on with: $config['admin']['panels'][] = 'snapshot'; --- lib/adminpanelaction.php | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'lib/adminpanelaction.php') diff --git a/lib/adminpanelaction.php b/lib/adminpanelaction.php index eb622871e..d1aab3dfc 100644 --- a/lib/adminpanelaction.php +++ b/lib/adminpanelaction.php @@ -381,6 +381,11 @@ class AdminPanelNav extends Widget _('Edit site notice'), $action_name == 'sitenoticeadminpanel', 'nav_sitenotice_admin_panel'); } + if (AdminPanelAction::canAdmin('snapshot')) { + $this->out->menuItem(common_local_url('snapshotadminpanel'), _('Snapshots'), + _('Snapshots configuration'), $action_name == 'snapshotadminpanel', 'nav_snapshot_admin_panel'); + } + Event::handle('EndAdminPanelNav', array($this)); } $this->action->elementEnd('ul'); -- cgit v1.2.3