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
What were you trying to do?
I have a Subscription Dashboard that has a field owner: Field::Polymorphic I would like to be able to search by owner attributes
What versions are you running?
Rails gem "rails", "~> 6.1.0"
administrate latest
The text was updated successfully, but these errors were encountered:
Thank you for your report. Indeed, polymorphic fields are tricky and our search doesn't currently support them.
Fortunately there are ways around this. It's possible to provide your own controllers that override Administrate's behaviour. This is the basis of many customisations. In this case, overriding Administrate::ApplicationController#index would be a way to do it.
Having said that, I had a look and realised that the way things are hooked up, this is not so evident in the case of customising the search. To fix this, I have opened a PR that introduces a small change that should make this easier to do, as well as provides an example of how to do it (in the specs): #2096
What were you trying to do?
I have a Subscription Dashboard that has a field
owner: Field::Polymorphic
I would like to be able to search by owner attributesWhat versions are you running?
gem "rails", "~> 6.1.0"
The text was updated successfully, but these errors were encountered: