mirror of
https://github.com/whyour/qinglong.git
synced 2026-07-18 02:14:32 +08:00
重构前端错误提示
This commit is contained in:
@@ -17,8 +17,10 @@ const Error = () => {
|
||||
setLoading(true);
|
||||
request
|
||||
.get(`${config.apiPrefix}public/panel/log`)
|
||||
.then((data: any) => {
|
||||
setData(data.data);
|
||||
.then(({ code, data }) => {
|
||||
if (code === 200) {
|
||||
setData(data);
|
||||
}
|
||||
})
|
||||
.finally(() => setLoading(false));
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user