add role and expose reason field to Instructor Dashboard Manual Enrollment
WL-1473
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
from __future__ import unicode_literals
|
||||
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('student', '0014_courseenrollmentallowed_user'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AddField(
|
||||
model_name='manualenrollmentaudit',
|
||||
name='role',
|
||||
field=models.CharField(max_length=64, null=True, blank=True),
|
||||
),
|
||||
]
|
||||
@@ -1973,9 +1973,10 @@ class ManualEnrollmentAudit(models.Model):
|
||||
time_stamp = models.DateTimeField(auto_now_add=True, null=True)
|
||||
state_transition = models.CharField(max_length=255, choices=TRANSITION_STATES)
|
||||
reason = models.TextField(null=True)
|
||||
role = models.CharField(blank=True, null=True, max_length=64)
|
||||
|
||||
@classmethod
|
||||
def create_manual_enrollment_audit(cls, user, email, state_transition, reason, enrollment=None):
|
||||
def create_manual_enrollment_audit(cls, user, email, state_transition, reason, enrollment=None, role=None):
|
||||
"""
|
||||
saves the student manual enrollment information
|
||||
"""
|
||||
@@ -1984,7 +1985,8 @@ class ManualEnrollmentAudit(models.Model):
|
||||
enrolled_email=email,
|
||||
state_transition=state_transition,
|
||||
reason=reason,
|
||||
enrollment=enrollment
|
||||
enrollment=enrollment,
|
||||
role=role,
|
||||
)
|
||||
|
||||
@classmethod
|
||||
|
||||
Reference in New Issue
Block a user