Add pagination link for previous page

This commit is contained in:
Franz Liedke 2018-01-10 20:35:07 +01:00
parent 6913e8f0f8
commit 8c470954eb
No known key found for this signature in database
GPG Key ID: 9A0231A879B055F4

View File

@ -16,6 +16,10 @@ $url = app('Flarum\Http\UrlGenerator');
@endforeach
</ul>
@if (isset($document->links->prev))
<a href="{{ $url->to('forum')->route('index') }}?page={{ $page - 1 }}">&laquo; {{ $translator->trans('core.views.index.previous_page_button') }}</a>
@endif
@if (isset($document->links->next))
<a href="{{ $url->to('forum')->route('index') }}?page={{ $page + 1 }}">{{ $translator->trans('core.views.index.next_page_button') }} &raquo;</a>
@endif