diff --git a/productMods/templates/freemarker/body/partials/individual/propStatement-organizationForTraining.ftl b/productMods/templates/freemarker/body/partials/individual/propStatement-organizationForTraining.ftl
index ce7ddb2a..711d2ee7 100644
--- a/productMods/templates/freemarker/body/partials/individual/propStatement-organizationForTraining.ftl
+++ b/productMods/templates/freemarker/body/partials/individual/propStatement-organizationForTraining.ftl
@@ -19,7 +19,7 @@
${statement.personName}
<#else>
<#-- This shouldn't happen, but we must provide for it -->
- ${i18n().missing_person_in_posn}
+ ${i18n().missing_person_in_posn}
#if>
#local>
<#local detailedInfo>
diff --git a/src/edu/cornell/mannlib/vitro/webapp/edit/n3editing/configuration/generators/OrganizationForTrainingGenerator.java b/src/edu/cornell/mannlib/vitro/webapp/edit/n3editing/configuration/generators/OrganizationForTrainingGenerator.java
index 1d8abae7..c7070d8b 100644
--- a/src/edu/cornell/mannlib/vitro/webapp/edit/n3editing/configuration/generators/OrganizationForTrainingGenerator.java
+++ b/src/edu/cornell/mannlib/vitro/webapp/edit/n3editing/configuration/generators/OrganizationForTrainingGenerator.java
@@ -42,7 +42,8 @@ public class OrganizationForTrainingGenerator extends VivoBaseGenerator impleme
conf.setN3Required( Arrays.asList( n3ForNewEdTraining, trainingTypeAssertion ) );
conf.setN3Optional(Arrays.asList( majorFieldAssertion, n3ForAwardedDegree, n3ForNewPerson, n3ForExistingPerson,
- n3ForNewPersonAwardedDegree, n3ForExistingPersonAwardedDegree, deptAssertion, infoAssertion, n3ForStart, n3ForEnd ));
+ n3ForNewPersonAwardedDegree, n3ForExistingPersonAwardedDegree, deptAssertion, infoAssertion, n3ForStart,
+ n3ForEnd, firstNameAssertion, lastNameAssertion ));
conf.addNewResource("edTraining", DEFAULT_NS_FOR_NEW_RESOURCE);
conf.addNewResource("awardedDegree",DEFAULT_NS_FOR_NEW_RESOURCE);
@@ -56,7 +57,7 @@ public class OrganizationForTrainingGenerator extends VivoBaseGenerator impleme
//uris in scope: none
//literals in scope: none
- conf.setUrisOnform( Arrays.asList( "existingPerson", "personType", "degreeType", "trainingType"));
+ conf.setUrisOnform( Arrays.asList( "existingPerson", "degreeType", "trainingType"));
conf.setLiteralsOnForm( Arrays.asList("personLabel", "personLabelDisplay", "awardedDegreeLabel",
"majorField", "dept", "info", "firstName", "lastName"));
@@ -70,7 +71,6 @@ public class OrganizationForTrainingGenerator extends VivoBaseGenerator impleme
conf.addSparqlForExistingUris("awardedDegree", existingAwardedDegreeQuery);
conf.addSparqlForExistingUris("existingPerson", existingPersonQuery);
-// conf.addSparqlForExistingUris("personType", personTypeQuery);
conf.addSparqlForExistingUris("trainingType", trainingTypeQuery);
conf.addSparqlForExistingUris("degreeType", degreeTypeQuery);
conf.addSparqlForExistingUris("intervalNode",existingIntervalNodeQuery);
@@ -177,38 +177,38 @@ public class OrganizationForTrainingGenerator extends VivoBaseGenerator impleme
final static String n3ForNewEdTraining =
"@prefix core: <"+ vivoCore +"> .\n"+
- "?organization ?edTraining .\n" +
+ "?organization ?edTraining .\n" +
"?edTraining a core:EducationalProcess .\n" +
- "?edTraining ?organization .";
+ "?edTraining ?organization .";
final static String trainingTypeAssertion =
"?edTraining a ?trainingType .";
final static String n3ForAwardedDegree =
"@prefix core: <"+ vivoCore +"> .\n"+
- "?edTraining ?awardedDegree . \n" +
- "?awardedDegree ?edTraining . \n" +
- "?awardedDegree ?organization . \n" +
- "?organization ?awardedDegree . \n" +
+ "?edTraining ?awardedDegree . \n" +
+ "?awardedDegree ?edTraining . \n" +
+ "?awardedDegree ?organization . \n" +
+ "?organization ?awardedDegree . \n" +
"?awardedDegree <"+ label +"> ?awardedDegreeLabel . \n" +
- "?awardedDegree ?degreeType .\n"+
- "?degreeType ?awardedDegree . \n"+
+ "?awardedDegree ?degreeType .\n"+
+ "?degreeType ?awardedDegree . \n"+
"?awardedDegree a core:AwardedDegree .";
final static String n3ForNewPerson =
- "?edTraining ?newPerson . \n" +
- "?newPerson ?edTraining . \n" +
+ "?edTraining ?newPerson . \n" +
+ "?newPerson ?edTraining . \n" +
"?newPerson a . \n" +
"?newPerson <"+ label +"> ?personLabel . ";
final static String n3ForExistingPerson =
- "?edTraining ?existingPerson . \n" +
- "?existingPerson ?edTraining . \n" +
- "?existingPerson a ?personType . ";
+ "?edTraining ?existingPerson . \n" +
+ "?existingPerson ?edTraining . \n" +
+ " ";
final static String n3ForNewPersonAwardedDegree =
- "?awardedDegree ?newPerson . \n" +
- "?newPerson ?awardedDegree . \n" +
+ "?awardedDegree ?newPerson . \n" +
+ "?newPerson ?awardedDegree . \n" +
"?newPerson a . \n" +
"?awardedDegree <"+ label +"> ?awardedDegreeLabel . \n" +
"?newPerson <"+ label +"> ?personLabel . ";
@@ -232,8 +232,8 @@ public class OrganizationForTrainingGenerator extends VivoBaseGenerator impleme
"?vcardName vcard:familyName ?lastName .";
final static String n3ForExistingPersonAwardedDegree =
- "?awardedDegree ?existingPerson . \n" +
- "?existingPerson ?awardedDegree . \n" +
+ "?awardedDegree ?existingPerson . \n" +
+ "?existingPerson ?awardedDegree . \n" +
"?awardedDegree <"+ label +"> ?awardedDegreeLabel . \n" +
"?existingPerson a . ";
@@ -266,26 +266,26 @@ public class OrganizationForTrainingGenerator extends VivoBaseGenerator impleme
final static String existingAwardedDegreeQuery =
"SELECT ?existingAwardedDegree WHERE {\n"+
- "?edTraining ?existingAwardedDegree . }\n";
+ "?edTraining ?existingAwardedDegree . }\n";
final static String existingAwardedDegreeLabelQuery =
"SELECT ?existingAwardedDegreeLabel WHERE {\n"+
- "?edTraining ?existingAwardedDegree . \n" +
+ "?edTraining ?existingAwardedDegree . \n" +
"?existingAwardedDegree <"+ label +"> ?existingAwardedDegreeLabel }\n";
final static String existingPersonQuery =
"PREFIX rdfs: <"+ rdfs +"> \n"+
"SELECT ?existingPerson WHERE {\n"+
- "?edTraining ?existingPerson . \n" +
- "?existingPerson ?edTraining . \n" +
+ "?edTraining ?existingPerson . \n" +
+ "?existingPerson ?edTraining . \n" +
"?existingPerson a . \n " +
" }";
final static String personLabelQuery =
"PREFIX rdfs: <"+ rdfs +"> \n"+
"SELECT ?existingPersonLabel WHERE {\n"+
- "?edTraining ?existingPerson . \n" +
- "?existingPerson ?edTraining .\n"+
+ "?edTraining ?existingPerson . \n" +
+ "?existingPerson ?edTraining .\n"+
"?existingPerson <"+ label +"> ?existingPersonLabel .\n"+
"?existingPerson a . \n " +
" }";
@@ -298,7 +298,7 @@ public class OrganizationForTrainingGenerator extends VivoBaseGenerator impleme
final static String degreeTypeQuery =
"PREFIX core: <"+ vivoCore +"> \n"+
"SELECT ?existingDegreeType WHERE {\n"+
- "?edTraining ?existingAwardedDegree . \n"+
+ "?edTraining ?existingAwardedDegree . \n"+
"?existingAwardedDegree a core:AwardedDegree . \n"+
"?existingAwardedDegree core:relates ?existingDegreeType . \n" +
"?existingDegreeType a core:AcademicDegree }";
@@ -370,7 +370,7 @@ public class OrganizationForTrainingGenerator extends VivoBaseGenerator impleme
final static String inverseTrainingAtPersonQuery =
"PREFIX owl: "
+ " SELECT ?inverseTrainingAtPerson "
- + " WHERE { ?inverseTrainingAtPerson owl:inverseOf . } ";
+ + " WHERE { ?inverseTrainingAtPerson owl:inverseOf . } ";
//Adding form specific data such as edit mode
@@ -382,7 +382,7 @@ public class OrganizationForTrainingGenerator extends VivoBaseGenerator impleme
public EditMode getEditMode(VitroRequest vreq) {
List predicates = new ArrayList();
- predicates.add("http://vivoweb.person/ontology/core#relates");
+ predicates.add("http://vivoweb.org/ontology/core#relates");
return EditModeUtils.getEditMode(vreq, predicates);
}
}
diff --git a/src/edu/cornell/mannlib/vitro/webapp/edit/n3editing/configuration/generators/OrganizationHasPositionHistoryGenerator.java b/src/edu/cornell/mannlib/vitro/webapp/edit/n3editing/configuration/generators/OrganizationHasPositionHistoryGenerator.java
index ac562d48..aad3d6b5 100644
--- a/src/edu/cornell/mannlib/vitro/webapp/edit/n3editing/configuration/generators/OrganizationHasPositionHistoryGenerator.java
+++ b/src/edu/cornell/mannlib/vitro/webapp/edit/n3editing/configuration/generators/OrganizationHasPositionHistoryGenerator.java
@@ -129,12 +129,22 @@ public class OrganizationHasPositionHistoryGenerator extends VivoBaseGenerator
+ "?person rdfs:label ?personLabel . ";
private static final String N3_NEW_FIRST_NAME = ""
- + "@prefix foaf: . \n"
- + "?person foaf:firstName ?firstName .";
+ + "@prefix vcard: . \n"
+ + "?person ?vcardPerson . \n"
+ + "?vcardPerson ?person . \n"
+ + "?vcardPerson a . \n"
+ + "?vcardPerson vcard:hasName ?vcardName . \n"
+ + "?vcardName a . \n"
+ + "?vcardName vcard:givenName ?firstName .";
private static final String N3_NEW_LAST_NAME = ""
- + "@prefix foaf: . \n"
- + "?person foaf:lastName ?lastName .";
+ + "@prefix vcard: . \n"
+ + "?person ?vcardPerson . \n"
+ + "?vcardPerson ?person . \n"
+ + "?vcardPerson a . \n"
+ + "?vcardPerson vcard:hasName ?vcardName . \n"
+ + "?vcardName a . \n"
+ + "?vcardName vcard:familyName ?lastName .";
private static final String N3_EXISTING_PERSON = ""
+ "@prefix core: . \n"
@@ -179,6 +189,8 @@ public class OrganizationHasPositionHistoryGenerator extends VivoBaseGenerator
conf.addNewResource("position", DEFAULT_NS_FOR_NEW_RESOURCE);
conf.addNewResource("person", DEFAULT_NS_FOR_NEW_RESOURCE);
+ conf.addNewResource("vcardName", DEFAULT_NS_FOR_NEW_RESOURCE);
+ conf.addNewResource("vcardPerson", DEFAULT_NS_FOR_NEW_RESOURCE);
conf.addNewResource("intervalNode", DEFAULT_NS_FOR_NEW_RESOURCE);
conf.addNewResource("startNode", DEFAULT_NS_FOR_NEW_RESOURCE);
conf.addNewResource("endNode", DEFAULT_NS_FOR_NEW_RESOURCE);