chore: get start from deploying

This commit is contained in:
jialin
2025-02-24 11:34:40 +08:00
parent 1dd7037aa0
commit bcbefe29e7
11 changed files with 214 additions and 26 deletions
+4 -5
View File
@@ -2,11 +2,12 @@ import { initialPasswordAtom, userAtom } from '@/atoms/user';
import SealInput from '@/components/seal-form/seal-input';
import { PasswordReg } from '@/config';
import { GlobalOutlined, LockOutlined } from '@ant-design/icons';
import { SelectLang, history, useIntl } from '@umijs/max';
import { SelectLang, useIntl } from '@umijs/max';
import { Button, Form, message } from 'antd';
import CryptoJS from 'crypto-js';
import { useAtom } from 'jotai';
import { updatePassword } from '../apis';
import { checkDefaultPage } from '../utils';
const CRYPT_TEXT = 'seal';
@@ -16,10 +17,8 @@ const PasswordForm: React.FC = () => {
const [userInfo, setUserInfo] = useAtom(userAtom);
const [initialPassword, setInitialPassword] = useAtom(initialPasswordAtom);
const gotoDefaultPage = (userInfo: any) => {
const pathname =
userInfo && userInfo?.is_admin ? '/dashboard' : '/playground';
history.push(pathname);
const gotoDefaultPage = async (userInfo: any) => {
checkDefaultPage(userInfo, false);
};
const decryptPassword = (password: string) => {