2018-05-10 05:35:18 +02:00
|
|
|
|
2018-12-09 17:51:31 +01:00
|
|
|
<div class="content-wrap card">
|
2019-02-03 14:45:45 +01:00
|
|
|
<div class="grid half v-center">
|
2018-12-01 22:28:21 +01:00
|
|
|
<h1 class="list-heading">{{ trans('entities.books') }}</h1>
|
|
|
|
<div class="text-right">
|
|
|
|
|
2019-02-03 14:45:45 +01:00
|
|
|
@include('partials.sort', ['options' => $sortOptions, 'order' => $order, 'sort' => $sort, 'type' => 'books'])
|
2018-12-01 22:28:21 +01:00
|
|
|
|
|
|
|
</div>
|
|
|
|
</div>
|
2018-05-10 05:35:18 +02:00
|
|
|
@if(count($books) > 0)
|
2018-12-07 19:33:32 +01:00
|
|
|
@if($view === 'list')
|
2018-12-01 17:29:57 +01:00
|
|
|
<div class="entity-list">
|
|
|
|
@foreach($books as $book)
|
2018-12-09 17:51:31 +01:00
|
|
|
@include('books.list-item', ['book' => $book])
|
2018-12-01 17:29:57 +01:00
|
|
|
@endforeach
|
|
|
|
</div>
|
2018-05-10 05:35:18 +02:00
|
|
|
@else
|
|
|
|
<div class="grid third">
|
|
|
|
@foreach($books as $key => $book)
|
2018-12-01 17:29:57 +01:00
|
|
|
@include('books.grid-item', ['book' => $book])
|
2018-05-10 05:35:18 +02:00
|
|
|
@endforeach
|
|
|
|
</div>
|
|
|
|
@endif
|
2018-12-09 17:51:31 +01:00
|
|
|
<div>
|
|
|
|
{!! $books->render() !!}
|
|
|
|
</div>
|
2018-05-10 05:35:18 +02:00
|
|
|
@else
|
|
|
|
<p class="text-muted">{{ trans('entities.books_empty') }}</p>
|
|
|
|
@if(userCan('books-create-all'))
|
2018-08-27 15:18:09 +02:00
|
|
|
<a href="{{ baseUrl("/create-book") }}" class="text-pos">@icon('edit'){{ trans('entities.create_now') }}</a>
|
2018-05-10 05:35:18 +02:00
|
|
|
@endif
|
|
|
|
@endif
|
|
|
|
</div>
|