Additional translations: Workaround for backend & date library #710
This commit is contained in:
parent
28880e682d
commit
cd38e507f9
2 changed files with 3 additions and 3 deletions
|
@ -80,7 +80,7 @@ Vue.prototype.$isMobile = isMobile;
|
|||
Vue.use(Vuetify, {"theme": config.theme});
|
||||
|
||||
Vue.config.language = config.values.settings.ui.language;
|
||||
Settings.defaultLocale = Vue.config.language;
|
||||
Settings.defaultLocale = Vue.config.language.substring(0, 2);
|
||||
|
||||
// Register other VueJS plugins
|
||||
Vue.use(GetTextPlugin, {
|
||||
|
|
|
@ -29,10 +29,10 @@ func SetDir(dir string) {
|
|||
}
|
||||
|
||||
func SetLocale(loc string) {
|
||||
if len(loc) != 2 {
|
||||
if len(loc) < 2 {
|
||||
locale = Default
|
||||
} else {
|
||||
loc = strings.ToLower(loc)
|
||||
loc = strings.ToLower(loc[:2])
|
||||
locale = Locale(loc)
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue