mirror of
https://github.com/e107inc/e107.git
synced 2025-07-30 19:30:25 +02:00
AdminUI: Modal option added to adminMenu navigation. Fixed #uiAlert - was not functioning as intended.
This commit is contained in:
@@ -541,7 +541,7 @@ echo "</head>
|
||||
<body".$body_onload.">\n";
|
||||
|
||||
echo getModal();
|
||||
// echo getAlert();
|
||||
echo getAlert();
|
||||
|
||||
function getModal($caption = '', $type='')
|
||||
{
|
||||
@@ -575,11 +575,11 @@ echo getModal();
|
||||
|
||||
function getAlert($caption='')
|
||||
{
|
||||
|
||||
return '<div id="uiAlert" class="alert alert-block alert-success hide fade in" style="box-shadow:0px 15px 8px #000;width:300px;position:absolute;left:40%;right:40%;top:15%;z-index:10000">
|
||||
<!-- rest of alert code goes here --> some
|
||||
Some text goes here and there and everywhere.
|
||||
</div>';
|
||||
// style="box-shadow:0px 15px 8px #000;width:300px;position:absolute;left:40%;right:40%;top:15%;z-index:10000"
|
||||
|
||||
|
||||
|
||||
return '<div id="uiAlert" class="notifications center"><!-- empty --></div>';
|
||||
|
||||
}
|
||||
|
||||
|
@@ -443,10 +443,11 @@ define("E_32_TRUE", "<i class='S32 e-true-32'></i>");
|
||||
|
||||
define("ADMIN_TRUE_ICON", "<i class='S16 e-true-16'></i>");
|
||||
define("ADMIN_FALSE_ICON", "<i class='S16 e-false-16'></i>");
|
||||
|
||||
define("ADMIN_WARNING_ICON", "<i class='S16 e-warning-16'></i>");
|
||||
|
||||
define("ADMIN_EDIT_ICON", "<i class='S32 e-edit-32'></i>");
|
||||
define("ADMIN_DELETE_ICON", "<i class='S32 e-delete-32'></i>");
|
||||
define("ADMIN_WARNING_ICON", "<i class='S32 e-warning-32'></i>");
|
||||
|
||||
define("ADMIN_ADD_ICON", "<i class='S32 e-add-32'></i>");
|
||||
define("ADMIN_INFO_ICON", "<i class='S16 e-info-16'></i>");
|
||||
define("ADMIN_CONFIGURE_ICON", "<i class='S32 e-configure-32'></i>");
|
||||
|
@@ -1549,6 +1549,16 @@ class e_admin_dispatcher
|
||||
/*$var[$key]['text'] = $val['caption'];
|
||||
$var[$key]['link'] = (vartrue($val['url']) ? $tp->replaceConstants($val['url'], 'abs') : e_SELF).'?mode='.$tmp[0].'&action='.$tmp[1];
|
||||
$var[$key]['perm'] = $val['perm']; */
|
||||
if(!empty($val['modal']))
|
||||
{
|
||||
$var[$key]['link_class'] = ' e-modal';
|
||||
if(!empty($val['modal-caption']))
|
||||
{
|
||||
$var[$key]['link_data'] = array('data-modal-caption' => $val['modal-caption']);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
@@ -1177,13 +1177,16 @@ i.e-cat_users-32{ background-position: -555px 0; width: 32px; height: 32px; }
|
||||
$search[7] = '/\{LINK_CLASS\}(.*?)/si';
|
||||
$search[8] = '/\{SUB_CLASS\}(.*?)/si';
|
||||
$search[9] = '/\{LINK_IMAGE\}(.*?)/si';
|
||||
|
||||
$search[10] = '/\{LINK_DATA\}/si';
|
||||
|
||||
foreach (array_keys($e107_vars) as $act)
|
||||
{
|
||||
if (isset($e107_vars[$act]['perm']) && !getperms($e107_vars[$act]['perm'])) // check perms first.
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
|
||||
|
||||
if (isset($e107_vars[$act]['header']))
|
||||
{
|
||||
@@ -1209,6 +1212,9 @@ i.e-cat_users-32{ background-position: -555px 0; width: 32px; height: 32px; }
|
||||
// print_a($e107_vars[$act]);
|
||||
|
||||
$replace = array();
|
||||
|
||||
|
||||
|
||||
|
||||
$rid = str_replace(array(' ', '_'), '-', $act).($id ? "-{$id}" : '');
|
||||
|
||||
@@ -1272,6 +1278,19 @@ i.e-cat_users-32{ background-position: -555px 0; width: 32px; height: 32px; }
|
||||
{
|
||||
$replace[9] = varset($e107_vars[$act]['image']);
|
||||
}
|
||||
|
||||
if(!empty($e107_vars[$act]['link_data']))
|
||||
{
|
||||
|
||||
$dataTmp = array();
|
||||
foreach($e107_vars[$act]['link_data'] as $k=>$v)
|
||||
{
|
||||
$dataTmp[] = $k.'="'.$v.'"';
|
||||
}
|
||||
|
||||
$replace[10] = implode(" ", $dataTmp); // $e107_vars[$act]['link_data']
|
||||
|
||||
}
|
||||
|
||||
|
||||
if($rid == 'logout' || $rid == 'home' || $rid == 'language')
|
||||
|
@@ -1017,6 +1017,16 @@ li.rssRow > div {
|
||||
}
|
||||
|
||||
|
||||
|
||||
/* uiAlert Styling */
|
||||
|
||||
.notifications{position:fixed;}.notifications.top-right{right:10px;top:25px;}
|
||||
.notifications.top-left{left:10px;top:25px;}
|
||||
.notifications.bottom-left{left:10px;bottom:25px;}
|
||||
.notifications.bottom-right{right:10px;bottom:25px;}
|
||||
.notifications>div{position:relative;z-index:9999;margin:5px 0px;}
|
||||
.notifications.center{top:30%;left:0;width:100%;}.notifications.center>div{margin:5px auto;width:20%;text-align:center;}
|
||||
|
||||
/*
|
||||
|
||||
body { background-color: rgb(68, 68, 68); }
|
||||
|
@@ -331,13 +331,13 @@ $E_ADMIN_MENU['start'] = '
|
||||
|
||||
$E_ADMIN_MENU['button'] = '
|
||||
<li>
|
||||
<a class="link{LINK_CLASS}" href="{LINK_URL}"{ID}{ONCLICK}><i class="icon-chevron-right"></i> {LINK_TEXT}</a>
|
||||
<a class="link{LINK_CLASS}" {LINK_DATA} href="{LINK_URL}"{ID}{ONCLICK}>{LINK_TEXT} </a>
|
||||
{SUB_MENU}
|
||||
</li>
|
||||
';
|
||||
$E_ADMIN_MENU['button_active'] = '
|
||||
<li class="active">
|
||||
<a class="link-active{LINK_CLASS}" href="{LINK_URL}"{ID}{ONCLICK}><i class="icon-chevron-right"></i> {LINK_TEXT}</a>
|
||||
<a class="link-active{LINK_CLASS}" {LINK_DATA} href="{LINK_URL}"{ID}{ONCLICK}>{LINK_TEXT} </a>
|
||||
{SUB_MENU}
|
||||
</li>
|
||||
';
|
||||
|
Reference in New Issue
Block a user