Refactor enabled languages from an array to a hash
Change-Id: I5173361818508849e5012a943a984af69d9d08cd Depends-On: I2d28d9019e8bcf9f6b8ef5698958932d44321679 Closes-Bug: #1668978
This commit is contained in:
parent
0d15f1de5a
commit
60db285fd5
@ -33,8 +33,17 @@
|
||||
#
|
||||
# [*enabled_languages*]
|
||||
# Which languages to show in the UI.
|
||||
# An array.
|
||||
# Defaults to ['en-GB', 'en', 'de', 'ja', 'ko-KR', 'zh-CN', 'es']
|
||||
# A hash.
|
||||
# Defaults to
|
||||
# {
|
||||
# 'de' => 'German',
|
||||
# 'en' => 'English',
|
||||
# 'en-GB' => 'British English',
|
||||
# 'es' => 'Spanish',
|
||||
# 'ja' => 'Japanese',
|
||||
# 'ko-KR' => 'Korean',
|
||||
# 'zh-CN' => 'Simplified Chinese'
|
||||
# }
|
||||
#
|
||||
# [*endpoint_proxy_keystone*]
|
||||
# The keystone proxy endpoint url
|
||||
@ -94,7 +103,15 @@ class tripleo::ui (
|
||||
$bind_host = hiera('controller_host'),
|
||||
$ui_port = 3000,
|
||||
$zaqar_default_queue = 'tripleo',
|
||||
$enabled_languages = ['en-GB', 'en', 'de', 'ja', 'ko-KR', 'zh-CN', 'es'],
|
||||
$enabled_languages = {
|
||||
'de' => 'German',
|
||||
'en' => 'English',
|
||||
'en-GB' => 'British English',
|
||||
'es' => 'Spanish',
|
||||
'ja' => 'Japanese',
|
||||
'ko-KR' => 'Korean',
|
||||
'zh-CN' => 'Simplified Chinese'
|
||||
},
|
||||
$endpoint_proxy_zaqar = undef,
|
||||
$endpoint_proxy_keystone = undef,
|
||||
$endpoint_proxy_heat = undef,
|
||||
|
@ -18,7 +18,7 @@ window.tripleOUiConfig = {
|
||||
// If you choose more than one language, a language switcher will appear in
|
||||
// the navigation bar.
|
||||
// Only 'en' (English) is enabled by default.
|
||||
'languages': ['<%= @enabled_languages.join("', '") %>'],
|
||||
'languages': <%= @enabled_languages.to_json %>,
|
||||
|
||||
// Logging
|
||||
// 'loggers': ['console']
|
||||
|
Loading…
x
Reference in New Issue
Block a user