I have been using Contenfull to create a custom app. Now the problem that I'm having is I can not see how can I query a nested collection
I have the following entry
query cfPageList(
$contentfulLocale: String
$entryId: String!
$preview: Boolean = false
) {
cfPageList(id: $entryId, locale: $contentfulLocale, preview: $preview) {
sys {
id
}
categoryListCollection {
options: items {
value: value
label: itemName
disabled: disabled
}
}
}
}
I would like to query all the CategoryList that have disabled
to false
I tried with cfPageList(id: $entryId, locale: $contentfulLocale, preview: $preview, where: { disabled: false })
Tried with
cfPageList(id: $entryId, locale: $contentfulLocale, preview: $preview, where: { categoryListCollection: { disabled: false } })
But none of it works, do any of you guys have any idea how it should work, or if it is possible to do it with Contentfull.
from Contentfull Api filter nested collection
No comments:
Post a Comment