Improve click/site behaviour

This commit is contained in:
Thomas Gelf 2014-03-09 23:30:37 +01:00
parent 11c44af35e
commit fcd05dfe81
3 changed files with 7 additions and 2 deletions

View File

@ -15,7 +15,7 @@ if ($notifications->hasMessages()) {
} }
} }
?></ul> ?></ul>
<div id="logo"><a href="<?= $this->href('/dashboard') ?>"><img src="<?= $this->href('img/logo_icinga-inv.png') ?>" class="logo" /></a> <div id="logo" data-base-target="_main"><a href="<?= $this->href('/dashboard') ?>"><img src="<?= $this->href('img/logo_icinga-inv.png') ?>" class="logo" /></a>
</div> </div>
</div> </div>
<!-- <!--

View File

@ -12,7 +12,7 @@ if (! $this->auth()->isAuthenticated()) {
$url = Url::fromRequest()->remove('_render')->getRelativeUrl(); $url = Url::fromRequest()->remove('_render')->getRelativeUrl();
$menu = Menu::fromConfig(); $menu = Menu::fromConfig();
?> ?>
<div id="menu" data-base-target="col1"> <div id="menu" data-base-target="_main">
<form action="<?= $this->href('search') ?>" method="post"> <form action="<?= $this->href('search') ?>" method="post">
<input type="text" name="q" class="search" placeholder="Search..." autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false" /> <input type="text" name="q" class="search" placeholder="Search..." autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false" />
</form> </form>

View File

@ -250,6 +250,11 @@
targetId = 'col2'; targetId = 'col2';
} }
if (targetId === '_main') {
targetId = 'col1';
icinga.ui.layout1col();
}
$target = $('#' + targetId); $target = $('#' + targetId);
} }