perf: model provider show; perf: get init data buffer (#3459)
* pr code * perf: model table show * perf: model provider show * perf: get init data buffer * perf: get init data buffer * perf: icon
This commit is contained in:
@@ -5,6 +5,7 @@ import { useSystemStore } from '@/web/common/system/useSystemStore';
|
||||
import type { FastGPTFeConfigsType } from '@fastgpt/global/common/system/types/index.d';
|
||||
import { useMemoizedFn, useMount } from 'ahooks';
|
||||
import { TrackEventName } from '../common/system/constants';
|
||||
import { useRequest2 } from '@fastgpt/web/hooks/useRequest';
|
||||
|
||||
export const useInitApp = () => {
|
||||
const router = useRouter();
|
||||
@@ -41,8 +42,6 @@ export const useInitApp = () => {
|
||||
});
|
||||
|
||||
useMount(() => {
|
||||
initFetch();
|
||||
|
||||
const errorTrack = (event: ErrorEvent) => {
|
||||
window.umami?.track(TrackEventName.windowError, {
|
||||
device: {
|
||||
@@ -62,6 +61,11 @@ export const useInitApp = () => {
|
||||
};
|
||||
});
|
||||
|
||||
useRequest2(initFetch, {
|
||||
manual: false,
|
||||
pollingInterval: 300000
|
||||
});
|
||||
|
||||
useEffect(() => {
|
||||
hiId && localStorage.setItem('inviterId', hiId);
|
||||
bd_vid && sessionStorage.setItem('bd_vid', bd_vid);
|
||||
|
||||
Reference in New Issue
Block a user