mirror of
https://github.com/getformwork/formwork.git
synced 2025-03-14 19:19:48 +01:00
Rename option panel.lang
to panel.translation
This commit is contained in:
parent
fc2a9be244
commit
151841e4cf
@ -4,7 +4,7 @@ return [
|
||||
'panel' => [
|
||||
'enabled' => true,
|
||||
'root' => 'panel',
|
||||
'lang' => 'en',
|
||||
'translation' => 'en',
|
||||
'login_attempts' => 10,
|
||||
'login_reset_time' => 300,
|
||||
'logout_redirect' => 'login',
|
||||
|
@ -256,6 +256,8 @@ final class Panel
|
||||
|
||||
if ($this->isLoggedIn()) {
|
||||
Formwork::instance()->translations()->setCurrent($this->user()->language());
|
||||
} else {
|
||||
Formwork::instance()->translations()->setCurrent(Formwork::instance()->config()->get('panel.translation'));
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -18,7 +18,7 @@
|
||||
<?php
|
||||
foreach (\Formwork\Panel\Panel::availableTranslations() as $key => $value):
|
||||
?>
|
||||
<option value="<?= $key ?>"<?php if ($key === $formwork->config()->get('panel.lang')): ?> selected<?php endif; ?>><?= $value ?></option>
|
||||
<option value="<?= $key ?>"<?php if ($key === $formwork->config()->get('panel.translation')): ?> selected<?php endif; ?>><?= $value ?></option>
|
||||
<?php
|
||||
endforeach;
|
||||
?>
|
||||
|
@ -26,7 +26,7 @@ layout:
|
||||
panel:
|
||||
collapsible: true
|
||||
label: '{{panel.options.system.admin-panel}}'
|
||||
fields: [panel.lang, panel.logout_redirect, panel.session_timeout, panel.color_scheme]
|
||||
fields: [panel.translation, panel.logout_redirect, panel.session_timeout, panel.color_scheme]
|
||||
|
||||
images:
|
||||
collapsible: true
|
||||
@ -102,7 +102,7 @@ fields:
|
||||
translate: [label]
|
||||
required: true
|
||||
|
||||
panel.lang:
|
||||
panel.translation:
|
||||
type: select
|
||||
label: '{{panel.options.system.admin-panel.default-language}}'
|
||||
translate: [label]
|
||||
|
Loading…
x
Reference in New Issue
Block a user