Add query to fetch categories with type

This commit is contained in:
2023-12-12 16:42:09 +01:00
parent d536b22ec6
commit 69a32e798c

View File

@@ -29,7 +29,7 @@ function isCategory(category: string) {
const {
data: getCategories,
} = await useFetch<Array<Category>>('/api/categories', { method: 'GET' })
} = await useFetch<Array<Category>>('/api/categories', { method: 'GET', query: { type: 'TALENT' } })
getCategories.value!.forEach((category: any) => categories.value.push({ label: category.name, slug: category.slug }))
const appConfig = useAppConfig()