app/Module/DescendancyModule.php
public function getFamilyLi(Family $family, Individual $person, $generations = 0): string
    {
        $spouse = $family->spouse($person);
        if ($spouse) {
            $spouse_name = $spouse->getSexImage() . $spouse->fullName();
            $spouse_link = '<a href="' . e($person->url()) . '" title="' . strip_tags($person->fullName()) . '">' . view('icons/individual') . '</a>';
        } else {
            $spouse_name = '';
            $spouse_link = '';
        }

        $family_link = '<a href="' . e($family->url()) . '" title="' . strip_tags($family->fullName()) . '">' . view('icons/family') . '</a>';

        $marryear = $family->getMarriageYear();
        $marr     = $marryear ? '<i class="icon-rings"></i>' . $marryear : '';

        return
            '<li class="sb_desc_indi_li">' .
            '<a class="sb_desc_indi" href="#"><i class="plusminus icon-minus"></i>' .
            $spouse_name .
            $marr .
            '</a>' .
            $spouse_link .
            $family_link .
            '<div>' . $this->loadChildren($family, $generations) . '</div>' .
            '</li>';
    }
public function getFamilyLi(Family $family, Individual $person, $generations = 0): string
    {
        $spouse = $family->spouse($person);
        if ($spouse) {
            $spouse_name = $spouse->getSexImage() . $spouse->fullName();
            $spouse_link = '<a href="' . e($person->url()) . '" title="' . strip_tags($person->fullName()) . '">' . view('icons/individual') . '</a>';
        } else {
            $spouse_name = '';
            $spouse_link = '';
        }

        $family_link = '<a href="' . e($family->url()) . '" title="' . strip_tags($family->fullName()) . '">' . view('icons/family') . '</a>';

        $marryear = $family->getMarriageYear();
        $marr     = $marryear ? '<i class="icon-rings"></i>' . $marryear : '';

        return
            '<li class="sb_desc_indi_li">' .
            '<a class="sb_desc_indi" href="#"><i class="plusminus icon-minus"></i>' .
            $spouse_name .
            $marr .
            '</a>' .
            $spouse_link .
            $family_link .
            '<div>' . $this->loadChildren($family, $generations) . '</div>' .
            '</li>';
    }
public function getFamilyLi ( Family $ family , Individual $ person , $ generations = 0 ) : string { $ spouse = $ family -> spouse ( $ person ) ; if ( $ spouse ) { $ spouse_name = $ spouse -> getSexImage ( ) . $ spouse -> fullName ( ) ; $ spouse_link = '<a href="' . e ( $ person -> url ( ) ) . '" title="' . strip_tags ( $ person -> fullName ( ) ) . '">' . view ( 'icons/individual' ) . '</a>' ; } else { $ spouse_name = '' ; $ spouse_link = '' ; } $ family_link = '<a href="' . e ( $ family -> url ( ) ) . '" title="' . strip_tags ( $ family -> fullName ( ) ) . '">' . view ( 'icons/family' ) . '</a>' ; $ marryear = $ family -> getMarriageYear ( ) ; $ marr = $ marryear ? '<i class="icon-rings"></i>' . $ marryear : '' ; return '<li class="sb_desc_indi_li">' . '<a class="sb_desc_indi" href="#"><i class="plusminus icon-minus"></i>' . $ spouse_name . $ marr . '</a>' . $ spouse_link . $ family_link . '<div>' . $ this -> loadChildren ( $ family , $ generations ) . '</div>' . '</li>' ; }
Format a family in a list.

@param Family     $family
@param Individual $person
@param int        $generations

@return string
Format a family in a list .