[Answer]-How can I reuse django form for searching?

1👍

You can programmatically change properties of a field within a form using its fields dictionary. So you could create a new form class that is derived from your current form class and in its __init__ set the required property of the fields you desired to be optional to be False like so:

self.fields['title'].required = False
👤OrenD

Leave a comment