DEPR-48 Remove CourseTalk integration & Course Reviews functionality
This commit is contained in:
@@ -11,9 +11,8 @@ from django.utils.translation import ugettext as _
|
||||
from lms.djangoapps.courseware.courses import get_course_by_id
|
||||
from common.djangoapps.student.models import CourseEnrollment
|
||||
|
||||
from . import DISABLE_UNIFIED_COURSE_TAB_FLAG, SHOW_REVIEWS_TOOL_FLAG
|
||||
from . import DISABLE_UNIFIED_COURSE_TAB_FLAG
|
||||
from .course_tools import CourseTool
|
||||
from .views.course_reviews import CourseReviewsModuleFragmentView
|
||||
from .views.course_updates import CourseUpdatesFragmentView
|
||||
|
||||
|
||||
@@ -60,45 +59,3 @@ class CourseUpdatesTool(CourseTool):
|
||||
Returns the URL for this tool for the specified course key.
|
||||
"""
|
||||
return reverse('openedx.course_experience.course_updates', args=[course_key])
|
||||
|
||||
|
||||
class CourseReviewsTool(CourseTool):
|
||||
"""
|
||||
The course reviews tool.
|
||||
"""
|
||||
@classmethod
|
||||
def analytics_id(cls):
|
||||
"""
|
||||
Returns an id to uniquely identify this tool in analytics events.
|
||||
"""
|
||||
return 'edx.reviews'
|
||||
|
||||
@classmethod
|
||||
def title(cls):
|
||||
"""
|
||||
Returns the title of this tool.
|
||||
"""
|
||||
return _('Reviews')
|
||||
|
||||
@classmethod
|
||||
def icon_classes(cls):
|
||||
"""
|
||||
Returns icon classes needed to represent this tool.
|
||||
"""
|
||||
return 'fa fa-star'
|
||||
|
||||
@classmethod
|
||||
def is_enabled(cls, request, course_key):
|
||||
"""
|
||||
Returns True if this tool is enabled for the specified course key.
|
||||
"""
|
||||
if not SHOW_REVIEWS_TOOL_FLAG.is_enabled(course_key):
|
||||
return False
|
||||
return CourseReviewsModuleFragmentView.is_configured()
|
||||
|
||||
@classmethod
|
||||
def url(cls, course_key):
|
||||
"""
|
||||
Returns the URL for this tool for the specified course key.
|
||||
"""
|
||||
return reverse('openedx.course_experience.course_reviews', args=[course_key])
|
||||
|
||||
Reference in New Issue
Block a user