refactor: remove unused TabsEditingMixin
This commit is contained in:
@@ -43,25 +43,3 @@ class EditingMixin(EditingFields, MakoTemplateBlockBase):
|
||||
# Add our specific template information (the raw data body)
|
||||
_context.update({'data': self.data})
|
||||
return _context
|
||||
|
||||
|
||||
class TabsEditingMixin(EditingFields, MakoTemplateBlockBase):
|
||||
"""
|
||||
Module that provides a raw editing view of its data and children. It does not
|
||||
perform any validation on its definition---just passes it along to the browser.
|
||||
|
||||
This class is intended to be used as a mixin.
|
||||
"""
|
||||
|
||||
mako_template = "widgets/tabs-aggregator.html"
|
||||
js_module_name = "TabsEditingDescriptor"
|
||||
tabs = []
|
||||
|
||||
def get_context(self):
|
||||
_context = MakoTemplateBlockBase.get_context(self)
|
||||
_context.update({
|
||||
'tabs': self.tabs,
|
||||
'html_id': self.location.html_id(), # element_id
|
||||
'data': self.data,
|
||||
})
|
||||
return _context
|
||||
|
||||
@@ -35,8 +35,9 @@ from openedx.core.djangoapps.video_pipeline.config.waffle import DEPRECATE_YOUTU
|
||||
from openedx.core.lib.cache_utils import request_cached
|
||||
from openedx.core.lib.license import LicenseMixin
|
||||
from xmodule.contentstore.content import StaticContent
|
||||
from xmodule.editing_module import EditingMixin, TabsEditingMixin
|
||||
from xmodule.editing_module import EditingMixin
|
||||
from xmodule.exceptions import NotFoundError
|
||||
from xmodule.mako_module import MakoTemplateBlockBase
|
||||
from xmodule.modulestore.inheritance import InheritanceKeyValueStore, own_metadata
|
||||
from xmodule.raw_module import EmptyDataRawMixin
|
||||
from xmodule.validation import StudioValidation, StudioValidationMessage
|
||||
@@ -112,9 +113,8 @@ EXPORT_IMPORT_STATIC_DIR = 'static'
|
||||
@XBlock.needs('mako', 'user')
|
||||
class VideoBlock(
|
||||
VideoFields, VideoTranscriptsMixin, VideoStudioViewHandlers, VideoStudentViewHandlers,
|
||||
TabsEditingMixin, EmptyDataRawMixin, XmlMixin, EditingMixin,
|
||||
XModuleToXBlockMixin, HTMLSnippet, ResourceTemplates, XModuleMixin,
|
||||
LicenseMixin):
|
||||
EmptyDataRawMixin, XmlMixin, EditingMixin, XModuleToXBlockMixin, HTMLSnippet,
|
||||
ResourceTemplates, XModuleMixin, LicenseMixin):
|
||||
"""
|
||||
XML source example:
|
||||
<video show_captions="true"
|
||||
@@ -146,6 +146,9 @@ class VideoBlock(
|
||||
}
|
||||
]
|
||||
|
||||
mako_template = "widgets/tabs-aggregator.html"
|
||||
js_module_name = "TabsEditingDescriptor"
|
||||
|
||||
uses_xmodule_styles_setup = True
|
||||
requires_per_student_anonymous_id = True
|
||||
|
||||
@@ -793,7 +796,12 @@ class VideoBlock(
|
||||
"""
|
||||
Extend context by data for transcript basic tab.
|
||||
"""
|
||||
_context = super().get_context()
|
||||
_context = MakoTemplateBlockBase.get_context(self)
|
||||
_context.update({
|
||||
'tabs': self.tabs,
|
||||
'html_id': self.location.html_id(), # element_id
|
||||
'data': self.data,
|
||||
})
|
||||
|
||||
metadata_fields = copy.deepcopy(self.editable_metadata_fields)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user