source/Application/Model/Basket.php
protected function _addBundles()
    {
        $aBundles = [];
        // iterating through articles and binding bundles
        foreach ($this->_aBasketContents as $key => $oBasketItem) {
            try {
                // adding discount type bundles
                if (!$oBasketItem->isDiscountArticle() && !$oBasketItem->isBundle()) {
                    $aBundles = $this->_getItemBundles($oBasketItem, $aBundles);
                } else {
                    continue;
                }

                // adding item type bundles
                $aArtBundles = $this->_getArticleBundles($oBasketItem);
                // adding bundles to basket
                $this->_addBundlesToBasket($aArtBundles);
            } catch (\OxidEsales\Eshop\Core\Exception\NoArticleException $oEx) {
                $this->removeItem($key);
                \OxidEsales\Eshop\Core\Registry::getUtilsView()->addErrorToDisplay($oEx);
            } catch (\OxidEsales\Eshop\Core\Exception\ArticleInputException $oEx) {
                $this->removeItem($key);
                \OxidEsales\Eshop\Core\Registry::getUtilsView()->addErrorToDisplay($oEx);
            }
        }

        // adding global basket bundles
        $aBundles = $this->_getBasketBundles($aBundles);

        // adding all bundles to basket
        if ($aBundles) {
            $this->_addBundlesToBasket($aBundles);
        }
    }
protected function _addBundles()
    {
        $aBundles = [];
        // iterating through articles and binding bundles
        foreach ($this->_aBasketContents as $key => $oBasketItem) {
            try {
                // adding discount type bundles
                if (!$oBasketItem->isDiscountArticle() && !$oBasketItem->isBundle()) {
                    $aBundles = $this->_getItemBundles($oBasketItem, $aBundles);
                } else {
                    continue;
                }

                // adding item type bundles
                $aArtBundles = $this->_getArticleBundles($oBasketItem);
                // adding bundles to basket
                $this->_addBundlesToBasket($aArtBundles);
            } catch (\OxidEsales\Eshop\Core\Exception\NoArticleException $oEx) {
                $this->removeItem($key);
                \OxidEsales\Eshop\Core\Registry::getUtilsView()->addErrorToDisplay($oEx);
            } catch (\OxidEsales\Eshop\Core\Exception\ArticleInputException $oEx) {
                $this->removeItem($key);
                \OxidEsales\Eshop\Core\Registry::getUtilsView()->addErrorToDisplay($oEx);
            }
        }

        // adding global basket bundles
        $aBundles = $this->_getBasketBundles($aBundles);

        // adding all bundles to basket
        if ($aBundles) {
            $this->_addBundlesToBasket($aBundles);
        }
    }
protected function _addBundles ( ) { $ aBundles = [ ] ; // iterating through articles and binding bundles foreach ( $ this -> _aBasketContents as $ key => $ oBasketItem ) { try { // adding discount type bundles if ( ! $ oBasketItem -> isDiscountArticle ( ) && ! $ oBasketItem -> isBundle ( ) ) { $ aBundles = $ this -> _getItemBundles ( $ oBasketItem , $ aBundles ) ; } else { continue ; } // adding item type bundles $ aArtBundles = $ this -> _getArticleBundles ( $ oBasketItem ) ; // adding bundles to basket $ this -> _addBundlesToBasket ( $ aArtBundles ) ; } catch ( \ OxidEsales \ Eshop \ Core \ Exception \ NoArticleException $ oEx ) { $ this -> removeItem ( $ key ) ; \ OxidEsales \ Eshop \ Core \ Registry :: getUtilsView ( ) -> addErrorToDisplay ( $ oEx ) ; } catch ( \ OxidEsales \ Eshop \ Core \ Exception \ ArticleInputException $ oEx ) { $ this -> removeItem ( $ key ) ; \ OxidEsales \ Eshop \ Core \ Registry :: getUtilsView ( ) -> addErrorToDisplay ( $ oEx ) ; } } // adding global basket bundles $ aBundles = $ this -> _getBasketBundles ( $ aBundles ) ; // adding all bundles to basket if ( $ aBundles ) { $ this -> _addBundlesToBasket ( $ aBundles ) ; } }
Iterates through basket contents and adds bundles to items + adds
global basket bundles
Iterates through basket contents and adds bundles to items + adds global basket bundles