chore: heygermany customer project
Some checks failed
Main / Setup and Test (push) Has been cancelled
Main / Build Website (push) Has been cancelled

This commit is contained in:
e2e
2026-07-11 11:17:38 +02:00
commit 40352e4179
370 changed files with 35601 additions and 0 deletions

View File

@@ -0,0 +1,18 @@
import { pikku } from '@/pikku/http'
import type { ApplicationCandidateData } from '@heygermany/sdk'
import { useQuery } from '@tanstack/react-query'
export const useGetCandidate = (candidateId?: string) => {
return useQuery({
queryKey: ['candidate'],
queryFn: async (): Promise<ApplicationCandidateData> => {
if (!candidateId) {
return await pikku().get('/candidate')
} else {
return await pikku().get('/candidate/:candidateId', { candidateId })
}
},
staleTime: 5 * 60 * 1000, // 5 minutes,
retry: 0
})
}