<?php

/**
 * Product:     Individual Promotions for Magento Enterpise Edition
 * Package:     Aitoc_Aitindividpromo_10.0.7_574525
 * Purchase ID: UjgdLvjpFE0u1HHQEOk2KNCXazbZ9kQjUnTtO4dMb0
 * Generated:   2013-05-13 06:35:45
 * File path:   app/code/local/Aitoc/Aitindividpromo/Model/Rewrite/FrontSalesRuleRule.php
 * Copyright:   (c) 2013 AITOC, Inc.
 */
if (Aitoc_Aitsys_Abstract_Service::initSource(__FILE__, 'Aitoc_Aitindividpromo')) {
    cCBMeDBMjooCseDq('2d7d728c2a2634bd8a8f08cf7ac0df69');
    /**
     * @copyright  Copyright (c) 2009 AITOC, Inc. 
     */
    class Aitoc_Aitindividpromo_Model_Rewrite_FrontSalesRuleRule extends Mage_SalesRule_Model_Rule
    {
        protected function _afterSave()
        {
            $iRuleId = $this->getId();
            $oReq = Mage::app()->getFrontController()->getRequest();
            $aData = $oReq->getPost();
            /* This check has been added for Amastsy extension to work properly while sending coupons through cron */
            if (empty($aData)) {
                return parent::_afterSave();
            }
            /* This check has been added for Amastsy extension to work properly while sending coupons through cron */
            /* modifying this line to trigger newsletter subscription coupon */
            if (!isset($aData['customer_individ_ids'])) {
                return parent::_afterSave();
            }
<?php

/**
 * Product:     Individual Promotions for Magento Enterpise Edition
 * Package:     Aitoc_Aitindividpromo_10.0.7_574525
 * Purchase ID: UjgdLvjpFE0u1HHQEOk2KNCXazbZ9kQjUnTtO4dMb0
 * Generated:   2013-05-13 06:35:45
 * File path:   app/code/local/Aitoc/Aitindividpromo/Model/Rewrite/FrontSalesRuleMysql4RuleCollection.php
 * Copyright:   (c) 2013 AITOC, Inc.
 */
if (Aitoc_Aitsys_Abstract_Service::initSource(__FILE__, 'Aitoc_Aitindividpromo')) {
    cCBMeDBMjooCseDq('b6108d981d99013e872baf6cd162877d');
    /**
     * @copyright  Copyright (c) 2009 AITOC, Inc. 
     */
    class Aitoc_Aitindividpromo_Model_Rewrite_FrontSalesRuleMysql4RuleCollection extends Mage_SalesRule_Model_Mysql4_Rule_Collection
    {
        public function setValidationFilter($websiteId, $customerGroupId, $couponCode = '', $now = null)
        {
            if (is_null($now)) {
                $now = Mage::getModel('core/date')->date('Y-m-d');
            }
            $this->addBindParam('code', $couponCode);
            $this->getSelect()->where('is_active=1');
            $this->getSelect()->where('find_in_set(?, website_ids)', (int) $websiteId);
            #        $this->getSelect()->where('find_in_set(?, customer_group_ids)', (int)$customerGroupId);
            $iCustomerId = Mage::getSingleton('customer/session')->getCustomerId();
            $oResource = Mage::getSingleton('core/resource');
            $sTable = $oResource->getTableName('aitoc_salesrule_assign_cutomer');
            if ($sTable) {
                if (!$iCustomerId) {
Beispiel #3
0
<?php

/**
 * Product:     Individual Promotions for Magento Enterpise Edition
 * Package:     Aitoc_Aitindividpromo_10.0.7_574525
 * Purchase ID: UjgdLvjpFE0u1HHQEOk2KNCXazbZ9kQjUnTtO4dMb0
 * Generated:   2013-05-13 06:35:45
 * File path:   app/code/local/Aitoc/Aitindividpromo/Model/Quote/Observer.php
 * Copyright:   (c) 2013 AITOC, Inc.
 */
if (Aitoc_Aitsys_Abstract_Service::initSource(__FILE__, 'Aitoc_Aitindividpromo')) {
    cCBMeDBMjooCseDq('3797cb991e2aee33ac5f3cc8d4bd23d8');
    class Aitoc_Aitindividpromo_Model_Quote_Observer extends Mage_Core_Model_Abstract
    {
        public function onCoreLocaleSetLocale($observer)
        {
            if (!Mage::registry('aitpagecache_check_14') && Mage::getConfig()->getNode('modules/Aitoc_Aitpagecache/active') === 'true') {
                if (file_exists(Mage::getBaseDir('magentobooster') . DS . 'use_cache.ser')) {
                    Mage::register('aitpagecache_check_14', 1);
                } elseif (file_exists(Mage::getBaseDir('app/etc') . DS . 'use_cache.ser')) {
                    Mage::register('aitpagecache_check_13', 1);
                }
            }
        }
    }
}
Beispiel #4
0
<?php

/**
 * Product:     Individual Promotions for Magento Enterpise Edition
 * Package:     Aitoc_Aitindividpromo_10.0.7_574525
 * Purchase ID: UjgdLvjpFE0u1HHQEOk2KNCXazbZ9kQjUnTtO4dMb0
 * Generated:   2013-05-13 06:35:45
 * File path:   app/code/local/Aitoc/Aitindividpromo/Helper/Data.php
 * Copyright:   (c) 2013 AITOC, Inc.
 */
if (Aitoc_Aitsys_Abstract_Service::initSource(__FILE__, 'Aitoc_Aitindividpromo')) {
    cCBMeDBMjooCseDq('e8509c35b5cb1b26c38a33bde220f7c2');
    /**
     * @copyright  Copyright (c) 2009 AITOC, Inc. 
     */
    class Aitoc_Aitindividpromo_Helper_Data extends Mage_Core_Helper_Abstract
    {
    }
}