From 18812397e5dc9d6c8a96669be062b3f71f4d59a9 Mon Sep 17 00:00:00 2001 From: afc163 Date: Sun, 21 Jun 2026 23:08:08 +0800 Subject: [PATCH] fix: remove debug logging (#11876) --- src/pages/form/advanced-form/index.tsx | 2 +- src/pages/list/search/applications/index.tsx | 9 ++------- src/pages/list/search/index.tsx | 6 ------ src/pages/user/login/index.tsx | 4 +--- 4 files changed, 4 insertions(+), 17 deletions(-) diff --git a/src/pages/form/advanced-form/index.tsx b/src/pages/form/advanced-form/index.tsx index a3e4c391..2f761f16 100644 --- a/src/pages/form/advanced-form/index.tsx +++ b/src/pages/form/advanced-form/index.tsx @@ -130,7 +130,7 @@ const AdvancedForm: FC> = () => { await fakeSubmitForm(values); message.success('提交成功'); } catch { - // console.log + message.error('提交失败,请重试!'); } }; const onFinishFailed = (errorInfo: any) => { diff --git a/src/pages/list/search/applications/index.tsx b/src/pages/list/search/applications/index.tsx index 9aef6d21..807a209c 100644 --- a/src/pages/list/search/applications/index.tsx +++ b/src/pages/list/search/applications/index.tsx @@ -88,19 +88,14 @@ const Applications: FC> = () => { queryFn: () => queryFakeList({ count: 8 }).then((res) => res.data), }); - const run = (values: any) => { - console.log('form data', values); - refetch(); - }; - const list = data?.list || []; return (
{ - run(values); + onValuesChange={() => { + refetch(); }} > = () => { } }; - const handleFormSubmit = (value: string) => { - // eslint-disable-next-line no-console - console.log(value); - }; - const getTabKey = () => { const tabKey = location.pathname.substring( location.pathname.lastIndexOf('/') + 1, @@ -68,7 +63,6 @@ const Search: FC = () => { placeholder="请输入" enterButton="搜索" size="large" - onSearch={handleFormSubmit} style={{ maxWidth: 522, width: '100%' }} />
diff --git a/src/pages/user/login/index.tsx b/src/pages/user/login/index.tsx index ed200e96..e4218395 100644 --- a/src/pages/user/login/index.tsx +++ b/src/pages/user/login/index.tsx @@ -166,15 +166,13 @@ const Login: React.FC = () => { window.location.href = redirectUrl; return; } - console.log(msg); // 如果失败去设置用户错误信息 setUserLoginState(msg); - } catch (error) { + } catch { const defaultLoginFailureMessage = intl.formatMessage({ id: 'pages.login.failure', defaultMessage: '登录失败,请重试!', }); - console.log(error); message.error(defaultLoginFailureMessage); } };