Last active
December 17, 2015 12:59
-
-
Save dougn/5614002 to your computer and use it in GitHub Desktop.
FogBugz BugMonkey Customization script to open selected cases in new windows (tabs).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: View Selected Cases | |
description: Adds a link to the titlebar (if there is one) to open all selected cases in new windows. | |
author: Daniel Jalkut, Doug Napoleone | |
version: 1.0.0.0 | |
js: | |
// Based on original code by Daniel Jalkut: https://gist.github.com/danielpunkass/5612389 | |
if ($('div.viewMoreOptions')) { | |
$('div.viewMoreOptions') | |
.prepend('<a href="javascript:;" id="idCustomDougCA2" ' + | |
'class="novisited listNavLink dotted">' + | |
'View Selected Cases</a> | '); | |
$('#idCustomDougCA2').click(function () { | |
var selected = $('td[style="background-color: rgb(253, 253, 212);"] div nobr span a[class$=vb]:not(.title), ' + | |
'td[style="background-color: rgb(249, 250, 211);"] div nobr span a[class$=vb]:not(.title)'); | |
$.each(selected, function(i, node) { | |
var newWindow = window.open(node.href, "_blank"); | |
}); | |
return false; | |
}); | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment