Replies: 1 comment
-
Hi All. I found a solution / hack which partially resolves this for now: If you set your foreign key up to be a NumberField, this allows you to search by the foreign key. For example, my Payments Model has a foreign key called company_id, so I include the following fields in my ModelView class PaymentsView(ModelView): The company field looks nice in the admin and the company_id is searchable Its not ideal, but workable for now. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Is it possible to make Custom Fields and/or RelationFields searchable in the ModelView list using the "Filter"widget?
I see that other fields such as StringField or NumericFields work well with search out the box.
For Custom Fields, they show up in the search, but the search does not work.
For RelationFields they do not show up in the search dropdown at all.
Thanks
Beta Was this translation helpful? Give feedback.
All reactions