src/Repositories/CategoryRepository.php
/**
     * Return's an array with the root categories with the store code as key.
     *
     * @return array The root categories
     */
Return's an array with the root categories with the store code as key.
@return array The root categories
Return ' s an array with the root categories with the store code as key . @return array The root categories
public function findAllRootCategories()
    {
        $this->rootCategoriesStmt->execute();
        $rootCategories = array();
        $availableRootCategories = $this->rootCategoriesStmt->fetchAll(\PDO::FETCH_ASSOC);
        foreach ($availableRootCategories as $category) {
            $rootCategories[$category[MemberNames::CODE]] = $category;
        }
        return $rootCategories;
    }
public function findAllRootCategories ( ) { $ this -> rootCategoriesStmt -> execute ( ) ; $ rootCategories = array ( ) ; $ availableRootCategories = $ this -> rootCategoriesStmt -> fetchAll ( \ PDO :: FETCH_ASSOC ) ; foreach ( $ availableRootCategories as $ category ) { $ rootCategories [ $ category [ MemberNames :: CODE ] ] = $ category ; } return $ rootCategories ; }
Return's an array with the root categories with the store code as key.
Return ' s an array with the root categories with the store code as key .
// try to load the categories // initialize the array with the store code as key // load the available root categories // prepare the array with the root categories // append the root categories to the cache