$individuals * @var bool $sosa * @var Tree $tree */ // lists requires a unique ID in case there are multiple lists per page $table_id = 'table-indi-' . Uuid::uuid4()->toString(); $today_jd = Registry::timestampFactory()->now()->julianDay(); $hundred_years_ago = Registry::timestampFactory()->now()->subtractYears(100)->julianDay(); $unique_indis = []; // Don't double-count indis with multiple names. $show_estimated_dates = (bool) $tree->getPreference('SHOW_EST_LIST_DATES'); $today = new Date(strtoupper(date('d M Y'))); $module = app(ModuleService::class) ->findByComponent(ModuleChartInterface::class, $tree, Auth::user()) ->first(static function (ModuleInterface $module) { return $module instanceof RelationshipsChartModule; }); ?> getPreference('MAX_ALIVE_AGE'); // Initialise chart data $deat_by_age = []; for ($age = 0; $age <= $max_age; $age++) { $deat_by_age[$age]['M'] = 0; $deat_by_age[$age]['F'] = 0; $deat_by_age[$age]['U'] = 0; } $birt_by_decade = []; $deat_by_decade = []; for ($year = 1400; $year < 2050; $year += 10) { $birt_by_decade[$year]['M'] = 0; $birt_by_decade[$year]['F'] = 0; $birt_by_decade[$year]['U'] = 0; $deat_by_decade[$year]['M'] = 0; $deat_by_decade[$year]['F'] = 0; $deat_by_decade[$year]['U'] = 0; } $birthData = [ [ [ 'label' => I18N::translate('Century'), 'type' => 'date', ], [ 'label' => I18N::translate('Males'), 'type' => 'number', ], [ 'label' => I18N::translate('Females'), 'type' => 'number', ], ] ]; $deathData = [ [ [ 'label' => I18N::translate('Century'), 'type' => 'date', ], [ 'label' => I18N::translate('Males'), 'type' => 'number', ], [ 'label' => I18N::translate('Females'), 'type' => 'number', ], ] ]; $deathAgeData = [ [ I18N::translate('Age'), I18N::translate('Males'), I18N::translate('Females'), I18N::translate('Average age'), ] ]; ?>
> $individual) : ?> getEstimatedBirthDate(); ?> gregorianYear() >= 1550 && $birth_dates[0]->gregorianYear() < 2030 && !isset($unique_indis[$individual->xref()])) : ?> gregorianYear() / 10) * 10][$individual->sex()]; ?> getAllDeathDates() ?> gregorianYear() >= 1550 && $death_dates[0]->gregorianYear() < 2030 && !isset($unique_indis[$individual->xref()])) : ?> gregorianYear() / 10) * 10][$individual->sex()]; ?> xref()]) && $age->ageYears() >= 0 && $age->ageYears() <= $max_age) : ?> ageYears()][$individual->sex()] ?> xref()] = true ?>
getAllNames() as $num => $name) : ?> getPrimaryName()) : ?> $individual->sex()]) ?>
$individual]) ?>
getAllBirthDates(); ?> $birth_date) : ?> display($tree, null, true) ?>
display($tree, null, true) ?>
ageYearsString() ?> getAllBirthPlaces() as $n => $birth_place) : ?> shortName(true) ?>
numberOfChildren()) ?> $death_date) : ?> display($tree, null, true) ?>
getEstimatedDeathDate()->minimumDate()->minimumJulianDay() < $today_jd) : ?> getEstimatedDeathDate()->display($tree, null, true) ?>
ageYearsString() ?> ageYearsString() ?> getAllDeathPlaces() as $n => $death_place) : ?> shortName(true) ?>
$individual->lastChangeTimestamp()]) ?>