Last active
December 14, 2015 01:09
-
-
Save COil/5004477 to your computer and use it in GitHub Desktop.
Twig C extension benchmark 2/2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<li> | |
{% if field.is_selected is defined %} | |
<input type="checkbox" value="1"{{ html_checked(selected) }} name="{{ name }}" id="{{ id }}" class="{{ class }}"> | |
<label for="{{ id }}">{{ field.element }}</label> | |
{% endif %} | |
{% if field.choices is defined %} | |
<ul> | |
{% for rankLevel2, subField in field.choices %} | |
{% include 'ThemesBundle:Search:_group_tree.html.twig' with { | |
'form': form, | |
'widget': widget, | |
'rankLevel1': rankLevel1, | |
'rankLevel2': rankLevel2, | |
'field': subField, | |
'parentSelected': field.is_selected, | |
'level': level + 1 | |
} %} | |
{% endfor %} | |
</ul> | |
{% endif %} | |
</li> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment