Pagination.html 708 B

12345678910111213141516171819202122
  1. {namespace ot=Opentalent\OtTemplating\ViewHelpers}
  2. <f:comment><!-- Pagination --></f:comment>
  3. <f:comment><!--
  4. This partial expects an ApiPagedCollection
  5. named {collection} as argument
  6. --></f:comment>
  7. <f:if condition="{collection.lastPage} > 0">
  8. <div class="pagination-bar">
  9. <p><f:translate key="pages"/>:</p>
  10. <ul>
  11. <f:for each="{collection.pages}" as="page">
  12. <li class="{f:if(condition: '{page}=={collection.currentPage}', then: 'current', else: '')}">
  13. <a href="{ot:request.withPage(page: page)}">
  14. {page}
  15. </a>
  16. </li>
  17. </f:for>
  18. </ul>
  19. </div>
  20. </f:if>