update upload way
This commit is contained in:
@@ -75,7 +75,7 @@ export const App = () => {
|
||||
<Route path='/container/*' element={<ContainerApp />} />
|
||||
<Route path='/map/*' element={<MapApp />} />
|
||||
<Route path='/user/*' element={<UserApp />} />
|
||||
<Route path='/user1/*' element={<UserApp />} />
|
||||
<Route path='/user-center/*' element={<UserApp />} />
|
||||
<Route path='/org/*' element={<OrgApp />} />
|
||||
<Route path='/config/*' element={<ConfigApp />} />
|
||||
<Route path='/app/*' element={<UserAppApp />} />
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import { QueryClient } from '@kevisual/query';
|
||||
import { QueryLoginBrowser } from '@kevisual/query-login';
|
||||
import { toastLogin } from '@kevisual/resources/pages/message/ToastLogin.tsx';
|
||||
import { toast } from 'react-toastify';
|
||||
export const query = new QueryClient({
|
||||
io: true,
|
||||
});
|
||||
@@ -25,6 +26,15 @@ query.afterResponse = async (res, ctx) => {
|
||||
afterAlso401: () => {
|
||||
toastLogin();
|
||||
},
|
||||
afterCheck: (res) => {
|
||||
if (res.code === 200) {
|
||||
// console.log('afterCheck');
|
||||
toast.success('刷新登陆信息');
|
||||
setTimeout(() => {
|
||||
window.location.reload();
|
||||
}, 1000);
|
||||
}
|
||||
},
|
||||
});
|
||||
|
||||
return newRes as any;
|
||||
|
||||
Reference in New Issue
Block a user