diff --git a/tasks/views/session_views.py b/tasks/views/session_views.py index ae8fa9ed7..61d02ba46 100644 --- a/tasks/views/session_views.py +++ b/tasks/views/session_views.py @@ -49,6 +49,9 @@ def delete(self, request, *args, **kwargs): class SessionCreate(RedirectActionView): + """Creates a session, from a study pk and redirects to SessionUpdate() + for that session.""" + def action(self, request): study = Study.objects.get(pk=self.kwargs["pk"]) order = study.session_set.count() + 1 diff --git a/tasks/views/task_views.py b/tasks/views/task_views.py index 736a4d012..4b6ffe0c9 100644 --- a/tasks/views/task_views.py +++ b/tasks/views/task_views.py @@ -18,6 +18,9 @@ class TaskCreate(RedirectActionView): + """Creates a task, from a session pk and redirects to TaskUpdate() + for that task.""" + def action(self, request): session = Session.objects.get(pk=self.kwargs["pk"]) order = session.task_set.count() + 1