mirror of
https://github.com/infiniflow/ragflow.git
synced 2025-12-08 20:42:30 +08:00
### What problem does this PR solve? feat: pull the message list after sending the message successfully #918 ### Type of change - [x] New Feature (non-breaking change which adds functionality)
This commit is contained in:
@ -80,9 +80,17 @@ export const useFetchFlowList = (): { data: IFlow[]; loading: boolean } => {
|
||||
return { data, loading };
|
||||
};
|
||||
|
||||
export const useFetchFlow = (): { data: IFlow; loading: boolean } => {
|
||||
export const useFetchFlow = (): {
|
||||
data: IFlow;
|
||||
loading: boolean;
|
||||
refetch: () => void;
|
||||
} => {
|
||||
const { id } = useParams();
|
||||
const { data, isFetching: loading } = useQuery({
|
||||
const {
|
||||
data,
|
||||
isFetching: loading,
|
||||
refetch,
|
||||
} = useQuery({
|
||||
queryKey: ['flowDetail'],
|
||||
initialData: {} as IFlow,
|
||||
queryFn: async () => {
|
||||
@ -92,7 +100,7 @@ export const useFetchFlow = (): { data: IFlow; loading: boolean } => {
|
||||
},
|
||||
});
|
||||
|
||||
return { data, loading };
|
||||
return { data, loading, refetch };
|
||||
};
|
||||
|
||||
export const useSetFlow = () => {
|
||||
|
||||
Reference in New Issue
Block a user