filter.html.twig 1.0 KB

1234567891011121314151617181920212223242526272829303132333435
  1. {% set options = { items: {'@page.children':blog.url}, 'order': {'by': 'folder', 'dir': 'asc'}} %}
  2. {% set my_collection = blog.collection(options) %}
  3. <ul>
  4. {% for child in collection %}
  5. {% if child.template == "default" or child.template == "archives" or child.template == "modular" or child.template == "form"%}
  6. <li><a href="{{child.url}}">{{child.title}}</a></li>
  7. {% endif %}
  8. {% endfor %}
  9. {% if blog.template == 'blog' and blog.title != "News" %}
  10. <a href="{{blog.url}}">Current + Upcomming</a>
  11. {% endif %}
  12. {% if blog.template == "default" %}
  13. {% for item in my_collection %}
  14. <a href= "{{item.url}}" >{{item.title}}</a>
  15. {% endfor %}
  16. {% endif %}
  17. {% if blog.title == "News" %}
  18. <li><a href="{{blog.url}}">{{blog.title}}</a></li>
  19. {% endif %}
  20. {% if blog.parent.template == "blog" %}
  21. <li>
  22. <a href="{{blog.parent.url}}">Current + Upcomming</a>
  23. </li>
  24. <li>
  25. <a href="{{blog.url}}">{{blog.title}}</a>
  26. </li>
  27. {{blog.parent.template}}
  28. {% endif %}
  29. </ul>