Closed
Description
When a resource is defined with an ExistsFilter
and a SearchFilter
on the same property, the graphql schema will convert both filters in the same way using the property name to identify the filter.
In the following example
/**
* @ApiResource()
* @ApiFilter(ExistsFilter::class, properties={"title"})
* @ApiFilter(SearchFilter::class, properties={"title": "exact"})
*/
class Dummy
{
/** @var null|string $title a nullable property */
private $title;
// ...
}
The REST collection endpoint enables both filter with the syntax /dummies?title=shirt
and /dummies?title[exists]=true
But the GraphQL endpoint enables only the SearchFilter
with the syntax dummies(title: "shirt") { ... }
(as the ExistFilter
uses the syntax dummies(title: {exists: true})
)