feat: add limit for temporary to verify email

pull/90/head
moonrailgun 2 years ago
parent 886e274a52
commit 3f6c3b08d8

@ -89,6 +89,7 @@
"k4231ab36": "Performance statistics",
"k42a98418": "File Service",
"k4539164b": "The OTP code is 6 digits",
"k45e2f71f": "Temporary users cannot verify email address, please claim account first",
"k4603baea": "Create Group Panel",
"k47489688": "Group Service",
"k48a38bc1": "Group not found",

@ -89,6 +89,7 @@
"k4231ab36": "性能统计",
"k42a98418": "文件服务",
"k4539164b": "校验码为6位",
"k45e2f71f": "临时用户无法认证邮箱, 请先认领账号",
"k4603baea": "创建群组面板",
"k47489688": "群组服务",
"k48a38bc1": "群组不存在",

@ -8,7 +8,7 @@ import { closeModal, pluginUserExtraInfo } from '@/plugin/common';
import { getGlobalSocket } from '@/utils/global-state-helper';
import { setUserJWT } from '@/utils/jwt-helper';
import { setGlobalUserLoginInfo } from '@/utils/user-helper';
import { Button, Divider, Tag, Typography } from 'antd';
import { Button, Divider, message, Tag, Typography } from 'antd';
import React, { useCallback } from 'react';
import { useNavigate } from 'react-router';
import { Avatar } from 'tailchat-design';
@ -125,6 +125,13 @@ export const SettingsAccount: React.FC = React.memo(() => {
color="warning"
className="cursor-pointer"
onClick={() => {
if (userInfo.temporary) {
message.warning(
t('临时用户无法认证邮箱, 请先认领账号')
);
return;
}
const key = openModal(
<EmailVerify
onSuccess={() => {

Loading…
Cancel
Save