VIVO-248 Move more RDF files into the home directory

Files for initializing the display, displayTbox and displayDisplay models. Also restructure the RDFFilesLoader.
This commit is contained in:
j2blake 2013-08-21 11:27:41 -04:00
parent 71ce2beffc
commit 37c35468ca
9 changed files with 0 additions and 0 deletions

View file

@ -0,0 +1,13 @@
# $This file is distributed under the terms of the license in /doc/license.txt$
@prefix about: <http://vitro.mannlib.cornell.edu/ns/default/about#> .
about:ABOUTDG
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#htmlValue>
"""<h2>Acerca VIVO</h2>
<div class=\"pageGroupBody\" id=\"aboutText\"><p>La aplicación VIVO permite el descubrimiento de los investigadores a través de las instituciones. Los participantes en la red se encuentran instituciones con instalaciones locales de VIVO o con la investigación y el descubrimiento de aplicaciones de perfiles que pueden proporcionar datos web compatibles semánticas. Por tanto, la información accesible a través de la búsqueda de VIVO y capacidad de exploración se residir y ser controlado a nivel local, dentro de vivos institucionales o de otras aplicaciones web compatibles con semánticos.</p>
<p>VIVO es una aplicación web semántica código abierto originalmente desarrollado e implementado en Cornell. Cuando se instala y se rellena con el contenido en una institución, que permite el descubrimiento de la investigación y de becas en todas las disciplinas de esta institución. VIVO compatible con la navegación y una función de búsqueda que devuelve resultados facetas para una rápida recuperación de la información deseada. Contenido en cualquier instalación VIVO local puede mantenerse manualmente o puesto en la base de datos de forma automática de los sistemas locales de registro, tales como recursos humanos, becas, cursos, y bases de datos de la actividad docente.</p>
<p>Ver más información sobre el <a href=\"http://vivoweb.org\">Proyecto VIVO</a>.</p></div>
"""@es .

View file

@ -0,0 +1,31 @@
# $This file is distributed under the terms of the license in /doc/license.txt$
@prefix owl: <http://www.w3.org/2002/07/owl#> .
@prefix display: <http://vitro.mannlib.cornell.edu/ontologies/display/1.1#> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix core: <http://vivoweb.org/ontology/core#> .
@prefix vivoweb: <http://vivoweb.org/ontology#> .
@prefix foaf: <http://xmlns.com/foaf/0.1/> .
# academic departments datagetter
<freemarker:lib-home-page.ftl> display:hasDataGetter display:academicDeptsDataGetter .
display:academicDeptsDataGetter
a <java:edu.cornell.mannlib.vitro.webapp.utils.dataGetter.SparqlQueryDataGetter> ;
display:saveToVar "academicDeptDG" ;
display:query """
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX vivo: <http://vivoweb.org/ontology/core#>
SELECT DISTINCT ?theURI (str(?label) as ?name)
WHERE
{
?theURI rdf:type vivo:AcademicDepartment .
?theURI rdfs:label ?label
}
""" .

View file

@ -0,0 +1,12 @@
# $This file is distributed under the terms of the license in /doc/license.txt$
#
# Associate the LocaleSelectionDataGetter with the languageSelector.ftl Freemarker template.
#
@prefix display: <http://vitro.mannlib.cornell.edu/ontologies/display/1.1#> .
<freemarker:languageSelector.ftl> display:hasDataGetter display:localeSelectorDataGetter .
display:localeSelectorDataGetter
a <java:edu.cornell.mannlib.vitro.webapp.i18n.selection.LocaleSelectionDataGetter> .

View file

@ -0,0 +1,20 @@
@prefix display: <http://vitro.mannlib.cornell.edu/ontologies/display/1.1#> .
display:HomeMenuItem display:linkText "Inicio"@es-ES .
display:PeopleMenuItem display:linkText "Personas"@es-ES .
display:OrganizationsMenuItem display:linkText "Organizaciones"@es-ES .
display:ResearchMenuItem display:linkText "Investigación"@es-ES .
display:EventsMenuItem display:linkText "Eventos"@es-ES .
display:Home display:title "Inicio"@es-ES .
display:Events display:title "Eventos"@es-ES .
display:Organizations display:title "Organizaciones"@es-ES .
display:People display:title "Personas"@es-ES .
display:Research display:title "Investigación"@es-ES .
display:pageListPage display:title "Páginas"@es-ES .
<java:edu.cornell.mannlib.vitro.webapp.utils.dataGetter.SparqlQueryDataGetter> <http://www.w3.org/2000/01/rdf-schema#label> "SPARQL Query Resultados"@es .
<java:edu.cornell.mannlib.vitro.webapp.utils.dataGetter.BrowseDataGetter> <http://www.w3.org/2000/01/rdf-schema#label> "Navegar P\u00E1gina"@es .
<java:edu.cornell.mannlib.vitro.webapp.utils.dataGetter.InternalClassesDataGetter> <http://www.w3.org/2000/01/rdf-schema#label> "Grupo Page Group - Institucional Clase Interna"@es .
<java:edu.cornell.mannlib.vitro.webapp.utils.dataGetter.ClassGroupPageData> <http://www.w3.org/2000/01/rdf-schema#label> "Grupo Clase p\u00E1gina"@es .
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#DefaultMenu> <http://www.w3.org/2000/01/rdf-schema#label> "men\u00FA predeterminado"@es .
<java:edu.cornell.mannlib.vitro.webapp.utils.dataGetter.IndividualsForClassesDataGetter> <http://www.w3.org/2000/01/rdf-schema#label> "Grupo Page Group - Clases seleccionadas"@es .

View file

@ -0,0 +1,197 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE rdf:RDF [
<!ENTITY display "http://vitro.mannlib.cornell.edu/ontologies/display/1.1#">
<!ENTITY owl "http://www.w3.org/2002/07/owl#">
<!ENTITY rdf "http://www.w3.org/1999/02/22-rdf-syntax-ns#">
<!ENTITY rdfs "http://www.w3.org/2000/01/rdf-schema#">
<!ENTITY xsd "http://www.w3.org/2001/XMLSchema#">
<!ENTITY vitro "http://vitro.mannlib.cornell.edu/ns/vitro/0.7#">
]>
<rdf:RDF xml:base="http://vitro.mannlib.cornell.edu/ontologies/display/1.1/"
xmlns:display="&display;"
xmlns:owl="&owl;"
xmlns:rdf="&rdf;"
xmlns:rdfs="&rdfs;"
xmlns:vitro="&vitro;">
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#authorInAuthorship">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-authorInAuthorship.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#educationalTraining">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-educationalTraining.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#informationResourceInAuthorship">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-informationResourceInAuthorship.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#personInPosition">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-personInPosition.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#organizationForPosition">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-organizationForPosition.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#organizationForTraining">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-organizationForTraining.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#mailingAddress">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-mailingAddress.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#awardOrHonor">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-awardOrHonor.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#advisorIn">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-advisorIn.xml</display:listViewConfigFile>
</rdf:Description>
<!--
******************************************************************
all roles use same config...is there a better way to specify this?
** core:hasClinicalRole
** core:hasLeaderRole
** core:hasMemberRole
** core:hasOutreachProviderRole
** core:hasServiceProviderRole
** core:hasResearcherRole
** core:hasTeacherRole
** core:hasOrganizerRole
** core:hasAttendeeRole
these three are an exception, and share a separate config
** core:hasInvestigatorRole
** core:hasCo-PrincipalInvestigatorRole
** core:hasPrincipalInvestigatorRole
******************************************************************
-->
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#hasClinicalRole">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-hasRole.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#hasRole">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-hasRole.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#hasLeaderRole">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-hasRole.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#hasMemberRole">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-hasRole.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#hasOutreachProviderRole">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-hasRole.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#hasServiceProviderRole">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-hasRole.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#hasResearcherRole">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-hasRole.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#hasTeacherRole">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-hasRole.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#hasOrganizerRole">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-hasRole.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#hasEditorRole">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-hasEditReviewRole.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#hasReviewerRole">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-hasEditReviewRole.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#hasPresenterRole">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-hasPresenterRole.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#hasAttendeeRole">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-hasAttendeeRole.xml</display:listViewConfigFile>
</rdf:Description>
<!-- The next three roles use a different config -->
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#hasInvestigatorRole">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-hasInvestigatorRole.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#hasCo-PrincipalInvestigatorRole">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-hasInvestigatorRole.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#hasPrincipalInvestigatorRole">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-hasInvestigatorRole.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#researchAreaOf">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-researchAreaOf.xml</display:listViewConfigFile>
</rdf:Description>
<!--
******************************************************************
end roles (from person) config
******************************************************************
-->
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#realizedRole">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-relatedRole.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#contributingRole">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-relatedRole.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#linkedRole">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-relatedRole.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#dateTimeInterval">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-dateTimeInterval.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#dateTimeValue">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-dateTimeValue.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#start">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-dateTimeValue.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#end">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-dateTimeValue.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#webpage">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-webpage.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#hasAssociatedConcept">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-hasAssociatedConcept.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#hasSubjectArea">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-hasAssociatedConcept.xml</display:listViewConfigFile>
</rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#hasResearchArea">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-hasAssociatedConcept.xml</display:listViewConfigFile>
</rdf:Description>
<!--
******************************************************************
data property custom list views
******************************************************************
-->
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#scopusId">
<display:listViewConfigFile rdf:datatype="http://www.w3.org/2001/XMLSchema#string">listViewConfig-scopusId.xml</display:listViewConfigFile>
</rdf:Description>
</rdf:RDF>

View file

@ -0,0 +1,183 @@
# $This file is distributed under the terms of the license in /doc/license.txt$
@prefix owl: <http://www.w3.org/2002/07/owl#> .
@prefix display: <http://vitro.mannlib.cornell.edu/ontologies/display/1.1#> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix core: <http://vivoweb.org/ontology/core#> .
@prefix vivoweb: <http://vivoweb.org/ontology#> .
@prefix afn: <http://jena.hpl.hp.com/ARQ/function#> .
#### n3 for research areas ####
## associate the classes with the datagetter ##
<http://vivoweb.org/ontology/core#Department> display:hasDataGetter display:getResearchAreaDataGetter .
<http://vivoweb.org/ontology/core#Center> display:hasDataGetter display:getResearchAreaDataGetter .
<http://vivoweb.org/ontology/core#ClinicalOrganization> display:hasDataGetter display:getResearchAreaDataGetter .
<http://vivoweb.org/ontology/core#Institute> display:hasDataGetter display:getResearchAreaDataGetter .
<http://vivoweb.org/ontology/core#Laboratory> display:hasDataGetter display:getResearchAreaDataGetter .
<http://vivoweb.org/ontology/core#Library> display:hasDataGetter display:getResearchAreaDataGetter .
<http://vivoweb.org/ontology/core#ResearchOrganization> display:hasDataGetter display:getResearchAreaDataGetter .
## define the datagetter ##
display:getResearchAreaDataGetter
a <java:edu.cornell.mannlib.vitro.webapp.utils.dataGetter.SparqlQueryDataGetter>;
display:saveToVar "researchAreaResults";
display:query
"""
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX vivo: <http://vivoweb.org/ontology/core#>
PREFIX afn: <http://jena.hpl.hp.com/ARQ/function#>
SELECT DISTINCT (str(?researchAreaLabel) AS ?raLabel) ?ra
WHERE {
?individualURI vivo:organizationForPosition ?posn .
?posn vivo:positionForPerson ?person .
?person vivo:hasResearchArea ?ra .
?ra rdfs:label ?researchAreaLabel
OPTIONAL { ?posn vivo:dateTimeInterval ?dti
OPTIONAL { ?dti vivo:end ?end .
?end vivo:dateTime ?endDate
}
}
FILTER ( !bound(?endDate) ||
afn:substring(str(?endDate), 0, 4) >= afn:substring(str(afn:now()), 0, 4) )
}
ORDER BY ?raLabel
""" .
## detail page for non-academic department research areas ##
<http://vitro.mannlib.cornell.edu/ns/default#n55550000>
a <http://vitro.mannlib.cornell.edu/ontologies/display/1.1#Page> ;
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#hasDataGetter> <http://vitro.mannlib.cornell.edu/ns/default#n55551111> ;
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#requiresBodyTemplate> "individual-affiliated-res-area-details.ftl" ;
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#title> "Affiliated Research Areas" ;
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#urlMapping> "/affiliatedResearchAreas" .
<http://vitro.mannlib.cornell.edu/ns/default#n55551111>
a <java:edu.cornell.mannlib.vitro.webapp.utils.dataGetter.SparqlQueryDataGetter> ;
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#query>
"""
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX vivo: <http://vivoweb.org/ontology/core#>
SELECT DISTINCT (str (?prsnLabel) AS ?personLabel)
?person
(str(?researchAreaLabel) AS ?raLabel)
(str(?organizationLabel) AS ?orgLabel)
?raURI
WHERE {
?orgURI vivo:organizationForPosition ?posn .
?orgURI rdfs:label ?organizationLabel .
?posn vivo:positionForPerson ?person .
?person rdfs:label ?prsnLabel .
?person vivo:hasResearchArea ?raURI .
?raURI rdfs:label ?researchAreaLabel
}
ORDER BY ?personLabel
""" ;
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#saveToVar> "affiliatedResearchAreas" .
## detail page for academic department research areas ##
<http://vitro.mannlib.cornell.edu/ns/default#n5100>
a <http://vitro.mannlib.cornell.edu/ontologies/display/1.1#Page> ;
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#hasDataGetter> <http://vitro.mannlib.cornell.edu/ns/default#n3450> ;
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#requiresBodyTemplate> "individual-dept-res-area-details.ftl" ;
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#title> "Departmental Research Areas" ;
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#urlMapping> "/deptResearchAreas" .
<http://vitro.mannlib.cornell.edu/ns/default#n3450>
a <java:edu.cornell.mannlib.vitro.webapp.utils.dataGetter.SparqlQueryDataGetter> ;
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#query>
"""
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX vivo: <http://vivoweb.org/ontology/core#>
SELECT DISTINCT (str (?prsnLabel) AS ?personLabel)
?person
(Str(?researchAreaLabel) AS ?raLabel)
(str(?departmentLabel) AS ?orgLabel)
?raURI
WHERE {
?orgURI vivo:organizationForPosition ?posn .
?orgURI rdfs:label ?orgLabel .
?posn vivo:positionForPerson ?person .
?person rdfs:label ?prsnLabel .
?person vivo:hasResearchArea ?raURI .
?raURI rdfs:label ?researchAreaLabel
}
ORDER BY ?personLabel
""" ;
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#saveToVar>
"deptResearchAreas" .
#### n3 for grants ####
## associate the classes with the datagetter ##
<http://vivoweb.org/ontology/core#AcademicDepartment> display:hasDataGetter display:getGrantsDataGetter .
## data getter to see if the department has any grants ##
display:getGrantsDataGetter
a <java:edu.cornell.mannlib.vitro.webapp.utils.dataGetter.SparqlQueryDataGetter>;
display:saveToVar "getGrantResults";
display:query
"""
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX vivo: <http://vivoweb.org/ontology/core#>
PREFIX afn: <http://jena.hpl.hp.com/ARQ/function#>
SELECT DISTINCT ?activity
WHERE {
?individualURI vivo:organizationForPosition ?posn .
?posn vivo:positionForPerson ?person .
?person ?roleProperty ?role .
?roleProperty rdfs:subPropertyOf vivo:hasResearcherRole .
?role vivo:roleContributesTo ?activity .
?activity vivo:dateTimeInterval ?dti .
?dti vivo:end ?end.
?end vivo:dateTime ?dt
FILTER (?dt > afn:now())
}
LIMIT 1
""" .
## data getter for the grants detail page ##
<http://vitro.mannlib.cornell.edu/ns/default#n1697>
a <http://vitro.mannlib.cornell.edu/ontologies/display/1.1#Page> ;
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#hasDataGetter> <http://vitro.mannlib.cornell.edu/ns/default#n4170> ;
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#requiresBodyTemplate> "individual-dept-active-grants.ftl" ;
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#title> "Departmental Grants" ;
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#urlMapping> "/deptGrants" .
<http://vitro.mannlib.cornell.edu/ns/default#n4170>
a <java:edu.cornell.mannlib.vitro.webapp.utils.dataGetter.SparqlQueryDataGetter> ;
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#query>
"""
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX vivo: <http://vivoweb.org/ontology/core#>
PREFIX afn: <http://jena.hpl.hp.com/ARQ/function#>
SELECT DISTINCT (str (?actLabel) AS ?activityLabel) ?dt (str(?departmentLabel) AS ?deptLabel) ?activity
WHERE {
?individualURI vivo:organizationForPosition ?posn .
?individualURI rdfs:label ?departmentLabel .
?posn vivo:positionForPerson ?person .
?person ?roleProperty ?role .
?roleProperty rdfs:subPropertyOf vivo:hasResearcherRole .
?role vivo:roleContributesTo ?activity .
?activity rdfs:label ?actLabel .
?activity vivo:dateTimeInterval ?dti .
?dti vivo:end ?end.
?end vivo:dateTime ?dt
FILTER (?dt > afn:now())
}
ORDER BY ?activityLabel
""" ;
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#saveToVar> "deptGrants" .

View file

@ -0,0 +1,27 @@
# $This file is distributed under the terms of the license in /doc/license.txt$
@prefix owl: <http://www.w3.org/2002/07/owl#> .
@prefix vitroDisplay: <http://vitro.mannlib.cornell.edu/ontologies/display/1.1#> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix core: <http://vivoweb.org/ontology/core#> .
@prefix localNav: <http://vitro.mannlib.cornell.edu/ns/localnav#> .
@prefix bibo: <http://purl.org/ontology/bibo/> .
# See vitroSearchProhibited.n3 for more information about files in this directory.
vitroDisplay:SearchIndex
rdf:type owl:Thing ;
vitroDisplay:excludeClass core:Role ;
vitroDisplay:excludeClass core:AdvisingRelationship ;
vitroDisplay:excludeClass core:Authorship ;
vitroDisplay:excludeClass core:Position ;
vitroDisplay:excludeClass core:AwardReceipt ;
vitroDisplay:excludeClass core:ResearchActivity ;
vitroDisplay:excludeClass core:EducationalTraining ;
vitroDisplay:excludeClass bibo:DocumentStatus ;
vitroDisplay:excludeClass core:DateTimeValue ;
vitroDisplay:excludeClass core:DateTimeInterval ;
vitroDisplay:excludeClass core:AcademicDegree ;
vitroDisplay:excludeClass core:URLLink ;
vitroDisplay:excludeClass <http://vitro.mannlib.cornell.edu/ns/vitro/public#File> ;
vitroDisplay:excludeClass <http://vitro.mannlib.cornell.edu/ns/vitro/public#FileByteStream> .