Deprecate Contentstore for Video Component Preview LMS/CMS

EDUCATOR-1756
This commit is contained in:
muhammad-ammar
2018-03-15 11:56:54 +05:00
parent 8c66d86704
commit d0cd247d08
9 changed files with 116 additions and 157 deletions

View File

@@ -217,7 +217,7 @@ def video_summary(video_profiles, course_id, video_descriptor, request, local_ca
# Transcripts...
feature_enabled = is_val_transcript_feature_enabled_for_course(course_id)
transcripts_info = video_descriptor.get_transcripts_info(include_val_transcripts=feature_enabled)
transcripts_info = video_descriptor.get_transcripts_info()
transcript_langs = video_descriptor.available_translations(
transcripts=transcripts_info,
include_val_transcripts=feature_enabled

View File

@@ -124,7 +124,7 @@ class VideoTranscripts(generics.RetrieveAPIView):
video_descriptor = modulestore().get_item(usage_key)
feature_enabled = is_val_transcript_feature_enabled_for_course(usage_key.course_key)
try:
transcripts = video_descriptor.get_transcripts_info(include_val_transcripts=feature_enabled)
transcripts = video_descriptor.get_transcripts_info()
content, filename, mimetype = video_descriptor.get_transcript(transcripts, lang=lang)
except (ValueError, NotFoundError):
# Fallback mechanism for edx-val transcripts