Fixed issues with click targets

refs #4611
This commit is contained in:
Jannis Moßhammer 2013-09-21 17:59:27 +02:00
parent 4206504c9c
commit 3e195501ac
3 changed files with 4 additions and 3 deletions

View File

@ -21,7 +21,6 @@
<b class="caret"></b> <b class="caret"></b>
</a> </a>
<ul class="dropdown-menu"> <ul class="dropdown-menu">
test
<li id="icinga_app_nav_preferences"> <li id="icinga_app_nav_preferences">
<a href="<?= $this->href('/preference'); ?>"><?= $this->translate('Preferences'); ?> </a> <a href="<?= $this->href('/preference'); ?>"><?= $this->translate('Preferences'); ?> </a>
</li> </li>

View File

@ -422,7 +422,9 @@ define(['jquery', 'logging', 'icinga/componentLoader', 'URIjs/URI', 'URIjs/URITe
} else { } else {
var container = new Container($(targetEl)); var container = new Container($(targetEl));
// detail links render to main by default; // detail links render to main by default;
Icinga.replaceBodyFromUrl(URI($(targetEl).attr('href')).href()); Icinga.replaceBodyFromUrl(
container.updateContainerHref(URI($(targetEl).attr('href')).href())
);
ev.preventDefault(); ev.preventDefault();
ev.stopPropagation(); ev.stopPropagation();

View File

@ -90,7 +90,7 @@ define([
}; };
if (Modernizr.history) { if (Modernizr.history) {
$(document.body).on('click', '#icinganavigation, #icingatopbar', function(ev) { $(document.body).on('click', '#icinganavigation', function(ev) {
var targetEl = ev.target || ev.toElement || ev.relatedTarget; var targetEl = ev.target || ev.toElement || ev.relatedTarget;
if (targetEl.tagName.toLowerCase() !== 'a') { if (targetEl.tagName.toLowerCase() !== 'a') {
return true; return true;