minor change

This commit is contained in:
Gowtham Sai 2022-07-28 14:36:54 +05:30
parent c1309326ae
commit 1e7cfa4cfa
2 changed files with 2 additions and 1 deletions

View File

@ -254,6 +254,7 @@ def submitApplication(request, id, email, user_type):
}
subject = STUDENT_APPLICATION_SUBMITTED_TEMPLATE_SUBJECT.format(company_name=opening.company_name)
application.changed_by = get_object_or_404(User, id=id)
application.save()
sendEmail(student_user.email, subject, data, STUDENT_APPLICATION_SUBMITTED_TEMPLATE)
return Response({'action': "Add Student Application", 'message': "Application added"},
status=status.HTTP_200_OK)

View File

@ -10,7 +10,7 @@ from .constants import *
class User(models.Model):
email = models.EmailField(blank=False, max_length=JNF_TEXT_MAX_CHARACTER_COUNT, unique=True, primary_key=True)
email = models.EmailField(primary_key=True, blank=False, max_length=JNF_TEXT_MAX_CHARACTER_COUNT)
id = models.CharField(blank=False, max_length=25, db_index=True)
user_type = ArrayField(models.CharField(blank=False, max_length=10), size=4, default=list, blank=False)
last_login_time = models.DateTimeField(default=timezone.now)