ragflow/web/src/hooks/store-hooks.ts
balibabu 906c0c5c89
fix: Set the default value of Self RAG to false #1220 (#1702)
### What problem does this PR solve?

fix: Set the default value of Self RAG  to false #1220
fix: Change all tool file names to kebab format

### Type of change

- [x] Bug Fix (non-breaking change which fixes an issue)
2024-07-25 14:38:17 +08:00

12 lines
424 B
TypeScript

import { getOneNamespaceEffectsLoading } from '@/utils/store-util';
import { useSelector } from 'umi';
// Get the loading status of given effects under a certain namespace
export const useOneNamespaceEffectsLoading = (
namespace: string,
effectNames: Array<string>,
) => {
const effects = useSelector((state: any) => state.loading.effects);
return getOneNamespaceEffectsLoading(namespace, effects, effectNames);
};