/**
  * Get inherited conditions selectors
  *
  * @return array
  */
 public function getNewChildSelectOptions()
 {
     $children = array_merge_recursive(parent::getNewChildSelectOptions(), array(array('value' => $this->getType(), 'label' => Mage::helper('rule')->__('Conditions Combination'))));
     if ($this->getDateConditions()) {
         $children = array_merge_recursive($children, array(array('value' => array(Mage::getModel('enterprise_customersegment/segment_condition_uptodate')->getNewChildSelectOptions(), Mage::getModel('enterprise_customersegment/segment_condition_daterange')->getNewChildSelectOptions()), 'label' => Mage::helper('enterprise_customersegment')->__('Date Ranges'))));
     }
     $children = array_merge_recursive($children, array(Mage::getModel('enterprise_customersegment/segment_condition_product_attributes')->getNewChildSelectOptions()));
     return $children;
 }
 /**
  * Get list of available subconditions
  *
  * @return array
  */
 public function getNewChildSelectOptions()
 {
     $prefix = 'enterprise_customersegment/segment_condition_customer_address_';
     $result = array_merge_recursive(parent::getNewChildSelectOptions(), array(array('value' => $this->getType(), 'label' => Mage::helper('enterprise_customersegment')->__('Conditions Combination')), Mage::getModel($prefix . 'default')->getNewChildSelectOptions(), Mage::getModel($prefix . 'attributes')->getNewChildSelectOptions()));
     return $result;
 }
Exemplo n.º 3
0
 /**
  * Get inherited conditions selectors
  *
  * @return array
  */
 public function getNewChildSelectOptions()
 {
     $conditions = array(array('value' => 'enterprise_customersegment/segment_condition_combine', 'label' => Mage::helper('enterprise_customersegment')->__('Conditions Combination'), 'available_in_guest_mode' => true), array('value' => 'enterprise_customersegment/segment_condition_customer_address', 'label' => Mage::helper('enterprise_customersegment')->__('Customer Address')), Mage::getModel('enterprise_customersegment/segment_condition_customer')->getNewChildSelectOptions(), Mage::getModel('enterprise_customersegment/segment_condition_shoppingcart')->getNewChildSelectOptions(), array('value' => array(array('value' => 'enterprise_customersegment/segment_condition_product_combine_list', 'label' => Mage::helper('enterprise_customersegment')->__('Product List'), 'available_in_guest_mode' => true), array('value' => 'enterprise_customersegment/segment_condition_product_combine_history', 'label' => Mage::helper('enterprise_customersegment')->__('Product History'), 'available_in_guest_mode' => true)), 'label' => Mage::helper('enterprise_customersegment')->__('Products'), 'available_in_guest_mode' => true), Mage::getModel('enterprise_customersegment/segment_condition_sales')->getNewChildSelectOptions());
     $conditions = array_merge_recursive(parent::getNewChildSelectOptions(), $conditions);
     return $this->_prepareConditionAccordingApplyToValue($conditions);
 }
Exemplo n.º 4
0
 /**
  * Get inherited conditions selectors
  *
  * @return array
  */
 public function getNewChildSelectOptions()
 {
     return array_merge_recursive(parent::getNewChildSelectOptions(), array(Mage::getModel('enterprise_customersegment/segment_condition_order_status')->getNewChildSelectOptions(), array('value' => array(Mage::getModel('enterprise_customersegment/segment_condition_uptodate')->getNewChildSelectOptions(), Mage::getModel('enterprise_customersegment/segment_condition_daterange')->getNewChildSelectOptions()), 'label' => Mage::helper('enterprise_customersegment')->__('Date Ranges'))));
 }