Skip to content
This repository has been archived by the owner on Apr 8, 2019. It is now read-only.

Commit

Permalink
GTNPORTAL-2988: Translation of navigation title doesn't work for lang…
Browse files Browse the repository at this point in the history
…uage with country variant

Problem analysis:
	- Locale in User Context does not support country part

Fix description:
	- Get right locale string by using locale service.
  • Loading branch information
TRAN Trung Thanh authored and trongtt committed May 28, 2013
1 parent 0dec969 commit a1daf0c
Showing 1 changed file with 2 additions and 1 deletion.
Expand Up @@ -59,6 +59,7 @@
import org.exoplatform.portal.webui.workspace.UIPortalApplication;
import org.exoplatform.services.log.ExoLogger;
import org.exoplatform.services.log.Log;
import org.exoplatform.services.resources.LocaleContextInfo;
import org.exoplatform.services.resources.Orientation;
import org.exoplatform.services.resources.ResourceBundleManager;
import org.exoplatform.web.ControllerContext;
Expand Down Expand Up @@ -593,7 +594,7 @@ public ResourceBundle getBundle(UserNavigation navigation) {
ResourceBundleManager rbMgr = (ResourceBundleManager) container
.getComponentInstanceOfType(ResourceBundleManager.class);
Locale locale = Util.getPortalRequestContext().getLocale();
return rbMgr.getNavigationResourceBundle(locale.getLanguage(), navigation.getKey().getTypeName(), navigation
return rbMgr.getNavigationResourceBundle(LocaleContextInfo.getLocaleAsString(locale), navigation.getKey().getTypeName(), navigation
.getKey().getName());
}

Expand Down

0 comments on commit a1daf0c

Please sign in to comment.