mirror of
https://github.com/jenkinsci/jenkins.git
synced 2026-11-13 12:02:20 +00:00
[JENKINS-53462] Use a workaround to submit the form with a trusted event. No comments on the underlying insanity of hudson-behavior.
This commit is contained in:
1 parent
b057abc7b8
commit
fa154b77d1
1 file changed
+10
-1
@@ -517,7 +517,16 @@ function registerRegexpValidator(e,regexp,message) {
|
||||
* YUI Button widget.
|
||||
*/
|
||||
function makeButton(e,onclick) {
|
||||
var h = e.onclick;
|
||||
var type = e.type;
|
||||
var h = e.onclick || function (event) {
|
||||
if (type && type.toLowerCase() === 'submit') {
|
||||
var target = event.target;
|
||||
var form = findAncestor(target, "FORM");
|
||||
form.submit();
|
||||
} else {
|
||||
//FIXME: get some usecases for else
|
||||
}
|
||||
};
|
||||
var clsName = e.className;
|
||||
var n = e.name;
|
||||
var btn = new YAHOO.widget.Button(e,{});
|
||||
|
||||
Reference in new issue
Block a user