mirror of
https://github.com/flarum/framework.git
synced 2024-11-26 02:10:09 +08:00
4679448300
- Support slug drivers for core's sluggable models, easily extends to other models - Add automated testing for affected single-model API routes - Fix nickname selection UI - Serialize slugs as `slug` attribute - Make min search length a constant
26 lines
934 B
PHP
26 lines
934 B
PHP
@inject('url', 'Flarum\Http\UrlGenerator')
|
|
|
|
<div class="container">
|
|
<h2>{{ $translator->trans('core.views.index.all_discussions_heading') }}</h2>
|
|
|
|
<ul>
|
|
@foreach ($apiDocument->data as $discussion)
|
|
<li>
|
|
<a href="{{ $url->to('forum')->route('discussion', [
|
|
'id' => $discussion->attributes->slug
|
|
]) }}">
|
|
{{ $discussion->attributes->title }}
|
|
</a>
|
|
</li>
|
|
@endforeach
|
|
</ul>
|
|
|
|
@if (isset($apiDocument->links->prev))
|
|
<a href="{{ $url->to('forum')->route('index') }}?page={{ $page - 1 }}">« {{ $translator->trans('core.views.index.previous_page_button') }}</a>
|
|
@endif
|
|
|
|
@if (isset($apiDocument->links->next))
|
|
<a href="{{ $url->to('forum')->route('index') }}?page={{ $page + 1 }}">{{ $translator->trans('core.views.index.next_page_button') }} »</a>
|
|
@endif
|
|
</div>
|