Skip to content

Commit 27993f4

Browse files
perf: User change ws api
1 parent c362223 commit 27993f4

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

backend/apps/system/api/user.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ async def ws_change(session: SessionDep, current_user: CurrentUser, trans:Trans,
101101
if not any(x.id == oid for x in ws_list):
102102
db_ws = session.get(WorkspaceModel, oid)
103103
if db_ws:
104-
raise Exception(trans('i18n_user.user_ws_miss', msg = db_ws.name))
104+
raise Exception(trans('i18n_user.ws_miss', ws = db_ws.name))
105105
raise Exception(trans('i18n_not_exist', msg = f"{trans('i18n_ws.title')}[{oid}]"))
106106
user_model: UserModel = get_db_user(session = session, user_id = current_user.id)
107107
user_model.oid = oid

backend/locales/en.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
"email": "Email",
1818
"password": "Password",
1919
"language_not_support": "System does not support [{key}] language!",
20-
"user_ws_miss:": "The current user is not in the workspace [{msg}]!"
20+
"ws_miss": "The current user is not in the workspace [{ws}]!"
2121
},
2222
"i18n_ws": {
2323
"title": "Workspace"

backend/locales/zh-CN.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
"email": "邮箱",
1818
"password": "密码",
1919
"language_not_support": "系统不支持[{key}]语言!",
20-
"user_ws_miss:": "当前用户不在工作空间[{msg}]中!"
20+
"ws_miss": "当前用户不在工作空间[{ws}]中!"
2121
},
2222
"i18n_ws": {
2323
"title": "工作空间"

0 commit comments

Comments
 (0)