diff --git a/lms/djangoapps/certificates/management/commands/find_unicode_certs.py b/lms/djangoapps/certificates/management/commands/find_unicode_certs.py index eff1171383..49497622c6 100644 --- a/lms/djangoapps/certificates/management/commands/find_unicode_certs.py +++ b/lms/djangoapps/certificates/management/commands/find_unicode_certs.py @@ -1,11 +1,11 @@ # -*- coding: utf-8 -*- from django.core.management.base import BaseCommand -from certificates.models import GeneratedCertificate +from certificates.models import certificate_status_for_student from certificates.queue import XQueueCertInterface from django.contrib.auth.models import User from student.models import UserProfile -import sys + class Command(BaseCommand): @@ -15,6 +15,9 @@ class Command(BaseCommand): """ def handle(self, *args, **options): + + # TODO this is only temporary for CS169 certs + course_id = 'BerkeleyX/CS169.1x/2012_Fall' enrolled_students = User.objects.filter( @@ -33,4 +36,3 @@ class Command(BaseCommand): if ret == 'generating': print 'generating for {0}'.format(student) break - diff --git a/lms/djangoapps/certificates/management/commands/ungenerated_certs.py b/lms/djangoapps/certificates/management/commands/ungenerated_certs.py index 06dd49ac8d..82e86c2097 100644 --- a/lms/djangoapps/certificates/management/commands/ungenerated_certs.py +++ b/lms/djangoapps/certificates/management/commands/ungenerated_certs.py @@ -1,5 +1,4 @@ from django.core.management.base import BaseCommand -from certificates.models import GeneratedCertificate from certificates.models import certificate_status_for_student from certificates.queue import XQueueCertInterface from django.contrib.auth.models import User @@ -16,6 +15,8 @@ class Command(BaseCommand): def handle(self, *args, **options): + # TODO This is only temporary for CS169 certs + course_id = 'BerkeleyX/CS169.1x/2012_Fall' enrolled_students = User.objects.filter( courseenrollment__course_id=course_id).prefetch_related(