updates for page management - for internal class content type.
This commit is contained in:
parent
5472c77cee
commit
24e7f9ef6d
3 changed files with 28 additions and 5 deletions
|
@ -1,6 +1,6 @@
|
|||
/* $This file is distributed under the terms of the license in /doc/license.txt$ */
|
||||
|
||||
var processIndividualsForClassesDataGetterContent = {
|
||||
var processInternalClassDataGetterContent = {
|
||||
dataGetterClass:null,
|
||||
//can use this if expect to initialize from elsewhere
|
||||
initProcessor:function(dataGetterClassInput) {
|
||||
|
@ -15,13 +15,13 @@ var processIndividualsForClassesDataGetterContent = {
|
|||
classesSelected.push($(this).val());
|
||||
});
|
||||
//If internal class selected, include here
|
||||
var isInternal:false;
|
||||
var isInternal=false;
|
||||
//if this checkbox is checked, then isInternal should be true
|
||||
pageContentSection.find("input[name='display-internalClass']:checked").each(function() {
|
||||
isInternal:true;
|
||||
isInternal=true;
|
||||
});
|
||||
var returnObject = {classGroup:classGroup,
|
||||
classesSelectedInClassGroup:classesSelected,
|
||||
//Not returning class group although could if need be..
|
||||
var returnObject = { classesSelectedInClassGroup:classesSelected,
|
||||
isInternal:isInternal,
|
||||
dataGetterClass:this.dataGetterClass};
|
||||
return returnObject;
|
||||
|
|
|
@ -0,0 +1,5 @@
|
|||
<#-- $This file is distributed under the terms of the license in /doc/license.txt$ -->
|
||||
<#-- Scripts for class group browsing -->
|
||||
<#--Replaces Vitro's processing for individuals for classes with VIVO's processing internal classes-->
|
||||
${scripts.add('<script type="text/javascript" src="${urls.base}/js/menupage/processClassGroupDataGetterContent.js"></script>')}
|
||||
${scripts.add('<script type="text/javascript" src="${urls.base}/js/menupage/processInternalClassDataGetterContent.js"></script>')}
|
|
@ -0,0 +1,18 @@
|
|||
<#-- $This file is distributed under the terms of the license in /doc/license.txt$ -->
|
||||
<#--Sets up script for custom form data. Including here instead of as separate javascript
|
||||
file to ensure this script is always loaded first. Can also make sure placed first in
|
||||
scripts list.-->
|
||||
|
||||
<#--Overwrites original in Vitro by including internalClass as the data getter instead of individuals for classes-->
|
||||
|
||||
<script type="text/javascript">
|
||||
var customFormData = {
|
||||
dataGetterLabelToURI:{
|
||||
//maps labels to URIs
|
||||
"browseClassGroup": "java:edu.cornell.mannlib.vitro.webapp.utils.dataGetter.ClassGroupPageData",
|
||||
"internalClass": "java:edu.cornell.mannlib.vitro.webapp.utils.dataGetter.InternalClassesDataGetter",
|
||||
"sparqlQuery":"java:edu.cornell.mannlib.vitro.webapp.utils.dataGetter.SparqlQueryDataGetter",
|
||||
"fixedHtml":"java:edu.cornell.mannlib.vitro.webapp.utils.dataGetter.FixedHTMLDataGetter"
|
||||
}
|
||||
};
|
||||
</script>
|
Loading…
Add table
Reference in a new issue