Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

Can't use custom filter with arguments in constructor #32

Open
digislexia opened this issue Jun 1, 2022 · 0 comments
Open

Can't use custom filter with arguments in constructor #32

digislexia opened this issue Jun 1, 2022 · 0 comments

Comments

@digislexia
Copy link

If my custom filter requires some arguments in constructor, for example i want to pass column name, operator for query etc. then i cant use this filter because of $currentFilter = new $filter; line in globalFiltered. Maybe it will be useful to check type of $filter and if it is already object just use it instead of trying to create new instance.
My current workaround - set all required properties in separated methods instead of passing them to constructor.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant