Commit dcb18910 authored by Laury Bueno's avatar Laury Bueno
Browse files

[Stats] Add Classroom to the list of actionable models

parent 684faa41
......@@ -10,6 +10,7 @@ class CoursesStatsConfig(AppConfig):
from actstream import registry
registry.register(get_user_model())
registry.register('courses.Course')
registry.register('courses.classroom.Classroom')
registry.register('stats.AccessibleArea')
registry.register('discussion.Topic')
registry.register('discussion.Forum')
......@@ -7,6 +7,7 @@ from discussion.models import Forum, Topic
from .serializers import UserActionsSerializer, UserAccessSerializer
from .models import AccessibleArea
from ..models import Course
from ..classroom.models import Classroom
class UserActionsView(views.APIView):
......@@ -16,6 +17,7 @@ class UserActionsView(views.APIView):
# Only models from this list are registered to be used on actions
allowed_models = {
'Course': Course,
'Classroom': Classroom,
'Topic': Topic,
'Forum': Forum,
}
......
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