From a6e341274e74b92bd80f5b11b5ed22ad46361da9 Mon Sep 17 00:00:00 2001 From: Cameron Date: Fri, 29 Jan 2021 09:27:38 -0800 Subject: [PATCH] Admin template clean up. 2 new admin styles added. (to be improved). Left admin panel collapse improved. (still needs a cookie to 'stick' . --- e107_admin/update_routines.php | 2 +- .../shortcodes/batch/admin_shortcodes.php | 15 +- e107_core/templates/admin_template.php | 10 +- e107_handlers/admin_ui.php | 8 +- e107_handlers/form_handler.php | 2 +- e107_handlers/sitelinks_class.php | 22 +- e107_handlers/theme_handler.php | 4 +- e107_themes/bootstrap3/admin_style.css | 8 + e107_themes/bootstrap3/css/modern-dark.css | 1563 ++++++++++++++++ e107_themes/bootstrap3/css/modern-light.css | 1568 +++++++++++++++++ e107_themes/bootstrap3/theme.xml | 6 +- e107_web/js/core/admin.jquery.js | 24 +- 12 files changed, 3202 insertions(+), 30 deletions(-) create mode 100644 e107_themes/bootstrap3/css/modern-dark.css create mode 100644 e107_themes/bootstrap3/css/modern-light.css diff --git a/e107_admin/update_routines.php b/e107_admin/update_routines.php index 511891b50..f30835443 100644 --- a/e107_admin/update_routines.php +++ b/e107_admin/update_routines.php @@ -882,7 +882,7 @@ function update_706_to_800($type='') if ($just_check) return update_needed('pref: Admin theme upgrade to bootstrap3 '); $pref['admintheme'] = 'bootstrap3'; - $pref['admincss'] = 'admin_dark.css'; + $pref['admincss'] = 'css/bootstrap-dark.min.css'; $do_save = true; } diff --git a/e107_core/shortcodes/batch/admin_shortcodes.php b/e107_core/shortcodes/batch/admin_shortcodes.php index 30dfaf35d..3967763ac 100644 --- a/e107_core/shortcodes/batch/admin_shortcodes.php +++ b/e107_core/shortcodes/batch/admin_shortcodes.php @@ -679,21 +679,18 @@ class admin_shortcodes extends e_shortcode { return ''; } - global $ns, $pref; // SecretR: NEW v0.8 - $tmp = e107::getAdminUI(); - if($tmp) + if($tmp = e107::getAdminUI()) { - ob_start(); - // FIXME - renderMenu(), respectively e_adm/in_menu() should return, not output content! - $tmp->renderMenu(); - $ret = ob_get_clean(); - - return $ret; + return $tmp->renderMenu(); } + unset($tmp); + $ns = e107::getRender(); + $pref = e107::getPref(); + $curScript = basename($_SERVER['SCRIPT_FILENAME']); diff --git a/e107_core/templates/admin_template.php b/e107_core/templates/admin_template.php index 8f38cdd69..4755bd72d 100644 --- a/e107_core/templates/admin_template.php +++ b/e107_core/templates/admin_template.php @@ -235,7 +235,7 @@ else {SETSTYLE=admin_menu} {ADMIN_MENU} - + {SETSTYLE=default}
@@ -282,7 +282,7 @@ $ADMIN_TEMPLATE['footer'] = ' * see function e107::getNav()->admin() in e107_admin/header.php */ $ADMIN_TEMPLATE['menu']['start'] = ' -