2010-02-17 00:22:49 +01:00
|
|
|
(function($) {
|
|
|
|
|
|
|
|
// Hide all owner dropdowns except the one for the current subsite
|
|
|
|
function showCorrectSubsiteIDDropdown(value) {
|
2013-03-18 03:20:51 +01:00
|
|
|
var domid = 'ContentReviewOwnerID' + value;
|
2010-02-17 00:22:49 +01:00
|
|
|
|
|
|
|
var ownerIDDropdowns = $('div.subsiteSpecificOwnerID');
|
|
|
|
for(var i = 0; i < ownerIDDropdowns.length; i++) {
|
|
|
|
if(ownerIDDropdowns[i].id == domid)
|
|
|
|
$(ownerIDDropdowns[i]).show();
|
|
|
|
else
|
|
|
|
$(ownerIDDropdowns[i]).hide();
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
// Call method to show on report load
|
|
|
|
$('#Form_EditForm_SubsiteIDWithOwner').livequery(
|
|
|
|
function() {
|
|
|
|
showCorrectSubsiteIDDropdown(this.value);
|
|
|
|
}
|
|
|
|
);
|
|
|
|
|
|
|
|
// Call method to show on dropdown change
|
|
|
|
$('#Form_EditForm_SubsiteIDWithOwner').livequery('change',
|
|
|
|
function() {
|
|
|
|
showCorrectSubsiteIDDropdown(this.value);
|
|
|
|
}
|
|
|
|
);
|
|
|
|
|
|
|
|
})(jQuery);
|