Commit f1af5b5c by Waheed Ahmed

Fixed admin course access role required field value not populating.

TNL-3049
parent e57bf4a5
......@@ -95,6 +95,11 @@ class CourseAccessRoleForm(forms.ModelForm):
return cleaned_data
def __init__(self, *args, **kwargs):
super(CourseAccessRoleForm, self).__init__(*args, **kwargs)
if self.instance.user_id:
self.fields['email'].initial = self.instance.user.email
class CourseAccessRoleAdmin(admin.ModelAdmin):
"""Admin panel for the Course Access Role. """
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment