Commit 8f4e7689 by E. Kolpakov

Adding ability to wrap children

parent 25063576
......@@ -437,7 +437,13 @@ class StudioContainerWithNestedXBlocksMixin(StudioContainerXBlockMixin):
"""
fragment = Fragment()
if 'wrap_children' in context:
fragment.add_content(context['wrap_children']['head'])
self.render_children(context, fragment, can_reorder=True, can_add=False)
if 'wrap_children' in context:
fragment.add_content(context['wrap_children']['tail'])
fragment.add_content(
loader.render_template('templates/add_buttons.html', {'child_blocks': self.get_nested_blocks_spec()})
)
......
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