xref: /webtrees/resources/views/statistics/families/top10-list-age.phtml (revision 8add1155cb77caede54752196ff44696d1346431)
1*8add1155SRico Sonntag<?php
2*8add1155SRico Sonntagdeclare(strict_types=1);
3*8add1155SRico Sonntag
4*8add1155SRico Sonntaguse Fisharebest\Webtrees\Family;
5*8add1155SRico Sonntaguse Fisharebest\Webtrees\I18N;
6*8add1155SRico Sonntaguse Fisharebest\Webtrees\Individual;
7*8add1155SRico Sonntag
8*8add1155SRico Sonntag/* @var array      $records */
9*8add1155SRico Sonntag/* @var Family     $family */
10*8add1155SRico Sonntag/* @var Individual $child1 */
11*8add1155SRico Sonntag/* @var Individual $child2 */
12*8add1155SRico Sonntag?>
13*8add1155SRico Sonntag
14*8add1155SRico Sonntag<ul class="list-group list-group-flush">
15*8add1155SRico Sonntag    <?php foreach ($records as $record): ?>
16*8add1155SRico Sonntag        <?php $child1 = $record['child1']; ?>
17*8add1155SRico Sonntag        <?php $child2 = $record['child2']; ?>
18*8add1155SRico Sonntag        <?php $family = $record['family']; ?>
19*8add1155SRico Sonntag        <li class="list-group-item d-flex justify-content-between align-items-center">
20*8add1155SRico Sonntag            <span>
21*8add1155SRico Sonntag                <a href="<?= e($child2->url()) ?>"><?= $child2->getFullName() ?></a> <?= I18N::translate('and') ?> <a href="<?= e($child1->url()) ?>"><?= $child1->getFullName() ?></a>
22*8add1155SRico Sonntag                <br>
23*8add1155SRico Sonntag                <a href="<?= e($family->url()) ?>">[<?= I18N::translate('View this family') ?>]</a>
24*8add1155SRico Sonntag            </span>
25*8add1155SRico Sonntag            <span class="badge badge-secondary badge-pill ml-3"><?= $record['age'] ?></span>
26*8add1155SRico Sonntag        </li>
27*8add1155SRico Sonntag    <?php endforeach; ?>
28*8add1155SRico Sonntag</ul>
29