Theme: Add ability to specify target on table row link.

This commit is contained in:
Nate 2019-05-06 10:08:15 -06:00
parent cd5dd78c25
commit 75a4154453
1 changed files with 8 additions and 4 deletions

View File

@ -201,7 +201,11 @@ echo "<script language='JavaScript' type='text/javascript' src='<!--{project_pat
$('.tr_hover tr').each(function(i,e) { $('.tr_hover tr').each(function(i,e) {
$(e).children('td:not(.list_control_icon,.list_control_icons,.tr_link_void)').click(function() { $(e).children('td:not(.list_control_icon,.list_control_icons,.tr_link_void)').click(function() {
var href = $(this).closest("tr").attr("href"); var href = $(this).closest("tr").attr("href");
if (href) { window.location = href; } var target = $(this).closest('tr').attr('target');
if (href) {
if (target) { window.open(href, target); }
else { window.location = href; }
}
}); });
}); });