diff --git a/sorteerhoed/HITStore.py b/sorteerhoed/HITStore.py index be1ba52..f557fb0 100644 --- a/sorteerhoed/HITStore.py +++ b/sorteerhoed/HITStore.py @@ -134,6 +134,7 @@ class HIT(Base): session = object_session(self) q = session.query(Assignment).\ filter(Assignment.submit_page_at < self.created_at).\ + filter(Assignment.worker_id != None).\ group_by(Assignment.worker_id).\ order_by(Assignment.created_at.desc()) if assignment and assignment.worker_id: