Commit 7959d2db by Zia Fazal Committed by Jonathan Piacenti

added active flag on organisation metrics

parent a5844662
...@@ -35,7 +35,8 @@ class OrganizationsViewSet(viewsets.ModelViewSet): ...@@ -35,7 +35,8 @@ class OrganizationsViewSet(viewsets.ModelViewSet):
response_data = {} response_data = {}
grade_avg = 0 grade_avg = 0
grade_complete_match_range = getattr(settings, 'GRADEBOOK_GRADE_COMPLETE_PROFORMA_MATCH_RANGE', 0.01) grade_complete_match_range = getattr(settings, 'GRADEBOOK_GRADE_COMPLETE_PROFORMA_MATCH_RANGE', 0.01)
org_user_grades = StudentGradebook.objects.filter(user__organizations=pk, user__is_active=True) org_user_grades = StudentGradebook.objects.filter(user__organizations=pk, user__is_active=True,
user__courseenrollment__is_active=True)
courses_filter = request.QUERY_PARAMS.get('courses', None) courses_filter = request.QUERY_PARAMS.get('courses', None)
if courses_filter: if courses_filter:
upper_bound = getattr(settings, 'API_LOOKUP_UPPER_BOUND', 100) upper_bound = getattr(settings, 'API_LOOKUP_UPPER_BOUND', 100)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment