join('link', function (JoinClause $join): void { $join->on('l_from', '=', 'i_id'); $join->on('l_file', '=', 'i_file'); }) ->where('l_type', '=', 'SOUR') ->where('l_file', '=', $tree->id()) ->groupBy('l_to') ->select(['l_to', DB::raw('COUNT(*) AS total')]) ->pluck('total', 'l_to') ->all(); $count_families = DB::table('families') ->join('link', function (JoinClause $join): void { $join->on('l_from', '=', 'f_id'); $join->on('l_file', '=', 'f_file'); }) ->where('l_type', '=', 'SOUR') ->where('l_file', '=', $tree->id()) ->groupBy('l_to') ->select(['l_to', DB::raw('COUNT(*) AS total')]) ->pluck('total', 'l_to') ->all(); $count_media = DB::table('media') ->join('link', function (JoinClause $join): void { $join->on('l_from', '=', 'm_id'); $join->on('l_file', '=', 'm_file'); }) ->where('l_type', '=', 'SOUR') ->where('l_file', '=', $tree->id()) ->groupBy('l_to') ->select(['l_to', DB::raw('COUNT(*) AS total')]) ->pluck('total', 'l_to') ->all(); $count_notes = DB::table('other') ->join('link', function (JoinClause $join): void { $join->on('l_from', '=', 'o_id'); $join->on('l_file', '=', 'o_file'); }) ->where('o_type', '=', 'NOTE') ->where('l_type', '=', 'SOUR') ->where('l_file', '=', $tree->id()) ->groupBy('l_to') ->select(['l_to', DB::raw('COUNT(*) AS total')]) ->pluck('total', 'l_to') ->all(); ?> data-auto-width="false" data-columns=" array_sum($count_individuals) > 0], ['visible' => array_sum($count_families) > 0], ['visible' => array_sum($count_media) > 0], ['visible' => array_sum($count_notes) > 0], ['visible' => (bool) $tree->getPreference('SHOW_LAST_CHANGE'), 'searchable' => false], ])) ?>" >
fullName() ?> facts(['AUTH'])->isNotEmpty() ? $source->facts(['AUTH'])->first()->value() : '') ?> xref()] ?? 0) ?> xref()] ?? 0) ?> xref()] ?? 0) ?> xref()] ?? 0) ?> $source->lastChangeTimestamp()]) ?>