clear upload_status if user makes changes to TestCenterUser or TestCenterRegistration (so the change is pending, rather than rejected)

This commit is contained in:
Brian Wilson
2013-01-16 15:43:15 -05:00
parent 1d6b1be888
commit 1de67be788

View File

@@ -271,6 +271,7 @@ class TestCenterUserForm(ModelForm):
new_user = self.save(commit=False)
# create additional values here:
new_user.user_updated_at = datetime.utcnow()
new_user.upload_status = ''
new_user.save()
log.info("Updated demographic information for user's test center exam registration: username \"{}\" ".format(new_user.user.username))
@@ -533,6 +534,7 @@ class TestCenterRegistrationForm(ModelForm):
registration = self.save(commit=False)
# create additional values here:
registration.user_updated_at = datetime.utcnow()
registration.upload_status = ''
registration.save()
log.info("Updated registration information for user's test center exam registration: username \"{}\" course \"{}\", examcode \"{}\"".format(registration.testcenter_user.user.username, registration.course_id, registration.exam_series_code))