EDUCATOR-1628

Enable Video Uploads by default with course rollout flag.
This commit is contained in:
Qubad786
2017-11-10 19:19:09 +05:00
parent 3431bb7933
commit dc335a2215
10 changed files with 226 additions and 15 deletions

View File

@@ -12,6 +12,7 @@ from django.conf import settings
import requests
from lazy import lazy
from lxml import etree
from openedx.core.djangoapps.video_pipeline.models import VideoUploadsEnabledByDefault
from openedx.core.lib.license import LicenseMixin
from path import Path as path
from pytz import utc
@@ -1337,7 +1338,7 @@ class CourseDescriptor(CourseFields, SequenceDescriptor, LicenseMixin):
"""
Returns whether the video pipeline advanced setting is configured for this course.
"""
return (
return VideoUploadsEnabledByDefault.feature_enabled(course_id=self.id) or (
self.video_upload_pipeline is not None and
'course_video_upload_token' in self.video_upload_pipeline
)