当前位置: 首页>>代码示例>>PHP>>正文


PHP Mage_Rule_Model_Condition_Combine::getNewChildSelectOptions方法代码示例

本文整理汇总了PHP中Mage_Rule_Model_Condition_Combine::getNewChildSelectOptions方法的典型用法代码示例。如果您正苦于以下问题:PHP Mage_Rule_Model_Condition_Combine::getNewChildSelectOptions方法的具体用法?PHP Mage_Rule_Model_Condition_Combine::getNewChildSelectOptions怎么用?PHP Mage_Rule_Model_Condition_Combine::getNewChildSelectOptions使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Mage_Rule_Model_Condition_Combine的用法示例。


在下文中一共展示了Mage_Rule_Model_Condition_Combine::getNewChildSelectOptions方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: getNewChildSelectOptions

 public function getNewChildSelectOptions()
 {
     $conditions = parent::getNewChildSelectOptions();
     $conditions = array_merge_recursive($conditions, array(array('value' => 'rewardpoints/rule_condition_combine', 'label' => Mage::helper('rewardpoints')->__('Conditions Combination'))));
     $c_attributes = array(array('value' => 'rewardpoints/rule_condition_customeraddress_params|postcode', 'label' => Mage::helper('rewardpoints')->__('User post code')), array('value' => 'rewardpoints/rule_condition_customeraddress_params|region_id', 'label' => Mage::helper('rewardpoints')->__('User region')), array('value' => 'rewardpoints/rule_condition_customeraddress_params|country_id', 'label' => Mage::helper('rewardpoints')->__('User country')));
     /*$customer = Mage::getModel('customer/customer');
       $c2_attributes = array();
       foreach ($customer->getAttributes() as $attribute){
           //echo $attribute->getAttributeCode();
           //echo $attribute->getFrontendLabel();
           //backend_type
           if ($attribute->getBackendModel() == "" && $attribute->getFrontendLabel() != ""){
               $c2_attributes[] = array('value'=>'rewardpoints/rule_condition_customerattribute_params|'.$attribute->getAttributeCode(), 'label'=> $attribute->getFrontendLabel());
           }
           
       }*/
     $conditions = array_merge_recursive($conditions, array(array('label' => Mage::helper('rewardpoints')->__('User location'), 'value' => $c_attributes)));
     /*$conditions = array_merge_recursive($conditions, array(
           array('label'=>Mage::helper('rewardpoints')->__('User Attributes'), 'value'=>$c2_attributes),
       ));*/
     $addressCondition = Mage::getModel('salesrule/rule_condition_address');
     $addressAttributes = $addressCondition->loadAttributeOptions()->getAttributeOption();
     $cart_attributes = array();
     foreach ($addressAttributes as $code => $label) {
         $cart_attributes[] = array('value' => 'salesrule/rule_condition_address|' . $code, 'label' => $label);
     }
     $conditions = array_merge_recursive($conditions, array(array('label' => Mage::helper('salesrule')->__('Cart Attributes'), 'value' => $cart_attributes)));
     return $conditions;
 }
开发者ID:ntnhan220488,项目名称:ggm,代码行数:29,代码来源:Combine.php

示例2: getNewChildSelectOptions

 public function getNewChildSelectOptions()
 {
     if ($this->getRule()->getType()) {
         $type = $this->getRule()->getType();
     } else {
         $type = Mage::app()->getRequest()->getParam('rule_type');
     }
     if ($type == Mirasvit_FeedExport_Model_Rule::TYPE_ATTRIBUTE) {
         $itemAttributes = $this->_getProductAttributes();
         $condition = 'product' . $this->getRulePrefix();
     } else {
         $itemAttributes = $this->_getPerformanceAttributes();
         $condition = 'performance';
     }
     $attributes = array();
     foreach ($itemAttributes as $code => $label) {
         $group = Mage::helper('feedexport/html')->getAttributeGroup(str_replace(Mirasvit_FeedExport_Model_Rule_Condition_Combine_Parent::ATTR_CODE_PREFIX, '', $code));
         $attributes[$group][] = array('value' => 'feedexport/rule_condition_' . $condition . '|' . $code, 'label' => $label);
     }
     $conditions = parent::getNewChildSelectOptions();
     $conditions = array_merge_recursive($conditions, array(array('value' => 'feedexport/rule_condition_combine', 'label' => Mage::helper('feedexport')->__('Conditions Combination')), array('value' => 'feedexport/rule_condition_combine_parent', 'label' => Mage::helper('feedexport')->__('Parent Product Attributes'))));
     foreach ($attributes as $group => $arrAttributes) {
         $conditions = array_merge_recursive($conditions, array(array('label' => $group, 'value' => $arrAttributes)));
     }
     return $conditions;
 }
开发者ID:santhosh400,项目名称:ecart,代码行数:26,代码来源:Combine.php

示例3: getNewChildSelectOptions

 public function getNewChildSelectOptions()
 {
     $attributes = array();
     $customAttributes = Mage::getSingleton('xtento_orderexport/export_condition_custom')->getCustomAttributes();
     foreach ($customAttributes as $code => $label) {
         if (preg_match('/xt\\_billing\\_/', $code)) {
             $attributes[] = array('value' => 'xtento_orderexport/export_condition_address_billing|' . str_replace('xt_billing_', '', $code), 'label' => $label);
         } else {
             if (preg_match('/xt\\_shipping\\_/', $code)) {
                 $attributes[] = array('value' => 'xtento_orderexport/export_condition_address_shipping|' . str_replace('xt_shipping_', '', $code), 'label' => $label);
             } else {
                 $attributes[] = array('value' => 'xtento_orderexport/export_condition_object|' . $code, 'label' => $label);
             }
         }
     }
     $otherAttributes = array();
     $customOtherAttributes = Mage::getSingleton('xtento_orderexport/export_condition_custom')->getCustomNotMappedAttributes();
     foreach ($customOtherAttributes as $code => $label) {
         $otherAttributes[] = array('value' => 'xtento_orderexport/export_condition_object|' . $code, 'label' => $label);
     }
     $conditions = parent::getNewChildSelectOptions();
     $conditions = array_merge_recursive($conditions, array(array('value' => 'xtento_orderexport/export_condition_product_found', 'label' => Mage::helper('salesrule')->__('Product / Item attribute combination')), array('value' => 'xtento_orderexport/export_condition_product_subselect', 'label' => Mage::helper('salesrule')->__('Products subselection')), array('value' => 'xtento_orderexport/export_condition_combine', 'label' => Mage::helper('salesrule')->__('Conditions combination')), array('label' => Mage::helper('xtento_orderexport')->__('%s Attributes', ucfirst(Mage::registry('order_export_profile')->getEntity())), 'value' => $attributes), array('label' => Mage::helper('xtento_orderexport')->__('Misc. %s Attributes', ucfirst(Mage::registry('order_export_profile')->getEntity())), 'value' => $otherAttributes)));
     $additional = new Varien_Object();
     Mage::dispatchEvent('xtento_orderexport_rule_condition_combine', array('additional' => $additional));
     if ($additionalConditions = $additional->getConditions()) {
         $conditions = array_merge_recursive($conditions, $additionalConditions);
     }
     return $conditions;
 }
开发者ID:xiaoguizhidao,项目名称:devfashion,代码行数:29,代码来源:Combine.php

示例4: getNewChildSelectOptions

 public function getNewChildSelectOptions()
 {
     if ($this->getRule()->getType()) {
         $type = $this->getRule()->getType();
     } else {
         $type = Mage::app()->getRequest()->getParam('rule_type');
     }
     $attributes = array();
     $ruleClasses = $this->_getRuleClasses();
     foreach ($ruleClasses as $key => $class) {
         $classCondition = Mage::getModel($class);
         $classAttributes = $classCondition->loadAttributeOptions()->getAttributeOption();
         if (is_array($classAttributes)) {
             foreach ($classAttributes as $code => $label) {
                 $attributes[ucfirst($key)][] = array('value' => 'email/rule_condition_' . $key . '|' . $code, 'label' => $label);
             }
         }
     }
     $conditions = parent::getNewChildSelectOptions();
     $conditions = array_merge_recursive($conditions, array(array('value' => 'email/rule_condition_combine', 'label' => Mage::helper('email')->__('Conditions Combination'))));
     foreach ($attributes as $group => $arrAttributes) {
         $conditions = array_merge_recursive($conditions, array(array('label' => $group, 'value' => $arrAttributes)));
     }
     return $conditions;
 }
开发者ID:ashfaqphplhr,项目名称:artificiallawnsforturf,代码行数:25,代码来源:Combine.php

示例5: getNewChildSelectOptions

 public function getNewChildSelectOptions()
 {
     $addressCondition = Mage::getModel('followupemail/followupemailrule_rule_condition_address');
     $addressAttributes = $addressCondition->loadAttributeOptions()->getAttributeOption();
     $cattributes = array();
     $oattributes = array();
     $cusattributes = array();
     $pattributes = array();
     foreach ($addressAttributes as $code => $label) {
         if (strpos($code, 'cart_') === 0) {
             $cattributes[] = array('value' => 'followupemail/followupemailrule_rule_condition_address|' . $code, 'label' => $label);
         } else {
             if (strpos($code, 'order_') === 0) {
                 $oattributes[] = array('value' => 'followupemail/followupemailrule_rule_condition_address|' . $code, 'label' => $label);
             } else {
                 if (strpos($code, 'product_') === 0) {
                     $pattributes[] = array('value' => 'followupemail/followupemailrule_rule_condition_address|' . $code, 'label' => $label);
                 } else {
                     $cusattributes[] = array('value' => 'followupemail/followupemailrule_rule_condition_address|' . $code, 'label' => $label);
                 }
             }
         }
     }
     $conditions = parent::getNewChildSelectOptions();
     $conditions = array_merge_recursive($conditions, array(array('label' => Mage::helper('followupemail')->__('Cart Attribute'), 'value' => $cattributes), array('label' => Mage::helper('followupemail')->__('Order Attribute'), 'value' => $oattributes), array('label' => Mage::helper('followupemail')->__('Has Product'), 'value' => $pattributes), array('label' => Mage::helper('followupemail')->__('Customer Attribute'), 'value' => $cusattributes)));
     //        $additional = new Varien_Object();
     //        //Mage::dispatchEvent('helpdesk_helpdeskrule_rule_condition_combine', array('additional' => $additional));
     //        Mage::dispatchEvent('salesrule_rule_condition_combine', array('additional' => $additional));
     //        if ($additionalConditions = $additional->getConditions()) {
     //            $conditions = array_merge_recursive($conditions, $additionalConditions);
     //        }
     return $conditions;
 }
开发者ID:santhosh400,项目名称:ecart,代码行数:33,代码来源:Combine.php

示例6: getNewChildSelectOptions

 public function getNewChildSelectOptions()
 {
     $cAttributes[] = array('value' => 'Aitoc_Aitloyalty_Model_Rule_Condition_Customer|amount_during_period', 'label' => 'Amount spent during period');
     $cAttributes[] = array('value' => 'Aitoc_Aitloyalty_Model_Rule_Condition_Customer|membership_period', 'label' => 'Period of membership');
     $cAttributes[] = array('value' => 'Aitoc_Aitloyalty_Model_Rule_Condition_Customer|amount_average', 'label' => 'Average order amount during period');
     $conditions = parent::getNewChildSelectOptions();
     $conditions = array_merge_recursive($conditions, array(array('value' => 'Aitoc_Aitloyalty_Model_Rule_Condition_Customer_Combine', 'label' => Mage::helper('catalog')->__('Conditions Combination')), array('label' => Mage::helper('catalog')->__('Customer Data'), 'value' => $cAttributes)));
     return $conditions;
 }
开发者ID:sagmahajan,项目名称:aswan_release,代码行数:9,代码来源:Combine.php

示例7: getNewChildSelectOptions

 public function getNewChildSelectOptions()
 {
     $bannerConditions = Mage::getModel('prolabels/rule_condition_product')->loadAttributeOptions()->getAttributeOption();
     $attributes = array();
     foreach ($bannerConditions as $code => $label) {
         $attributes[] = array('value' => 'prolabels/rule_condition_product|' . $code, 'label' => $label);
     }
     $conditions = parent::getNewChildSelectOptions();
     $conditions = array_merge_recursive($conditions, array(array('value' => 'prolabels/rule_condition_combine', 'label' => Mage::helper('catalogrule')->__('Conditions Combination')), array('value' => $attributes, 'label' => Mage::helper('catalogrule')->__('Product'))));
     return $conditions;
 }
开发者ID:jokusafet,项目名称:MagentoSource,代码行数:11,代码来源:Combine.php

示例8: getNewChildSelectOptions

 public function getNewChildSelectOptions()
 {
     $productCondition = Mage::getModel('Mage_CatalogRule_Model_Rule_Condition_Product');
     $productAttributes = $productCondition->loadAttributeOptions()->getAttributeOption();
     $attributes = array();
     foreach ($productAttributes as $code => $label) {
         $attributes[] = array('value' => 'Mage_CatalogRule_Model_Rule_Condition_Product|' . $code, 'label' => $label);
     }
     $conditions = parent::getNewChildSelectOptions();
     $conditions = array_merge_recursive($conditions, array(array('value' => 'Mage_CatalogRule_Model_Rule_Condition_Combine', 'label' => Mage::helper('Mage_CatalogRule_Helper_Data')->__('Conditions Combination')), array('label' => Mage::helper('Mage_CatalogRule_Helper_Data')->__('Product Attribute'), 'value' => $attributes)));
     return $conditions;
 }
开发者ID:natxetee,项目名称:magento2,代码行数:12,代码来源:Combine.php

示例9: getNewChildSelectOptions

 public function getNewChildSelectOptions()
 {
     $addressCondition = AO::getModel('salesrule/rule_condition_address');
     $addressAttributes = $addressCondition->loadAttributeOptions()->getAttributeOption();
     $attributes = array();
     foreach ($addressAttributes as $code => $label) {
         $attributes[] = array('value' => 'salesrule/rule_condition_address|' . $code, 'label' => $label);
     }
     $conditions = parent::getNewChildSelectOptions();
     $conditions = array_merge_recursive($conditions, array(array('value' => 'salesrule/rule_condition_product_found', 'label' => AO::helper('salesrule')->__('Product attribute combination')), array('value' => 'salesrule/rule_condition_product_subselect', 'label' => AO::helper('salesrule')->__('Products subselection')), array('value' => 'salesrule/rule_condition_combine', 'label' => AO::helper('salesrule')->__('Conditions combination')), array('label' => AO::helper('salesrule')->__('Cart Attribute'), 'value' => $attributes)));
     return $conditions;
 }
开发者ID:ronseigel,项目名称:agent-ohm,代码行数:12,代码来源:Rule_Condition_Combine.php

示例10: getNewChildSelectOptions

 /**
  * get child select options
  * @return type
  */
 public function getNewChildSelectOptions()
 {
     $orderAttributes = Mage::getModel('rewardpointsreferfriends/rule_condition_order')->loadAttributeOptions()->getAttributeOption();
     $attributes = array();
     foreach ($orderAttributes as $attribute => $label) {
         $attributes[] = array('value' => 'rewardpointsreferfriends/rule_condition_order|' . $attribute, 'label' => $label);
     }
     $conditions = parent::getNewChildSelectOptions();
     $conditions = array_merge_recursive($conditions, array(array('value' => 'salesrule/rule_condition_product_found', 'label' => Mage::helper('rewardpointsreferfriends')->__('Product attribute combination')), array('value' => 'salesrule/rule_condition_product_subselect', 'label' => Mage::helper('rewardpointsreferfriends')->__('Products subselection')), array('value' => 'rewardpointsreferfriends/rule_condition_combine', 'label' => Mage::helper('rewardpointsreferfriends')->__('Conditions combination')), array('value' => $attributes, 'label' => Mage::helper('rewardpointsreferfriends')->__('Cart Order Attribute'))));
     $additional = new Varien_Object();
     Mage::dispatchEvent('rewardpointsreferfriends_rule_condition_combine', array('additional' => $additional));
     if ($additionalConditions = $additional->getConditions()) {
         $conditions = array_merge_recursive($conditions, $additionalConditions);
     }
     return $conditions;
 }
开发者ID:sshegde123,项目名称:wmp8,代码行数:20,代码来源:Combine.php

示例11: getNewChildSelectOptions

 /**
  * Retrieve the product options for the select field.
  *
  * @see Mage_Rule_Model_Condition_Abstract::getNewChildSelectOptions()
  * @return array Conditions as array
  */
 public function getNewChildSelectOptions()
 {
     $productCondition = Mage::getModel('dynamiccategory/rule_condition_product');
     $productAttributes = $productCondition->loadAttributeOptions()->getAttributeOption();
     $pAttributes = array();
     $iAttributes = array();
     foreach ($productAttributes as $code => $label) {
         if (strpos($code, 'quote_item_') === 0) {
             $iAttributes[] = array('value' => 'dynamiccategory/rule_condition_product|' . $code, 'label' => $label);
         } else {
             $pAttributes[] = array('value' => 'dynamiccategory/rule_condition_product|' . $code, 'label' => $label);
         }
     }
     $conditions = parent::getNewChildSelectOptions();
     $conditions = array_merge_recursive($conditions, array(array('value' => 'dynamiccategory/rule_condition_product_combine', 'label' => Mage::helper('dynamiccategory')->__('Conditions Combination')), array('label' => Mage::helper('dynamiccategory')->__('Product Attribute'), 'value' => $pAttributes)));
     return $conditions;
 }
开发者ID:amorkan,项目名称:firegento-dynamiccategory,代码行数:23,代码来源:Combine.php

示例12: getNewChildSelectOptions

 public function getNewChildSelectOptions()
 {
     $productCondition = Mage::getModel('hipay/rule_condition_product');
     $productAttributes = $productCondition->loadAttributeOptions()->getAttributeOption();
     $pAttributes = array();
     $iAttributes = array();
     foreach ($productAttributes as $code => $label) {
         if (strpos($code, 'order_item_') === 0) {
             $iAttributes[] = array('value' => 'hipay/rule_condition_product|' . $code . '|' . $this->getPaymentMethodCode(), 'label' => $label);
         } else {
             $pAttributes[] = array('value' => 'hipay/rule_condition_product|' . $code . '|' . $this->getPaymentMethodCode(), 'label' => $label);
         }
     }
     $conditions = parent::getNewChildSelectOptions();
     $conditions = array_merge_recursive($conditions, array(array('value' => 'hipay/rule_condition_product_combine||' . $this->getPaymentMethodCode(), 'label' => Mage::helper('catalog')->__('Conditions Combination')), array('label' => Mage::helper('hipay')->__('Order Attribute'), 'value' => $iAttributes), array('label' => Mage::helper('catalog')->__('Product Attribute'), 'value' => $pAttributes)));
     return $conditions;
 }
开发者ID:hipay,项目名称:hipay-fullservice-sdk-magento1,代码行数:17,代码来源:Combine.php

示例13: getNewChildSelectOptions

 public function getNewChildSelectOptions()
 {
     $addressCondition = Mage::getModel('salesrule/rule_condition_address');
     $addressAttributes = $addressCondition->loadAttributeOptions()->getAttributeOption();
     $attributes = array();
     foreach ($addressAttributes as $code => $label) {
         $attributes[] = array('value' => 'salesrule/rule_condition_address|' . $code, 'label' => $label);
     }
     $conditions = parent::getNewChildSelectOptions();
     $conditions = array_merge_recursive($conditions, array(array('value' => 'amacart/rule_condition_carts', 'label' => Mage::helper('amacart')->__('Number of recovered cards this month')), array('value' => 'salesrule/rule_condition_product_subselect', 'label' => Mage::helper('salesrule')->__('Products subselection')), array('value' => $this->getType(), 'label' => Mage::helper('salesrule')->__('Conditions combination')), array('label' => Mage::helper('salesrule')->__('Cart Attribute'), 'value' => $attributes)));
     $additional = new Varien_Object();
     Mage::dispatchEvent('salesrule_rule_condition_combine', array('additional' => $additional));
     if ($additionalConditions = $additional->getConditions()) {
         $conditions = array_merge_recursive($conditions, $additionalConditions);
     }
     return $conditions;
 }
开发者ID:rcclaudrey,项目名称:dev,代码行数:17,代码来源:Combine.php

示例14: getNewChildSelectOptions

 public function getNewChildSelectOptions()
 {
     $addressCondition = Mage::getModel('Mage_SalesRule_Model_Rule_Condition_Address');
     $addressAttributes = $addressCondition->loadAttributeOptions()->getAttributeOption();
     $attributes = array();
     foreach ($addressAttributes as $code => $label) {
         $attributes[] = array('value' => 'Mage_SalesRule_Model_Rule_Condition_Address|' . $code, 'label' => $label);
     }
     $conditions = parent::getNewChildSelectOptions();
     $conditions = array_merge_recursive($conditions, array(array('value' => 'Mage_SalesRule_Model_Rule_Condition_Product_Found', 'label' => Mage::helper('Mage_SalesRule_Helper_Data')->__('Product attribute combination')), array('value' => 'Mage_SalesRule_Model_Rule_Condition_Product_Subselect', 'label' => Mage::helper('Mage_SalesRule_Helper_Data')->__('Products subselection')), array('value' => 'Mage_SalesRule_Model_Rule_Condition_Combine', 'label' => Mage::helper('Mage_SalesRule_Helper_Data')->__('Conditions combination')), array('label' => Mage::helper('Mage_SalesRule_Helper_Data')->__('Cart Attribute'), 'value' => $attributes)));
     $additional = new Varien_Object();
     Mage::dispatchEvent('salesrule_rule_condition_combine', array('additional' => $additional));
     if ($additionalConditions = $additional->getConditions()) {
         $conditions = array_merge_recursive($conditions, $additionalConditions);
     }
     return $conditions;
 }
开发者ID:nemphys,项目名称:magento2,代码行数:17,代码来源:Combine.php

示例15: getNewChildSelectOptions

 public function getNewChildSelectOptions()
 {
     $addressCondition = Mage::getModel('hhennes_autogroups/rule_condition_address');
     $addressAttributes = $addressCondition->loadAttributeOptions()->getAttributeOption();
     $attributes = array();
     foreach ($addressAttributes as $code => $label) {
         $attributes[] = array('value' => 'hhennes_autogroups/rule_condition_address|' . $code, 'label' => $label);
     }
     $customerCondition = Mage::getModel('hhennes_autogroups/rule_condition_customer');
     $customerAttributes = $customerCondition->loadAttributeOptions()->getAttributeOption();
     $CustomersAttributes = array();
     foreach ($customerAttributes as $code => $label) {
         $CustomersAttributes[] = array('value' => 'hhennes_autogroups/rule_condition_customer|' . $code, 'label' => $label);
     }
     $conditions = parent::getNewChildSelectOptions();
     $conditions = array_merge_recursive($conditions, array(array('label' => Mage::helper('hhennes_autogroups')->__('Address Attributes'), 'value' => $attributes), array('label' => Mage::helper('hhennes_autogroups')->__('Customer Attributes'), 'value' => $CustomersAttributes)));
     return $conditions;
 }
开发者ID:nenes25,项目名称:magento_customerautogroups,代码行数:18,代码来源:Combine.php


注:本文中的Mage_Rule_Model_Condition_Combine::getNewChildSelectOptions方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。