| | |
| | | |
| | | type UseStandardServiceDetailOptions = { |
| | | id: MaybeRef<string>; |
| | | onSuccess?: (data: API.GetStandardServiceQueryResult) => any; |
| | | }; |
| | | |
| | | export function useStandardServiceDetail({ id }: UseStandardServiceDetailOptions) { |
| | | export function useStandardServiceDetail({ id, onSuccess }: UseStandardServiceDetailOptions) { |
| | | const { data, refetch, isLoading, isError } = useQuery({ |
| | | queryKey: ['standardServiceServices/getStandardService', id], |
| | | queryFn: async () => { |
| | |
| | | }); |
| | | }, |
| | | placeholderData: () => ({} as API.GetStandardServiceQueryResult), |
| | | onSuccess(data) { |
| | | onSuccess?.(data); |
| | | }, |
| | | }); |
| | | |
| | | return { |