<?php /** * Product: Loyalty Program for Enterprise Edition * Package: Aitoc_Aitloyalty_10.0.10_574534 * Purchase ID: INzRIwyyaNoeOLERhAgt4U28qVKIeEa3dfPrgaAN3C * Generated: 2013-05-13 06:36:55 * File path: app/code/local/Aitoc/Aitloyalty/Helper/Legal.php * Copyright: (c) 2013 AITOC, Inc. */ if (Aitoc_Aitsys_Abstract_Service::initSource(__FILE__, 'Aitoc_Aitloyalty')) { ZSegBBZTWMZrRmUW('a77a52ac449bfdfe346bd5c5883e1a5f'); /** * @copyright Copyright (c) 2009 AITOC, Inc. */ class Aitoc_Aitloyalty_Helper_Legal extends Mage_Core_Helper_Abstract { protected $_hasLoyaltyFeatures = false; protected $_isNotifyRestrictedFeatures = false; public function setHasLoyaltyFeatures() { $this->_hasLoyaltyFeatures = true; return $this; } public function getHasLoyaltyFeatures() { return $this->_hasLoyaltyFeatures; } public function setIsNotifyRestrictedFeatures() { $this->_isNotifyRestrictedFeatures = true;
<?php /** * Product: Loyalty Program for Enterprise Edition * Package: Aitoc_Aitloyalty_10.0.10_574534 * Purchase ID: INzRIwyyaNoeOLERhAgt4U28qVKIeEa3dfPrgaAN3C * Generated: 2013-05-13 06:36:55 * File path: app/code/local/Aitoc/Aitloyalty/Block/Account/Promostats.php * Copyright: (c) 2013 AITOC, Inc. */ if (Aitoc_Aitsys_Abstract_Service::initSource(__FILE__, 'Aitoc_Aitloyalty')) { ZSegBBZTWMZrRmUW('3139d183afd7863c201c3ba12dfefbd9'); /** * @copyright Copyright (c) 2009 AITOC, Inc. */ class Aitoc_Aitloyalty_Block_Account_Promostats extends Mage_Core_Block_Template { private $_couponCodesUses; public function getCouponCodes($rule) { $couponCode = null; $aCouponCode = array(); if (version_compare(Mage::getVersion(), '1.12.0.0', 'ge')) { $couponCode = $rule->getCode(); if (!$couponCode) { $couponCodes = Mage::getResourceModel('salesrule/coupon_collection'); $couponCodes->addRuleToFilter($rule); $couponCodes->getSelect()->limit(500); foreach ($couponCodes as $_code) { if ($this->_isCodeAvailible($rule, $_code)) { $aCouponCode[] = $_code->getCode();
<?php /** * Product: Loyalty Program for Enterprise Edition * Package: Aitoc_Aitloyalty_10.0.10_574534 * Purchase ID: INzRIwyyaNoeOLERhAgt4U28qVKIeEa3dfPrgaAN3C * Generated: 2013-05-13 06:36:55 * File path: app/code/local/Aitoc/Aitloyalty/Model/Rewrite/Mysql4/ReportsReportCollection.php * Copyright: (c) 2013 AITOC, Inc. */ if (Aitoc_Aitsys_Abstract_Service::initSource(__FILE__, 'Aitoc_Aitloyalty')) { ZSegBBZTWMZrRmUW('52a6e84a72b9eeb5208690300f0d572e'); /** * @copyright Copyright (c) 2011 AITOC, Inc. */ class Aitoc_Aitloyalty_Model_Rewrite_Mysql4_ReportsReportCollection extends Mage_Reports_Model_Mysql4_Report_Collection { public function getIntervals() { if (!$this->_intervals) { $this->_intervals = array(); if (!$this->_from && !$this->_to) { return $this->_intervals; } $dateStart = new Zend_Date($this->_from); $dateEnd = new Zend_Date($this->_to); $t = array(); $firstInterval = true; /** START AITOC FIX **/ if (in_array((string) $this->_period, array('day', 'month', 'year'))) { /** END AITOC FIX **/
<?php /** * Product: Loyalty Program for Enterprise Edition * Package: Aitoc_Aitloyalty_10.0.10_574534 * Purchase ID: INzRIwyyaNoeOLERhAgt4U28qVKIeEa3dfPrgaAN3C * Generated: 2013-05-13 06:36:55 * File path: app/code/local/Aitoc/Aitloyalty/Model/ModuleObserver.php * Copyright: (c) 2013 AITOC, Inc. */ if (Aitoc_Aitsys_Abstract_Service::initSource(__FILE__, 'Aitoc_Aitloyalty')) { ZSegBBZTWMZrRmUW('68d6f8bb35cdd306c9f0ec59b9915b3f'); /** * @copyright Copyright (c) 2009 AITOC, Inc. */ class Aitoc_Aitloyalty_Model_ModuleObserver { public function __construct() { } public function onAitocModuleDisableBefore($observer) { if ('Aitoc_Aitloyalty' == $observer->getAitocmodulename()) { $oInstaller = $observer->getObject(); /* @var $oInstaller Aitoc_Aitsys_Model_Aitsys */ $oDb = Mage::getModel('sales_entity/order')->getReadConnection(); /* @var $oDb Varien_Db_Adapter_Pdo_Mysql */ $oSelect = $oDb->select(); /* @var $oSelect Varien_Db_Select */ $oSelect->from(array('salesrule' => Mage::getSingleton('core/resource')->getTableName('salesrule')), array('name' => 'salesrule.name', 'rule_id' => 'salesrule.rule_id'))->where('( (salesrule.conditions_serialized LIKE "%Aitoc_Aitloyalty%") OR (salesrule.simple_action LIKE "%surcharge%") )')->where('salesrule.is_active = "1"'); $aRules = $oDb->fetchAll($oSelect);
<?php /** * Product: Loyalty Program for Enterprise Edition * Package: Aitoc_Aitloyalty_10.0.10_574534 * Purchase ID: INzRIwyyaNoeOLERhAgt4U28qVKIeEa3dfPrgaAN3C * Generated: 2013-05-13 06:36:55 * File path: app/code/local/Aitoc/Aitloyalty/Block/Rewrite/FrontAccountNavigation.php * Copyright: (c) 2013 AITOC, Inc. */ if (Aitoc_Aitsys_Abstract_Service::initSource(__FILE__, 'Aitoc_Aitloyalty')) { ZSegBBZTWMZrRmUW('ae36f793c228d71b35d24941fd596859'); class Aitoc_Aitloyalty_Block_Rewrite_FrontAccountNavigation extends Mage_Customer_Block_Account_Navigation { public function addLink($name, $path, $label, $urlParams = array()) { $isAddLink = true; if ('aitloyalty' == $name) { $iStoreId = Mage::app()->getStore()->getId(); $iSiteId = Mage::app()->getWebsite()->getId(); /* */ $performer = Aitoc_Aitsys_Abstract_Service::get()->platform()->getModule('Aitoc_Aitloyalty')->getLicense()->getPerformer(); $ruler = $performer->getRuler(); if (!($ruler->checkRule('store', $iStoreId, 'store') || $ruler->checkRule('store', $iSiteId, 'website'))) { $isAddLink = false; } /* */ } if ($isAddLink) { parent::addLink($name, $path, $label, $urlParams); }