BUGFIX Fixed 'add member' popup in SecurityAdmin

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/cms/trunk@92851 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
Ingo Schommer 2009-11-21 03:21:10 +00:00
parent 683dfa9426
commit 2c7e4c1dd4

View File

@ -17,13 +17,20 @@
} }
); );
}); });
$.concrete('ss', function($){
$('#Form_EditForm .Actions #action_addmember').concrete({
onclick: function(e) {
// CAUTION: Assumes that a MemberTableField-instance is present as an editing form
var t = $('#Form_EditForm_Members');
t[0].openPopup(
null,
$('base').attr('href') + t.find('a.addlink').attr('href'),
t.find('table')[0]
);
return false;
}
});
});
}(jQuery)); }(jQuery));
/**
* CAUTION: Assumes that a MemberTableField-instance is present as an editing form
*/
function action_addmember_right() {
var memberTableFields = document.getElementsBySelector('#Form_EditForm div.MemberTableField');
var tables = document.getElementsBySelector('#Form_EditForm div.MemberTableField table');
var addLinks = document.getElementsBySelector('#Form_EditForm div.MemberTableField a.addlink');
memberTableFields[0].openPopup(null,addLinks[0].href,tables[0]);
}