You must specify a custom ModelForm that modifies the set of fieldclass field requests and adds it to your ModelAdmin :
class DriverForm(forms.ModelForm): def __init__(self, *args, **kwargs): super(DriverForm, self).__init__(*args, **kwargs) if self.instance.event:
One caveat is that when you change Event parameters for DriverClass not updated until the form is DriverClass . The form will raise a ValidationError, and the returned form will have the right choice. Ajax requests and dynamic updates through Javascript will be required to change this behavior.
source share