NIHVIVO-646 More work on addAuthorsToInformationResource custom form. Create edit submission preprocessing mechanism to make automated modifications to the form submission (e.g., creating a label from first, last, and middle name entries).

This commit is contained in:
rjy7 2010-06-15 19:35:38 +00:00
parent ab3e088cdf
commit 8570254efb
4 changed files with 64 additions and 37 deletions

View file

@ -31,13 +31,13 @@
WebappDaoFactory wdf = vreq.getWebappDaoFactory();
vreq.setAttribute("defaultNamespace", ""); //empty string triggers default new URI behavior
String flagURI = null;
String flagUri = null;
if (vreq.getAppBean().isFlag1Active()) {
flagURI = VitroVocabulary.vitroURI+"Flag1Value"+vreq.getPortal().getPortalId()+"Thing";
flagUri = VitroVocabulary.vitroURI+"Flag1Value"+vreq.getPortal().getPortalId()+"Thing";
} else {
flagURI = wdf.getVClassDao().getTopConcept().getURI(); // fall back to owl:Thing if not portal filtering
flagUri = wdf.getVClassDao().getTopConcept().getURI(); // fall back to owl:Thing if not portal filtering
}
vreq.setAttribute("flagURI",flagURI);
vreq.setAttribute("flagUri",flagUri);
request.setAttribute("stringDatatypeUriJson", MiscWebUtils.escape(XSD.xstring.toString()));
request.setAttribute("gYearDatatypeUriJson", MiscWebUtils.escape(XSD.gYear.toString()));
@ -121,7 +121,7 @@
?positionUri core:positionForPerson ?person ;
a ?positionType ,
<${flagURI}> .
<${flagUri}> .
</v:jsonset>
<v:jsonset var="n3ForNewOrg">
@ -129,7 +129,7 @@
?newOrg <${label}> ?newOrgName ;
a ?newOrgType ,
<${flagURI}> ;
<${flagUri}> ;
<${orgForPositionPred}> ?positionUri .
</v:jsonset>