1

I want to add a custom filter to the order collection, checking if some conditions are met. A helper method should return false/true, and then apply the custom filter if it returns true. The custom filter is just a boolean returned from a custom column added to sales_order table. Basically, I want to show the orders that have this column value set as true only to a specific admin user and hide them from the other admin users. Of course, this should only be applied to the admin sales order grid.

I am just starting to learn about the UI components and I have no idea how could I achieve this using the new system.

Should I go with a class preference for the grid collection instead? Should I add a plugin to a relevant method maybe?

I'm hoping that some more advanced users can help me choosing the best path for this.

Thanks!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.