![]() System : Linux absol.cf 5.4.0-198-generic #218-Ubuntu SMP Fri Sep 27 20:18:53 UTC 2024 x86_64 User : www-data ( 33) PHP Version : 7.4.33 Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare, Directory : /var/www/html/webtrees/resources/views/ |
Upload File : |
<?php declare(strict_types=1); use Fisharebest\Webtrees\Family; use Fisharebest\Webtrees\Http\RequestHandlers\AddChildToFamilyPage; use Fisharebest\Webtrees\Http\RequestHandlers\ReorderChildrenPage; use Fisharebest\Webtrees\I18N; /** * @var Family $family */ ?> <div class="align-self-center"> <div class="badge bg-secondary m-2"> <?php if ($family->children()->count() === 0) : ?> <?= I18N::translate('No children') ?> <?php else : ?> <?= I18N::plural('%s child', '%s children', $family->children()->count(), I18N::number($family->children()->count())) ?> <?php endif ?> </div> <?php foreach ($family->children() as $n => $child) : ?> <div class="d-flex"> <?= view('chart-box', ['individual' => $child]) ?> <div class="wt-chart-horizontal-spacer"> <?php if ($family->children()->count() === 1) : ?> <div class="wt-chart-horizontal-line"></div> <?php elseif ($n === 0) : ?> <div class="wt-chart-horizontal-first-child"></div> <?php elseif ($n + 1 === $family->children()->count()) : ?> <div class="wt-chart-horizontal-last-child"></div> <?php else : ?> <div class="wt-chart-horizontal-middle-child"><div class="wt-chart-horizontal-line"></div></div> <?php endif ?> </div> </div> <?php endforeach ?> <?php if ($family->canEdit()) : ?> <div class="wt-chart-box"> <a class="btn btn-link" href="<?= e(route(AddChildToFamilyPage::class, ['tree' => $family->tree()->name(), 'xref' => $family->xref(), 'sex' => 'M'])) ?>"> <?= I18N::translate('Add a son') ?> </a> | <a class="btn btn-link" href="<?= e(route(AddChildToFamilyPage::class, ['tree' => $family->tree()->name(), 'xref' => $family->xref(), 'sex' => 'F'])) ?>"> <?= I18N::translate('Add a daughter') ?> </a> <br> <?php if ($family->numberOfChildren() > 1) : ?> <a class="btn btn-link" href="<?= e(route(ReorderChildrenPage::class, ['tree' => $family->tree()->name(), 'xref' => $family->xref()])) ?>"> <?= I18N::translate('Re-order children') ?> </a> <?php endif ?> </div> <?php endif ?> </div> <?php if ($family->children()->count() !== 1) : ?> <div class="wt-chart-horizontal-spacer"> <div class="wt-chart-horizontal-line"></div> </div> <?php endif ?>