feat: 日志优化

This commit is contained in:
zdl
2025-10-18 22:32:50 +08:00
parent 47fcb570c0
commit 5eab62c673

View File

@@ -31,6 +31,7 @@ import AuthHeader from "../../../components/Auth/AuthHeader";
import AuthFooter from "../../../components/Auth/AuthFooter";
import VerificationCodeInput from "../../../components/Auth/VerificationCodeInput";
import WechatRegister from "../../../components/Auth/WechatRegister";
import { logger } from "../../../utils/logger";
export default function SignInIllustration() {
const navigate = useNavigate();
@@ -350,7 +351,11 @@ export default function SignInIllustration() {
}
}
} catch (error) {
console.error('Login error:', error);
logger.error('SignInIllustration', 'handleTraditionalLogin', error, {
phone: formData.phone ? formData.phone.substring(0, 3) + '****' + formData.phone.substring(7) : 'N/A',
useVerificationCode,
loginType: 'phone'
});
toast({
title: "登录失败",
description: error.message || "发生未预期的错误,请重试",