mirror of
https://github.com/e107inc/e107.git
synced 2025-08-04 05:37:32 +02:00
Custom template and layout for admin dashboard.
This commit is contained in:
@@ -33,6 +33,9 @@ if (varset($pref['adminstyle'])=='cascade' || varset($pref['adminstyle'])=='begi
|
|||||||
|
|
||||||
if(strpos($pref['adminstyle'], 'infopanel') === 0)
|
if(strpos($pref['adminstyle'], 'infopanel') === 0)
|
||||||
{
|
{
|
||||||
|
// Define constant for using custom template on the dashboard.
|
||||||
|
define('e_DASHBOARD', true);
|
||||||
|
|
||||||
require_once(e_ADMIN.'includes/'.$pref['adminstyle'].'.php');
|
require_once(e_ADMIN.'includes/'.$pref['adminstyle'].'.php');
|
||||||
$_class = 'adminstyle_'.$pref['adminstyle'];
|
$_class = 'adminstyle_'.$pref['adminstyle'];
|
||||||
if(class_exists($_class, false))
|
if(class_exists($_class, false))
|
||||||
|
@@ -19,7 +19,7 @@ if (!defined('e107_INIT'))
|
|||||||
}
|
}
|
||||||
$In_e107_Footer = TRUE; // For registered shutdown function
|
$In_e107_Footer = TRUE; // For registered shutdown function
|
||||||
|
|
||||||
global $error_handler,$db_time,$ADMIN_FOOTER;
|
global $error_handler,$db_time,$ADMIN_FOOTER,$ADMIN_FOOTER_DASHBOARD;
|
||||||
|
|
||||||
// Legacy fix - call header if not already done, mainly fixing left side menus to work proper
|
// Legacy fix - call header if not already done, mainly fixing left side menus to work proper
|
||||||
if(!deftrue('e_ADMIN_UI') && !deftrue('ADMIN_AREA'))
|
if(!deftrue('e_ADMIN_UI') && !deftrue('ADMIN_AREA'))
|
||||||
@@ -98,7 +98,15 @@ if (varset($e107_popup) != 1)
|
|||||||
//NEW - Iframe mod
|
//NEW - Iframe mod
|
||||||
if (!deftrue('e_IFRAME'))
|
if (!deftrue('e_IFRAME'))
|
||||||
{
|
{
|
||||||
parse_admin($ADMIN_FOOTER);
|
// Dashboard uses its own template.
|
||||||
|
if (deftrue('e_DASHBOARD', false) === true)
|
||||||
|
{
|
||||||
|
parse_admin($ADMIN_FOOTER_DASHBOARD);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
parse_admin($ADMIN_FOOTER);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
$eTimingStop = microtime();
|
$eTimingStop = microtime();
|
||||||
|
@@ -588,7 +588,16 @@ if ($e107_popup != 1)
|
|||||||
if (!deftrue('e_IFRAME'))
|
if (!deftrue('e_IFRAME'))
|
||||||
{
|
{
|
||||||
//removed check strpos(e_SELF.'?'.e_QUERY, 'menus.php?configure') === FALSE
|
//removed check strpos(e_SELF.'?'.e_QUERY, 'menus.php?configure') === FALSE
|
||||||
parse_admin($ADMIN_HEADER);
|
|
||||||
|
// Dashboard uses its own template.
|
||||||
|
if (deftrue('e_DASHBOARD', false) === true)
|
||||||
|
{
|
||||||
|
parse_admin($ADMIN_HEADER_DASHBOARD);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
parse_admin($ADMIN_HEADER);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
elseif(!vartrue($_GET['configure']))
|
elseif(!vartrue($_GET['configure']))
|
||||||
{
|
{
|
||||||
|
@@ -281,22 +281,9 @@ class adminstyle_infopanel
|
|||||||
if(vartrue($_GET['mode']) != 'customize')
|
if(vartrue($_GET['mode']) != 'customize')
|
||||||
{
|
{
|
||||||
// $ns->tablerender(ADLAN_47." ".ADMINNAME, $emessage->render().$text);
|
// $ns->tablerender(ADLAN_47." ".ADMINNAME, $emessage->render().$text);
|
||||||
echo $mes->render().'
|
// echo $mes->render(); // TODO
|
||||||
|
echo $text; // Control Panel
|
||||||
<!-- INFOPANEL -->
|
echo $text2; // Latest e107 News + Website Status
|
||||||
<div class="row">
|
|
||||||
<div class="span6 col-md-6">
|
|
||||||
'.$text.'
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="span6 col-md-6">
|
|
||||||
'.$text2.'
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<!-- -->
|
|
||||||
|
|
||||||
|
|
||||||
';
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@@ -208,121 +208,129 @@ $ADMIN_MODAL = '<div id="uiModal" class="modal hide fade" tabindex="-1" role="d
|
|||||||
</div>';*/
|
</div>';*/
|
||||||
|
|
||||||
|
|
||||||
$ADMIN_MODAL = '<div id="uiModal" class="modal fade">
|
$ADMIN_MODAL = '
|
||||||
<div id="admin-ui-modal" class="modal-dialog modal-lg">
|
<div id="uiModal" class="modal fade">
|
||||||
<div class="modal-content">
|
<div id="admin-ui-modal" class="modal-dialog modal-lg">
|
||||||
<div class="modal-header">
|
<div class="modal-content">
|
||||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
|
<div class="modal-header">
|
||||||
<h4 class="modal-title modal-caption"> </h4>
|
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
|
||||||
</div>
|
<span aria-hidden="true">×</span>
|
||||||
<div class="modal-body">
|
</button>
|
||||||
<p>Loading...</p>
|
<h4 class="modal-title modal-caption"> </h4>
|
||||||
</div>
|
</div>
|
||||||
<div class="modal-footer">
|
<div class="modal-body">
|
||||||
<button type="button" class="btn btn-primary" data-dismiss="modal">Close</button>
|
<p>Loading...</p>
|
||||||
|
</div>
|
||||||
</div>
|
<div class="modal-footer">
|
||||||
</div><!-- /.modal-content -->
|
<button type="button" class="btn btn-primary" data-dismiss="modal">Close</button>
|
||||||
</div><!-- /.modal-dialog -->
|
</div>
|
||||||
|
</div><!-- /.modal-content -->
|
||||||
|
</div><!-- /.modal-dialog -->
|
||||||
</div><!-- /.modal -->';
|
</div><!-- /.modal -->';
|
||||||
|
|
||||||
|
|
||||||
|
$ADMIN_HEADER_DASHBOARD = $ADMIN_HEADER = $ADMIN_MODAL . '
|
||||||
// <li>{ADMIN_COREUPDATE=icon}</li>
|
|
||||||
|
|
||||||
$ADMIN_HEADER = $ADMIN_MODAL. '
|
|
||||||
|
|
||||||
<div class="navbar navbar-default navbar-fixed-top" role="navigation">
|
<div class="navbar navbar-default navbar-fixed-top" role="navigation">
|
||||||
<div class="container" >
|
<div class="container">
|
||||||
<div class="navbar-header">
|
<div class="navbar-header">
|
||||||
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
|
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
|
||||||
<span class="sr-only">Toggle navigation</span>
|
<span class="sr-only">Toggle navigation</span>
|
||||||
<span class="icon-bar"></span>
|
<span class="icon-bar"></span>
|
||||||
<span class="icon-bar"></span>
|
<span class="icon-bar"></span>
|
||||||
<span class="icon-bar"></span>
|
<span class="icon-bar"></span>
|
||||||
</button>
|
</button>
|
||||||
<a class="brand navbar-brand" href="'.e_ADMIN_ABS.'admin.php" title="Return to Front Panel"><img class="admin-logo" src="'.e_THEME_ABS.'bootstrap3/images/e107_adminlogo.png" alt="e107" /></a>
|
<a class="brand navbar-brand" href="' . e_ADMIN_ABS . 'admin.php" title="Return to Front Panel">
|
||||||
</div>
|
<img class="admin-logo" src="' . e_THEME_ABS . 'bootstrap3/images/e107_adminlogo.png" alt="e107"/>
|
||||||
<div class="navbar-collapse collapse">
|
</a>
|
||||||
|
</div>
|
||||||
{ADMIN_NAVIGATION=no-main}
|
<div class="navbar-collapse collapse">
|
||||||
|
{ADMIN_NAVIGATION=no-main}
|
||||||
<div>
|
<div>
|
||||||
{ADMIN_NAVIGATION=logout}
|
{ADMIN_NAVIGATION=logout}
|
||||||
{ADMIN_NAVIGATION=language}
|
{ADMIN_NAVIGATION=language}
|
||||||
{ADMIN_NAVIGATION=home}
|
{ADMIN_NAVIGATION=home}
|
||||||
{ADMIN_PM}
|
{ADMIN_PM}
|
||||||
{ADMIN_DEBUG}
|
{ADMIN_DEBUG}
|
||||||
</div>
|
</div>
|
||||||
|
</div><!--/.navbar-collapse -->
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
';
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div><!--/.navbar-collapse -->
|
|
||||||
</div>
|
|
||||||
</div>';
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
$ADMIN_HEADER .= '<div class="container-fluid">
|
|
||||||
|
|
||||||
<div class="row">
|
$ADMIN_HEADER_DASHBOARD .= '
|
||||||
<div class="col-md-3 col-lg-2" id="left-panel">
|
<div class="container-fluid">
|
||||||
{SETSTYLE=admin_menu}
|
<div class="row">
|
||||||
|
<div class="col-md-12">
|
||||||
|
{SETSTYLE=admin_menu}
|
||||||
{ADMIN_MENU}
|
{ADMIN_MENU}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
{ADMIN_PWORD}
|
{ADMIN_PWORD}
|
||||||
{ADMIN_MENUMANAGER}
|
{ADMIN_MENUMANAGER}
|
||||||
|
|
||||||
<div class="e-scroll-fixed">
|
|
||||||
|
|
||||||
|
|
||||||
{SETSTYLE=site_info}
|
{SETSTYLE=site_info}
|
||||||
|
|
||||||
{ADMINUI_HELP}
|
{ADMINUI_HELP}
|
||||||
{ADMIN_HELP}
|
{ADMIN_HELP}
|
||||||
|
|
||||||
</div>
|
|
||||||
|
|
||||||
{ADMIN_SITEINFO=creditsonly}
|
{ADMIN_SITEINFO=creditsonly}
|
||||||
{SETSTYLE=admin_menu}
|
{SETSTYLE=admin_menu}
|
||||||
|
|
||||||
{ADMIN_LATEST=infopanel}
|
{ADMIN_LATEST=infopanel}
|
||||||
{ADMIN_STATUS=infopanel}
|
{ADMIN_STATUS=infopanel}
|
||||||
|
|
||||||
{ADMIN_LOG=request}
|
{ADMIN_LOG=request}
|
||||||
{ADMIN_MSG=request}
|
{ADMIN_MSG=request}
|
||||||
{ADMIN_PLUGINS}
|
{ADMIN_PLUGINS}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
{SETSTYLE=default}
|
{SETSTYLE=default}
|
||||||
|
';
|
||||||
</div>
|
|
||||||
<div class="col-md-9 col-lg-10" id="right-panel" >
|
|
||||||
<div class="sidebar-toggle"><a href="#" title="Toggle Sidebar" data-toggle-sidebar="true"> </a></div>
|
|
||||||
<div>
|
|
||||||
|
|
||||||
';
|
|
||||||
|
|
||||||
|
$ADMIN_FOOTER_DASHBOARD = '
|
||||||
|
</div><!--/span-->
|
||||||
|
</div><!--/row-->
|
||||||
|
</div><!--/.fluid-container-->
|
||||||
|
|
||||||
|
<footer class="center mute">
|
||||||
|
Copyright © 2008-2015 e107 Inc (e107.org)<br />
|
||||||
|
</footer>
|
||||||
|
';
|
||||||
|
|
||||||
|
|
||||||
|
$ADMIN_HEADER .= '
|
||||||
|
<div class="container-fluid">
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-md-3 col-lg-2" id="left-panel">
|
||||||
|
{SETSTYLE=admin_menu}
|
||||||
|
{ADMIN_MENU}
|
||||||
|
{ADMIN_PWORD}
|
||||||
|
{ADMIN_MENUMANAGER}
|
||||||
|
<div class="e-scroll-fixed">
|
||||||
|
{SETSTYLE=site_info}
|
||||||
|
{ADMINUI_HELP}
|
||||||
|
{ADMIN_HELP}
|
||||||
|
</div>
|
||||||
|
{ADMIN_SITEINFO=creditsonly}
|
||||||
|
{SETSTYLE=admin_menu}
|
||||||
|
{ADMIN_LATEST=infopanel}
|
||||||
|
{ADMIN_STATUS=infopanel}
|
||||||
|
{ADMIN_LOG=request}
|
||||||
|
{ADMIN_MSG=request}
|
||||||
|
{ADMIN_PLUGINS}
|
||||||
|
{SETSTYLE=default}
|
||||||
|
</div>
|
||||||
|
<div class="col-md-9 col-lg-10" id="right-panel">
|
||||||
|
<div class="sidebar-toggle">
|
||||||
|
<a href="#" title="Toggle Sidebar" data-toggle-sidebar="true"> </a>
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
';
|
||||||
|
|
||||||
$ADMIN_FOOTER = '
|
$ADMIN_FOOTER = '
|
||||||
</div><!--/row-->
|
</div><!--/row-->
|
||||||
</div><!--/span-->
|
</div><!--/span-->
|
||||||
</div><!--/row-->
|
</div><!--/row-->
|
||||||
|
</div><!--/.fluid-container-->
|
||||||
|
|
||||||
</div><!--/.fluid-container-->
|
|
||||||
<footer class="center mute">
|
|
||||||
Copyright © 2008-2015 e107 Inc (e107.org)<br />
|
|
||||||
</footer>';
|
|
||||||
|
|
||||||
|
<footer class="center mute">
|
||||||
|
Copyright © 2008-2015 e107 Inc (e107.org)<br />
|
||||||
|
</footer>
|
||||||
|
';
|
||||||
|
|
||||||
|
|
||||||
//{FS_ADMIN_ALT_NAV}
|
//{FS_ADMIN_ALT_NAV}
|
||||||
|
Reference in New Issue
Block a user