Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $conf = Mage::getModel('catalog/product_type_configurable')->setProduct($currentProduct);
- $childProducts = $conf->getUsedProductCollection()
- ->addAttributeToSelect('id')
- ->addAttributeToSelect('size')
- ->addAttributeToSelect('color')
- ->addAttributeToSelect('millship')
- ->addAttributeToSelect('closeout')
- ->addAttributeToSelect('msrp')
- ->addAttributeToSelect('price')
- ->addAttributeToSelect('soldby_caseqty')
- ->addAttributeToSelect('case_qty')
- ->addAttributeToSort('size_value')
- ->addAttributeToSort('color_value')
- ->joinField(
- 'qty',
- 'cataloginventory/stock_item',
- 'qty',
- 'product_id=entity_id',
- '{{table}}.stock_id=1',
- 'left'
- );
Add Comment
Please, Sign In to add comment