1<?php use Fisharebest\Webtrees\I18N; ?> 2<?php use Fisharebest\Webtrees\View; ?> 3 4<div class="table-responsive"> 5 <table class="table table-sm datatables wt-table-changes" data-filter="false" data-info="false" data-paging="false"> 6 <thead> 7 <tr> 8 <th class="wt-side-block-optional"> 9 <span class="sr-only"> 10 <?= I18N::translate('Type') ?> 11 </span> 12 </th> 13 <th> 14 <?= I18N::translate('Record') ?> 15 </th> 16 <th> 17 <?= I18N::translate('Last change') ?> 18 </th> 19 <?php if ($show_user) : ?> 20 <th> 21 <?= I18N::translate('User') ?> 22 </th> 23 <?php endif ?> 24 </tr> 25 </thead> 26 <tbody> 27 <?php foreach ($records as $record) : ?> 28 <tr> 29 <td data-sort="<?= $record::RECORD_TYPE ?>" class="text-centre wt-side-block-optional"> 30 <?php if ($record::RECORD_TYPE === 'INDI') : ?> 31 <?= view('icons/individual') ?> 32 <span class="sr-only"><?= I18N::translate('Individual') ?></span> 33 <?php elseif ($record::RECORD_TYPE === 'FAM') : ?> 34 <?= view('icons/family') ?> 35 <span class="sr-only"><?= I18N::translate('Family') ?></span> 36 <?php elseif ($record::RECORD_TYPE === 'OBJE') : ?> 37 <?= view('icons/media') ?> 38 <span class="sr-only"><?= I18N::translate('Media') ?></span> 39 <?php elseif ($record::RECORD_TYPE === 'NOTE') : ?> 40 <?= view('icons/note') ?> 41 <span class="sr-only"><?= I18N::translate('Note') ?></span> 42 <?php elseif ($record::RECORD_TYPE === 'SOUR') : ?> 43 <?= view('icons/source') ?> 44 <span class="sr-only"><?= I18N::translate('Source') ?></span> 45 <?php elseif ($record::RECORD_TYPE === 'SUBM') : ?> 46 <?= view('icons/submitter') ?> 47 <span class="sr-only"><?= I18N::translate('Submitter') ?></span> 48 <?php elseif ($record::RECORD_TYPE === 'REPO') : ?> 49 <?= view('icons/repository') ?> 50 <span class="sr-only"><?= I18N::translate('Repository') ?></span> 51 <?php endif ?> 52 </td> 53 54 <td data-sort="<?= e($record->sortName()) ?>"> 55 <a href="<?= e($record->url()) ?>"><?= $record->fullName() ?></a> 56 </td> 57 58 <td data-sort="<?= $record->lastChangeTimestamp()->unix() ?>"> 59 <?= view('components/datetime', ['timestamp' => $record->lastChangeTimestamp()]) ?> 60 </td> 61 62 <?php if ($show_user) : ?> 63 <td> 64 <?= e($record->lastChangeUser()) ?> 65 </td> 66 <?php endif ?> 67 </tr> 68 <?php endforeach ?> 69 </tbody> 70 </table> 71</div> 72 73<?php View::push('javascript') ?> 74<script> 75 $(".wt-table-changes").dataTable(); 76</script> 77<?php View::endpush() ?> 78