$locations * @var Tree $tree */ ?> join('link', static function (JoinClause $join): void { $join->on('l_from', '=', 'i_id'); $join->on('l_file', '=', 'i_file'); }) ->where('l_type', '=', '_LOC') ->where('l_file', '=', $tree->id()) ->groupBy(['l_to']) ->select(['l_to', new Expression('COUNT(*) AS total')]) ->pluck('total', 'l_to') ->map(static fn (string $n) => (int) $n) ->all(); $count_families = DB::table('families') ->join('link', static function (JoinClause $join): void { $join->on('l_from', '=', 'f_id'); $join->on('l_file', '=', 'f_file'); }) ->where('l_type', '=', '_LOC') ->where('l_file', '=', $tree->id()) ->groupBy(['l_to']) ->select(['l_to', new Expression('COUNT(*) AS total')]) ->pluck('total', 'l_to') ->map(static fn (string $n) => (int) $n) ->all(); ?>
= I18N::translate('Location') ?> | = I18N::translate('Individuals') ?> | = I18N::translate('Families') ?> | = I18N::translate('Last change') ?> |
---|---|---|---|
= $location->fullName() ?> | = I18N::number($count_individuals[$location->xref()] ?? 0) ?> | = I18N::number($count_families[$location->xref()] ?? 0) ?> | = view('components/datetime', ['timestamp' => $location->lastChangeTimestamp()]) ?> |