page management related updates
This commit is contained in:
parent
7da1f47b62
commit
f327e91a3c
12 changed files with 266 additions and 80 deletions
|
@ -15,7 +15,19 @@ var processClassGroupDataGetterContent = {
|
|||
//query model should also be an input, ensure class group URI is saved as URI and not string
|
||||
var returnObject = {classGroup:classGroup, dataGetterClass:this.dataGetterClass};
|
||||
return returnObject;
|
||||
},
|
||||
//For an existing set of content where form is already set, fill in the values
|
||||
populatePageContentSection:function(existingContentObject, pageContentSection) {
|
||||
var classGroupValue = existingContentObject["classGroup"];
|
||||
pageContentSection.find("select[name='selectClassGroup']").val(classGroupValue);
|
||||
},
|
||||
//For the label of the content section for editing, need to add additional value
|
||||
retrieveAdditionalLabelText:function(existingContentObject) {
|
||||
//Right now return empty but can hook this into a hashmap with labels and uris
|
||||
//set up in browse class group
|
||||
return "";
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
|
@ -19,6 +19,24 @@ var processIndividualsForClassesDataGetterContent = {
|
|||
});
|
||||
var returnObject = {classGroup:classGroup, classesSelectedInClassGroup:classesSelected, dataGetterClass:this.dataGetterClass};
|
||||
return returnObject;
|
||||
}
|
||||
},
|
||||
//For an existing set of content where form is already set, fill in the values
|
||||
populatePageContentSection:function(existingContentObject, pageContentSection) {
|
||||
var classGroupValue = existingContentObject["classGroup"];
|
||||
var classesSelected = existingContenetObject["classesSelectedInClassGroup"];
|
||||
var numberSelected = classesSelected.length;
|
||||
var i;
|
||||
for(i = 0; i < numberSelected; i++) {
|
||||
var classSelected = classesSelected[i];
|
||||
pageContentSection.find("input[name='classInClassGroup'][value='" + classSelected + "']").attr("checked", "checked");
|
||||
}
|
||||
pageContentSection.find("select[name='selectClassGroup']").val(classGroupValue);
|
||||
},
|
||||
//For the label of the content section for editing, need to add additional value
|
||||
retrieveAdditionalLabelText:function(existingContentObject) {
|
||||
//Right now return empty but can hook this into a hashmap with labels and uris
|
||||
//set up in browse class group
|
||||
return "";
|
||||
}
|
||||
|
||||
}
|
|
@ -17,6 +17,21 @@ var processSparqlDataGetterContent = {
|
|||
//set query model to query model here - vitro:contentDisplayModel
|
||||
var returnObject = {saveToVar:variableValue, query:queryValue, dataGetterClass:this.dataGetterClass, queryModel:queryModel};
|
||||
return returnObject;
|
||||
},
|
||||
//For an existing set of content where form is already set, fill in the values
|
||||
populatePageContentSection:function(existingContentObject, pageContentSection) {
|
||||
var saveToVarValue = existingContentObject["saveToVar"];
|
||||
var queryValue = existingContentObject["query"];
|
||||
var queryModelValue = existingContentObject["queryModel"];
|
||||
//Now find and set value
|
||||
pageContentSection.find("input[name='saveToVar']").val(saveToVarValue);
|
||||
pageContentSection.find("textarea[name='query']").val(queryValue);
|
||||
pageContentSection.find("input[name='queryModel']").val(queryModelValue);
|
||||
},
|
||||
//For the label of the content section for editing, need to add additional value
|
||||
retrieveAdditionalLabelText:function(existingContentObject) {
|
||||
var saveToVarValue = existingContentObject["saveToVar"];
|
||||
return saveToVarValue;
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue