src/Utils/Breadcrumb.php
public function addGroup(
        GroupChecker $groupChecker,
        $firstLabel = null,
        $route = null,
        array $routeArgs = null
    ) {
        $routeArgs = (array) $routeArgs;
        if (empty($route)) {
            $base = Base::instance();
            $routeArgs = ($base['PARAMS'] ?: []) + ($base['GET'] ?: []);
            $route = $base['ALIAS'];
            unset($routeArgs[0]);
        }

        $i = 0;
        foreach ($groupChecker->getGroups() as $label => $group) {
            if ($i === 0 && $firstLabel) {
                $label = $firstLabel;
            }

            $this->add($route, ['group' => $group] + $routeArgs, $label);
            $i++;

            if ($groupChecker->isEqual($group)) {
                break;
            }
        }

        return $this;
    }
public function addGroup(
        GroupChecker $groupChecker,
        $firstLabel = null,
        $route = null,
        array $routeArgs = null
    ) {
        $routeArgs = (array) $routeArgs;
        if (empty($route)) {
            $base = Base::instance();
            $routeArgs = ($base['PARAMS'] ?: []) + ($base['GET'] ?: []);
            $route = $base['ALIAS'];
            unset($routeArgs[0]);
        }

        $i = 0;
        foreach ($groupChecker->getGroups() as $label => $group) {
            if ($i === 0 && $firstLabel) {
                $label = $firstLabel;
            }

            $this->add($route, ['group' => $group] + $routeArgs, $label);
            $i++;

            if ($groupChecker->isEqual($group)) {
                break;
            }
        }

        return $this;
    }
public function addGroup ( GroupChecker $ groupChecker , $ firstLabel = null , $ route = null , array $ routeArgs = null ) { $ routeArgs = ( array ) $ routeArgs ; if ( empty ( $ route ) ) { $ base = Base :: instance ( ) ; $ routeArgs = ( $ base [ 'PARAMS' ] ? : [ ] ) + ( $ base [ 'GET' ] ? : [ ] ) ; $ route = $ base [ 'ALIAS' ] ; unset ( $ routeArgs [ 0 ] ) ; } $ i = 0 ; foreach ( $ groupChecker -> getGroups ( ) as $ label => $ group ) { if ( $ i === 0 && $ firstLabel ) { $ label = $ firstLabel ; } $ this -> add ( $ route , [ 'group' => $ group ] + $ routeArgs , $ label ) ; $ i ++ ; if ( $ groupChecker -> isEqual ( $ group ) ) { break ; } } return $ this ; }
Add Group to breadcrumb
@param GroupChecker $groupChecker
@param string       $firstLabel
@param string       $route
@param array|null   $routeArgs
Add Group to breadcrumb