Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
chenpangpang
open-webui
Commits
0c021e42
"...git@developer.sourcefind.cn:chenpangpang/open-webui.git" did not exist on "c0fbf1e7d096ae7478c773fc650b8b080f9b126e"
Commit
0c021e42
authored
Mar 26, 2024
by
Ased Mammad
Browse files
rename config key to default_locale
parent
64e60036
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
4 additions
and
4 deletions
+4
-4
backend/data/config.json
backend/data/config.json
+1
-1
backend/main.py
backend/main.py
+1
-1
src/routes/+layout.svelte
src/routes/+layout.svelte
+2
-2
No files found.
backend/data/config.json
View file @
0c021e42
{
{
"version"
:
0
,
"version"
:
0
,
"ui"
:
{
"ui"
:
{
"locale"
:
"en-US"
,
"
default_
locale"
:
"en-US"
,
"prompt_suggestions"
:
[
"prompt_suggestions"
:
[
{
{
"title"
:
[
"title"
:
[
...
...
backend/main.py
View file @
0c021e42
...
@@ -167,7 +167,7 @@ async def get_app_config():
...
@@ -167,7 +167,7 @@ async def get_app_config():
"status"
:
True
,
"status"
:
True
,
"name"
:
WEBUI_NAME
,
"name"
:
WEBUI_NAME
,
"version"
:
VERSION
,
"version"
:
VERSION
,
"locale"
:
CONFIG_DATA
[
"ui"
][
"locale"
],
"
default_
locale"
:
CONFIG_DATA
[
"ui"
][
"
default_
locale"
],
"images"
:
images_app
.
state
.
ENABLED
,
"images"
:
images_app
.
state
.
ENABLED
,
"default_models"
:
webui_app
.
state
.
DEFAULT_MODELS
,
"default_models"
:
webui_app
.
state
.
DEFAULT_MODELS
,
"default_prompt_suggestions"
:
webui_app
.
state
.
DEFAULT_PROMPT_SUGGESTIONS
,
"default_prompt_suggestions"
:
webui_app
.
state
.
DEFAULT_PROMPT_SUGGESTIONS
,
...
...
src/routes/+layout.svelte
View file @
0c021e42
...
@@ -25,8 +25,8 @@
...
@@ -25,8 +25,8 @@
if (backendConfig) {
if (backendConfig) {
// Save Backend Status to Store
// Save Backend Status to Store
await config.set(backendConfig);
await config.set(backendConfig);
if ($config.locale) {
if ($config.
default_
locale) {
initI18n($config.locale);
initI18n($config.
default_
locale);
} else {
} else {
initI18n();
initI18n();
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment