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
The filters are used to filtering a collection of items.
It is common to want a filter applying only for a specific route.
Unfortunately, the method (supports(string $class)) doesn't have the request. To implement this logic you have to inject the requestStack and do the classic checks against null value.
It could be helpful and have sense to inject the current request to the support method (and only support)
Imagine a that use {id} to filter related line_items in a collection call.
You want this filter to be applied only on the order_line_items route.
But actually, it's a specific use case, so I guess you can depend on Request in your filter for this @Nek-
The filters are used to filtering a collection of items.
It is common to want a filter applying only for a specific route.
Unfortunately, the method (
supports(string $class)
) doesn't have the request. To implement this logic you have to inject therequestStack
and do the classic checks against null value.It could be helpful and have sense to inject the current request to the support method (and only support)
This is BC IMHO, but what do you think @Nek- ?
This issue was originally written by @mcsky on biig repository.
The text was updated successfully, but these errors were encountered: