From 2d9e5778593f22425f233e88f3b2264b0da3ab25 Mon Sep 17 00:00:00 2001 From: Jimmy Liow Date: Wed, 10 Jul 2024 15:38:58 +0800 Subject: [PATCH] =?UTF-8?q?feat:=E8=B4=A6=E5=8F=B7=E7=AE=A1=E7=90=86?= =?UTF-8?q?=E7=95=8C=E9=9D=A2=E5=A2=9E=E5=8A=A0=E4=B8=AD=E8=8B=B1=E6=96=87?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- public/locales/en/account.json | 26 +++++++++++++++++++++++++- public/locales/zh/account.json | 1 + src/views/account/Management.jsx | 5 +++-- 3 files changed, 29 insertions(+), 3 deletions(-) diff --git a/public/locales/en/account.json b/public/locales/en/account.json index 7abb5cf..e8ea251 100644 --- a/public/locales/en/account.json +++ b/public/locales/en/account.json @@ -8,5 +8,29 @@ "CurrentPassword": "Please input your password.", "NewPassword": "Please input your new password.", "ReenterPassword": "Please reenter your password." - } + }, + "createdOn": "Created on", + "action": "Action", + "action.edit": "Edit", + "action.enable": "Enable", + "action.disable": "Disable", + "action.enable.title": "Do you want to enable account?", + "action.disable.title": "Do you want to disable account?", + "action.resetPassword": "Reset Password", + "action.resetPassword.tile": "Do you want to reset password?", + + "accountList": "Account List", + "newAccount": "New Account", + "detail": "Detail", + "username": "Username", + "realname": "Realname", + "travelAgency": "Travel Agency", + "travelAgencyName": "Travel Agency Name", + "email": "Email", + "lastLogin": "Last Login", + + "roleList": "Role List", + "newRole": "New Role", + "roleName": "Role Name", + "permission": "Permission" } \ No newline at end of file diff --git a/public/locales/zh/account.json b/public/locales/zh/account.json index a1d78c4..b38946c 100644 --- a/public/locales/zh/account.json +++ b/public/locales/zh/account.json @@ -17,6 +17,7 @@ "action.enable.title": "确定启用该账号吗?", "action.disable.title": "确定禁用该账号吗?", "action.resetPassword": "重置密码", + "action.resetPassword.tile": "确定重置账号密码吗?", "accountList": "管理账号", "newAccount": "新增账号", diff --git a/src/views/account/Management.jsx b/src/views/account/Management.jsx index 5a8abdc..7081be3 100644 --- a/src/views/account/Management.jsx +++ b/src/views/account/Management.jsx @@ -193,11 +193,12 @@ function Management() { } const showResetPasswordConfirm = (account) => { + const confirmTitle = t('account:action.resetPassword.tile') const randomPassword = account.username + '@' + (Math.floor(Math.random() * 900) + 100) modal.confirm({ - title: 'Do you want to reset password?', + title: confirmTitle, icon: , - content: `Username: ${account.username}, Realname: ${account.realname}`, + content: t('account:username') + ': ' + account.username + ', ' + t('account:realname') + ': ' + account.realname, onOk() { resetAccountPassword(account.userId, randomPassword) .then(() => {