From f150f1c54ee5941d72f2e4057af8c90cca588292 Mon Sep 17 00:00:00 2001 From: mahesh Date: Wed, 4 May 2016 16:33:18 +0530 Subject: teachers added to course can grade user --- yaksh/views.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'yaksh') diff --git a/yaksh/views.py b/yaksh/views.py index 9be2c02..a91da29 100644 --- a/yaksh/views.py +++ b/yaksh/views.py @@ -893,7 +893,8 @@ def grade_user(request, quiz_id=None, user_id=None, attempt_number=None): ci = RequestContext(request) if not current_user.is_authenticated() or not is_moderator(current_user): raise Http404('You are not allowed to view this page!') - course_details = Course.objects.filter(creator=current_user) + course_details = Course.objects.filter(Q(creator=current_user)| + Q(teachers=current_user)).distinct() context = {"course_details": course_details} if quiz_id is not None: questionpaper_id = QuestionPaper.objects.filter(quiz_id=quiz_id)\ -- cgit