This commit is contained in:
anupsawant 2011-06-17 16:30:15 +00:00
commit b4cfc992ac
17 changed files with 1946 additions and 1815 deletions

View file

@ -1,147 +0,0 @@
# -----------------------------------------------------------------------------
#
# VIVO deployment properties
#
# This file is provided as example.deploy.properties.
#
# Save a copy of this file as deploy.properties, and edit the properties as
# needed for your deployment.
#
# -----------------------------------------------------------------------------
#
# This namespace will be used when generating URIs for objects created in the
# editor. Change it to reflect your own domain. For example, Cornell's
# namespace is http://vivo.cornell.edu/individual/
#
# Note: it is essential that this namespace end with a trailing slash.
#
Vitro.defaultNamespace = http://vivo.mydomain.edu/individual/
#
# Where is the Vitro core directory?
# In most deployments, this is set to ./vitro-core (It is not uncommon for this
# setting to point elsewhere in development environments).
# Examples:
# vitro.core.dir = ./vitro-core
# vitro.core.dir = ../vitro
# vitro.core.dir = /usr/local/vitro/trunk
vitro.core.dir = ./vitro-core
#
# The base install directory for your Tomcat server. The VIVO application
# will be deployed in the /webapps directory below this base.
#
tomcat.home = /usr/local/tomcat
#
# The name of the VIVO application. This will be used as the name of the
# subdirectory within your Tomcat server's /webapps directory. It also appears
# in the URL for the application. For example, http://my.vivo.server/vivo
#
webapp.name = vivo
#
# URL of Solr context used in local VIVO search. Should consist of
# scheme + servername + port + contextpath + "solr"
#
vitro.local.solr.url = http://localhost:8080/vivosolr
#
# The location where the VIVO application will store the data that it creates.
# This includes uploaded files (usually images) and the Lucene search index.
#
vitro.home.directory = /usr/local/vivo/data
#
# Email parameters which VIVO can use to send mail. If these are left empty,
# the "Contact Us" form will be disabled and users will not be notified of
# changes to their accounts.
#
email.smtpHost = smtp.my.domain.edu
email.replyTo = vivoAdmin@my.domain.edu
#
# The basic parameters for a database connection. Change the end of the
# URL to reflect your database name (if it is not "vitrodb"). Change the username
# and password to match the authorized database user you created.
#
VitroConnection.DataSource.url = jdbc:mysql://localhost/vitrodb
VitroConnection.DataSource.username = vitrodbUsername
VitroConnection.DataSource.password = vitrodbPassword
#
# The maximum number of active connections in the database connection pool.
# Increase this value to support a greater number of concurrent page requests.
#
VitroConnection.DataSource.pool.maxActive = 40
#
# The maximum number of database connections that will be allowed
# to remain idle in the connection pool. Default is 25%
# of the maximum number of active connections.
#
VitroConnection.DataSource.pool.maxIdle = 10
#
# Parameters to change in order to use VIVO with a database other than
# MySQL.
#
VitroConnection.DataSource.dbtype = MySQL
VitroConnection.DataSource.driver = com.mysql.jdbc.Driver
VitroConnection.DataSource.validationQuery = SELECT 1
#
# The email address of the root user for the VIVO application. The password
# for this user is initially set to "rootPassword", but you will be asked to
# change the password the first time you log in.
#
rootUser.emailAddress = root@myDomain.com
#
# How is a logged-in user associated with a particular Individual? One way is
# for the Individual to have a property whose value is the username of the user.
# This value should be the URI for that property.
#
selfEditing.idMatchingProperty = http://vivo.mydomain.edu/ns#networkId
#
# If an external authentication system like Shibboleth or CUWebAuth is to be
# used, these properties say how the login button should be labeled, and which
# HTTP header will contain the user ID from the authentication system. If such
# a system is not to be used, leave these commented out. Consult the
# installation instructions for more details.
#
#externalAuth.buttonText = Log in using BearCat Shibboleth
#externalAuth.netIdHeaderName = remote_userID
#
# The temporal graph visualization can require extensive machine resources.
# This can have a particularly noticable impact on memory usage if
# - VIVO is configured to use Jena SDB,
# - The organization tree is deep,
# - The number of grants and publications is large.
# VIVO release 1.2 guards against this impact by disabling the temporal graph
# visualization unless the "visualization.temporal" flag is set to "enabled".
#
# visualization.temporal = enabled
#
# The temporal graph visualization is used to compare different organizations/people
# within an organization on parameters like number of publications or grants.
# By default, the app will attempt to make its best guess at the top level
# organization in your instance. If you're unhappy with this selection, uncomment out
# the property below and set it to the URI of the organization individual you want to
# identify as the top level organization. It will be used as the default whenever the
# temporal graph visualization is rendered without being passed an explicit org.
# For example, to use "Ponce School of Medicine" as the top organization:
# visualization.topLevelOrg = http://vivo.psm.edu/individual/n2862
#
# visualization.topLevelOrg = http://vivo.mydomain.edu/individual/topLevelOrgURI
#
# Default type(s) for Google Refine Reconciliation Service
# 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#Course, Course; http://vivoweb.org/ontology/core#Grant, Grant; http://aims.fao.org/aos/geopolitical.owl, Location; http://xmlns.com/foaf/0.1/Organization, Organization; http://xmlns.com/foaf/0.1/Person, Person; http://purl.org/ontology/bibo/Article, Publication

View file

@ -112,11 +112,6 @@ NOTE that we are not addressing for now the issue of whether a foaf:Person is a
<rdf:type rdf:resource="http://www.w3.org/2002/07/owl#Class"/> <rdf:type rdf:resource="http://www.w3.org/2002/07/owl#Class"/>
<vitro:shortDef rdf:datatype="http://www.w3.org/2001/XMLSchema#string">An organism is a material entity that is an individual living system, such as animal, plant, bacteria or virus, that is capable of replicating or reproducing, growth and maintenance in the right environment.</vitro:shortDef> <vitro:shortDef rdf:datatype="http://www.w3.org/2001/XMLSchema#string">An organism is a material entity that is an individual living system, such as animal, plant, bacteria or virus, that is capable of replicating or reproducing, growth and maintenance in the right environment.</vitro:shortDef>
</rdf:Description> </rdf:Description>
<rdf:Description rdf:nodeID="A0">
<rdf:type rdf:resource="http://www.w3.org/2002/07/owl#Restriction"/>
<owl:onProperty rdf:resource="http://purl.obolibrary.org/obo/ERO_0000460"/>
<owl:allValuesFrom rdf:resource="http://purl.org/ontology/bibo/Document"/>
</rdf:Description>
<rdf:Description rdf:about="http://purl.obolibrary.org/obo/ERO_0000016"> <rdf:Description rdf:about="http://purl.obolibrary.org/obo/ERO_0000016">
<rdf:type rdf:resource="http://www.w3.org/2002/07/owl#Class"/> <rdf:type rdf:resource="http://www.w3.org/2002/07/owl#Class"/>
<rdfs:subClassOf rdf:resource="http://purl.obolibrary.org/obo/ERO_0000015"/> <rdfs:subClassOf rdf:resource="http://purl.obolibrary.org/obo/ERO_0000015"/>
@ -142,6 +137,11 @@ NOTE that we are not addressing for now the issue of whether a foaf:Person is a
<vitro:shortDef rdf:datatype="http://www.w3.org/2001/XMLSchema#string">An implement used to facilitate work, especially precision work.</vitro:shortDef> <vitro:shortDef rdf:datatype="http://www.w3.org/2001/XMLSchema#string">An implement used to facilitate work, especially precision work.</vitro:shortDef>
<rdfs:subClassOf rdf:resource="http://vivoweb.org/ontology/core#Equipment"/> <rdfs:subClassOf rdf:resource="http://vivoweb.org/ontology/core#Equipment"/>
</rdf:Description> </rdf:Description>
<rdf:Description rdf:nodeID="A0">
<rdf:type rdf:resource="http://www.w3.org/2002/07/owl#Restriction"/>
<owl:onProperty rdf:resource="http://purl.obolibrary.org/obo/ERO_0000460"/>
<owl:allValuesFrom rdf:resource="http://purl.org/ontology/bibo/Document"/>
</rdf:Description>
<rdf:Description rdf:about="http://purl.obolibrary.org/obo/ERO_0000029"> <rdf:Description rdf:about="http://purl.obolibrary.org/obo/ERO_0000029">
<owl:inverseOf rdf:resource="http://vivoweb.org/ontology/scientific-research#accessProvidedBy"/> <owl:inverseOf rdf:resource="http://vivoweb.org/ontology/scientific-research#accessProvidedBy"/>
<rdfs:domain rdf:resource="http://purl.obolibrary.org/obo/ERO_0000391"/> <rdfs:domain rdf:resource="http://purl.obolibrary.org/obo/ERO_0000391"/>

File diff suppressed because it is too large Load diff

View file

@ -551,15 +551,16 @@
<rdfs:label xml:lang="en-US">report identifier</rdfs:label> <rdfs:label xml:lang="en-US">report identifier</rdfs:label>
</rdf:Description> </rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#hasEditorRole"> <rdf:Description rdf:about="http://vivoweb.org/ontology/core#hasEditorRole">
<vitro:customEntryFormAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#string">addEditorRoleToPerson.jsp</vitro:customEntryFormAnnot>
<vitro:offerCreateNewOptionAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#boolean">true</vitro:offerCreateNewOptionAnnot>
<vitro:selectFromExistingAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#boolean">true</vitro:selectFromExistingAnnot>
<vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">5</vitro:displayLimitAnnot>
<rdfs:label xml:lang="en-US">editor for</rdfs:label>
<vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<vitro:inPropertyGroupAnnot rdf:resource="http://vivoweb.org/ontology#vitroPropertyGroupoutreach"/>
<vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">2</vitro:displayRankAnnot> <vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">2</vitro:displayRankAnnot>
<vitro:inPropertyGroupAnnot rdf:resource="http://vivoweb.org/ontology#vitroPropertyGroupoutreach"/>
<vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">5</vitro:displayLimitAnnot>
<vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<vitro:selectFromExistingAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#boolean">true</vitro:selectFromExistingAnnot>
<vitro:offerCreateNewOptionAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#boolean">true</vitro:offerCreateNewOptionAnnot>
<vitro:publicDescriptionAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#string">use this property to record editorial management or oversight responsibilities for a collection or a series such as a journal.</vitro:publicDescriptionAnnot>
<vitro:customEntryFormAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#string">addEditorRoleToPerson.jsp</vitro:customEntryFormAnnot>
<rdfs:label xml:lang="en-US">collection or series editor for</rdfs:label>
</rdf:Description> </rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#equipmentFor"> <rdf:Description rdf:about="http://vivoweb.org/ontology/core#equipmentFor">
<vitro:inPropertyGroupAnnot rdf:resource="http://vivoweb.org/ontology#vitroPropertyGroupoverview"/> <vitro:inPropertyGroupAnnot rdf:resource="http://vivoweb.org/ontology#vitroPropertyGroupoverview"/>
@ -1091,10 +1092,10 @@
<vitro:inPropertyGroupAnnot rdf:resource="http://vivoweb.org/ontology#vitroPropertyGroupbibliographic"/> <vitro:inPropertyGroupAnnot rdf:resource="http://vivoweb.org/ontology#vitroPropertyGroupbibliographic"/>
</rdf:Description> </rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#EditorRole"> <rdf:Description rdf:about="http://vivoweb.org/ontology/core#EditorRole">
<vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">2</vitro:displayRankAnnot>
<vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/> <vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/> <vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">2</vitro:displayLimitAnnot> <vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">2</vitro:displayLimitAnnot>
<vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">2</vitro:displayRankAnnot>
<rdfs:label xml:lang="en-US">Editor Role</rdfs:label> <rdfs:label xml:lang="en-US">Editor Role</rdfs:label>
</rdf:Description> </rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#NewsRelease"> <rdf:Description rdf:about="http://vivoweb.org/ontology/core#NewsRelease">
@ -1948,11 +1949,11 @@
<vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">-1</vitro:displayRankAnnot> <vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">-1</vitro:displayRankAnnot>
</rdf:Description> </rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#UndergraduateAdvisingRelationship"> <rdf:Description rdf:about="http://vivoweb.org/ontology/core#UndergraduateAdvisingRelationship">
<rdfs:label xml:lang="en-US">Undergraduate Advising Relationship</rdfs:label>
<vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">1</vitro:displayLimitAnnot>
<vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">1</vitro:displayRankAnnot>
<vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/> <vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/> <vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">1</vitro:displayLimitAnnot>
<vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">1</vitro:displayRankAnnot>
<rdfs:label xml:lang="en-US">Undergraduate Advising Relationship</rdfs:label>
</rdf:Description> </rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#Position"> <rdf:Description rdf:about="http://vivoweb.org/ontology/core#Position">
<rdfs:label xml:lang="en-US">Position</rdfs:label> <rdfs:label xml:lang="en-US">Position</rdfs:label>
@ -1983,11 +1984,11 @@
<rdfs:label xml:lang="en-US">Non-Academic</rdfs:label> <rdfs:label xml:lang="en-US">Non-Academic</rdfs:label>
</rdf:Description> </rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#PostdocOrFellowAdvisingRelationship"> <rdf:Description rdf:about="http://vivoweb.org/ontology/core#PostdocOrFellowAdvisingRelationship">
<rdfs:label xml:lang="en-US">Postdoc or Fellow Advising Relationship</rdfs:label>
<vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">1</vitro:displayLimitAnnot>
<vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">1</vitro:displayRankAnnot>
<vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/> <vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/> <vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">1</vitro:displayLimitAnnot>
<vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">1</vitro:displayRankAnnot>
<rdfs:label xml:lang="en-US">Postdoc or Fellow Advising Relationship</rdfs:label>
</rdf:Description> </rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#governingAuthorityFor"> <rdf:Description rdf:about="http://vivoweb.org/ontology/core#governingAuthorityFor">
<vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">5</vitro:displayLimitAnnot> <vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">5</vitro:displayLimitAnnot>
@ -2035,16 +2036,15 @@
<vitro:extendedLinkedData rdf:datatype="http://www.w3.org/2001/XMLSchema#boolean">true</vitro:extendedLinkedData> <vitro:extendedLinkedData rdf:datatype="http://www.w3.org/2001/XMLSchema#boolean">true</vitro:extendedLinkedData>
</rdf:Description> </rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#editorOf"> <rdf:Description rdf:about="http://vivoweb.org/ontology/core#editorOf">
<vitro:publicDescriptionAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#string">This relates the information resource for which a person has managerial and sometimes policy-making responsibility to the person.</vitro:publicDescriptionAnnot>
<vitro:selectFromExistingAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#boolean">true</vitro:selectFromExistingAnnot>
<vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<vitro:offerCreateNewOptionAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#boolean">true</vitro:offerCreateNewOptionAnnot>
<rdfs:label xml:lang="en-US">editor of</rdfs:label>
<vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">20</vitro:displayRankAnnot>
<vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<vitro:inPropertyGroupAnnot rdf:resource="http://vivoweb.org/ontology#vitroPropertyGroupbibliographic"/>
<vitro:fullPropertyNameAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#string">editorOf</vitro:fullPropertyNameAnnot>
<vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">5</vitro:displayLimitAnnot> <vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">5</vitro:displayLimitAnnot>
<vitro:inPropertyGroupAnnot rdf:resource="http://vivoweb.org/ontology#vitroPropertyGroupbibliographic"/>
<vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">20</vitro:displayRankAnnot>
<rdfs:label xml:lang="en-US">editor of </rdfs:label>
<vitro:offerCreateNewOptionAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#boolean">true</vitro:offerCreateNewOptionAnnot>
<vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<vitro:publicDescriptionAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#string">use this property to record editorial work performed for a document, such as a book, an academic article or a conference paper.</vitro:publicDescriptionAnnot>
<vitro:selectFromExistingAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#boolean">true</vitro:selectFromExistingAnnot>
</rdf:Description> </rdf:Description>
<rdf:Description rdf:about="http://aims.fao.org/aos/geopolitical.owl#agriculturalAreaYear"> <rdf:Description rdf:about="http://aims.fao.org/aos/geopolitical.owl#agriculturalAreaYear">
<vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#nobody"/> <vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#nobody"/>
@ -3181,6 +3181,16 @@
<vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">60</vitro:displayRankAnnot> <vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">60</vitro:displayRankAnnot>
<rdfs:label xml:lang="en-US">primary phone</rdfs:label> <rdfs:label xml:lang="en-US">primary phone</rdfs:label>
</rdf:Description> </rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#editor">
<vitro:inPropertyGroupAnnot rdf:resource="http://vivoweb.org/ontology#vitroPropertyGroupbibobscure"/>
<vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">5</vitro:displayLimitAnnot>
<vitro:selectFromExistingAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#boolean">true</vitro:selectFromExistingAnnot>
<vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">20</vitro:displayRankAnnot>
<vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<rdfs:label xml:lang="en-US">editor</rdfs:label>
<vitro:offerCreateNewOptionAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#boolean">true</vitro:offerCreateNewOptionAnnot>
<vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
</rdf:Description>
<rdf:Description rdf:about="http://aims.fao.org/aos/geopolitical.owl#hasCode"> <rdf:Description rdf:about="http://aims.fao.org/aos/geopolitical.owl#hasCode">
<vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#nobody"/> <vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#nobody"/>
<vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/> <vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
@ -3587,12 +3597,12 @@
<rdfs:label xml:lang="en-US">Relationship</rdfs:label> <rdfs:label xml:lang="en-US">Relationship</rdfs:label>
</rdf:Description> </rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#email"> <rdf:Description rdf:about="http://vivoweb.org/ontology/core#email">
<rdfs:label xml:lang="en-US">email</rdfs:label>
<vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">1</vitro:displayRankAnnot>
<vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">9</vitro:displayLimitAnnot>
<vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/> <vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/> <vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<vitro:inPropertyGroupAnnot rdf:resource="http://vivoweb.org/ontology#vitroPropertyGroupaddress"/> <vitro:inPropertyGroupAnnot rdf:resource="http://vivoweb.org/ontology#vitroPropertyGroupaddress"/>
<vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">9</vitro:displayLimitAnnot>
<vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">1</vitro:displayRankAnnot>
<rdfs:label xml:lang="en-US">email</rdfs:label>
</rdf:Description> </rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/provenance-support"> <rdf:Description rdf:about="http://vivoweb.org/ontology/provenance-support">
<vitro:ontologyPrefixAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#string">pvs</vitro:ontologyPrefixAnnot> <vitro:ontologyPrefixAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#string">pvs</vitro:ontologyPrefixAnnot>
@ -3736,11 +3746,11 @@
<rdfs:label xml:lang="en-US">Date/Time Value Precision</rdfs:label> <rdfs:label xml:lang="en-US">Date/Time Value Precision</rdfs:label>
</rdf:Description> </rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#GraduateAdvisingRelationship"> <rdf:Description rdf:about="http://vivoweb.org/ontology/core#GraduateAdvisingRelationship">
<rdfs:label xml:lang="en-US">Graduate Advising Relationship</rdfs:label>
<vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">1</vitro:displayLimitAnnot>
<vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">1</vitro:displayRankAnnot>
<vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/> <vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/> <vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">1</vitro:displayLimitAnnot>
<vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">1</vitro:displayRankAnnot>
<rdfs:label xml:lang="en-US">Graduate Advising Relationship</rdfs:label>
</rdf:Description> </rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#preferredTitle"> <rdf:Description rdf:about="http://vivoweb.org/ontology/core#preferredTitle">
<vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/> <vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
@ -3923,13 +3933,13 @@
<rdfs:label xml:lang="en-US">has prerequisite</rdfs:label> <rdfs:label xml:lang="en-US">has prerequisite</rdfs:label>
</rdf:Description> </rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#validIn"> <rdf:Description rdf:about="http://vivoweb.org/ontology/core#validIn">
<vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">2</vitro:displayRankAnnot>
<vitro:offerCreateNewOptionAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#boolean">true</vitro:offerCreateNewOptionAnnot>
<vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/> <vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<vitro:selectFromExistingAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#boolean">true</vitro:selectFromExistingAnnot> <vitro:offerCreateNewOptionAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#boolean">true</vitro:offerCreateNewOptionAnnot>
<vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/> <vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<rdfs:label xml:lang="en-US">valid in</rdfs:label> <vitro:selectFromExistingAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#boolean">true</vitro:selectFromExistingAnnot>
<vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">5</vitro:displayLimitAnnot> <vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">5</vitro:displayLimitAnnot>
<vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">2</vitro:displayRankAnnot>
<rdfs:label xml:lang="en-US">valid in</rdfs:label>
</rdf:Description> </rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/scientific-research#Phase0ClinicalTrial"> <rdf:Description rdf:about="http://vivoweb.org/ontology/scientific-research#Phase0ClinicalTrial">
<vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/> <vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
@ -4407,8 +4417,8 @@
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#NonFacultyAcademicPosition"> <rdf:Description rdf:about="http://vivoweb.org/ontology/core#NonFacultyAcademicPosition">
<vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">-1</vitro:displayLimitAnnot> <vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">-1</vitro:displayLimitAnnot>
<vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">-1</vitro:displayRankAnnot> <vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">-1</vitro:displayRankAnnot>
<rdfs:label xml:lang="en-US">Non-Faculty Academic Position</rdfs:label>
<vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/> <vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<rdfs:label xml:lang="en-US">Non-Faculty Academic Position</rdfs:label>
<vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/> <vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<vitro:extendedLinkedData rdf:datatype="http://www.w3.org/2001/XMLSchema#boolean">true</vitro:extendedLinkedData> <vitro:extendedLinkedData rdf:datatype="http://www.w3.org/2001/XMLSchema#boolean">true</vitro:extendedLinkedData>
</rdf:Description> </rdf:Description>
@ -4556,15 +4566,16 @@
<vitro:customShortViewAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#string">linkShortView.jsp</vitro:customShortViewAnnot> <vitro:customShortViewAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#string">linkShortView.jsp</vitro:customShortViewAnnot>
</rdf:Description> </rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#hasReviewerRole"> <rdf:Description rdf:about="http://vivoweb.org/ontology/core#hasReviewerRole">
<vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">5</vitro:displayLimitAnnot>
<vitro:offerCreateNewOptionAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#boolean">true</vitro:offerCreateNewOptionAnnot>
<rdfs:label xml:lang="en-US">reviewer of</rdfs:label>
<vitro:inPropertyGroupAnnot rdf:resource="http://vivoweb.org/ontology#vitroPropertyGroupoutreach"/>
<vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<vitro:customEntryFormAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#string">addReviewerRoleToPerson.jsp</vitro:customEntryFormAnnot>
<vitro:selectFromExistingAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#boolean">true</vitro:selectFromExistingAnnot>
<vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">2</vitro:displayRankAnnot> <vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">2</vitro:displayRankAnnot>
<vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<vitro:selectFromExistingAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#boolean">true</vitro:selectFromExistingAnnot>
<vitro:customEntryFormAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#string">addReviewerRoleToPerson.jsp</vitro:customEntryFormAnnot>
<vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<vitro:inPropertyGroupAnnot rdf:resource="http://vivoweb.org/ontology#vitroPropertyGroupoutreach"/>
<vitro:publicDescriptionAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#string">use this property to indicate ongoing reviewer responsibility for a bibo:Collection, such as a Journal or Series, and also to record a review performed for a bibo:Document such as a book, academic article or conference paper.</vitro:publicDescriptionAnnot>
<rdfs:label xml:lang="en-US">reviewer of</rdfs:label>
<vitro:offerCreateNewOptionAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#boolean">true</vitro:offerCreateNewOptionAnnot>
<vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">5</vitro:displayLimitAnnot>
</rdf:Description> </rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#courseOfferedBy"> <rdf:Description rdf:about="http://vivoweb.org/ontology/core#courseOfferedBy">
<vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/> <vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
@ -4903,16 +4914,13 @@
<rdfs:label xml:lang="en-US">number of pages</rdfs:label> <rdfs:label xml:lang="en-US">number of pages</rdfs:label>
</rdf:Description> </rdf:Description>
<rdf:Description rdf:about="http://purl.org/ontology/bibo/editor"> <rdf:Description rdf:about="http://purl.org/ontology/bibo/editor">
<vitro:fullPropertyNameAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#string">editor</vitro:fullPropertyNameAnnot> <vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#nobody"/>
<vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">20</vitro:displayRankAnnot>
<vitro:publicDescriptionAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#string">A person having managerial and sometimes policy-making responsibility for the editorial part of a publishing firm or of a newspaper, magazine, or other publication.</vitro:publicDescriptionAnnot>
<vitro:offerCreateNewOptionAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#boolean">true</vitro:offerCreateNewOptionAnnot>
<rdfs:label xml:lang="en-US">editor</rdfs:label>
<vitro:inPropertyGroupAnnot rdf:resource="http://vivoweb.org/ontology#vitroPropertyGroupbibobscure"/>
<vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">5</vitro:displayLimitAnnot>
<vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<vitro:selectFromExistingAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#boolean">true</vitro:selectFromExistingAnnot> <vitro:selectFromExistingAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#boolean">true</vitro:selectFromExistingAnnot>
<vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/> <vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">5</vitro:displayLimitAnnot>
<vitro:inPropertyGroupAnnot rdf:resource="http://vivoweb.org/ontology#vitroPropertyGroupbibobscure"/>
<rdfs:label xml:lang="en-US">editor</rdfs:label>
<vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#nobody"/>
<vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">20</vitro:displayRankAnnot>
</rdf:Description> </rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#Association"> <rdf:Description rdf:about="http://vivoweb.org/ontology/core#Association">
<vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">-1</vitro:displayLimitAnnot> <vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">-1</vitro:displayLimitAnnot>
@ -5140,11 +5148,11 @@
<vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#nobody"/> <vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#nobody"/>
</rdf:Description> </rdf:Description>
<rdf:Description rdf:about="http://vivoweb.org/ontology/core#FacultyMentoringRelationship"> <rdf:Description rdf:about="http://vivoweb.org/ontology/core#FacultyMentoringRelationship">
<rdfs:label xml:lang="en-US">Faculty Mentoring Relationship</rdfs:label>
<vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">1</vitro:displayLimitAnnot>
<vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">1</vitro:displayRankAnnot>
<vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/> <vitro:hiddenFromDisplayBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/> <vitro:prohibitedFromUpdateBelowRoleLevelAnnot rdf:resource="http://vitro.mannlib.cornell.edu/ns/vitro/role#public"/>
<vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">1</vitro:displayLimitAnnot>
<vitro:displayRankAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">1</vitro:displayRankAnnot>
<rdfs:label xml:lang="en-US">Faculty Mentoring Relationship</rdfs:label>
</rdf:Description> </rdf:Description>
<rdf:Description rdf:about="http://purl.org/ontology/bibo/Bill"> <rdf:Description rdf:about="http://purl.org/ontology/bibo/Bill">
<vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">-1</vitro:displayLimitAnnot> <vitro:displayLimitAnnot rdf:datatype="http://www.w3.org/2001/XMLSchema#int">-1</vitro:displayLimitAnnot>

View file

@ -117,11 +117,14 @@
</listener> </listener>
<!-- The following two listeners remain temporarily until SDB becomes the default triple store --> <!-- The following listener remains temporarily until SDB becomes the default triple store -->
<listener> <listener>
<listener-class>edu.cornell.mannlib.vitro.webapp.servlet.setup.AttachSubmodels</listener-class> <listener-class>edu.cornell.mannlib.vitro.webapp.servlet.setup.AttachSubmodels</listener-class>
</listener> </listener>
<!-- This listener sets up SimpleReasoner also in SDB mode. In SDB mode, Pellet is used for -->
<!-- TBox reasoning and SimpleReasoner is used for ABox reasoning. In RDF mode, Pellet was -->
<!-- used for both. -->
<listener> <listener>
<listener-class>edu.cornell.mannlib.vitro.webapp.servlet.setup.PelletReasonerSetup</listener-class> <listener-class>edu.cornell.mannlib.vitro.webapp.servlet.setup.PelletReasonerSetup</listener-class>
</listener> </listener>
@ -1078,18 +1081,6 @@
<url-pattern>/dwr/*</url-pattern> <url-pattern>/dwr/*</url-pattern>
</servlet-mapping> </servlet-mapping>
<!-- Deprecated servlet (still used in Datastar) - retain temporarily for testing and comparison. -->
<servlet>
<servlet-name>sendmail</servlet-name>
<servlet-class>edu.cornell.mannlib.vitro.webapp.controller.ContactMailServlet</servlet-class>
<load-on-startup>5</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>sendmail</servlet-name>
<url-pattern>/sendmail</url-pattern>
</servlet-mapping>
<!-- end deprecated servlet -->
<servlet> <servlet>
<servlet-name>sendMail</servlet-name> <servlet-name>sendMail</servlet-name>
<servlet-class>edu.cornell.mannlib.vitro.webapp.controller.freemarker.ContactMailController</servlet-class> <servlet-class>edu.cornell.mannlib.vitro.webapp.controller.freemarker.ContactMailController</servlet-class>

View file

@ -11,7 +11,7 @@
#map-of-science-info { #map-of-science-info {
margin-bottom: 6px; margin-bottom: 6px;
margin-top: -6px; margin-top: 6px;
} }
.hide-dom-on-init { .hide-dom-on-init {

View file

@ -5,7 +5,7 @@
<jsp:param name="roleType" value="http://vivoweb.org/ontology/core#MemberRole" /> <jsp:param name="roleType" value="http://vivoweb.org/ontology/core#MemberRole" />
<jsp:param name="roleToActivityPredicate" value="http://vivoweb.org/ontology/core#roleIn" /> <jsp:param name="roleToActivityPredicate" value="http://vivoweb.org/ontology/core#roleIn" />
<jsp:param name="activityToRolePredicate" value="http://vivoweb.org/ontology/core#relatedRole" /> <jsp:param name="activityToRolePredicate" value="http://vivoweb.org/ontology/core#relatedRole" />
<jsp:param name="roleActivityType_optionsType" value="CHILD_VCLASSES" /> <jsp:param name="roleActivityType_optionsType" value="VCLASSGROUP" />
<jsp:param name="roleActivityType_objectClassUri" value="http://xmlns.com/foaf/0.1/Organization" /> <jsp:param name="roleActivityType_objectClassUri" value="http://vivoweb.org/ontology#vitroClassGrouporganizations" />
<jsp:param name="roleActivityType_literalOptions" value="[ 'Select one' ]" /> <jsp:param name="roleActivityType_literalOptions" value="[ 'Select one' ]" />
</jsp:include> </jsp:include>

View file

@ -6,6 +6,6 @@
<jsp:param name="roleToActivityPredicate" value="http://vivoweb.org/ontology/core#forInformationResource" /> <jsp:param name="roleToActivityPredicate" value="http://vivoweb.org/ontology/core#forInformationResource" />
<jsp:param name="activityToRolePredicate" value="http://vivoweb.org/ontology/core#linkedRole" /> <jsp:param name="activityToRolePredicate" value="http://vivoweb.org/ontology/core#linkedRole" />
<jsp:param name="roleActivityType_optionsType" value="CHILD_VCLASSES" /> <jsp:param name="roleActivityType_optionsType" value="CHILD_VCLASSES" />
<jsp:param name="roleActivityType_objectClassUri" value="http://purl.org/ontology/bibo/Collection" /> <jsp:param name="roleActivityType_objectClassUri" value="http://vivoweb.org/ontology/core#InformationResource" />
<jsp:param name="roleActivityType_literalOptions" value="[ 'Select one' ]" /> <jsp:param name="roleActivityType_literalOptions" value="[ 'Select one' ]" />
</jsp:include> </jsp:include>

View file

@ -91,8 +91,9 @@ browseByVClass.getIndividuals = function(vclassUri, alpha, page, scroll) {
browseByVClass.pagination(pages, page); browseByVClass.pagination(pages, page);
} }
selectedClassHeading = '<h3 class="selected-class">'+ results.vclass.name +'</h3>'; // selectedClassHeading = '<h3 class="selected-class">'+ results.vclass.name +'</h3>'; NIHVIVO-2483 tlw72
browseByVClass.individualsContainer.prepend(selectedClassHeading); // browseByVClass.individualsContainer.prepend(selectedClassHeading);
$('h4#selectedClassHeading').text(results.vclass.name); // NIHVIVO-2483 tlw72
// set selected class, alpha and page // set selected class, alpha and page
browseByVClass.selectedVClass(results.vclass.URI); browseByVClass.selectedVClass(results.vclass.URI);

View file

@ -0,0 +1,49 @@
/* $This file is distributed under the terms of the license in /doc/license.txt$ */
$(document).ready(function(){
// This function creates and styles the "qTip" tooltip that displays when the user hovers over the info icons.
$('.filterInfoIcon').each(function()
{
var tipText ;
var tipLocation = "topLeft";
if ( $(this).attr('id') == 'imageIconOne' ) {
tipText = $('#toolTipOne').html();
}
else if ( $(this).attr('id') == 'imageIconTwo' ) {
tipText = $('#toolTipTwo').html();
}
else {
tipText = $('#toolTipThree').html();
tipLocation = "topRight"
};
$(this).qtip(
{
content: {
text: tipText
},
position: {
corner: {
target: 'center',
tooltip: tipLocation
}
},
show: {
when: {event: 'mouseover'}
},
hide: {
fixed: true // Make it fixed so it can be hovered over
},
style: {
padding: '6px 6px', // Give it some extra padding
width: 500,
textAlign: 'left',
backgroundColor: '#ffffc0',
fontSize: '.7em',
padding: '6px 10px 6px 10px',
lineHeight: '14px'
}
});
});
});

View file

@ -1,5 +1,10 @@
<#-- $This file is distributed under the terms of the license in /doc/license.txt$ --> <#-- $This file is distributed under the terms of the license in /doc/license.txt$ -->
<#if jobKnown == "false">
<p>Error: No file harvest job was specified, or an unknown job was specified.</p>
<p>The end user should not see this error under normal circumstances, so this is probably a bug and should be reported.</p>
<#else>
<script type="text/javascript"> <script type="text/javascript">
var harvestProgressResponse; var harvestProgressResponse;
@ -17,9 +22,10 @@
window.setTimeout(continueHarvest, 1000); window.setTimeout(continueHarvest, 1000);
} }
} }
request.open("POST", "/vivo/harvester/testfile", true); request.open("POST", "${postTo}", true);
request.setRequestHeader("content-type","application/x-www-form-urlencoded"); request.setRequestHeader("content-type","application/x-www-form-urlencoded");
request.send("${paramIsHarvestClick}=true"); //request.send("${paramMode}=${modeHarvest}&${paramJob}=${job}");
request.send("${paramMode}=${modeHarvest}");
} }
@ -41,9 +47,10 @@
window.setTimeout(continueHarvest, 1000); window.setTimeout(continueHarvest, 1000);
} }
} }
request.open("POST", "/vivo/harvester/testfile", true); request.open("POST", "${postTo}", true);
request.setRequestHeader("Content-type","application/x-www-form-urlencoded"); request.setRequestHeader("Content-type","application/x-www-form-urlencoded");
request.send("${paramIsHarvestClick}=false"); //request.send("${paramMode}=${modeCheckStatus}&${paramJob}=${job}");
request.send("${paramMode}=${modeCheckStatus}");
} else { } else {
var importedGrants = document.getElementById("importedGrants") var importedGrants = document.getElementById("importedGrants")
@ -117,6 +124,10 @@
document.getElementById("fileUploadForm").target = "uploadTarget"; document.getElementById("fileUploadForm").target = "uploadTarget";
document.getElementById("uploadTarget").onload = fileResponse; document.getElementById("uploadTarget").onload = fileResponse;
} }
document.getElementById("downloadTemplateForm").onsubmit = function()
{
document.getElementById("downloadTemplateForm").target = "uploadTarget";
}
} }
window.onload = init; window.onload = init;
</script> </script>
@ -143,12 +154,15 @@
} }
</style> </style>
<h2>${jobSpecificHeader}</h2>
<div id="step1" class="testfile-step"> <div id="step1" class="testfile-step">
<h3 class="testfile-step-header">Step 1</h3> <h3 class="testfile-step-header">Step 1</h3>
<div id="step1-inner" class="testfile-step-body"> <div id="step1-inner" class="testfile-step-body">
<h4 class="testfile-step-subheader">Download template</h4> <h4 class="testfile-step-subheader">Download template</h4>
<p><input type="button" value="Download" style="margin-right:10px" />We are providing a helpful template file for you to download.</p> <form id="downloadTemplateForm" method="post" action=${postTo}>
<input type="hidden" id="${paramMode}" name="${paramMode}" value="${modeDownloadTemplate}" />
<p><input type="submit" name="submit" value="Download" style="margin-right:10px" />We are providing a helpful template file for you to download.</p>
</form>
</div> </div>
<div class="clearBothDiv" /> <div class="clearBothDiv" />
</div> </div>
@ -173,8 +187,9 @@
<div id="step3-inner" class="testfile-step-body"> <div id="step3-inner" class="testfile-step-body">
<h4 class="testfile-step-subheader">Upload file(s)</h4> <h4 class="testfile-step-subheader">Upload file(s)</h4>
<p>Upload your filled-in template(s).</p> <p>Upload your filled-in template(s).</p>
<form id="fileUploadForm" method="post" enctype="multipart/form-data" action="/vivo/harvester/testfile"> <form id="fileUploadForm" method="post" enctype="multipart/form-data" action=${postTo}>
<input type="hidden" id="${paramFirstUpload}" name="${paramFirstUpload}" value="true" /> <input type="hidden" id="${paramFirstUpload}" name="${paramFirstUpload}" value="true" />
<!--<input type="hidden" id="${paramJob}" name="${paramJob}" value="${job}" /> -->
<input type="file" name="${paramUploadedFile}" /> <input type="file" name="${paramUploadedFile}" />
<input type="submit" name="submit" value="Upload" /> <input type="submit" name="submit" value="Upload" />
<iframe id="uploadTarget" name="uploadTarget" src="" style="width:0;height:0;border:0px solid #fff;"></iframe> <iframe id="uploadTarget" name="uploadTarget" src="" style="width:0;height:0;border:0px solid #fff;"></iframe>
@ -226,4 +241,6 @@
<div class="clearBothDiv" /> <div class="clearBothDiv" />
</div> </div>
</#if>

View file

@ -15,21 +15,12 @@ corresponding changes in the included Templates. -->
</div> </div>
--> -->
<h2 id="header-entity-label" class="hide-dom-on-init"><span><a id="entityMoniker" href="${entityVivoProfileURL}">${entityLabel}</a>&nbsp; <h2 id="header-entity-label" class="hide-dom-on-init"><span><a id="entityMoniker" href="${entityVivoProfileURL}">${entityLabel}</a></span></h2>
<img id="incomplete-data-disclaimer" class="infoIcon" src="${urls.images}/iconInfo.png" alt="information icon" title="This information is based solely on Publications which have been loaded into the VIVO system" /></span></h2>
<div id="map-of-science-info" class="hide-dom-on-init"> Explore <span id="mapped-publications" style="font-weight: bold"></span> publications activity across 554 scientific sub-disciplines <div id="map-of-science-info" class="hide-dom-on-init"> Explore <span id="mapped-publications" style="font-weight: bold"></span> publications activity across 554 scientific sub-disciplines
<img class="filterInfoIcon" src="${urls.images}/iconInfo.png" <img class="filterInfoIcon" id="imageIconOne" src="${urls.images}/iconInfo.png"
alt="information icon" alt="information icon"
title="VIVO's Map of Science visualization shows the publication activity of any organization, person, or university in a VIVO instance, overlaid on the map of science. This particular page shows the publication activity of ${entityLabel}. title="" />
You can use VIVO's Map of Science visualization to see where ${entityLabel} is active in the world of science, based on publications that have been loaded into this VIVO instance.
Overlaid circles are larger if ${entityLabel} has many publications in that sub-discipline, and are smaller if ${entityLabel} has fewer publications in that sub-discipline.
Circles are overlaid on the Map of Science itself, which is made of 554 interconnected sub-disciplines, shown as grey dots here. A sub-discipline is defined as a cluster of journals. The Map of Science groups over 16,000 journals into 554 sub-disciplines using similarities in their lists of references and key terms. Sub-disciplines that are especially similar to one another are interconnected, and will be closer to one another on the map.
For more information on this and other maps of science, see http://mapofscience.com or http://scimaps.org" />
</div> </div>
<div id="left-column" class="hide-dom-on-init"> <div id="left-column" class="hide-dom-on-init">
@ -55,13 +46,9 @@ For more information on this and other maps of science, see http://mapofscience.
<div id="science-areas-filter"> <div id="science-areas-filter">
<span id="discipline-filter" class="filter-option active-filter">13 Disciplines</span> | <span id="discipline-filter" class="filter-option active-filter">13 Disciplines</span> |
<span id="subdisciplines-filter" class="filter-option">554 Sub-Disciplines</span> <span id="subdisciplines-filter" class="filter-option">554 Sub-Disciplines</span>
<img class="filterInfoIcon" src="${urls.images}/iconInfo.png" <img class="filterInfoIcon" id="imageIconTwo" src="${urls.images}/iconInfo.png"
alt="information icon" alt="information icon"
title="${entityLabel}'s publication activity can be categorized into 13 disciplines or 554 sub-disciplines on the map of science. title="" />
The map of science is divided into 13 disciplines, each of which has its own area on the map, as well as its own color. Each of these disciplines contains multiple sub-disciplines. You can hover over a discipline in the table below to show which overlaid circles it corresponds to on the map.
Each grey dot on the map represents one of the 554 sub-disciplines. A sub-discipline is defined as a cluster of journals. We grouped over 16,000 journals into 554 disciplines using similarities in their lists of references and key terms. Sub-disciplines that are especially similar to one another are connected by lines, and are closer to one another on the map. You can hover over a sub-discipline in the table below to show which overlaid circle it corresponds to on the map." />
</div> </div>
<div id="main-science-areas-table-container"></div> <div id="main-science-areas-table-container"></div>
@ -74,11 +61,32 @@ Each grey dot on the map represents one of the 554 sub-disciplines. A sub-discip
<div id="right-column"><div id="map_area"></div> <div id="right-column"><div id="map_area"></div>
<div id="percent-mapped-info"> <div id="percent-mapped-info">
mapped <span id="percent-mapped"></span>% of <span id="total-publications"></span> publications mapped <span id="percent-mapped"></span>% of <span id="total-publications"></span> publications
<img class="filterInfoIcon" src="${urls.images}/iconInfo.png" <img class="filterInfoIcon" id="imageIconThree" src="${urls.images}/iconInfo.png"
alt="information icon" alt="information icon"
title="This visualization is based on the publications we were able to 'science locate' for ${entityLabel}, and therefore it may not be fully representative of the overall publication activity for ${entityLabel}. title="" /></div>
The publication coverage of this visualization can be improved by including more publication data in the VIVO system, and by ensuring that each publication in the VIVO system is associated with a journal that the Map of Science recognizes (based on the holdings of Thomson's ISI database and Elsevier's Scopus database). Journal names containing typos or other idiosyncracies may need to be cleaned up before they are recognized. You may contact a VIVO system administrator if publication coverage is a concern." /></div>
</div> </div>
</div> </div>
<div id="toolTipOne" style="display:none;">
VIVO's Map of Science visualization shows the publication activity of any organization, person, or university in a VIVO instance, overlaid on the map of science. This particular page shows the publication activity of ${entityLabel}.<br /> <br />
You can use VIVO's Map of Science visualization to see where ${entityLabel} is active in the world of science -- <em><b>based solely on publications that have been loaded into this VIVO instance.</b></em><br /><br />
Overlaid circles are larger if ${entityLabel} has many publications in that sub-discipline, and are smaller if ${entityLabel} has fewer publications in that sub-discipline.<br /><br />
Circles are overlaid on the Map of Science itself, which is made of 554 interconnected sub-disciplines, shown as grey dots here. A sub-discipline is defined as a cluster of journals. The Map of Science groups over 16,000 journals into 554 sub-disciplines using similarities in their lists of references and key terms. Sub-disciplines that are especially similar to one another are interconnected, and will be closer to one another on the map.
<br /><br />
For more information on this and other maps of science, see <a href='http://mapofscience.com'>http://mapofscience.com</a> or <a href='http://scimaps.org'>http://scimaps.org</a></div>
<div id="toolTipTwo" style="display:none;">
${entityLabel}'s publication activity can be categorized into 13 disciplines or 554 sub-disciplines on the map of science.
<br /><br />
The map of science is divided into 13 disciplines, each of which has its own area on the map, as well as its own color. Each of these disciplines contains multiple sub-disciplines. You can hover over a discipline in the table below to show which overlaid circles it corresponds to on the map.
<br /><br />
Each grey dot on the map represents one of the 554 sub-disciplines. A sub-discipline is defined as a cluster of journals. We grouped over 16,000 journals into 554 disciplines using similarities in their lists of references and key terms. Sub-disciplines that are especially similar to one another are connected by lines, and are closer to one another on the map. You can hover over a sub-discipline in the table below to show which overlaid circle it corresponds to on the map.</div>
<div id="toolTipThree" style="display:none;">
This visualization is based on the publications we were able to 'science locate' for ${entityLabel}, and therefore it may not be fully representative of the overall publication activity for ${entityLabel}.<br /><br />
The publication coverage of this visualization can be improved by including more publication data in the VIVO system, and by ensuring that each publication in the VIVO system is associated with a journal that the Map of Science recognizes (based on the holdings of Thomson's ISI database and Elsevier's Scopus database). Journal names containing typos or other idiosyncracies may need to be cleaned up before they are recognized. You may contact a VIVO system administrator if publication coverage is a concern.</div>
${headScripts.add('<script type="text/javascript" src="${urls.base}/js/jquery_plugins/qtip/jquery.qtip-1.0.0-rc3.min.js"></script>')}
${scripts.add('<script type="text/javascript" src="${urls.base}/js/visualization/mapofscience/Utils.js"></script>')}

View file

@ -0,0 +1,251 @@
/* $This file is distributed under the terms of the license in /doc/license.txt$ */
package edu.cornell.mannlib.vitro.webapp.controller.harvester;
import java.io.BufferedReader;
import java.io.File;
import java.io.FileReader;
import java.io.IOException;
import java.util.ArrayList;
import java.util.List;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.skife.csv.SimpleReader;
import edu.cornell.mannlib.vitro.webapp.controller.VitroRequest;
/**
* An implementation of FileHarvestJob that can be used for any CSV file harvest.
*/
class CsvFileHarvestJob implements FileHarvestJob {
/**
* Logger.
*/
private static final Log log = LogFactory.getLog(CsvFileHarvestJob.class);
/**
* The HTTP request.
*/
private VitroRequest vreq;
/**
* The template file against which uploaded CSV files will be validated.
*/
private File templateFile;
/**
* The script which will be run after needed replacements are made.
*/
private File scriptFile;
/**
* The namespace to be used for the harvest.
*/
private final String namespace;
/**
* A name for the type of data being imported. For example "Grant" or "Person".
*/
private final String friendlyName;
/**
* Constructor.
* @param templateFileName just the name of the template file. The directory is assumed to be standard.
*/
public CsvFileHarvestJob(VitroRequest vreq, String templateFileName, String scriptFileName, String namespace, String friendlyName) {
this.vreq = vreq;
this.templateFile = new File(getTemplateFileDirectory() + templateFileName);
this.scriptFile = new File(getScriptFileDirectory() + scriptFileName);
log.error(getTemplateFileDirectory() + templateFileName);
this.namespace = namespace;
this.friendlyName = friendlyName;
}
/**
* Gets the path to the directory containing the template files.
* @return the path to the directory containing the template files
*/
private String getTemplateFileDirectory() {
String harvesterPath = TestFileController.getHarvesterPath();
String pathToTemplateFiles = harvesterPath + TestFileController.PATH_TO_TEMPLATE_FILES;
return pathToTemplateFiles;
}
/**
* Gets the path to the directory containing the script files.
* @return the path to the directory containing the script files
*/
private String getScriptFileDirectory() {
String harvesterPath = TestFileController.getHarvesterPath();
String pathToScriptFiles = harvesterPath + TestFileController.PATH_TO_HARVESTER_SCRIPTS;
return pathToScriptFiles;
}
private boolean[] getLinesEndingInComma(File file) throws IOException {
ArrayList<Boolean> linesEndingInCommaList = new ArrayList<Boolean>();
BufferedReader reader = new BufferedReader(new FileReader(file));
for(String line = reader.readLine(); line != null; line = reader.readLine()) {
boolean lineEndsInComma = line.endsWith(",");
linesEndingInCommaList.add(lineEndsInComma);
}
reader.close();
boolean[] linesEndingInComma = new boolean[linesEndingInCommaList.size()];
for(int i = 0; i < linesEndingInComma.length; i++) {
linesEndingInComma[i] = linesEndingInCommaList.get(i);
}
return linesEndingInComma;
}
@Override
@SuppressWarnings("rawtypes")
public String validateUpload(File file) {
try {
SimpleReader reader = new SimpleReader();
List templateCsv = reader.parse(this.templateFile);
String[] templateFirstLine = (String[])templateCsv.get(0);
//if a line ends in a comma (absolutely a comma, no whitespace), SimpleReader will not consider the part after the comma to be a blank section.
List csv = reader.parse(file);
boolean[] linesEndingInComma = getLinesEndingInComma(file);
int length = csv.size();
if(length == 0)
return "No data in file";
for(int i = 0; i < length; i++) {
String[] line = (String[])csv.get(i);
boolean endsInComma = linesEndingInComma[i];
if(i == 0) {
String errorMessage = validateCsvFirstLine(templateFirstLine, line);
if(errorMessage != null)
return errorMessage;
}
else if(line.length != 0) {
int actualLineLength = line.length + (endsInComma ? 1 : 0);
if(actualLineLength != templateFirstLine.length) {
return "Mismatch in number of entries in row " + i + ": expected " + templateFirstLine.length + ", found " + actualLineLength;
}
}
}
} catch (IOException e) {
log.error(e, e);
return e.getMessage();
}
return null;
}
/**
* Makes sure that the first line of the CSV file is identical to the first line of the template file. This is
* assuming we are expecting all user CSV files to contain an initial header line. If this is not the case, then
* this method is unnecessary.
* @param templateFirstLine the parsed-out contents of the first line of the template file
* @param line the parsed-out contents of the first line of the input file
* @return an error message if the two lines don't match, or null if they do
*/
private String validateCsvFirstLine(String[] templateFirstLine, String[] line) {
String errorMessage = "File header does not match template";
if(line.length != templateFirstLine.length) {
//return errorMessage + ": " + "file header columns = " + line.length + ", template columns = " + templateFirstLine.length;
String errorMsg = "";
errorMsg += "file header items: ";
for(int i = 0; i < line.length; i++) {
errorMsg += line[i] + ", ";
}
errorMsg += "template items: ";
for(int i = 0; i < templateFirstLine.length; i++) {
errorMsg += templateFirstLine[i] + ", ";
}
return errorMsg;
}
for(int i = 0; i < line.length; i++)
{
if(!line[i].equals(templateFirstLine[i]))
return errorMessage + ": file header column " + (i + 1) + " = " + line[i] + ", template column " + (i + 1) + " = " + templateFirstLine[i];
}
return null;
}
@Override
public String getScript()
{
File scriptTemplate = this.scriptFile;
String scriptTemplateContents = readScriptTemplate(scriptTemplate);
String replacements = performScriptTemplateReplacements(scriptTemplateContents);
return replacements;
}
private String performScriptTemplateReplacements(String scriptTemplateContents) {
String replacements = scriptTemplateContents;
String fileDirectory = TestFileController.getUploadPath(vreq);
replacements = replacements.replace("${UPLOADS_FOLDER}", fileDirectory);
/*
* What needs to be replaced?
*
* task directory name
*/
//todo: complete
return replacements;
}
private String readScriptTemplate(File scriptTemplate) {
String scriptTemplateContents = null;
BufferedReader reader = null;
try {
int fileSize = (int)(scriptTemplate.length());
char[] buffer = new char[fileSize];
reader = new BufferedReader(new FileReader(scriptTemplate), fileSize);
reader.read(buffer);
scriptTemplateContents = new String(buffer);
} catch (IOException e) {
log.error(e, e);
} finally {
try {
if(reader != null)
reader.close();
} catch(IOException e) {
log.error(e, e);
}
}
return scriptTemplateContents;
}
@Override
public String getAdditionsFilePath() {
return TestFileController.getHarvesterPath() + TestFileController.PATH_TO_ADDITIONS_FILE;
}
@Override
public String getPageHeader() {
return "Harvest " + this.friendlyName + " data from CSV file(s)";
}
@Override
public String getTemplateFilePath() {
return this.templateFile.getPath();
}
}

View file

@ -19,22 +19,28 @@ interface FileHarvestJob {
*/ */
String validateUpload(File file); String validateUpload(File file);
/**
* Gets the path on the server of the file which the user can download to serve as a guide for what to upload.
* @return the path on the server of the file which the user can download to serve as a guide for what to upload.
*/
String getTemplateFilePath();
/** /**
* Gets the console script which can be used to run the harvest job. * Gets the console script which can be used to run the harvest job.
* @return the console script which can be used to run the harvest job * @return the console script which can be used to run the harvest job
*/ */
String getScript(); String getScript();
/**
* Runs a harvest on the files in the specified directory.
* @param directory the directory containing files to harvest
*/
void performHarvest(File directory);
/** /**
* The path to the file containing the RDF/XML triples that get added to VIVO. * The path to the file containing the RDF/XML triples that get added to VIVO.
* @return the path to the file containing the RDF/XML triples that get added to VIVO * @return the path to the file containing the RDF/XML triples that get added to VIVO
*/ */
String getAdditionsFilePath(); String getAdditionsFilePath();
/**
* A heading to be shown at the top of the page.
* @return a heading to be shown at the top of the page
*/
String getPageHeader();
} }

View file

@ -3,18 +3,22 @@
package edu.cornell.mannlib.vitro.webapp.controller.harvester; package edu.cornell.mannlib.vitro.webapp.controller.harvester;
import java.io.BufferedReader; import java.io.BufferedReader;
import java.io.DataInputStream;
import java.io.File; import java.io.File;
import java.io.FileInputStream;
import java.io.FileReader; import java.io.FileReader;
import java.io.FileWriter; import java.io.FileWriter;
import java.io.IOException; import java.io.IOException;
import java.io.InputStreamReader; import java.io.InputStreamReader;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.Arrays;
import java.util.HashMap; import java.util.HashMap;
import java.util.Hashtable; import java.util.Hashtable;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
import javax.servlet.ServletContext; import javax.servlet.ServletContext;
import javax.servlet.ServletException; import javax.servlet.ServletException;
import javax.servlet.ServletOutputStream;
import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpServletResponse;
import javax.xml.parsers.DocumentBuilderFactory; import javax.xml.parsers.DocumentBuilderFactory;
@ -48,16 +52,72 @@ public class TestFileController extends FreemarkerHttpServlet {
private static final String PARAMETER_FIRST_UPLOAD = "firstUpload"; private static final String PARAMETER_FIRST_UPLOAD = "firstUpload";
private static final String PARAMETER_UPLOADED_FILE = "uploadedFile"; private static final String PARAMETER_UPLOADED_FILE = "uploadedFile";
private static final String PARAMETER_IS_HARVEST_CLICK = "isHarvestClick"; private static final String PARAMETER_MODE = "mode";
private static final String PARAMETER_JOB = "job";
private static final String POST_TO = "/vivo/harvester/harvest";
private static final String JOB_CSV_GRANT = "csvGrant";
private static final String JOB_CSV_PERSON = "csvPerson";
private static final String MODE_HARVEST = "harvest";
private static final String MODE_CHECK_STATUS = "checkStatus";
private static final String MODE_DOWNLOAD_TEMPLATE = "template";
private static final List<String> knownJobs = Arrays.asList(JOB_CSV_GRANT.toLowerCase(), JOB_CSV_PERSON.toLowerCase());
/**
* Relative path from the VIVO Uploads directory to the root location where user-uploaded files will be stored. Include
* final slash.
*/
private static final String PATH_TO_UPLOADS = "harvester/";
/**
* Absolute path on the server of the Harvester root directory. Include final slash.
*/
private static final String PATH_TO_HARVESTER = "/home/mbarbieri/workspace/HarvesterDev/";
/**
* Relative path from the Harvester root directory to the Additions file containing rdf/xml added to VIVO from Harvest run.
*/
public static final String PATH_TO_ADDITIONS_FILE = "harvested-data/csv/additions.rdf.xml"; //todo: this is job-specific
/**
* Relative path from the Harvester root directory to the directory where user-downloadable template files are stored.
*/
public static final String PATH_TO_TEMPLATE_FILES = "files/";
/**
* Relative path from the Harvester root directory to the directory containing the script templates. Include final slash.
*/
public static final String PATH_TO_HARVESTER_SCRIPTS = "scripts/";
@Override @Override
protected ResponseValues processRequest(VitroRequest vreq) { protected ResponseValues processRequest(VitroRequest vreq) {
try { try {
String job = vreq.getParameter(PARAMETER_JOB);
String jobKnown = "false";
if((job != null) && TestFileController.knownJobs.contains(job.toLowerCase()))
jobKnown = "true";
Map<String, Object> body = new HashMap<String, Object>(); Map<String, Object> body = new HashMap<String, Object>();
//body.put("uploadPostback", "false"); //body.put("uploadPostback", "false");
body.put("paramFirstUpload", PARAMETER_FIRST_UPLOAD); body.put("paramFirstUpload", PARAMETER_FIRST_UPLOAD);
body.put("paramUploadedFile", PARAMETER_UPLOADED_FILE); body.put("paramUploadedFile", PARAMETER_UPLOADED_FILE);
body.put("paramIsHarvestClick", PARAMETER_IS_HARVEST_CLICK); body.put("paramMode", PARAMETER_MODE);
body.put("paramJob", PARAMETER_JOB);
body.put("modeHarvest", MODE_HARVEST);
body.put("modeCheckStatus", MODE_CHECK_STATUS);
body.put("modeDownloadTemplate", MODE_DOWNLOAD_TEMPLATE);
body.put("job", job);
body.put("jobKnown", jobKnown);
body.put("postTo", POST_TO + "?" + PARAMETER_JOB + "=" + job);
body.put("jobSpecificHeader", getJob(vreq, job).getPageHeader());
return new TemplateResponseValues(TEMPLATE_DEFAULT, body); return new TemplateResponseValues(TEMPLATE_DEFAULT, body);
} catch (Throwable e) { } catch (Throwable e) {
log.error(e, e); log.error(e, e);
@ -76,8 +136,7 @@ public class TestFileController extends FreemarkerHttpServlet {
*/ */
public static String getHarvesterPath() public static String getHarvesterPath()
{ {
//String harvesterPath = "/usr/share/vivo/harvester/"; //todo: hack String harvesterPath = PATH_TO_HARVESTER;
String harvesterPath = "/home/mbarbieri/workspace/HarvesterDevTomcat2/";
return harvesterPath; return harvesterPath;
} }
@ -94,7 +153,7 @@ public class TestFileController extends FreemarkerHttpServlet {
throw new Exception("Vitro home directory name could not be found."); throw new Exception("Vitro home directory name could not be found.");
} }
String pathBase = vitroHomeDirectoryName + "/" + FileStorageSetup.FILE_STORAGE_SUBDIRECTORY + "/harvester/"; String pathBase = vitroHomeDirectoryName + "/" + FileStorageSetup.FILE_STORAGE_SUBDIRECTORY + "/" + PATH_TO_UPLOADS;
return pathBase; return pathBase;
} }
@ -102,14 +161,27 @@ public class TestFileController extends FreemarkerHttpServlet {
* Gets the FileHarvestJob implementation that is needed to handle the specified request. This * Gets the FileHarvestJob implementation that is needed to handle the specified request. This
* will depend on the type of harvest being performed (CSV, RefWorks, etc.) * will depend on the type of harvest being performed (CSV, RefWorks, etc.)
* @param vreq the request from the browser * @param vreq the request from the browser
* @param jobParameter the POST or GET parameter "job". Might not be available in vreq at this point,
* thus we are requiring that it be sent in.
* @return the FileHarvestJob that will provide harvest-type-specific services for this request * @return the FileHarvestJob that will provide harvest-type-specific services for this request
*/ */
private FileHarvestJob getJob(VitroRequest vreq) private FileHarvestJob getJob(VitroRequest vreq, String jobParameter)
{ {
String namespace = vreq.getWebappDaoFactory().getDefaultNamespace(); String namespace = vreq.getWebappDaoFactory().getDefaultNamespace();
FileHarvestJob job = null;
//todo: complete //todo: complete
return new CsvHarvestJob(vreq, "granttemplate.csv", namespace); if(jobParameter == null)
log.error("No job specified.");
else if(jobParameter.equalsIgnoreCase(JOB_CSV_GRANT))
job = new CsvFileHarvestJob(vreq, "granttemplate.csv", "testCSVtoRDFgrant.sh", namespace, "Grant");
else if(jobParameter.equalsIgnoreCase(JOB_CSV_PERSON))
job = new CsvFileHarvestJob(vreq, "persontemplate.csv", "testCSVtoRDFperson.sh", namespace, "Person");
else
log.error("Invalid job: " + jobParameter);
return job;
} }
/** /**
@ -137,12 +209,17 @@ public class TestFileController extends FreemarkerHttpServlet {
try { try {
boolean isMultipart = ServletFileUpload.isMultipartContent(request); boolean isMultipart = ServletFileUpload.isMultipartContent(request);
String mode = request.getParameter(PARAMETER_MODE);
if(isMultipart) if(isMultipart)
doFileUploadPost(request, response); doFileUploadPost(request, response);
else if(request.getParameter(PARAMETER_IS_HARVEST_CLICK).toLowerCase().equals("true")) else if(mode.equals(MODE_HARVEST))
doHarvestPost(request, response); doHarvestPost(request, response);
else else if(mode.equals(MODE_CHECK_STATUS))
doCheckHarvestStatusPost(request, response); doCheckHarvestStatusPost(request, response);
else if(mode.equals(MODE_DOWNLOAD_TEMPLATE))
doDownloadTemplatePost(request, response);
else
throw new Exception("Unrecognized post mode: " + mode);
} catch(Exception e) { } catch(Exception e) {
log.error(e, e); log.error(e, e);
} }
@ -173,6 +250,9 @@ public class TestFileController extends FreemarkerHttpServlet {
new ExceptionVisibleToUser(e); new ExceptionVisibleToUser(e);
} }
//get the job parameter
String jobParameter = req.getParameter(PARAMETER_JOB);
//get the location where we want to save the files (it will end in a slash), then create a File object out of it //get the location where we want to save the files (it will end in a slash), then create a File object out of it
String path = getUploadPath(vreq); String path = getUploadPath(vreq);
File directory = new File(path); File directory = new File(path);
@ -197,7 +277,7 @@ public class TestFileController extends FreemarkerHttpServlet {
directory.mkdirs(); directory.mkdirs();
//get the file harvest job for this request (this will determine what type of harvest is run) //get the file harvest job for this request (this will determine what type of harvest is run)
FileHarvestJob job = getJob(vreq); FileHarvestJob job = getJob(vreq, jobParameter);
//get the files out of the parsed request (there should only be one) //get the files out of the parsed request (there should only be one)
Map<String, List<FileItem>> fileStreams = req.getFiles(); Map<String, List<FileItem>> fileStreams = req.getFiles();
@ -285,7 +365,7 @@ public class TestFileController extends FreemarkerHttpServlet {
log.error("harvest post."); log.error("harvest post.");
try { try {
VitroRequest vreq = new VitroRequest(request); VitroRequest vreq = new VitroRequest(request);
FileHarvestJob job = getJob(vreq); FileHarvestJob job = getJob(vreq, vreq.getParameter(PARAMETER_JOB));
//String path = getUploadPath(vreq); //String path = getUploadPath(vreq);
@ -366,6 +446,32 @@ public class TestFileController extends FreemarkerHttpServlet {
} }
} }
private void doDownloadTemplatePost(HttpServletRequest request, HttpServletResponse response) {
VitroRequest vreq = new VitroRequest(request);
FileHarvestJob job = getJob(vreq, vreq.getParameter(PARAMETER_JOB));
File fileToSend = new File(job.getTemplateFilePath());
response.setContentType("application/octet-stream");
response.setContentLength((int)(fileToSend.length()));
response.setHeader("Content-Disposition", "attachment; filename=\"" + fileToSend.getName() + "\"");
try {
byte[] byteBuffer = new byte[(int)(fileToSend.length())];
DataInputStream inStream = new DataInputStream(new FileInputStream(fileToSend));
ServletOutputStream outputStream = response.getOutputStream();
for(int length = inStream.read(byteBuffer); length != -1; length = inStream.read(byteBuffer)) {
outputStream.write(byteBuffer, 0, length);
}
inStream.close();
outputStream.flush();
outputStream.close();
} catch(IOException e) {
log.error(e, e);
}
}
private File createScriptFile(String script) throws IOException { private File createScriptFile(String script) throws IOException {
@ -590,198 +696,3 @@ public class TestFileController extends FreemarkerHttpServlet {
} }
/**
* An implementation of FileHarvestJob that can be used for any CSV file harvest.
*/
class CsvHarvestJob implements FileHarvestJob {
/**
* Logger.
*/
private static final Log log = LogFactory.getLog(CsvHarvestJob.class);
/**
* The HTTP request.
*/
private VitroRequest vreq;
/**
* The template file against which uploaded CSV files will be validated.
*/
private File templateFile;
/**
* The namespace to be used for the harvest.
*/
private final String namespace;
/**
* Constructor.
* @param templateFileName just the name of the template file. The directory is assumed to be standard.
*/
public CsvHarvestJob(VitroRequest vreq, String templateFileName, String namespace) {
this.vreq = vreq;
this.templateFile = new File(getTemplateFileDirectory() + templateFileName);
log.error(getTemplateFileDirectory() + templateFileName);
this.namespace = namespace;
}
/**
* Gets the path to the directory containing the template files.
* @return the path to the directory containing the template files
*/
private String getTemplateFileDirectory() {
String harvesterPath = TestFileController.getHarvesterPath();
String pathToTemplateFiles = harvesterPath + "files/";
return pathToTemplateFiles;
}
@Override
@SuppressWarnings("rawtypes")
public String validateUpload(File file) {
try {
SimpleReader reader = new SimpleReader();
List templateCsv = reader.parse(this.templateFile);
String[] templateFirstLine = (String[])templateCsv.get(0);
List csv = reader.parse(file);
int length = csv.size();
if(length == 0)
return "No data in file";
for(int i = 0; i < length; i++) {
String[] line = (String[])csv.get(i);
if(i == 0) {
String errorMessage = validateCsvFirstLine(templateFirstLine, line);
if(errorMessage != null)
return errorMessage;
}
else if(line.length != 0) {
if(line.length != templateFirstLine.length) {
String retval = "Mismatch in number of entries in row " + i + ": expected , " + templateFirstLine.length + ", found " + line.length + " ";
for(int j = 0; j < line.length; j++) {
retval += "\"" + line[j] + "\", ";
}
//return retval;
return "Mismatch in number of entries in row " + i + ": expected , " + templateFirstLine.length + ", found " + line.length;
}
}
}
} catch (IOException e) {
log.error(e, e);
return e.getMessage();
}
return null;
}
/**
* Makes sure that the first line of the CSV file is identical to the first line of the template file. This is
* assuming we are expecting all user CSV files to contain an initial header line. If this is not the case, then
* this method is unnecessary.
* @param templateFirstLine the parsed-out contents of the first line of the template file
* @param line the parsed-out contents of the first line of the input file
* @return an error message if the two lines don't match, or null if they do
*/
private String validateCsvFirstLine(String[] templateFirstLine, String[] line) {
String errorMessage = "File header does not match template";
if(line.length != templateFirstLine.length) {
//return errorMessage + ": " + "file header columns = " + line.length + ", template columns = " + templateFirstLine.length;
String errorMsg = "";
errorMsg += "file header items: ";
for(int i = 0; i < line.length; i++) {
errorMsg += line[i] + ", ";
}
errorMsg += "template items: ";
for(int i = 0; i < templateFirstLine.length; i++) {
errorMsg += templateFirstLine[i] + ", ";
}
return errorMsg;
}
for(int i = 0; i < line.length; i++)
{
if(!line[i].equals(templateFirstLine[i]))
return errorMessage + ": file header column " + (i + 1) + " = " + line[i] + ", template column " + (i + 1) + " = " + templateFirstLine[i];
}
return null;
}
@Override
public String getScript()
{
String path = TestFileController.getHarvesterPath() + "scripts/" + "testCSVtoRDFgrant.sh"; //todo: complete
File scriptTemplate = new File(path);
String scriptTemplateContents = readScriptTemplate(scriptTemplate);
String replacements = performScriptTemplateReplacements(scriptTemplateContents);
return replacements;
}
private String performScriptTemplateReplacements(String scriptTemplateContents) {
String replacements = scriptTemplateContents;
String fileDirectory = TestFileController.getUploadPath(vreq);
replacements = replacements.replace("${UPLOADS_FOLDER}", fileDirectory);
/*
* What needs to be replaced?
*
* task directory name
*/
//todo: complete
return replacements;
}
private String readScriptTemplate(File scriptTemplate) {
String scriptTemplateContents = null;
BufferedReader reader = null;
try {
int fileSize = (int)(scriptTemplate.length());
char[] buffer = new char[fileSize];
reader = new BufferedReader(new FileReader(scriptTemplate), fileSize);
reader.read(buffer);
scriptTemplateContents = new String(buffer);
} catch (IOException e) {
log.error(e, e);
} finally {
try {
if(reader != null)
reader.close();
} catch(IOException e) {
log.error(e, e);
}
}
return scriptTemplateContents;
}
@Override
public void performHarvest(File directory) {
}
@Override
public String getAdditionsFilePath() {
return TestFileController.getHarvesterPath() + "harvested-data/csv/additions.rdf.xml";
}
}

View file

@ -97,6 +97,11 @@ input.block {
label { label {
margin-top: .5em; margin-top: .5em;
} }
label.inline {
display: inline;
font-weight: normal;
font-size: .9em;
}
.verbose-toggle, .verbose-toggle,
.verbose-toggle:visited, .verbose-toggle:visited,
#showAddFormButton, #showAddFormButton,
@ -365,15 +370,19 @@ form select {
border: 1px dotted #FFD324; border: 1px dotted #FFD324;
} }
a.ingestMenu:link, a.ingestMenu:link,
a.ingestMenu:visited { a.ingestMenu:visited,
text-decoration: none; a.account-menu:link,
color: #5E6363; a.account-menu:visited {
}
a.ingestMenu:hover,
a.ingestMenu:active {
text-decoration: none; text-decoration: none;
color: #2485AE; color: #2485AE;
} }
a.ingestMenu:hover,
a.ingestMenu:active,
a.account-menu:hover,
a.account-menu:active {
text-decoration: none;
color: #5E6363;
}
/* -------------------------------------------------> */ /* -------------------------------------------------> */
/* HOMEPAGE AND INTERIOR PAGES STYLES --------------> */ /* HOMEPAGE AND INTERIOR PAGES STYLES --------------> */
@ -411,8 +420,8 @@ ul#header-nav {
ul#header-nav li { ul#header-nav li {
float: left; float: left;
display: block; display: block;
padding-left: 20px; padding-left: 10px;
padding-right: 20px; padding-right: 10px;
border-right: 1px solid #7c7d7f; border-right: 1px solid #7c7d7f;
font-size: .7em; font-size: .7em;
color: #fff; color: #fff;
@ -421,7 +430,7 @@ ul#header-nav li.last {
border-right: none; border-right: none;
} }
ul#header-nav li:last-child { ul#header-nav li:last-child {
padding-left: 10px; padding-left: 1px;
padding-right: 0; padding-right: 0;
border-right: none; border-right: none;
} }
@ -433,10 +442,13 @@ ul#header-nav a:visited {
text-decoration: none text-decoration: none
} }
ul#header-nav a:hover, ul#header-nav a:hover,
ul#header-nav a:active { ul#header-nav a:active {
text-decoration: none; text-decoration: none;
color: #999; color: #999;
} }
ul#header-nav a.log-out {
padding-left: 10px;
}
/* SEARCH ------> */ /* SEARCH ------> */
#search { #search {
position: absolute; position: absolute;
@ -680,6 +692,21 @@ p.password-note {
margin-right:-10px; margin-right:-10px;
height:34px; height:34px;
} }
p.external-auth {
margin: 0 auto;
}
p.external-auth a.blue,
p.external-auth a.blue:visited {
background-color: #398AAC;
width: 180px;
margin-bottom: 17px;
line-height: 1.3em;
padding-top: 10px;
}
p.external-auth a.blue:hover {
background-color: #58A2C1;
color: #fff;
}
/* HOME SEARCH ------> */ /* HOME SEARCH ------> */
#search-home { #search-home {
float: left; float: left;
@ -1044,10 +1071,7 @@ ul#browse-classes .count-classes {
} }
/* ALPHA BROWSE------> */ /* ALPHA BROWSE------> */
ul#alpha-browse-individuals { ul#alpha-browse-individuals {
border: 1px solid #dde4e3;
background-color: #fff; background-color: #fff;
border-left: 1px solid #dde4e3;
border-bottom: none;
} }
ul#alpha-browse-individuals li { ul#alpha-browse-individuals li {
font-size: .8em; font-size: .8em;
@ -1072,6 +1096,16 @@ ul#alpha-browse-individuals .count-classes {
.alphaIndex { .alphaIndex {
font-size: .8em; font-size: .8em;
} }
nav#alpha-browse-container {
border: 1px solid #dde4e3;
background-color: #fff;
border-left: 1px solid #dde4e3;
border-bottom: none;
width: 619px;
float: left;
padding-left: 10px;
margin-left: 1px;
}
/* BROWSE INDIVIDUALS------> */ /* BROWSE INDIVIDUALS------> */
#individuals-in-class { #individuals-in-class {
width: 629px; width: 629px;
@ -1467,7 +1501,7 @@ h2#hasResearchArea .verbosePropertyListing {
display: block; display: block;
} }
/* -------------------------------------------------> */ /* -------------------------------------------------> */
/* ACCOUNTS PAGE -----------------------------------> */ /* ACCOUNT PAGE ------------------------------------> */
/* -------------------------------------------------> */ /* -------------------------------------------------> */
.account-feedback p { .account-feedback p {
line-height: 1.5em; line-height: 1.5em;
@ -1514,7 +1548,7 @@ table#account tr:nth-child(2n+1) {
} }
.accounts { .accounts {
clear: left; clear: left;
overflow: hidden; height: 60px;
border-top: 1px dotted #e1e5e7; border-top: 1px dotted #e1e5e7;
padding-top: 0; padding-top: 0;
border-bottom: 1px dotted #e1e5e7; border-bottom: 1px dotted #e1e5e7;
@ -1535,23 +1569,49 @@ section.accounts .delete-account{
.accounts-per-page-form { .accounts-per-page-form {
display: inline-block; display: inline-block;
} }
/* -------------------------------------------------> */ /* ADD ACCOUNTS ------> */
/* ADD ACCOUNTS -----------------------------------> */ form.customForm p {
/* -------------------------------------------------> */ margin-top: 8px;
#add-account p {
margin-top: 15px;
}
#reset-password {
background-color: green;
} }
form.customForm #reset-password { form.customForm #reset-password {
margin-top: 20px; margin-top: 20px;
margin-left: 0;
} }
#add-account .note { form.customForm p.note{
padding-bottom: 20px; padding-bottom: 20px;
padding-top: 0; padding-top: 0;
margin-top: 25px;
} }
#add-account p.note {
margin-top: 20px;
width: 400px;
}
#add-account input[type="text"],
#create-account input[type="text"],
#edit-account input[type="text"],
#my-account input[type="text"],
#my-account input[type="password"] {
width: 20em;
}
/* CREATE PASSWORD ------> */
#create-password p.note {
margin-top: 0;
}
/* EDIT ACCOUNT ------> */
#edit-account p.note {
margin-top: 3px;
width: 400px;
}
/* MY ACCOUNT ------> */
#my-account p.note {
padding-bottom: 10px;
width: 400px;
}
#my-account input#email-address,
#my-account input#new-password {
margin-bottom: 0;
}
/* RESET PASSWORD ------> */
/* -------------------------------------------------> */ /* -------------------------------------------------> */
/* DROP DOWN USER MENU ----------------------------> */ /* DROP DOWN USER MENU ----------------------------> */
/* -------------------------------------------------> */ /* -------------------------------------------------> */
@ -1582,7 +1642,6 @@ ul.dropdown li#user-menu:hover {
color: #000 !important; color: #000 !important;
position: relative; position: relative;
background: #fff url(../images/arrow-down-account.gif) right 9px no-repeat; background: #fff url(../images/arrow-down-account.gif) right 9px no-repeat;
padding-right: 10px;
border-bottom: 1px solid #cdcfcf; border-bottom: 1px solid #cdcfcf;
} }
ul.dropdown li.hover a, ul.dropdown li.hover a,

View file

@ -29,7 +29,7 @@
${scripts.add('<script type="text/javascript" src="${urls.base}/js/userMenu/userMenuUtils.js"></script>')} ${scripts.add('<script type="text/javascript" src="${urls.base}/js/userMenu/userMenuUtils.js"></script>')}
<#else> <#else>
<li role="listitem"><a title="log in to manage this site" href="${urls.login}">Log in</a></li> <li role="listitem"><a class="log-out" title="log in to manage this site" href="${urls.login}">Log in</a></li>
</#if> </#if>
</ul> </ul>