1<?php 2 3declare(strict_types=1); 4 5use Fisharebest\Webtrees\Date; 6use Fisharebest\Webtrees\Fact; 7use Fisharebest\Webtrees\I18N; 8use Fisharebest\Webtrees\Individual; 9use Illuminate\Support\Collection; 10 11/** 12 * @var int $limit_high 13 * @var int $limit_low 14 * @var Collection<int,object{individual:Individual,yahrzeit_date:Date,fact_date:Date,fact:Fact}> $yahrzeits 15 */ 16 17?> 18 19<div class="table-responsive"> 20 <table 21 class="table table-sm datatable wt-table-yahrzeits" 22 <?= view('lists/datatables-attributes') ?> 23 data-paging="<?= $yahrzeits->count() >= $limit_high ? 'true' : 'false' ?>" 24 data-filter="false" 25 data-info="false" 26 data-length-change="false" 27 data-page-length="<?= e($limit_low) ?>" 28 > 29 <thead> 30 <tr> 31 <th><?= I18N::translate('Name') ?></th> 32 <th><?= I18N::translate('Death') ?></th> 33 <th> 34 <span title="<?= I18N::translate('Anniversary') ?>"> 35 <?= view('icons/anniversary') ?> 36 </span> 37 38 </th> 39 <th><?= I18N::translate('Yahrzeit') ?></th> 40 </tr> 41 </thead> 42 <tbody> 43 44 <?php foreach ($yahrzeits as $yahrzeit) : ?> 45 <tr> 46 <td data-sort="<?= e($yahrzeit->individual->sortName()) ?>"> 47 <a href="<?= e($yahrzeit->individual->url()) ?>"> 48 <?= $yahrzeit->individual->fullName() ?> 49 <?php if ($yahrzeit->individual->alternateName()) : ?> 50 <br> 51 <?= $yahrzeit->individual->alternateName() ?> 52 <?php endif ?> 53 </a> 54 </td> 55 <td data-sort="<?= sprintf('x%07d', $yahrzeit->yahrzeit_date->julianDay()) ?>"> 56 <?= $yahrzeit->fact_date->display($yahrzeit->individual->tree()) ?> 57 </td> 58 <td data-sort="<?= sprintf('x%07d', $yahrzeit->fact->anniv) ?>"> 59 <?= I18N::number($yahrzeit->fact->anniv) ?> 60 </td> 61 <td data-sort="<?= sprintf('x%07d', $yahrzeit->yahrzeit_date->julianDay()) ?>"> 62 <?= $yahrzeit->yahrzeit_date->display($yahrzeit->individual->tree()) ?> 63 </td> 64 </tr> 65 <?php endforeach ?> 66 </tbody> 67 </table> 68</div> 69 70<script> 71 $(".wt-table-yahrzeits").dataTable(); 72</script> 73