From 03e8ba88e41a23748871e1a23c8b7a1413710c47 Mon Sep 17 00:00:00 2001 From: Thomas Gelf Date: Fri, 9 May 2014 14:53:34 +0000 Subject: [PATCH] Restore click behaviour for table links and rows Multiselect handlers should influence only multiselect tables. Still unhappy with current behaviour, but links should work fine right now. refs #6162 --- public/js/icinga/events.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/public/js/icinga/events.js b/public/js/icinga/events.js index 840cd0bbf..39cd3cd00 100644 --- a/public/js/icinga/events.js +++ b/public/js/icinga/events.js @@ -95,10 +95,10 @@ // We want to catch each link click $(document).on('click', 'a', { self: this }, this.linkClicked); + $(document).on('click', 'tr[href]', { self: this }, this.linkClicked); // Select a table row - $(document).on('click', 'table.action tr[href]', { self: this }, this.rowSelected); - $(document).on('click', 'table.action tr a', { self: this }, this.rowSelected); + $(document).on('click', 'table.multiselect tr[href]', { self: this }, this.rowSelected); $(document).on('click', 'button', { self: this }, this.submitForm); @@ -432,8 +432,8 @@ return false; } - // ignore links inside of tables. - if ($a.closest('table tr').length > 0) { + // ignore multiselect table row clicks + if ($a.is('tr') && $a.closest('table.multiselect').length > 0) { return; }