taxonomylist.html.twig 605 B

12345678910111213141516171819202122
  1. {% set taxlist = children_only is defined ? taxonomylist.getChildPagesTags() : taxonomylist.get() %}
  2. {% macro pageLinkName(text) %}
  3. {{ text|lower|replace({' ':'_'}) }}
  4. {% endmacro %}
  5. {% import _self as macro %}
  6. {% for tax,value in taxlist[taxonomy] %}
  7. <ul class="{{ macro.pageLinkName(tax) }}">
  8. {{ tax }}
  9. {% set options = { items: {'@taxonomy': {'category': tax} } } %}
  10. {% set my_collection = page.collection(options) %}
  11. {% for i in my_collection %}
  12. <li>
  13. <a id="{{i.parent.folder}}" href="{{i.url}}">{{i.title}}</a>
  14. </li>
  15. {% endfor %}
  16. </ul>
  17. {% endfor %}