I want to exclude certain fields in the init function of a modelform depending on a parameter passed in, how do I do this? I know I can add exclude fields using the meta class of a model form but I need this to be dynamic depending on the variable passed in.
Thanks
You can modify the self.fields list after calling super.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With