Skip to content
Snippets Groups Projects
Commit b61df3af authored by Zainab Amir's avatar Zainab Amir
Browse files

LEARNER-6944 Add new fields to SoftwareSecurePhotoVerification

parent 932d65d6
No related branches found
No related tags found
No related merge requests found
# -*- coding: utf-8 -*-
# Generated by Django 1.11.16 on 2019-01-10 09:19
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('verify_student', '0010_manualverification'),
]
operations = [
migrations.AddField(
model_name='softwaresecurephotoverification',
name='expiry_date',
field=models.DateTimeField(blank=True, db_index=True, null=True),
),
migrations.AddField(
model_name='softwaresecurephotoverification',
name='expiry_email_date',
field=models.DateTimeField(blank=True, db_index=True, null=True),
),
]
...@@ -536,6 +536,13 @@ class SoftwareSecurePhotoVerification(PhotoVerification): ...@@ -536,6 +536,13 @@ class SoftwareSecurePhotoVerification(PhotoVerification):
IMAGE_LINK_DURATION = 5 * 60 * 60 * 24 # 5 days in seconds IMAGE_LINK_DURATION = 5 * 60 * 60 * 24 # 5 days in seconds
copy_id_photo_from = models.ForeignKey("self", null=True, blank=True, on_delete=models.CASCADE) copy_id_photo_from = models.ForeignKey("self", null=True, blank=True, on_delete=models.CASCADE)
# Fields for functionality of sending email when verification expires
# expiry_date: The date when the SoftwareSecurePhotoVerification will expire
# expiry_email_date: This field is used to maintain a check for learners to which email
# to notify for expired verification is already sent.
expiry_date = models.DateTimeField(null=True, blank=True, db_index=True)
expiry_email_date = models.DateTimeField(null=True, blank=True, db_index=True)
@classmethod @classmethod
def get_initial_verification(cls, user, earliest_allowed_date=None): def get_initial_verification(cls, user, earliest_allowed_date=None):
"""Get initial verification for a user with the 'photo_id_key'. """Get initial verification for a user with the 'photo_id_key'.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment