BookStack/resources/views/pages/revisions.blade.php
Dan Brown 031c67ba58
Reduced the memory usage, db queries and cache hits loading revisions
Updated revision listing to only fetch required fields, massively
reducing memory usage by not loading content.
This also updates user avatar handling to effectively cache the avatar
url within request to avoid re-searching from cache, which may improve
performance of others areas of the application.
This also upates handling of the revisions list view to extract table
row to its own view to break things down a bit.

For #3633
2022-08-10 17:50:35 +01:00

45 lines
1.6 KiB
PHP

@extends('layouts.simple')
@section('body')
<div class="container">
<div class="my-s">
@include('entities.breadcrumbs', ['crumbs' => [
$page->book,
$page->chapter,
$page,
$page->getUrl('/revisions') => [
'text' => trans('entities.pages_revisions'),
'icon' => 'history',
]
]])
</div>
<main class="card content-wrap">
<h1 class="list-heading">{{ trans('entities.pages_revisions') }}</h1>
@if(count($revisions) > 0)
<table class="table">
<tr>
<th width="56">{{ trans('entities.pages_revisions_number') }}</th>
<th>
{{ trans('entities.pages_name') }} / {{ trans('entities.pages_revisions_editor') }}
</th>
<th colspan="2">{{ trans('entities.pages_revisions_created_by') }} / {{ trans('entities.pages_revisions_date') }}</th>
<th>{{ trans('entities.pages_revisions_changelog') }}</th>
<th class="text-right">{{ trans('common.actions') }}</th>
</tr>
@foreach($revisions as $index => $revision)
@include('pages.parts.revision-table-row', ['revision' => $revision])
@endforeach
</table>
@else
<p>{{ trans('entities.pages_revisions_none') }}</p>
@endif
</main>
</div>
@stop