use supported languages from service
This commit is contained in:
parent
59eb434840
commit
ef50c63dc7
7 changed files with 31 additions and 10 deletions
|
@ -83,6 +83,9 @@ const GeneralTab = {
|
|||
this.$store.dispatch('setOption', { name: 'interfaceLanguage', value: val })
|
||||
}
|
||||
},
|
||||
translationLanguages () {
|
||||
return (this.$store.getters.mergedConfig.supportedTranslationLanguages || []).map(lang => ({ key: lang.code, value: lang.code, label: lang.name }))
|
||||
},
|
||||
translationLanguage: {
|
||||
get: function () { return this.$store.getters.mergedConfig.translationLanguage },
|
||||
set: function (val) {
|
||||
|
|
|
@ -157,14 +157,14 @@
|
|||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<interface-language-switcher
|
||||
:globe-icon="false"
|
||||
:prompt-text="$t('settings.translation_language')"
|
||||
:language="translationLanguage"
|
||||
:set-language="setTranslationLanguage"
|
||||
/>
|
||||
</p>
|
||||
<ChoiceSetting
|
||||
v-if="user && (translationLanguages.length > 0)"
|
||||
id="translationLanguage"
|
||||
path="translationLanguage"
|
||||
:options="translationLanguages"
|
||||
>
|
||||
{{ $t('settings.translation_language') }}
|
||||
</ChoiceSetting>
|
||||
</li>
|
||||
<li>
|
||||
<BooleanSetting
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue