Updating javascript to enable display of correct content type name in internal class message "only display x within my institution" on content type change. NIHVIVO-3026
This commit is contained in:
parent
154a3b80ad
commit
e1eca52416
1 changed files with 9 additions and 2 deletions
|
@ -19,12 +19,13 @@ var menuManagementEdit = {
|
|||
this.selectedGroupForPage = $('#selectedContentTypeValue');
|
||||
// this.selectClassesMessage = $('#selectClassesMessage');
|
||||
this.allClassesSelectedCheckbox = $('#allSelected');
|
||||
|
||||
this.displayInternalMessage = $('#internal-class label em');
|
||||
},
|
||||
bindEventListeners: function() {
|
||||
// Listeners for vClass switching
|
||||
this.changeContentType.click(function() {
|
||||
menuManagementEdit.showClassGroups();
|
||||
|
||||
return false;
|
||||
});
|
||||
this.selectClassGroupDropdown.change(function() {
|
||||
|
@ -54,6 +55,10 @@ var menuManagementEdit = {
|
|||
}
|
||||
});
|
||||
},
|
||||
updateInternalClassMessage:function(classGroupName) { //User has changed content type
|
||||
//Set content type within internal class message
|
||||
this.displayInternalMessage.filter(":first").html(classGroupName);
|
||||
},
|
||||
showClassGroups: function() { //User has clicked change content type
|
||||
//Show the section with the class group dropdown
|
||||
this.selectContentType.removeClass("hidden");
|
||||
|
@ -148,6 +153,8 @@ var menuManagementEdit = {
|
|||
menuManagementEdit.hideClassGroups();
|
||||
|
||||
menuManagementEdit.selectedGroupForPage.html(results.classGroupName);
|
||||
//update content type in message to "display x within my institution"
|
||||
menuManagementEdit.updateInternalClassMessage(results.classGroupName);
|
||||
//retrieve classes for class group and display with all selected
|
||||
var selectedClassesList = menuManagementEdit.classesForClassGroup.children('ul#selectedClasses');
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue