]> git.parisson.com Git - teleforma.git/commitdiff
Fix perdio for script corrector
authorGuillaume Pellerin <guillaume.pellerin@ircam.fr>
Fri, 19 May 2017 15:33:45 +0000 (17:33 +0200)
committerGuillaume Pellerin <guillaume.pellerin@ircam.fr>
Fri, 19 May 2017 15:33:45 +0000 (17:33 +0200)
teleforma/exam/models.py

index e93176bdaf5b610d65378a369bbf2715539eddd7..62d75d7ccc9523a12893e92ae2a1515e0b6e270e 100644 (file)
@@ -278,11 +278,13 @@ class Script(BaseResource):
         quota_list = []
         quotas = self.course.quotas.filter(date_start__lte=self.date_submitted,
                                             date_end__gte=self.date_submitted,
-                                            script_type=self.type)
+                                            script_type=self.type,
+                                            period=self.period)
         if not quotas:
             quotas = self.course.quotas.filter(date_start__lte=self.date_submitted,
                                             date_end__gte=self.date_submitted,
-                                            script_type=None)
+                                            script_type=None,
+                                            period=self.period)
         if quotas:
             for quota in quotas:
                 if quota.value: