dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #25595
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 12744: Translation minor changes - set to display no fallback data on translation entry page/settingAppe...
------------------------------------------------------------
revno: 12744
committer: James Chang <jamesbchang@xxxxxxxxx>
branch nick: dhis2
timestamp: Thu 2013-10-17 00:46:06 +0700
message:
Translation minor changes - set to display no fallback data on translation entry page/settingAppearance page. Also, blank to delete the translation.
removed:
dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/settings/systemAppearanceSettingsString.vm
dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/settings/system/
dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/settings/system/action/
dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/settings/system/action/GetAppearanceSettingsStringAction.java
added:
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-settings/src/main/java/org/hisp/dhis/settings/action/system/GetAppearanceSettingsStringAction.java
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-settings/src/main/webapp/dhis-web-maintenance-settings/systemAppearanceSettingsString.vm
modified:
dhis-2/dhis-api/src/main/java/org/hisp/dhis/setting/TranslateSystemSettingManager.java
dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/i18n/DefaultI18nService.java
dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/i18n/I18nService.java
dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/setting/DefaultTranslateSystemSettingManager.java
dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/i18n/action/GetTranslationsAction.java
dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/i18n/action/I18nAction.java
dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/i18n/action/TranslateAction.java
dhis-2/dhis-web/dhis-web-commons/src/main/resources/META-INF/dhis/beans.xml
dhis-2/dhis-web/dhis-web-commons/src/main/resources/dhis-web-commons.xml
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-settings/src/main/resources/META-INF/dhis/beans.xml
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-settings/src/main/resources/struts.xml
dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-settings/src/main/webapp/dhis-web-maintenance-settings/javascripts/systemAppearanceSettings.js
--
lp:dhis2
https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk
Your team DHIS 2 developers is subscribed to branch lp:dhis2.
To unsubscribe from this branch go to https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk/+edit-subscription
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/setting/TranslateSystemSettingManager.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/setting/TranslateSystemSettingManager.java 2013-10-10 12:00:38 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/setting/TranslateSystemSettingManager.java 2013-10-16 17:46:06 +0000
@@ -37,4 +37,6 @@
public interface TranslateSystemSettingManager
{
Map<String, String> getTranslation_SystemAppearanceSetting( String localeStr );
+
+ Map<String, String> getTranslationNoFallback_SystemAppearanceSetting( String localeStr );
}
=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/i18n/DefaultI18nService.java'
--- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/i18n/DefaultI18nService.java 2013-10-08 17:16:47 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/i18n/DefaultI18nService.java 2013-10-16 17:46:06 +0000
@@ -221,7 +221,7 @@
Translation translation = translationService.getTranslation( className, id, locale, key );
if ( value != null && !value.trim().isEmpty() )
- {
+ {
if ( translation != null )
{
translation.setValue( value );
@@ -256,6 +256,21 @@
return new HashMap<String, String>();
}
+ public Map<String, String> getTranslationsNoFallback( String className, int id )
+ {
+ return getTranslationsNoFallback( className, id, getCurrentLocale() );
+ }
+
+ public Map<String, String> getTranslationsNoFallback( String className, int id, Locale locale )
+ {
+ if ( locale != null && className != null )
+ {
+ return convertTranslations( translationService.getTranslationsNoFallback( className, id, locale ) );
+ }
+
+ return new HashMap<String, String>();
+ }
+
// -------------------------------------------------------------------------
// Locale
// -------------------------------------------------------------------------
=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/i18n/I18nService.java'
--- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/i18n/I18nService.java 2013-10-01 16:44:42 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/i18n/I18nService.java 2013-10-16 17:46:06 +0000
@@ -64,11 +64,15 @@
// -------------------------------------------------------------------------
void updateTranslation( String className, int id, Locale thisLocale, Map<String, String> translations );
-
+
Map<String, String> getTranslations( String className, int id );
Map<String, String> getTranslations( String className, int id, Locale locale );
+ Map<String, String> getTranslationsNoFallback( String className, int id );
+
+ Map<String, String> getTranslationsNoFallback( String className, int id, Locale locale );
+
// -------------------------------------------------------------------------
// Locale
// -------------------------------------------------------------------------
=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/setting/DefaultTranslateSystemSettingManager.java'
--- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/setting/DefaultTranslateSystemSettingManager.java 2013-10-10 12:00:38 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/setting/DefaultTranslateSystemSettingManager.java 2013-10-16 17:46:06 +0000
@@ -74,6 +74,20 @@
return translations;
}
+ @Override
+ public Map<String, String> getTranslationNoFallback_SystemAppearanceSetting( String localeStr )
+ {
+ Map<String, String> translations = new Hashtable<String, String>();
+
+ // Add the key application data (with localeCode name) into translations map object
+ translations.put( KEY_APPLICATION_TITLE, systemSettingManager.getSystemSetting( KEY_APPLICATION_TITLE + localeStr, DEFAULT_APPLICATION_TITLE ).toString() );
+ translations.put( KEY_APPLICATION_INTRO, systemSettingManager.getSystemSetting( KEY_APPLICATION_INTRO + localeStr, "" ).toString() );
+ translations.put( KEY_APPLICATION_NOTIFICATION, systemSettingManager.getSystemSetting( KEY_APPLICATION_NOTIFICATION + localeStr, "" ).toString() );
+ translations.put( KEY_APPLICATION_FOOTER, systemSettingManager.getSystemSetting( KEY_APPLICATION_FOOTER + localeStr, "" ).toString() );
+
+ return translations;
+ }
+
// -------------------------------------------------------------------------
// Support Method implementation
// -------------------------------------------------------------------------
=== removed file 'dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/settings/systemAppearanceSettingsString.vm'
--- dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/settings/systemAppearanceSettingsString.vm 2013-10-10 15:49:20 +0000
+++ dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/settings/systemAppearanceSettingsString.vm 1970-01-01 00:00:00 +0000
@@ -1,6 +0,0 @@
-{
-"applicationTitle": "$!encoder.jsonEncode( $!translations.get( "applicationTitle" ) )",
-"keyApplicationIntro": "$!encoder.jsonEncode( $translations.get( "keyApplicationIntro" ) )",
-"keyApplicationNotification": "$!encoder.jsonEncode( $translations.get( "keyApplicationNotification" ) )",
-"keyApplicationFooter": "$!encoder.jsonEncode( $translations.get( "keyApplicationFooter" ) )"
-}
=== modified file 'dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/i18n/action/GetTranslationsAction.java'
--- dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/i18n/action/GetTranslationsAction.java 2013-10-01 16:44:42 +0000
+++ dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/i18n/action/GetTranslationsAction.java 2013-10-16 17:46:06 +0000
@@ -94,7 +94,7 @@
{
Locale locale = LocaleUtils.getLocale( loc );
- translations = i18nService.getTranslations( className, id, locale );
+ translations = i18nService.getTranslationsNoFallback( className, id, locale );
return SUCCESS;
}
=== modified file 'dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/i18n/action/I18nAction.java'
--- dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/i18n/action/I18nAction.java 2013-10-01 16:44:42 +0000
+++ dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/i18n/action/I18nAction.java 2013-10-16 17:46:06 +0000
@@ -169,7 +169,7 @@
availableLocales = i18nService.getAvailableLocales();
- translations = i18nService.getTranslations( className, objectId );
+ translations = i18nService.getTranslationsNoFallback( className, objectId );
IdentifiableObject object = identifiableObjectManager.getObject( objectId, className );
=== modified file 'dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/i18n/action/TranslateAction.java'
--- dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/i18n/action/TranslateAction.java 2013-10-01 16:44:42 +0000
+++ dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/i18n/action/TranslateAction.java 2013-10-16 17:46:06 +0000
@@ -157,8 +157,8 @@
for ( String propertyName : propertyNames )
{
String[] translation = request.getParameterValues( propertyName );
-
- if ( translation != null && translation.length > 0 && translation[0] != null && !translation[0].trim().isEmpty() )
+
+ if ( translation != null && translation.length > 0 )
{
translations.put( propertyName, translation[0] );
}
=== removed directory 'dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/settings/system'
=== removed directory 'dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/settings/system/action'
=== removed file 'dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/settings/system/action/GetAppearanceSettingsStringAction.java'
--- dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/settings/system/action/GetAppearanceSettingsStringAction.java 2013-10-10 12:00:38 +0000
+++ dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/settings/system/action/GetAppearanceSettingsStringAction.java 1970-01-01 00:00:00 +0000
@@ -1,87 +0,0 @@
-package org.hisp.dhis.settings.system.action;
-
-/*
- * Copyright (c) 2004-2013, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- *
- * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import java.util.Hashtable;
-import java.util.Map;
-
-import org.hisp.dhis.setting.TranslateSystemSettingManager;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author James Chang
- */
-public class GetAppearanceSettingsStringAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private TranslateSystemSettingManager translateSystemSettingManager;
-
- public void setTranslateSystemSettingManager( TranslateSystemSettingManager translateSystemSettingManager )
- {
- this.translateSystemSettingManager = translateSystemSettingManager;
- }
-
- // -------------------------------------------------------------------------
- // Input
- // -------------------------------------------------------------------------
-
- private String localeCode;
-
- public void setLocaleCode( String localeCode )
- {
- this.localeCode = localeCode;
- }
-
- // -------------------------------------------------------------------------
- // Output
- // -------------------------------------------------------------------------
-
- private Map<String, String> translations = new Hashtable<String, String>();
-
- public Map<String, String> getTranslations()
- {
- return translations;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- {
- translations = translateSystemSettingManager.getTranslation_SystemAppearanceSetting( localeCode );
-
- return SUCCESS;
- }
-}
=== modified file 'dhis-2/dhis-web/dhis-web-commons/src/main/resources/META-INF/dhis/beans.xml'
--- dhis-2/dhis-web/dhis-web-commons/src/main/resources/META-INF/dhis/beans.xml 2013-10-10 12:00:38 +0000
+++ dhis-2/dhis-web/dhis-web-commons/src/main/resources/META-INF/dhis/beans.xml 2013-10-16 17:46:06 +0000
@@ -595,14 +595,6 @@
<property name="styleManager" ref="org.hisp.dhis.setting.StyleManager" />
</bean>
- <!-- System settings -->
-
- <bean id="org.hisp.dhis.settings.system.action.GetAppearanceSettingsStringAction"
- class="org.hisp.dhis.settings.system.action.GetAppearanceSettingsStringAction"
- scope="prototype">
- <property name="translateSystemSettingManager" ref="org.hisp.dhis.setting.TranslateSystemSettingManager" />
- </bean>
-
<!-- Others -->
<bean id="org.hisp.dhis.commons.action.GetPingAction" class="org.hisp.dhis.commons.action.GetPingAction">
=== modified file 'dhis-2/dhis-web/dhis-web-commons/src/main/resources/dhis-web-commons.xml'
--- dhis-2/dhis-web/dhis-web-commons/src/main/resources/dhis-web-commons.xml 2013-10-10 12:00:38 +0000
+++ dhis-2/dhis-web/dhis-web-commons/src/main/resources/dhis-web-commons.xml 2013-10-16 17:46:06 +0000
@@ -467,11 +467,6 @@
</result>
<param name="onExceptionReturn">plainTextError</param>
</action>
-
- <action name="systemAppearanceSettingsString" class="org.hisp.dhis.settings.system.action.GetAppearanceSettingsStringAction">
- <result name="success" type="velocity-json">/dhis-web-commons/settings/systemAppearanceSettingsString.vm</result>
- </action>
-
</package>
=== added file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-settings/src/main/java/org/hisp/dhis/settings/action/system/GetAppearanceSettingsStringAction.java'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-settings/src/main/java/org/hisp/dhis/settings/action/system/GetAppearanceSettingsStringAction.java 1970-01-01 00:00:00 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-settings/src/main/java/org/hisp/dhis/settings/action/system/GetAppearanceSettingsStringAction.java 2013-10-16 17:46:06 +0000
@@ -0,0 +1,87 @@
+package org.hisp.dhis.settings.action.system;
+
+/*
+ * Copyright (c) 2004-2013, University of Oslo
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ * Redistributions of source code must retain the above copyright notice, this
+ * list of conditions and the following disclaimer.
+ *
+ * Redistributions in binary form must reproduce the above copyright notice,
+ * this list of conditions and the following disclaimer in the documentation
+ * and/or other materials provided with the distribution.
+ * Neither the name of the HISP project nor the names of its contributors may
+ * be used to endorse or promote products derived from this software without
+ * specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
+ * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
+ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+import java.util.Hashtable;
+import java.util.Map;
+
+import org.hisp.dhis.setting.TranslateSystemSettingManager;
+
+import com.opensymphony.xwork2.Action;
+
+/**
+ * @author James Chang
+ */
+public class GetAppearanceSettingsStringAction
+ implements Action
+{
+ // -------------------------------------------------------------------------
+ // Dependencies
+ // -------------------------------------------------------------------------
+
+ private TranslateSystemSettingManager translateSystemSettingManager;
+
+ public void setTranslateSystemSettingManager( TranslateSystemSettingManager translateSystemSettingManager )
+ {
+ this.translateSystemSettingManager = translateSystemSettingManager;
+ }
+
+ // -------------------------------------------------------------------------
+ // Input
+ // -------------------------------------------------------------------------
+
+ private String localeCode;
+
+ public void setLocaleCode( String localeCode )
+ {
+ this.localeCode = localeCode;
+ }
+
+ // -------------------------------------------------------------------------
+ // Output
+ // -------------------------------------------------------------------------
+
+ private Map<String, String> translations = new Hashtable<String, String>();
+
+ public Map<String, String> getTranslations()
+ {
+ return translations;
+ }
+
+ // -------------------------------------------------------------------------
+ // Action implementation
+ // -------------------------------------------------------------------------
+
+ public String execute()
+ {
+ translations = translateSystemSettingManager.getTranslationNoFallback_SystemAppearanceSetting( localeCode );
+
+ return SUCCESS;
+ }
+}
=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-settings/src/main/resources/META-INF/dhis/beans.xml'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-settings/src/main/resources/META-INF/dhis/beans.xml 2013-10-10 12:00:38 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-settings/src/main/resources/META-INF/dhis/beans.xml 2013-10-16 17:46:06 +0000
@@ -41,6 +41,12 @@
<property name="styleManager" ref="org.hisp.dhis.setting.StyleManager" />
</bean>
+ <bean id="org.hisp.dhis.settings.action.system.GetAppearanceSettingsStringAction"
+ class="org.hisp.dhis.settings.action.system.GetAppearanceSettingsStringAction"
+ scope="prototype">
+ <property name="translateSystemSettingManager" ref="org.hisp.dhis.setting.TranslateSystemSettingManager" />
+ </bean>
+
<bean id="org.hisp.dhis.settings.action.system.GetSMTPSettingsAction"
class="org.hisp.dhis.settings.action.system.GetSMTPSettingsAction"
scope="prototype">
=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-settings/src/main/resources/struts.xml'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-settings/src/main/resources/struts.xml 2013-10-10 12:00:38 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-settings/src/main/resources/struts.xml 2013-10-16 17:46:06 +0000
@@ -47,6 +47,10 @@
<param name="requiredAuthorities">F_SYSTEM_SETTING</param>
</action>
+ <action name="systemAppearanceSettingsString" class="org.hisp.dhis.settings.action.system.GetAppearanceSettingsStringAction">
+ <result name="success" type="velocity-json">/dhis-web-maintenance-settings/systemAppearanceSettingsString.vm</result>
+ </action>
+
<!-- Email settings -->
<action name="systemEmailSettings" class="org.hisp.dhis.settings.action.system.GetSMTPSettingsAction">
=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-settings/src/main/webapp/dhis-web-maintenance-settings/javascripts/systemAppearanceSettings.js'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-settings/src/main/webapp/dhis-web-maintenance-settings/javascripts/systemAppearanceSettings.js 2013-10-10 12:00:38 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-settings/src/main/webapp/dhis-web-maintenance-settings/javascripts/systemAppearanceSettings.js 2013-10-16 17:46:06 +0000
@@ -1,7 +1,7 @@
function changeLocale()
{
- $.get( '../dhis-web-commons-ajax/systemAppearanceSettingsString.action?localeCode=' + $( '#localeSelect' ).val(), function( json ) {
+ $.get( 'systemAppearanceSettingsString.action?localeCode=' + $( '#localeSelect' ).val(), function( json ) {
$( '#applicationTitle' ).val( json.applicationTitle );
$( '#applicationIntro' ).val( json.keyApplicationIntro );
$( '#applicationNotification' ).val( json.keyApplicationNotification );
=== added file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-settings/src/main/webapp/dhis-web-maintenance-settings/systemAppearanceSettingsString.vm'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-settings/src/main/webapp/dhis-web-maintenance-settings/systemAppearanceSettingsString.vm 1970-01-01 00:00:00 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-settings/src/main/webapp/dhis-web-maintenance-settings/systemAppearanceSettingsString.vm 2013-10-16 17:46:06 +0000
@@ -0,0 +1,6 @@
+{
+"applicationTitle": "$!encoder.jsonEncode( $!translations.get( "applicationTitle" ) )",
+"keyApplicationIntro": "$!encoder.jsonEncode( $translations.get( "keyApplicationIntro" ) )",
+"keyApplicationNotification": "$!encoder.jsonEncode( $translations.get( "keyApplicationNotification" ) )",
+"keyApplicationFooter": "$!encoder.jsonEncode( $translations.get( "keyApplicationFooter" ) )"
+}