protected function _extractQuoteSkuData(Mage_Sales_Model_Quote $quote)
    {
        $skuData = [];
        // use getAllVisibleItems to prevent dupes due to parent config + child used both being included
        foreach ($quote->getAllVisibleItems() as $item) {
            // before item's have been saved, getAllVisible items won't properly
            // filter child items...this extra check fixes it
            if ($item->getParentItem()) {
                continue;
            }
            $skuData[$item->getSku()] = [
                'item_id' => $item->getId(),
                'managed' => Mage::helper('radial_core/quote_item')->isItemInventoried($item),
                'virtual' => $item->getIsVirtual(),
                'qty' => $item->getQty(),
            ];
        }
        return $skuData;
    }
protected function _extractQuoteSkuData(Mage_Sales_Model_Quote $quote)
    {
        $skuData = [];
        // use getAllVisibleItems to prevent dupes due to parent config + child used both being included
        foreach ($quote->getAllVisibleItems() as $item) {
            // before item's have been saved, getAllVisible items won't properly
            // filter child items...this extra check fixes it
            if ($item->getParentItem()) {
                continue;
            }
            $skuData[$item->getSku()] = [
                'item_id' => $item->getId(),
                'managed' => Mage::helper('radial_core/quote_item')->isItemInventoried($item),
                'virtual' => $item->getIsVirtual(),
                'qty' => $item->getQty(),
            ];
        }
        return $skuData;
    }
protected function _extractQuoteSkuData ( Mage_Sales_Model_Quote $ quote ) { $ skuData = [ ] ; // use getAllVisibleItems to prevent dupes due to parent config + child used both being included foreach ( $ quote -> getAllVisibleItems ( ) as $ item ) { // before item's have been saved, getAllVisible items won't properly // filter child items...this extra check fixes it if ( $ item -> getParentItem ( ) ) { continue ; } $ skuData [ $ item -> getSku ( ) ] = [ 'item_id' => $ item -> getId ( ) , 'managed' => Mage :: helper ( 'radial_core/quote_item' ) -> isItemInventoried ( $ item ) , 'virtual' => $ item -> getIsVirtual ( ) , 'qty' => $ item -> getQty ( ) , ] ; } return $ skuData ; }
Get sku and qty data for a given quote
@param  Mage_Sales_Model_Quote $quote Quote object to extract data from
@return array                         Array of 'sku' => qty
Get sku and qty data for a given quote