mirror of
https://github.com/BookStackApp/BookStack.git
synced 2025-08-09 10:22:51 +03:00
Added Popular books list with relevant tests
This commit is contained in:
@@ -34,11 +34,22 @@
|
||||
@endif
|
||||
</div>
|
||||
<div class="col-sm-4 col-sm-offset-1">
|
||||
<div id="recents">
|
||||
@if($recents)
|
||||
<div class="margin-top large"> </div>
|
||||
<h3>Recently Viewed</h3>
|
||||
@include('partials/entity-list', ['entities' => $recents])
|
||||
@endif
|
||||
</div>
|
||||
<div class="margin-top large"> </div>
|
||||
@if($recents)
|
||||
<h3>Recently Viewed</h3>
|
||||
@include('partials/entity-list', ['entities' => $recents])
|
||||
@endif
|
||||
<div id="popular">
|
||||
<h3>Popular Books</h3>
|
||||
@if(count($popular) > 0)
|
||||
@include('partials/entity-list', ['entities' => $popular])
|
||||
@else
|
||||
<p class="text-muted">The most popular books will appear here.</p>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@@ -1,6 +1,6 @@
|
||||
|
||||
@if(count($entities) > 0)
|
||||
@foreach($entities as $entity)
|
||||
@foreach($entities as $index => $entity)
|
||||
@if($entity->isA('page'))
|
||||
@include('pages/list-item', ['page' => $entity])
|
||||
@elseif($entity->isA('book'))
|
||||
@@ -8,7 +8,11 @@
|
||||
@elseif($entity->isA('chapter'))
|
||||
@include('chapters/list-item', ['chapter' => $entity, 'hidePages' => true])
|
||||
@endif
|
||||
<hr>
|
||||
|
||||
@if($index !== count($entities) - 1)
|
||||
<hr>
|
||||
@endif
|
||||
|
||||
@endforeach
|
||||
@else
|
||||
<p class="text-muted">
|
||||
|
Reference in New Issue
Block a user