Support Email and phone login.

This commit is contained in:
Yang Luo
2021-05-01 20:23:20 +08:00
parent 5b1b8662ac
commit 0f7cd56441
5 changed files with 30 additions and 8 deletions

View File

@ -178,11 +178,11 @@ class LoginPage extends React.Component {
</Form.Item>
<Form.Item
name="username"
rules={[{ required: true, message: i18next.t("login:Please input your username!") }]}
rules={[{ required: true, message: i18next.t("login:Please input your username, Email or phone number!") }]}
>
<Input
prefix={<UserOutlined className="site-form-item-icon" />}
placeholder={i18next.t("login:username")}
placeholder={i18next.t("login:username, Email or phone number")}
disabled={!application.enablePassword}
/>
</Form.Item>

View File

@ -50,8 +50,8 @@
},
"login":
{
"Please input your username!": "Please input your username!",
"username": "username",
"Please input your username, Email or phone number!": "Please input your username, Email or phone number!",
"username, Email or phone number": "username, Email or phone number",
"Please input your password!": "Please input your password!",
"password": "password",
"Auto login": "Auto login",

View File

@ -50,8 +50,8 @@
},
"login":
{
"Please input your username!": "请输入您的用户名!",
"username": "用户名",
"Please input your username, Email or phone number!": "请输入您的用户名、Email或手机号",
"username, Email or phone number": "用户名、Email或手机号",
"Please input your password!": "请输入您的密码!",
"password": "密码",
"Auto login": "下次自动登录",