Skip to content

Instantly share code, notes, and snippets.

@JustusW
Created January 9, 2015 21:44
Show Gist options
  • Save JustusW/47c9590a34fccf92ba03 to your computer and use it in GitHub Desktop.
Save JustusW/47c9590a34fccf92ba03 to your computer and use it in GitHub Desktop.
{% from tpl_container import render as container with context %}
{% call container() %}
{% from tpl_before import render as before with context %}
{{ before(compo) }}
{% for compo_obj in compo.components %}
{% if compo_obj.is_visible() %}
{% from tpl_row import render as row with context %}
{% call row() %}
{{ compo_obj.render() }}
{% endcall %}
{% endif %}
{% endfor %}
{% from tpl_after import render as after with context %}
{{ after(compo) }}
{% endcall %}
row should be this:
{% macro render(caller=None) %}
<div class="list-group-item col-sm-12">
{{ compo_obj.render() }}
</div>
{% endmacro %}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment