Mage_CatalogRule_Model_Rule_Condition_Combine Class Reference

Inheritance diagram for Mage_CatalogRule_Model_Rule_Condition_Combine:

Mage_Rule_Model_Condition_Combine Mage_Rule_Model_Condition_Abstract Varien_Object Mage_Rule_Model_Condition_Interface

List of all members.

Public Member Functions

 __construct ()
 getNewChildSelectOptions ()
 collectValidatedAttributes ($productCollection)


Detailed Description

Definition at line 28 of file Combine.php.


Constructor & Destructor Documentation

__construct (  ) 

Constructor

By default is looking for first argument as array and assignes it as object attributes This behaviour may change in child classes

Reimplemented from Mage_Rule_Model_Condition_Combine.

Definition at line 30 of file Combine.php.

00031     {
00032         parent::__construct();
00033         $this->setType('catalogrule/rule_condition_combine');
00034     }


Member Function Documentation

collectValidatedAttributes ( productCollection  ) 

Definition at line 52 of file Combine.php.

00053     {
00054         foreach ($this->getConditions() as $condition) {
00055             $condition->collectValidatedAttributes($productCollection);
00056         }
00057         return $this;
00058     }

getNewChildSelectOptions (  ) 

Reimplemented from Mage_Rule_Model_Condition_Abstract.

Definition at line 36 of file Combine.php.

00037     {
00038         $productCondition = Mage::getModel('catalogrule/rule_condition_product');
00039         $productAttributes = $productCondition->loadAttributeOptions()->getAttributeOption();
00040         $attributes = array();
00041         foreach ($productAttributes as $code=>$label) {
00042             $attributes[] = array('value'=>'catalogrule/rule_condition_product|'.$code, 'label'=>$label);
00043         }
00044         $conditions = parent::getNewChildSelectOptions();
00045         $conditions = array_merge_recursive($conditions, array(
00046             array('value'=>'catalogrule/rule_condition_combine', 'label'=>Mage::helper('catalogrule')->__('Conditions Combination')),
00047             array('label'=>Mage::helper('catalogrule')->__('Product Attribute'), 'value'=>$attributes),
00048         ));
00049         return $conditions;
00050     }


The documentation for this class was generated from the following file:

Generated on Sat Jul 4 17:23:48 2009 for Magento by  doxygen 1.5.8