1👍
✅
So the word is Providing initial values for custom fields based on instance data
include below code in your forms.py then it will work ….
def __init__(self, *args, **kwargs):
instance = kwargs.get('instance')
if instance:
pprint.pprint(instance.values)
self.base_fields['values'].initial = instance.values
forms.ModelForm.__init__(self, *args, **kwargs)
Source:stackexchange.com