VIVO-12 NIHVIVO-4011 Provide config and GUI for selecting Locale

This commit is contained in:
j2blake 2013-01-24 16:14:45 -05:00
parent 89f759fcbc
commit a3bd67097b
11 changed files with 230 additions and 7 deletions

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

@ -59,6 +59,9 @@ edu.cornell.mannlib.vitro.webapp.services.shortview.ShortViewServiceSetup
edu.ucsf.vitro.opensocial.OpenSocialSmokeTests
# For multiple language support
edu.cornell.mannlib.vitro.webapp.i18n.selection.LocaleSelectionSetup
# Add VIVO specific DocumentModifers, this must come before SolrSetup
edu.cornell.mannlib.vitro.webapp.search.solr.VivoDocumentModifiers

View file

@ -81,6 +81,16 @@
<url-pattern>/*</url-pattern>
</filter-mapping>
<filter>
<description>Override the Locale in the HttpRequest, if appropriate.</description>
<filter-name>Locale selection filter</filter-name>
<filter-class>edu.cornell.mannlib.vitro.webapp.i18n.selection.LocaleSelectionFilter</filter-class>
</filter>
<filter-mapping>
<filter-name>Locale selection filter</filter-name>
<url-pattern>/*</url-pattern>
</filter-mapping>
<filter>
<filter-name>JSession Strip Filter</filter-name>
<filter-class>edu.cornell.mannlib.vitro.webapp.filters.JSessionStripFilter</filter-class>
@ -1401,6 +1411,16 @@
<url-pattern>/orng/*</url-pattern>
</servlet-mapping>
<servlet>
<description>Multiple-language support. Allows user to select his preferred langauge</description>
<servlet-name>LocaleSelectionController</servlet-name>
<servlet-class>edu.cornell.mannlib.vitro.webapp.i18n.selection.LocaleSelectionController</servlet-class>
</servlet>
<servlet-mapping>
<servlet-name>LocaleSelectionController</servlet-name>
<url-pattern>/selectLocale</url-pattern>
</servlet-mapping>
<!-- ============================== servlet-mappings ======================== -->
<servlet-mapping>