From f1587409f24f3f5b37b574e1a6a4022a043f8281 Mon Sep 17 00:00:00 2001 From: hudajkhan Date: Wed, 30 Oct 2013 16:29:24 -0400 Subject: [PATCH 1/6] updates for restricting broader/narrower term to adding individuals with most specific type of concept, and updates to isPersonType for new individual form --- .../edit/forms/addAssociatedConcept.ftl | 3 + ...nceptThroughObjectPropertyAutoComplete.ftl | 145 ++++++++++++++++++ ...dConceptThroughObjectPropertyCreateNew.ftl | 35 +++++ .../addConceptThroughObjectPropertyForm.ftl | 49 ++++++ rdf/tbox/firsttime/initialTBoxAnnotations.n3 | 4 + ...ConceptThroughObjectPropertyGenerator.java | 133 ++++++++++++++++ .../NewIndividualFormGenerator.java | 4 +- 7 files changed, 372 insertions(+), 1 deletion(-) create mode 100644 productMods/templates/freemarker/edit/forms/addConceptThroughObjectPropertyAutoComplete.ftl create mode 100644 productMods/templates/freemarker/edit/forms/addConceptThroughObjectPropertyCreateNew.ftl create mode 100644 productMods/templates/freemarker/edit/forms/addConceptThroughObjectPropertyForm.ftl create mode 100644 src/edu/cornell/mannlib/vitro/webapp/edit/n3editing/configuration/generators/AddConceptThroughObjectPropertyGenerator.java diff --git a/productMods/templates/freemarker/edit/forms/addAssociatedConcept.ftl b/productMods/templates/freemarker/edit/forms/addAssociatedConcept.ftl index ee613943..fe1f81c6 100644 --- a/productMods/templates/freemarker/edit/forms/addAssociatedConcept.ftl +++ b/productMods/templates/freemarker/edit/forms/addAssociatedConcept.ftl @@ -66,6 +66,9 @@
<#if existingConcept.vocabURI?has_content && existingConcept.vocabLabel?has_content> ${existingConcept.vocabLabel} + <#else> +   + <#--We still want the column to be there even if no vocabulary source is present-->
diff --git a/productMods/templates/freemarker/edit/forms/addConceptThroughObjectPropertyAutoComplete.ftl b/productMods/templates/freemarker/edit/forms/addConceptThroughObjectPropertyAutoComplete.ftl new file mode 100644 index 00000000..9d92cefa --- /dev/null +++ b/productMods/templates/freemarker/edit/forms/addConceptThroughObjectPropertyAutoComplete.ftl @@ -0,0 +1,145 @@ +<#-- $This file is distributed under the terms of the license in /doc/license.txt$ --> +<#--Assign variables from editConfig--> +<#assign rangeOptions = editConfiguration.pageData.objectVar /> +<#-- +<#assign rangeOptionsExist = false /> +<#if (rangeOptions?keys?size > 0)> + <#assign rangeOptionsExist = true/> + + --> + +<#assign rangeOptionsExist = true /> + +<#assign objectTypes = editConfiguration.pageData.objectTypes /> +<#assign objectTypesSize = objectTypes?length /> +<#assign objectTypesExist = false /> +<#assign multipleTypes = false /> +<#if (objectTypesSize > 1)> + <#assign objectTypesExist = true /> + +<#if objectTypes?contains(",")> + <#assign multipleTypes = true/> + +<#assign sparqlForAcFilter = editConfiguration.pageData.sparqlForAcFilter /> +<#assign editMode = editConfiguration.pageData.editMode /> +<#assign propertyNameForDisplay = "" /> +<#if editConfiguration.objectPropertyNameForDisplay?has_content> + <#assign propertyNameForDisplay = editConfiguration.objectPropertyNameForDisplay /> + +<#if editMode = "edit" > + <#assign titleVerb = "${i18n().edit_capitalized}" /> + <#assign objectLabel = editConfiguration.pageData.objectLabel /> + <#assign selectedObjectUri = editConfiguration.objectUri /> + <#assign submitButtonText = "${i18n().save_button}" /> +<#else> + <#assign titleVerb = "${i18n().add_capitalized}" > + <#assign objectLabel = "" /> + <#assign selectedObjectUri = ""/> + <#assign submitButtonText = "${i18n().create_entry}" /> + + +<#if editConfiguration.formTitle?contains("collaborator") > + <#assign formTitle = "${i18n().select_existing_collaborator(editConfiguration.subjectName)}" /> +<#else> + <#assign formTitle = editConfiguration.formTitle /> + +<#--In order to fill out the subject--> +<#assign acFilterForIndividuals = "['" + editConfiguration.subjectUri + "']" /> + +

${formTitle}

+ +<#if editConfiguration.propertySelectFromExisting = true> + <#if rangeOptionsExist = true > +
+ + <#if editConfiguration.propertyPublicDescription?has_content> +

${editConfiguration.propertyPublicDescription}

+ + + <#---This section should become autocomplete instead--> +

+ + +

+ +
+

+ + + (${i18n().verify_this_match} ${i18n().or} + ${i18n().change_selection}) +

+ +
+ + <#--The above section should be autocomplete--> + +

+ + + or + ${i18n().cancel_link} +

+
+ <#else> +

${i18n().there_are_no_entries_for_selection}

+ + +

 

+<#if editConfiguration.propertyOfferCreateNewOption = true> +<#include "addConceptThroughObjectPropertyCreateNew.ftl"> + + + +<#if editConfiguration.propertySelectFromExisting = false && editConfiguration.propertyOfferCreateNewOption = false> +

${i18n().editing_prohibited}

+ + + +<#if editConfiguration.includeDeletionForm = true> +<#include "defaultDeletePropertyForm.ftl"> + + + +<#assign sparqlQueryUrl = "${urls.base}/ajax/sparqlQuery" > +<#--Passing in object types only if there are any types returned, otherwise +the parameter should not be passed at all to the solr search. +Also multiple types parameter set to true only if more than one type returned--> + +<#-- + edu.cornell.mannlib.vitro.webapp.edit.n3editing.configuration.generators.AutocompleteObjectPropertyFormGenerator + edu.cornell.mannlib.vitro.webapp.edit.n3editing.configuration.generators.AddAttendeeRoleToPersonGenerator +--> + +${stylesheets.add('')} + ${stylesheets.add('')} + ${stylesheets.add('')} + + + ${scripts.add('', + '', + '', + '')} diff --git a/productMods/templates/freemarker/edit/forms/addConceptThroughObjectPropertyCreateNew.ftl b/productMods/templates/freemarker/edit/forms/addConceptThroughObjectPropertyCreateNew.ftl new file mode 100644 index 00000000..9efc361b --- /dev/null +++ b/productMods/templates/freemarker/edit/forms/addConceptThroughObjectPropertyCreateNew.ftl @@ -0,0 +1,35 @@ +<#-- $This file is distributed under the terms of the license in /doc/license.txt$ --> +<#--Overriding default form here to allow just concepts to show in the list--> + + <#if rangeOptionsExist = true > +

${i18n().no_appropriate_entry}:

+ <#else> +

${i18n().create_new_entry}

+ + + <#if editConfiguration.objectUri?has_content> + <#assign objectUri = editConfiguration.objectUri> + <#else> + <#assign objectUri = ""/> + + + <#assign typesList = editConfiguration.pageData.createNewTypes/> +
+ + + + + + + + + <#if rangeOptionsExist = false > + ${i18n().or} + ${i18n().cancel_link} + +
\ No newline at end of file diff --git a/productMods/templates/freemarker/edit/forms/addConceptThroughObjectPropertyForm.ftl b/productMods/templates/freemarker/edit/forms/addConceptThroughObjectPropertyForm.ftl new file mode 100644 index 00000000..89b5ddc4 --- /dev/null +++ b/productMods/templates/freemarker/edit/forms/addConceptThroughObjectPropertyForm.ftl @@ -0,0 +1,49 @@ +<#-- $This file is distributed under the terms of the license in /doc/license.txt$ --> + +<#--Assign variables from editConfig--> +<#assign rangeOptions = editConfiguration.pageData.objectVar /> +<#assign rangeOptionsExist = false /> +<#if (rangeOptions?keys?size > 0)> + <#assign rangeOptionsExist = true/> + + +

${editConfiguration.formTitle}

+ +<#if editConfiguration.propertySelectFromExisting = true> + <#if rangeOptionsExist = true > + <#assign rangeOptionKeys = rangeOptions?keys /> +
+ + <#if editConfiguration.propertyPublicDescription?has_content> +

${editConfiguration.propertyPublicDescription}

+ + + +

+ + ${i18n().or} + ${i18n().cancel_link} +

+
+ <#else> +

${i18n().there_are_no_entries_for_selection}

+ + + +<#if editConfiguration.propertyOfferCreateNewOption = true> +<#include "addConceptThroughObjectPropertyCreateNew.ftl"> + + +<#if editConfiguration.propertySelectFromExisting = false && editConfiguration.propertyOfferCreateNewOption = false> +

${i18n().editing_prohibited}

+ + + +<#if editConfiguration.includeDeletionForm = true> +<#include "defaultDeletePropertyForm.ftl"> + + diff --git a/rdf/tbox/firsttime/initialTBoxAnnotations.n3 b/rdf/tbox/firsttime/initialTBoxAnnotations.n3 index 36af8a0a..d8e1fe18 100644 --- a/rdf/tbox/firsttime/initialTBoxAnnotations.n3 +++ b/rdf/tbox/firsttime/initialTBoxAnnotations.n3 @@ -329,6 +329,8 @@ vivo:GovernmentAgency skos:narrower rdfs:label "narrower term"@en-US ; + vitro:customEntryFormAnnot + "edu.cornell.mannlib.vitro.webapp.edit.n3editing.configuration.generators.AddConceptThroughObjectPropertyGenerator"^^xsd:string ; vitro:displayLimitAnnot "5"^^xsd:int ; vitro:displayRankAnnot @@ -4744,6 +4746,8 @@ obo:ERO_0001245 skos:broader rdfs:label "broader term"@en-US ; + vitro:customEntryFormAnnot + "edu.cornell.mannlib.vitro.webapp.edit.n3editing.configuration.generators.AddConceptThroughObjectPropertyGenerator"^^xsd:string ; vitro:displayLimitAnnot "5"^^xsd:int ; vitro:displayRankAnnot diff --git a/src/edu/cornell/mannlib/vitro/webapp/edit/n3editing/configuration/generators/AddConceptThroughObjectPropertyGenerator.java b/src/edu/cornell/mannlib/vitro/webapp/edit/n3editing/configuration/generators/AddConceptThroughObjectPropertyGenerator.java new file mode 100644 index 00000000..56fd11dd --- /dev/null +++ b/src/edu/cornell/mannlib/vitro/webapp/edit/n3editing/configuration/generators/AddConceptThroughObjectPropertyGenerator.java @@ -0,0 +1,133 @@ +/* $This file is distributed under the terms of the license in /doc/license.txt$ */ + +package edu.cornell.mannlib.vitro.webapp.edit.n3editing.configuration.generators; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import javax.servlet.http.HttpSession; + +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; + +import edu.cornell.mannlib.vitro.webapp.beans.Individual; +import edu.cornell.mannlib.vitro.webapp.beans.VClass; +import edu.cornell.mannlib.vitro.webapp.controller.VitroRequest; +import edu.cornell.mannlib.vitro.webapp.dao.WebappDaoFactory; +import edu.cornell.mannlib.vitro.webapp.edit.n3editing.VTwo.EditConfigurationUtils; +import edu.cornell.mannlib.vitro.webapp.edit.n3editing.VTwo.EditConfigurationVTwo; +import edu.cornell.mannlib.vitro.webapp.edit.n3editing.VTwo.fields.ConstantFieldOptions; +import edu.cornell.mannlib.vitro.webapp.edit.n3editing.VTwo.fields.FieldVTwo; +import edu.cornell.mannlib.vitro.webapp.edit.n3editing.VTwo.fields.IndividualsViaObjectPropetyOptions; +import edu.cornell.mannlib.vitro.webapp.edit.n3editing.VTwo.fields.IndividualsViaSolrQueryOptions; + +/** + * This generator is for the case where a new concept is being added for an object property other than research/subject areas where the + * default object property form generator would work instead of the generator for managing concepts. + * In this case, we don't want the dropdown list for types for "add a new item of this type" to show concept subclasses, so we are overriding + * the fields to just include the Concept class. + */ +public class AddConceptThroughObjectPropertyGenerator extends DefaultObjectPropertyFormGenerator implements EditConfigurationGenerator { + + private Log log = LogFactory.getLog(AddConceptThroughObjectPropertyGenerator.class); + + @Override + public EditConfigurationVTwo getEditConfiguration(VitroRequest vreq, + HttpSession session) throws Exception { + EditConfigurationVTwo editConfig = super.getEditConfiguration(vreq, session); + //return rangetypes in form specific data + editConfig.addFormSpecificData("createNewTypes", getCreateNewTypesOptions(vreq)); + //override templates with ones that will override create new types portion + editConfig.setTemplate(getTemplate(vreq)); + return editConfig; + } + + private HashMap getCreateNewTypesOptions(VitroRequest vreq) { + HashMap options = new HashMap(); + List rangeTypes = getRangeTypes(vreq); + for(VClass v: rangeTypes) { + options.put(v.getURI(), v.getName()); + } + return options; + } + + //We will override range types as well so that autocomplete and other fields dependent on range + //will only consider the main concept type to be the range type + @Override + protected List getRangeTypes(VitroRequest vreq) { + // This first part needs a WebappDaoFactory with no filtering/RDFService + // funny business because it needs to be able to retrieve anonymous union + // classes by their "pseudo-bnode URIs". + // Someday we'll need to figure out a different way of doing this. + //WebappDaoFactory ctxDaoFact = ModelAccess.on( + // vreq.getSession().getServletContext()).getWebappDaoFactory(); + WebappDaoFactory ctxDaoFact = vreq.getLanguageNeutralWebappDaoFactory(); + + List types = new ArrayList(); + Individual subject = EditConfigurationUtils.getSubjectIndividual(vreq); + String predicateUri = EditConfigurationUtils.getPredicateUri(vreq); + String rangeUri = EditConfigurationUtils.getRangeUri(vreq); + if (rangeUri != null) { + VClass rangeVClass = ctxDaoFact.getVClassDao().getVClassByURI(rangeUri); + if (!rangeVClass.isUnion()) { + types.add(rangeVClass); + } else { + for (VClass unionComponent : rangeVClass.getUnionComponents()) { + types.add(unionComponent); + } + } + return types; + } else { + //This should never happen + log.warn("Range not found for this property so employing SKOS concept class"); + String vclassURI = "http://www.w3.org/2004/02/skos/core#Concept"; + VClass rangeVClass = ctxDaoFact.getVClassDao().getVClassByURI(vclassURI); + types.add(rangeVClass); + } + + return types; + } + + //Should override the method in default object property + private String getTemplate( + VitroRequest vreq) { + + String acObjectPropertyTemplate = "addConceptThroughObjectPropertyAutoComplete.ftl"; + String objectPropertyTemplate = "addConceptThroughObjectPropertyForm.ftl"; + String template = objectPropertyTemplate; + if( doAutoComplete ) + template = acObjectPropertyTemplate; + return template; + + } + + @Override + protected void setFields(EditConfigurationVTwo editConfiguration, VitroRequest vreq, String predicateUri, List rangeTypes) throws Exception { + FieldVTwo field = new FieldVTwo(); + field.setName("objectVar"); + + List validators = new ArrayList(); + validators.add("nonempty"); + field.setValidators(validators); + + if( ! doAutoComplete ){ + List types = new ArrayList(); + for(VClass v: rangeTypes) { + types.add(v.getURI()); + } + field.setOptions( new IndividualsViaSolrQueryOptions( + vreq.getSession().getServletContext(), + types.toArray(new String[types.size()]))); + }else{ + field.setOptions(null); + } + + Map fields = new HashMap(); + fields.put(field.getName(), field); + + editConfiguration.setFields(fields); + } + +} diff --git a/src/edu/cornell/mannlib/vitro/webapp/edit/n3editing/configuration/generators/NewIndividualFormGenerator.java b/src/edu/cornell/mannlib/vitro/webapp/edit/n3editing/configuration/generators/NewIndividualFormGenerator.java index 4ebe249a..9851b90e 100644 --- a/src/edu/cornell/mannlib/vitro/webapp/edit/n3editing/configuration/generators/NewIndividualFormGenerator.java +++ b/src/edu/cornell/mannlib/vitro/webapp/edit/n3editing/configuration/generators/NewIndividualFormGenerator.java @@ -172,7 +172,9 @@ public class NewIndividualFormGenerator extends BaseEditConfigurationGenerator i WebappDaoFactory wdf = vreq.getWebappDaoFactory(); Boolean isPersonType = Boolean.FALSE; String foafPersonType = getFOAFPersonClassURI(); - List superTypes = wdf.getVClassDao().getAllSuperClassURIs(getTypeOfNew(vreq)); + List superTypes = wdf.getVClassDao().getAllSuperClassURIs(getTypeOfNew(vreq)); + //add foaf person type too so that can also get checked + superTypes.add(foafPersonType); if( superTypes != null ){ for( String typeUri : superTypes){ if( foafPersonType.equals(typeUri)) { From 750e7c3f861956d575a0f024d86f79c65da64960 Mon Sep 17 00:00:00 2001 From: hudajkhan Date: Thu, 31 Oct 2013 15:09:29 -0400 Subject: [PATCH 2/6] update to new individual to make sure type of new gets passed --- .../AddConceptThroughObjectPropertyGenerator.java | 14 +++++++++----- .../generators/NewIndividualFormGenerator.java | 7 ++++--- 2 files changed, 13 insertions(+), 8 deletions(-) diff --git a/src/edu/cornell/mannlib/vitro/webapp/edit/n3editing/configuration/generators/AddConceptThroughObjectPropertyGenerator.java b/src/edu/cornell/mannlib/vitro/webapp/edit/n3editing/configuration/generators/AddConceptThroughObjectPropertyGenerator.java index 56fd11dd..09c6c7e5 100644 --- a/src/edu/cornell/mannlib/vitro/webapp/edit/n3editing/configuration/generators/AddConceptThroughObjectPropertyGenerator.java +++ b/src/edu/cornell/mannlib/vitro/webapp/edit/n3editing/configuration/generators/AddConceptThroughObjectPropertyGenerator.java @@ -37,10 +37,13 @@ public class AddConceptThroughObjectPropertyGenerator extends DefaultObjectPrope public EditConfigurationVTwo getEditConfiguration(VitroRequest vreq, HttpSession session) throws Exception { EditConfigurationVTwo editConfig = super.getEditConfiguration(vreq, session); - //return rangetypes in form specific data - editConfig.addFormSpecificData("createNewTypes", getCreateNewTypesOptions(vreq)); - //override templates with ones that will override create new types portion - editConfig.setTemplate(getTemplate(vreq)); + //If this isn't adding a new individual, then override template/types + if(!DefaultAddMissingIndividualFormGenerator.isCreateNewIndividual(vreq, session)) { + //return rangetypes in form specific data + editConfig.addFormSpecificData("createNewTypes", getCreateNewTypesOptions(vreq)); + //override templates with ones that will override create new types portion + editConfig.setTemplate(getTemplate(vreq)); + } return editConfig; } @@ -117,9 +120,10 @@ public class AddConceptThroughObjectPropertyGenerator extends DefaultObjectPrope for(VClass v: rangeTypes) { types.add(v.getURI()); } + String[] typesArray = types.toArray(new String[types.size()]); field.setOptions( new IndividualsViaSolrQueryOptions( vreq.getSession().getServletContext(), - types.toArray(new String[types.size()]))); + typesArray)); }else{ field.setOptions(null); } diff --git a/src/edu/cornell/mannlib/vitro/webapp/edit/n3editing/configuration/generators/NewIndividualFormGenerator.java b/src/edu/cornell/mannlib/vitro/webapp/edit/n3editing/configuration/generators/NewIndividualFormGenerator.java index 9851b90e..bef4eeda 100644 --- a/src/edu/cornell/mannlib/vitro/webapp/edit/n3editing/configuration/generators/NewIndividualFormGenerator.java +++ b/src/edu/cornell/mannlib/vitro/webapp/edit/n3editing/configuration/generators/NewIndividualFormGenerator.java @@ -172,9 +172,10 @@ public class NewIndividualFormGenerator extends BaseEditConfigurationGenerator i WebappDaoFactory wdf = vreq.getWebappDaoFactory(); Boolean isPersonType = Boolean.FALSE; String foafPersonType = getFOAFPersonClassURI(); - List superTypes = wdf.getVClassDao().getAllSuperClassURIs(getTypeOfNew(vreq)); - //add foaf person type too so that can also get checked - superTypes.add(foafPersonType); + String typeOfNew = getTypeOfNew(vreq); + List superTypes = wdf.getVClassDao().getAllSuperClassURIs(typeOfNew); + //add the actual type as well so we can add that for the list to be checked + superTypes.add(typeOfNew); if( superTypes != null ){ for( String typeUri : superTypes){ if( foafPersonType.equals(typeUri)) { From 6ebb58c746e5b629329af40e2ee4595dcd86b0b6 Mon Sep 17 00:00:00 2001 From: brianjlowe Date: Fri, 1 Nov 2013 09:26:53 -0400 Subject: [PATCH 3/6] VIVO-390 re-add subjectAreaFor --- rdf/tbox/filegraph/object-properties3.owl | 10 ++++++++++ rdf/tbox/firsttime/initialTBoxAnnotations.n3 | 17 +++++++++++++++++ 2 files changed, 27 insertions(+) diff --git a/rdf/tbox/filegraph/object-properties3.owl b/rdf/tbox/filegraph/object-properties3.owl index 9016bea2..f4ea1be4 100644 --- a/rdf/tbox/filegraph/object-properties3.owl +++ b/rdf/tbox/filegraph/object-properties3.owl @@ -448,9 +448,19 @@ + + + + + + + + + + diff --git a/rdf/tbox/firsttime/initialTBoxAnnotations.n3 b/rdf/tbox/firsttime/initialTBoxAnnotations.n3 index 36af8a0a..98a5b7cc 100644 --- a/rdf/tbox/firsttime/initialTBoxAnnotations.n3 +++ b/rdf/tbox/firsttime/initialTBoxAnnotations.n3 @@ -581,6 +581,23 @@ vivo:researchAreaOf vitro:selectFromExistingAnnot "true"^^xsd:boolean . +vivo:subjectAreaOf + rdfs:label "subject area of"@en-US ; + vitro:displayLimitAnnot + "5"^^xsd:int ; + vitro:displayRankAnnot + "10"^^xsd:int ; + vitro:hiddenFromDisplayBelowRoleLevelAnnot + ; + vitro:inPropertyGroupAnnot + ; + vitro:offerCreateNewOptionAnnot + "true"^^xsd:boolean ; + vitro:prohibitedFromUpdateBelowRoleLevelAnnot + ; + vitro:selectFromExistingAnnot + "true"^^xsd:boolean . + geo:populationTotal rdfs:label "total population"@en-US ; vitro:hiddenFromDisplayBelowRoleLevelAnnot From d666a076bfc93fe82dd7bd7125651ac44ac6fb0f Mon Sep 17 00:00:00 2001 From: brianjlowe Date: Fri, 1 Nov 2013 09:32:40 -0400 Subject: [PATCH 4/6] VIVO-392 use vcard:Kind for non-agents --- .../update/sparqlConstructs/additions/vcard1-3.sparql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/productMods/WEB-INF/ontologies/update/sparqlConstructs/additions/vcard1-3.sparql b/productMods/WEB-INF/ontologies/update/sparqlConstructs/additions/vcard1-3.sparql index 96076c4f..fb409425 100644 --- a/productMods/WEB-INF/ontologies/update/sparqlConstructs/additions/vcard1-3.sparql +++ b/productMods/WEB-INF/ontologies/update/sparqlConstructs/additions/vcard1-3.sparql @@ -7,7 +7,7 @@ PREFIX owl: CONSTRUCT { ?s arg:ARG_2000028 _:vcard . _:vcard arg:ARG_2000029 ?s . - _:vcard a v:Individual . + _:vcard a v:Kind . } WHERE { ?s vivo:webpage ?webpage FILTER NOT EXISTS { ?s a foaf:Agent } From fe81ba5927411e7be186e8e8670e837eb79342cc Mon Sep 17 00:00:00 2001 From: j2blake Date: Fri, 1 Nov 2013 10:57:55 -0400 Subject: [PATCH 5/6] VIVO-465 Adjust the Vitro.reconcile.defaultTypeList to suit the ISF --- config/example.runtime.properties | 8 +++++++- doc/upgrade-1.6.html | 32 ++++++++++++++++++++++++++++++- 2 files changed, 38 insertions(+), 2 deletions(-) diff --git a/config/example.runtime.properties b/config/example.runtime.properties index a25e5922..6e61088d 100644 --- a/config/example.runtime.properties +++ b/config/example.runtime.properties @@ -143,7 +143,13 @@ visualization.temporal = enabled # The format for this property is id, name; id1, name1; id2, name2 etc. # See Service Metadata from this page http://code.google.com/p/google-refine/wiki/ReconciliationServiceApi # for more information. -Vitro.reconcile.defaultTypeList = http://vivoweb.org/ontology/core#Role, core:Role; http://vivoweb.org/ontology/core#AcademicDegree, core:Academic Degree; http://purl.org/NET/c4dm/event.owl#Event, event:Event; http://vivoweb.org/ontology/core#Agreement, core:Agreement; http://vivoweb.org/ontology/core#Location, core:Location; http://xmlns.com/foaf/0.1/Organization, foaf:Organization; http://xmlns.com/foaf/0.1/Person, foaf:Person; http://vivoweb.org/ontology/core#InformationResource, core:Information Resource +Vitro.reconcile.defaultTypeList = http://vivoweb.org/ontology/core#Role, core:Role; \ + http://vivoweb.org/ontology/core#AcademicDegree, core:Academic Degree; \ + http://purl.org/NET/c4dm/event.owl#Event, event:Event; \ + http://vivoweb.org/ontology/core#Location, core:Location; \ + http://xmlns.com/foaf/0.1/Organization, foaf:Organization; \ + http://xmlns.com/foaf/0.1/Person, foaf:Person; \ + http://purl.obolibrary.org/obo/IAO_0000030, obo:IAO_0000030 # # Types of individual for which we can create proxy editors. diff --git a/doc/upgrade-1.6.html b/doc/upgrade-1.6.html index 6fdd5356..0cb35e51 100644 --- a/doc/upgrade-1.6.html +++ b/doc/upgrade-1.6.html @@ -51,6 +51,7 @@
  • Auto-loaded RDF files move to the Home directory
  • Support for additional languages
  • More compact responses to Linked data requests
  • +
  • Changes to default types for Google Refine
  • Upgrade Instructions
  • @@ -143,7 +144,9 @@
  • webapp.name
  • + +
  • Solr is no longer secured

    In previous releases, Solr was deployed to Tomcat with a RemoteAddrValve @@ -163,7 +166,9 @@

    Sites that need to secure Solr are now left to their own devices.

    +
  • +
  • Log4J properties file renamed

    In previous releases, the properties file for the VIVO logging system @@ -175,7 +180,9 @@ Note that debug.log4j.properties, if present, will still override the default.

    +
  • +
  • Property groups now displayed in a tab format, including a "View All" tab

    With release 1.6, the property group menu bar that was used on profile pages has been replaced @@ -183,7 +190,9 @@ within that group while the contents of the previously displayed group will be hidden. The array of tabs also includes a "View All" tab that, when clicked, displays the contents of all the property groups.

    +
  • +
  • Class-specific SPARQL Query Data Getters

    The VIVO software now supports the development of SPARQL query data getters that can be associated @@ -195,7 +204,9 @@ data getters: https://wiki.duraspace.org/display/VIVO/Enriching+VIVO+Content+Using+SPARQL+Query+Data+Getters.

    +
  • +
  • The foaf:Person template has been re-located.

    The template individual--foaf-person.ftl has been moved to the "templates" subdirectory in the wilma @@ -204,7 +215,9 @@ theme directory or, if your installation does not have it's own theme directory, in the themes/wilma/templates subdirectory.

    +
  • +
  • Multiple foaf:Person Profile Pages

    VIVO now supports multiple profile pages for foaf:Persons. This feature, which is optional so installations @@ -218,7 +231,9 @@ Websnapr.) For more information on how to implement multiple profile page views, refer to this wiki page: https://wiki.duraspace.org/display/VIVO/Multiple+foaf%3APerson+Profile+Pages.

    +
  • +
  • Home Page Re-design

    For Release 1.6 the VIVO Home Page has been redesigned. The Search field beneath the "welcome" text now @@ -229,7 +244,9 @@ activities and organizations; and, optionally a global map showing researchers' areas of geographic focus.

    +
  • +
  • Auto-loaded RDF files move to the Home directory

    The RDF files that initialize the data model have moved, in both the distribution and @@ -326,7 +343,9 @@ <include name="context.xml" /> </patternset>

    +
  • +
  • Support for additional languages

    VIVO 1.6 includes limited support for other languages, in addition to American English. @@ -350,7 +369,9 @@ Add a new language to VIVO.

    +
  • +
  • More compact responses to Linked data requests

    In VIVO 1.6, the response to requests for linked data is changed, to be smaller and faster. @@ -391,8 +412,17 @@ VIVO release 1.6 can be configured to produce extended linked data like previous releases. However, extended linked data will not be supported in future releases.

    -
  • + +
  • +

    Changes to default types for Google Refine

    +

    + The list of default types for Google Refine has changed, to accomodate changes in the + ontology. If you are using Google Refine, you may need to change your runtime properties + accordingly. The new defaults appear in example.runtime.properties. +

    +
  • +
  • Supported Browsers

    From c080c0484c82188e4631108db940fddfa53ba6fb Mon Sep 17 00:00:00 2001 From: hudajkhan Date: Fri, 1 Nov 2013 11:24:05 -0400 Subject: [PATCH 6/6] updating field options constructor --- .../AddConceptThroughObjectPropertyGenerator.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/edu/cornell/mannlib/vitro/webapp/edit/n3editing/configuration/generators/AddConceptThroughObjectPropertyGenerator.java b/src/edu/cornell/mannlib/vitro/webapp/edit/n3editing/configuration/generators/AddConceptThroughObjectPropertyGenerator.java index 09c6c7e5..9c2e7404 100644 --- a/src/edu/cornell/mannlib/vitro/webapp/edit/n3editing/configuration/generators/AddConceptThroughObjectPropertyGenerator.java +++ b/src/edu/cornell/mannlib/vitro/webapp/edit/n3editing/configuration/generators/AddConceptThroughObjectPropertyGenerator.java @@ -122,8 +122,11 @@ public class AddConceptThroughObjectPropertyGenerator extends DefaultObjectPrope } String[] typesArray = types.toArray(new String[types.size()]); field.setOptions( new IndividualsViaSolrQueryOptions( - vreq.getSession().getServletContext(), - typesArray)); + vreq.getSession().getServletContext(), + getSubjectUri(), + predicateUri, + getObjectUri(), + typesArray)); }else{ field.setOptions(null); }