You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
it'd be helpful to export the helper that filters query against a filter object such as { field__in: [1,2] }.
Sample code:
queryFilteredAssets($limit: Int, $offset: Int, $events_filter: Filter) {
assets(limit: $limit, offset: $offset, filter: $filter, eventsFilter: $eventsFilter) {
name # events could be included or could be omitted - that doesn't affect the assets query!events(filter: $eventsFilter) {
idevent_type
}
}
}
Resolver:
Assets: async(parent,args,context,info)=>{constassets=awaitresolveGraph(context,info,Asset.query().whereExists(Assets.relatedQuery('events').where(// construct custom condition from args.eventsFilter// <------ TODO: use the newly exported function)))returnassets}
The text was updated successfully, but these errors were encountered:
See #4 (comment):
it'd be helpful to export the helper that filters query against a filter object such as
{ field__in: [1,2] }
.Sample code:
Resolver:
The text was updated successfully, but these errors were encountered: