Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[OLD/ABANDONED] fix: add should_display_status_to_user method and status_changed field to VerificationAttempt model #35507

Closed
wants to merge 3 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Generated by Django 4.2.15 on 2024-09-19 16:17

from django.db import migrations
import django.utils.timezone
import model_utils.fields


class Migration(migrations.Migration):

dependencies = [
('verify_student', '0015_verificationattempt'),
]

operations = [
migrations.AddField(
model_name='verificationattempt',
name='status_changed',
field=model_utils.fields.MonitorField(default=django.utils.timezone.now, monitor='status', verbose_name='status changed'),
),
]
7 changes: 6 additions & 1 deletion lms/djangoapps/verify_student/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -1214,7 +1214,7 @@ def __str__(self):
return str(self.arguments)


class VerificationAttempt(TimeStampedModel):
class VerificationAttempt(TimeStampedModel, StatusModel):
"""
The model represents impelementation-agnostic information about identity verification (IDV) attempts.

Expand Down Expand Up @@ -1251,3 +1251,8 @@ def retire_user(cls, user_id):
"""
verification_attempts = cls.objects.filter(user_id=user_id)
verification_attempts.delete()

@classmethod
def should_display_status_to_user(cls):
"""Temporary placeholder so that calls to this method do not break edx-platform"""
return False
Loading