]> git.ipfire.org Git - thirdparty/bacula.git/commitdiff
baculum: Fix opening job details in job table on main dashboard page - reported by...
authorMarcin Haba <marcin.haba@bacula.pl>
Wed, 7 Jul 2021 17:48:12 +0000 (19:48 +0200)
committerEric Bollengier <eric@baculasystems.com>
Thu, 24 Mar 2022 08:03:25 +0000 (09:03 +0100)
gui/baculum/protected/Web/JavaScript/misc.js

index d8d6c9e3cdf3b00028836f797e13d5c74d5c318c..e11b6e5f4759ac1b593a38ce4f411483d123cae4 100644 (file)
@@ -775,8 +775,15 @@ var oLastJobsList = {
        set_events: function() {
                var self = this;
                $('#' + this.ids.last_jobs_list + ' tbody').on('click', 'tr', function (e) {
-                       var data = self.last_jobs_table.row(this).data();
-                       document.location.href = '/web/job/history/' + data.jobid + '/'
+                       var td = e.target;
+                       if (td.nodeName != 'TD') {
+                               td = $(td).closest('td');
+                       }
+                       // first cell should not be clickable, it contains the button to open row details
+                       if ($(td).index() > 0) {
+                               var data = self.last_jobs_table.row(this).data();
+                               document.location.href = '/web/job/history/' + data.jobid + '/'
+                       }
                });
        }
 };