Fix side-menu position

This commit is contained in:
Duncan Sommerville 2015-08-19 17:18:42 -04:00
parent cfa543e835
commit a8955e2ea1
6 changed files with 97 additions and 99 deletions

View file

@ -1,80 +1,65 @@
<?php echo $this->doctype() ?>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<?php echo $this->headTitle() ?>
<?php echo $this->headLink() ?>
<?php echo $this->headScript() ?>
<?php echo isset($this->google_analytics)?$this->google_analytics:"" ?>
<?php echo isset($this->google_analytics) ? $this->google_analytics : "" ?>
<?php $baseUrl = Application_Common_OsPath::getBaseDir(); ?>
</head>
<body class="page-sub-menu">
<!-- Google Tag Manager -->
<noscript><iframe src="//www.googletagmanager.com/ns.html?id=GTM-55N6NH"
height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
<script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':
new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],
j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=
'//www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);
})(window,document,'script','dataLayer','GTM-55N6NH');</script>
<noscript>
<iframe src="//www.googletagmanager.com/ns.html?id=GTM-55N6NH"
height="0" width="0" style="display:none;visibility:hidden"></iframe>
</noscript>
<script>(function (w, d, s, l, i) {
w[l] = w[l] || [];
w[l].push({
'gtm.start': new Date().getTime(), event: 'gtm.js'
});
var f = d.getElementsByTagName(s)[0],
j = d.createElement(s), dl = l != 'dataLayer' ? '&l=' + l : '';
j.async = true;
j.src =
'//www.googletagmanager.com/gtm.js?id=' + i + dl;
f.parentNode.insertBefore(j, f);
})(window, document, 'script', 'dataLayer', 'GTM-55N6NH');</script>
<!-- End Google Tag Manager -->
<?php echo $this->partial('partialviews/trialBox.phtml', array("is_trial"=>$this->isTrial(), "trial_remain"=> $this->trialRemaining())) ?>
<?php echo $this->partial('partialviews/trialBox.phtml', array("is_trial" => $this->isTrial(), "trial_remain" => $this->trialRemaining())) ?>
<div id="Panel" class="sticky">
<?php if($this->suspended) : ?>
<?php if ($this->suspended) { ?>
<?php echo $this->partial('partialviews/suspended.phtml'); ?>
<?php else : ?>
<?php } else { ?>
<?php echo $this->versionNotify();
$sss = $this->SourceSwitchStatus();
$scs = $this->SourceConnectionStatus();
?>
<?php echo $this->partial('partialviews/header.phtml', array("live_dj_switch"=>$sss['live_dj'], "live_dj_connection"=>$scs['live_dj'], "master_dj_switch"=>$sss['master_dj'], "master_dj_connection"=>$scs['master_dj'],
"scheduled_play_switch"=>$sss['scheduled_play'])) ?>
<?php $partial = array('menu.phtml', 'default');
$this->navigation()->menu()->setPartial($partial); ?>
<?php echo $this->versionNotify();
$sss = $this->SourceSwitchStatus();
$scs = $this->SourceConnectionStatus();
?>
<?php echo $this->partial('partialviews/header.phtml', array(
"live_dj_switch" => $sss['live_dj'], "live_dj_connection" => $scs['live_dj'], "master_dj_switch" => $sss['master_dj'], "master_dj_connection" => $scs['master_dj'],
"scheduled_play_switch" => $sss['scheduled_play']
)) ?>
<?php $partial = array('menu.phtml', 'default');
$this->navigation()->menu()->setPartial($partial); ?>
<script type="text/javascript">
var schedulePreLoaded = <?php
<script type="text/javascript">
var schedulePreLoaded = <?php
//Awful hack to speed up loading - Embed the schedule in the response so that the dashboard
//doesn't have to make a separate AJAX request to get this data.
require_once("ScheduleController.php");
ScheduleController::printCurrentPlaylistForEmbedding();
?>;
//The DOM elements that these calls depend on exist by this point:
parseItems(schedulePreLoaded.entries);
parseSourceStatus(schedulePreLoaded.source_status);
parseSwitchStatus(schedulePreLoaded.switch_status);
}?>;
//The DOM elements that these calls depend on exist by this point:
parseItems(schedulePreLoaded.entries);
parseSourceStatus(schedulePreLoaded.source_status);
parseSwitchStatus(schedulePreLoaded.switch_status);
</script>
<!--<div id="nav">
<div class="logo"></div>
<div class="personal-block solo">
<ol>
<li>
<a id="current-user" href=<?php /*echo $baseUrl . "user/edit-user"*/?>><span class="name"><?php /*echo $this->escape($this->loggedInAs()); */?></span></a>
| <a href=<?php /*echo $baseUrl . "login/logout"*/?>><?php /*echo _("Logout")*/?></a>
</li>
</ol>
</div>
<div id="mobile-nav">
<div class="menu-btn" id="menu-btn">
<div></div>
<span></span>
<span></span>
<span></span>
</div>
</div>
<div class="responsive-menu">
<?php /*echo $this->navigation()->menu() */?>
</div>
<div style="clear:both;"></div>
</div>-->
<?php endif; //suspended ?>
</script>
</div>
<div id="media_type_nav"> <!-- class="content-pane" -->
@ -104,30 +89,34 @@
<div class="media_type_selector dashboard_sub_nav" selection_id="2">
<a href="/showbuilder#playlists"><i class='icon-list icon-white'></i><?php echo _("Playlists") ?></a></div>
<div class="media_type_selector dashboard_sub_nav" selection_id="3">
<a href="/showbuilder#smart-blocks"><i class='icon-time icon-white'></i><?php echo _("Smart Blocks") ?></a></div>
<a href="/showbuilder#smart-blocks"><i class='icon-time icon-white'></i><?php echo _("Smart Blocks") ?></a>
</div>
<div class="media_type_selector dashboard_sub_nav" selection_id="4">
<a href="/showbuilder#webstreams"><i class='icon-random icon-white'></i><?php echo _("Webstreams") ?></a></div>
<hr style="margin-left: 5px; margin-right: 5px">
<div id="nav">
<?php echo $this->navigation()->menu(); ?>
</div>
</div>
<?php $hint = Application_Common_UsabilityHints::getUsabilityHint(); ?>
<div class="usability_hint <?php if ($hint == "") { echo "hidden"; } ?>"><?php echo $hint; ?></div>
<div class="usability_hint <?php if ($hint == "") {
echo "hidden";
} ?>"><?php echo $hint; ?></div>
<div class="wrapper wrapper_panel" id="content">
<div style="display: flex; width: 100%">
<div id="sub-menu">
<h3><?php //parent_page is passed in from controller
echo $this->layout()->parent_page; ?></h3>
<hr>
<?php
$page = $this->navigation()->findOneBy('title', $this->layout()->parent_page);
echo $this->navigation()->menu()->renderMenu($page);
?>
<div style="flex: 0 140px;"> <!-- placeholder object so we can fixed position the submenu -->
<div id="sub-menu">
<h3><?php //parent_page is passed in from controller
echo $this->layout()->parent_page; ?></h3>
<hr>
<?php
$page = $this->navigation()->findOneBy('title', $this->layout()->parent_page);
echo $this->navigation()->menu()->renderMenu($page);
?>
</div>
</div>
<div id="sub-menu-content-panel">
<?php echo $this->layout()->content ?>
@ -179,4 +168,3 @@
</script>
</body>
</html>