Don't show header items during maintenance mode

merge-requests/28/head
Mike Koch 8 years ago
parent e6ff8672cf
commit eeadeb543d

@ -40,6 +40,7 @@ if (!function_exists('mfh_getSettings')) {
$modsForHesk_settings = array(); $modsForHesk_settings = array();
if (is_dir(HESK_PATH . 'install')) { if (is_dir(HESK_PATH . 'install')) {
define('MAINTENANCE_MODE', true);
$modsForHesk_settings['navbar_title_url'] = 'javascript:;'; $modsForHesk_settings['navbar_title_url'] = 'javascript:;';
$modsForHesk_settings['rtl'] = 0; $modsForHesk_settings['rtl'] = 0;
$modsForHesk_settings['use_bootstrap_theme'] = 1; $modsForHesk_settings['use_bootstrap_theme'] = 1;
@ -55,14 +56,14 @@ if (is_dir(HESK_PATH . 'install')) {
$modsForHesk_settings['dropdownItemTextHoverColor'] = '#262626'; $modsForHesk_settings['dropdownItemTextHoverColor'] = '#262626';
$modsForHesk_settings['dropdownItemTextHoverBackgroundColor'] = '#f5f5f5'; $modsForHesk_settings['dropdownItemTextHoverBackgroundColor'] = '#f5f5f5';
$modsForHesk_settings['questionMarkColor'] = '#000000'; $modsForHesk_settings['questionMarkColor'] = '#000000';
$modsForHesk_settings['enable_calendar'] = 1;
} else { } else {
$modsForHesk_settings = mfh_getSettings(); $modsForHesk_settings = mfh_getSettings();
} }
?> ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" <!DOCTYPE html>
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head> <head>
<title><?php echo(isset($hesk_settings['tmp_title']) ? $hesk_settings['tmp_title'] : $hesk_settings['hesk_title']); ?></title> <title><?php echo(isset($hesk_settings['tmp_title']) ? $hesk_settings['tmp_title'] : $hesk_settings['hesk_title']); ?></title>
<meta http-equiv="Content-Type" content="text/html;charset=<?php echo $hesklang['ENCODING']; ?>"/> <meta http-equiv="Content-Type" content="text/html;charset=<?php echo $hesklang['ENCODING']; ?>"/>
@ -283,7 +284,7 @@ if ($modsForHesk_settings['show_icons']) {
<div class="navbar-collapse collapse"> <div class="navbar-collapse collapse">
<ul class="nav navbar-nav"> <ul class="nav navbar-nav">
<?php <?php
if ($hesk_settings['kb_enable'] !== 2) { if ($hesk_settings['kb_enable'] !== 2 && !defined('MAINTENANCE_MODE')) {
$active = ''; $active = '';
if (defined('PAGE_TITLE') && PAGE_TITLE == 'CUSTOMER_HOME') { if (defined('PAGE_TITLE') && PAGE_TITLE == 'CUSTOMER_HOME') {
$active = 'class="active"'; $active = 'class="active"';
@ -313,9 +314,7 @@ if ($modsForHesk_settings['show_icons']) {
</li> </li>
<?php <?php
} }
?> if ($hesk_settings['kb_enable'] && !defined('MAINTENANCE_MODE')) {
<?php if ($hesk_settings['kb_enable']) {
$active = ''; $active = '';
if (defined('PAGE_TITLE') && PAGE_TITLE == 'CUSTOMER_KB') { if (defined('PAGE_TITLE') && PAGE_TITLE == 'CUSTOMER_KB') {
$active = 'class="active"'; $active = 'class="active"';
@ -328,7 +327,7 @@ if ($modsForHesk_settings['show_icons']) {
if (defined('PAGE_TITLE') && PAGE_TITLE == 'CUSTOMER_CALENDAR') { if (defined('PAGE_TITLE') && PAGE_TITLE == 'CUSTOMER_CALENDAR') {
$active = ' active'; $active = ' active';
} }
if ($modsForHesk_settings['enable_calendar'] == 1): if ($modsForHesk_settings['enable_calendar'] == 1 && !defined('MAINTENANCE_MODE')):
?> ?>
<li class="<?php echo $active; ?>"> <li class="<?php echo $active; ?>">
<a href="<?php echo HESK_PATH; ?>calendar.php"><i class="fa fa-calendar" <?php echo $iconDisplay; ?>></i>&nbsp;<?php echo $hesklang['calendar_title_case']; ?></a> <a href="<?php echo HESK_PATH; ?>calendar.php"><i class="fa fa-calendar" <?php echo $iconDisplay; ?>></i>&nbsp;<?php echo $hesklang['calendar_title_case']; ?></a>
@ -338,11 +337,13 @@ if ($modsForHesk_settings['show_icons']) {
</ul> </ul>
<?php if ($hesk_settings['can_sel_lang']) { ?> <?php if ($hesk_settings['can_sel_lang']) { ?>
<div class="navbar-form navbar-right" role="search" style="margin-right: 20px; min-width: 80px;"> <div class="navbar-form navbar-right" role="search" style="margin-right: 20px; min-width: 80px;">
<?php <?php
if (defined('PAGE_TITLE') && PAGE_TITLE == 'CUSTOMER_TICKET') { if (!defined('MAINTENANCE_MODE')) {
hesk_getLanguagesAsFormIfNecessary($trackingID); if (defined('PAGE_TITLE') && PAGE_TITLE == 'CUSTOMER_TICKET') {
} else { hesk_getLanguagesAsFormIfNecessary($trackingID);
hesk_getLanguagesAsFormIfNecessary(); } else {
hesk_getLanguagesAsFormIfNecessary();
}
} }
?> ?>
</div> </div>

Loading…
Cancel
Save