Version Notes
Version 11.1.5
Download this release
Release Info
| Developer | Carson Reinke |
| Extension | Autorespondermax_Autorespondermax |
| Version | 11.1.5 |
| Comparing to | |
| See all releases | |
Code changes from version 11.0.6 to 11.1.5
- app/code/community/Autorespondermax/Autorespondermax/Block/System/Config/AutocompleteOff.php +23 -9
- app/code/community/Autorespondermax/Autorespondermax/Block/System/Config/Readonly.php +4 -4
- app/code/community/Autorespondermax/Autorespondermax/Helper/Data.php +183 -183
- app/code/community/Autorespondermax/Autorespondermax/Helper/Track.php +1 -1
- app/code/community/Autorespondermax/Autorespondermax/Model/Observer.php +1 -1
- app/code/community/Autorespondermax/Autorespondermax/Model/System/Config/Form/Field/Button.php +16 -16
- package.xml +5 -5
app/code/community/Autorespondermax/Autorespondermax/Block/System/Config/AutocompleteOff.php
CHANGED
|
@@ -1,14 +1,28 @@
|
|
| 1 |
<?php
|
| 2 |
|
| 3 |
class Autorespondermax_Autorespondermax_Block_System_Config_AutocompleteOff extends Mage_Adminhtml_Block_System_Config_Form_Field {
|
| 4 |
-
|
| 5 |
-
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
|
| 9 |
-
|
| 10 |
-
|
| 11 |
-
|
| 12 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 13 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 14 |
}
|
| 1 |
<?php
|
| 2 |
|
| 3 |
class Autorespondermax_Autorespondermax_Block_System_Config_AutocompleteOff extends Mage_Adminhtml_Block_System_Config_Form_Field {
|
| 4 |
+
protected function _getElementHtml(Varien_Data_Form_Element_Abstract $element) {
|
| 5 |
+
$parent = parent::_getElementHtml($element);
|
| 6 |
+
$child = null;
|
| 7 |
+
|
| 8 |
+
//Attempt to add attribute `autocomplete` to element
|
| 9 |
+
try {
|
| 10 |
+
$dom = new DOMDocument();
|
| 11 |
+
$dom->loadHTML($parent);
|
| 12 |
+
$xpath = new DOMXPath($dom);
|
| 13 |
+
$node = $xpath->query('//input')->item(0);
|
| 14 |
+
if(!is_null($node)) {
|
| 15 |
+
$node->setAttribute('autocomplete', 'off');
|
| 16 |
+
$child = $dom->saveHtml($node);
|
| 17 |
+
}
|
| 18 |
}
|
| 19 |
+
catch(Exception $e) {
|
| 20 |
+
Mage::logException($e);
|
| 21 |
+
}
|
| 22 |
+
|
| 23 |
+
if(empty($child) || count(trim($child)) < 1) {
|
| 24 |
+
$child = $parent;
|
| 25 |
+
}
|
| 26 |
+
return $child;
|
| 27 |
+
}
|
| 28 |
}
|
app/code/community/Autorespondermax/Autorespondermax/Block/System/Config/Readonly.php
CHANGED
|
@@ -1,8 +1,8 @@
|
|
| 1 |
<?php
|
| 2 |
|
| 3 |
class Autorespondermax_Autorespondermax_Block_System_Config_Readonly extends Mage_Adminhtml_Block_System_Config_Form_Field {
|
| 4 |
-
|
| 5 |
-
|
| 6 |
-
|
| 7 |
-
|
| 8 |
}
|
| 1 |
<?php
|
| 2 |
|
| 3 |
class Autorespondermax_Autorespondermax_Block_System_Config_Readonly extends Mage_Adminhtml_Block_System_Config_Form_Field {
|
| 4 |
+
protected function _getElementHtml(Varien_Data_Form_Element_Abstract $element) {
|
| 5 |
+
$element->setReadonly(true, true);
|
| 6 |
+
return parent::_getElementHtml($element);
|
| 7 |
+
}
|
| 8 |
}
|
app/code/community/Autorespondermax/Autorespondermax/Helper/Data.php
CHANGED
|
@@ -1,191 +1,191 @@
|
|
| 1 |
<?php
|
| 2 |
|
| 3 |
class Autorespondermax_Autorespondermax_Helper_Data extends Mage_Core_Helper_Abstract {
|
| 4 |
-
|
| 5 |
-
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
|
| 9 |
-
|
| 10 |
-
|
| 11 |
-
|
| 12 |
-
|
| 13 |
-
|
| 14 |
-
|
| 15 |
-
|
| 16 |
-
|
| 17 |
-
|
| 18 |
-
|
| 19 |
-
|
| 20 |
-
|
| 21 |
-
|
| 22 |
-
|
| 23 |
-
|
| 24 |
-
|
| 25 |
-
|
| 26 |
-
|
| 27 |
-
|
| 28 |
-
|
| 29 |
-
|
| 30 |
-
|
| 31 |
-
|
| 32 |
-
|
| 33 |
-
|
| 34 |
-
|
| 35 |
-
|
| 36 |
-
|
| 37 |
-
|
| 38 |
-
|
| 39 |
-
|
| 40 |
-
|
| 41 |
-
|
| 42 |
-
|
| 43 |
-
|
| 44 |
-
|
| 45 |
-
|
| 46 |
-
|
| 47 |
-
|
| 48 |
-
|
| 49 |
-
|
| 50 |
-
|
| 51 |
-
|
| 52 |
-
|
| 53 |
-
|
| 54 |
-
|
| 55 |
-
|
| 56 |
-
|
| 57 |
-
|
| 58 |
-
|
| 59 |
-
|
| 60 |
-
|
| 61 |
-
|
| 62 |
-
|
| 63 |
-
|
| 64 |
-
|
| 65 |
-
|
| 66 |
-
|
| 67 |
-
|
| 68 |
-
|
| 69 |
-
|
| 70 |
-
|
| 71 |
-
|
| 72 |
-
|
| 73 |
-
|
| 74 |
-
|
| 75 |
-
|
| 76 |
-
|
| 77 |
-
|
| 78 |
-
|
| 79 |
-
|
| 80 |
-
|
| 81 |
-
|
| 82 |
-
|
| 83 |
-
|
| 84 |
-
|
| 85 |
-
|
| 86 |
-
|
| 87 |
-
|
| 88 |
-
|
| 89 |
-
|
| 90 |
-
|
| 91 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 92 |
}
|
| 93 |
-
}
|
| 94 |
-
|
| 95 |
-
public function refresh($store) {
|
| 96 |
-
//Get the new data
|
| 97 |
-
$data = Mage::helper('autorespondermax/api')->getStore($store);
|
| 98 |
|
| 99 |
-
//
|
| 100 |
-
|
| 101 |
-
|
| 102 |
-
//$helper->setApiSecret(, $store);
|
| 103 |
-
$this->setUseTracking($data['use_tracking'], $store);
|
| 104 |
-
}
|
| 105 |
-
|
| 106 |
-
/**
|
| 107 |
-
* Should we verify SSL? No, if in Developer Mode
|
| 108 |
-
*
|
| 109 |
-
* @return bool
|
| 110 |
-
*/
|
| 111 |
-
public function sslVerifyHost() {
|
| 112 |
-
return Mage::getIsDeveloperMode() ? false : true;
|
| 113 |
-
}
|
| 114 |
-
|
| 115 |
-
/**
|
| 116 |
-
* Host name to use for dashboard
|
| 117 |
-
*
|
| 118 |
-
* @return string
|
| 119 |
-
*/
|
| 120 |
-
public function dashboardHostName() {
|
| 121 |
-
return $this->hostName(self::DASHBOARD_HOST_NAME_ENV, self::DASHBOARD_HOST_NAME);
|
| 122 |
-
}
|
| 123 |
-
|
| 124 |
-
/**
|
| 125 |
-
* Host name to use for tracking
|
| 126 |
-
*
|
| 127 |
-
* @return string
|
| 128 |
-
*/
|
| 129 |
-
public function trackHostName() {
|
| 130 |
-
return $this->hostName(self::TRACK_HOST_NAME_ENV, self::TRACK_HOST_NAME);
|
| 131 |
-
}
|
| 132 |
-
|
| 133 |
-
/**
|
| 134 |
-
* Host name to use for API
|
| 135 |
-
*
|
| 136 |
-
* @return string
|
| 137 |
-
*/
|
| 138 |
-
public function apiHostName() {
|
| 139 |
-
return $this->hostName(self::API_HOST_NAME_ENV, self::API_HOST_NAME);
|
| 140 |
-
}
|
| 141 |
-
|
| 142 |
-
|
| 143 |
-
/**
|
| 144 |
-
* Save a configuration variable and delete it if null
|
| 145 |
-
*
|
| 146 |
-
* @param string $path
|
| 147 |
-
* @param string $value
|
| 148 |
-
* @param Mage_Core_Model_Store $store
|
| 149 |
-
*/
|
| 150 |
-
private function _save($path, $value, $store = null) {
|
| 151 |
-
if(is_null($store)) {
|
| 152 |
-
$store = Mage::app()->getStore();
|
| 153 |
-
}
|
| 154 |
-
|
| 155 |
-
//Delete value if null
|
| 156 |
-
if(is_null($value)) {
|
| 157 |
-
Mage::getConfig()->deleteConfig($path, 'stores', $store->getId());
|
| 158 |
-
}
|
| 159 |
-
else {
|
| 160 |
-
Mage::getConfig()->saveConfig($path, $value, 'stores', $store->getId());
|
| 161 |
-
}
|
| 162 |
-
}
|
| 163 |
-
|
| 164 |
-
/**
|
| 165 |
-
* @param string $env environment variable name
|
| 166 |
-
* @param string $default default host name
|
| 167 |
-
* @return string host name to use
|
| 168 |
-
*/
|
| 169 |
-
private function hostName($env, $default) {
|
| 170 |
-
$value = $this->getEnvironmentVariable($env);
|
| 171 |
-
if(empty($value)) {
|
| 172 |
-
$value = $default;
|
| 173 |
}
|
| 174 |
-
|
| 175 |
-
|
| 176 |
-
|
| 177 |
-
/**
|
| 178 |
-
* @param string $varname
|
| 179 |
-
* @return string value of environment variable
|
| 180 |
-
*/
|
| 181 |
-
private function getEnvironmentVariable($varname) {
|
| 182 |
-
$value = null;
|
| 183 |
-
if(function_exists('apache_getenv')) {
|
| 184 |
-
$value = apache_getenv($varname, true);
|
| 185 |
-
}
|
| 186 |
-
if(empty($value)) {
|
| 187 |
-
$value = getenv($varname);
|
| 188 |
}
|
| 189 |
-
|
| 190 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 191 |
}
|
| 1 |
<?php
|
| 2 |
|
| 3 |
class Autorespondermax_Autorespondermax_Helper_Data extends Mage_Core_Helper_Abstract {
|
| 4 |
+
const CONFIG_STORE_ID = 'autorespondermax/credentials/store_id';
|
| 5 |
+
const CONFIG_TOKEN = 'autorespondermax/credentials/token';
|
| 6 |
+
const CONFIG_API_SECRET = 'autorespondermax/credentials/api_secret';
|
| 7 |
+
const CONFIG_USE_TRACKING = 'autorespondermax/credentials/use_tracking';
|
| 8 |
+
|
| 9 |
+
const DASHBOARD_HOST_NAME_ENV = 'AUTORESPONDERMAX_DASHBOARD';
|
| 10 |
+
const TRACK_HOST_NAME_ENV = 'AUTORESPONDERMAX_TRACK';
|
| 11 |
+
const API_HOST_NAME_ENV = 'AUTORESPONDERMAX_API';
|
| 12 |
+
const DASHBOARD_HOST_NAME = 'dashboard.autorespondermax.com';
|
| 13 |
+
const TRACK_HOST_NAME = 'atrsp.mx';
|
| 14 |
+
const API_HOST_NAME = 'api.autorespondermax.com';
|
| 15 |
+
|
| 16 |
+
public static $API_ROLE_RULE_RESOURCES = array(
|
| 17 |
+
'core',
|
| 18 |
+
'core/magento',
|
| 19 |
+
'core/magento/info',
|
| 20 |
+
'core/store',
|
| 21 |
+
'core/store/list',
|
| 22 |
+
'autorespondermax',
|
| 23 |
+
'autorespondermax/general',
|
| 24 |
+
'autorespondermax/general/info',
|
| 25 |
+
'autorespondermax/sales_quote',
|
| 26 |
+
'autorespondermax/sales_quote/list',
|
| 27 |
+
'autorespondermax/sales_quote/ids',
|
| 28 |
+
'autorespondermax/customer',
|
| 29 |
+
'autorespondermax/customer/list',
|
| 30 |
+
'autorespondermax/customer/ids',
|
| 31 |
+
'autorespondermax/product',
|
| 32 |
+
'autorespondermax/product/list',
|
| 33 |
+
'autorespondermax/product/ids',
|
| 34 |
+
'autorespondermax/sales_order',
|
| 35 |
+
'autorespondermax/sales_order/list',
|
| 36 |
+
'autorespondermax/sales_order/ids'
|
| 37 |
+
);
|
| 38 |
+
const API_ROLE_NAME = 'Autoresponder Max';
|
| 39 |
+
|
| 40 |
+
public function getStoreId($store = null) {
|
| 41 |
+
return Mage::getStoreConfig(self::CONFIG_STORE_ID, $store);
|
| 42 |
+
}
|
| 43 |
+
public function setStoreId($value, $store = null) {
|
| 44 |
+
$this->_save(self::CONFIG_STORE_ID, $value, $store);
|
| 45 |
+
return $this;
|
| 46 |
+
}
|
| 47 |
+
public function getToken($store = null) {
|
| 48 |
+
return Mage::getStoreConfig(self::CONFIG_TOKEN, $store);
|
| 49 |
+
}
|
| 50 |
+
public function setToken($value, $store = null) {
|
| 51 |
+
$this->_save(self::CONFIG_TOKEN, $value, $store);
|
| 52 |
+
return $this;
|
| 53 |
+
}
|
| 54 |
+
public function getApiSecret($store = null) {
|
| 55 |
+
return Mage::getStoreConfig(self::CONFIG_API_SECRET, $store);
|
| 56 |
+
}
|
| 57 |
+
public function setApiSecret($value, $store = null) {
|
| 58 |
+
$this->_save(self::CONFIG_API_SECRET, $value, $store);
|
| 59 |
+
return $this;
|
| 60 |
+
}
|
| 61 |
+
public function getUseTracking($store = null) {
|
| 62 |
+
return Mage::getStoreConfig(self::CONFIG_USE_TRACKING, $store);
|
| 63 |
+
}
|
| 64 |
+
public function setUseTracking($value, $store = null) {
|
| 65 |
+
$this->_save(self::CONFIG_USE_TRACKING, $value, $store);
|
| 66 |
+
return $this;
|
| 67 |
+
}
|
| 68 |
+
|
| 69 |
+
public function connected($store = null) {
|
| 70 |
+
$storeId = $this->getStoreId($store);
|
| 71 |
+
return empty($storeId) ? false : true;
|
| 72 |
+
}
|
| 73 |
+
|
| 74 |
+
public function disconnected() {
|
| 75 |
+
return !$this->connected();
|
| 76 |
+
}
|
| 77 |
+
|
| 78 |
+
public function createApiUsername($store) {
|
| 79 |
+
return substr('autorespondermax_store_'.$store->getCode(), 0, 40); //Only 40 characters is allowed for username
|
| 80 |
+
}
|
| 81 |
+
|
| 82 |
+
public function createApiEmail($store) {
|
| 83 |
+
return 'platform+store_'.$store->getCode().'@autorespondermax.com';
|
| 84 |
+
}
|
| 85 |
+
|
| 86 |
+
public function createToken($size = 16) {
|
| 87 |
+
if(function_exists('openssl_random_pseudo_bytes')) {
|
| 88 |
+
return bin2hex(openssl_random_pseudo_bytes($size));
|
| 89 |
+
}
|
| 90 |
+
else {
|
| 91 |
+
return bin2hex(mcrypt_create_iv($size, MCRYPT_DEV_RANDOM));
|
| 92 |
+
}
|
| 93 |
+
}
|
| 94 |
+
|
| 95 |
+
public function refresh($store) {
|
| 96 |
+
//Get the new data
|
| 97 |
+
$data = Mage::helper('autorespondermax/api')->getStore($store);
|
| 98 |
+
|
| 99 |
+
//Update the configuration
|
| 100 |
+
//$helper->setStoreId(, $store);
|
| 101 |
+
//$helper->setToken(, $store);
|
| 102 |
+
//$helper->setApiSecret(, $store);
|
| 103 |
+
$this->setUseTracking($data['use_tracking'], $store);
|
| 104 |
+
}
|
| 105 |
+
|
| 106 |
+
/**
|
| 107 |
+
* Should we verify SSL? No, if in Developer Mode
|
| 108 |
+
*
|
| 109 |
+
* @return bool
|
| 110 |
+
*/
|
| 111 |
+
public function sslVerifyHost() {
|
| 112 |
+
return Mage::getIsDeveloperMode() ? false : true;
|
| 113 |
+
}
|
| 114 |
+
|
| 115 |
+
/**
|
| 116 |
+
* Host name to use for dashboard
|
| 117 |
+
*
|
| 118 |
+
* @return string
|
| 119 |
+
*/
|
| 120 |
+
public function dashboardHostName() {
|
| 121 |
+
return $this->hostName(self::DASHBOARD_HOST_NAME_ENV, self::DASHBOARD_HOST_NAME);
|
| 122 |
+
}
|
| 123 |
+
|
| 124 |
+
/**
|
| 125 |
+
* Host name to use for tracking
|
| 126 |
+
*
|
| 127 |
+
* @return string
|
| 128 |
+
*/
|
| 129 |
+
public function trackHostName() {
|
| 130 |
+
return $this->hostName(self::TRACK_HOST_NAME_ENV, self::TRACK_HOST_NAME);
|
| 131 |
+
}
|
| 132 |
+
|
| 133 |
+
/**
|
| 134 |
+
* Host name to use for API
|
| 135 |
+
*
|
| 136 |
+
* @return string
|
| 137 |
+
*/
|
| 138 |
+
public function apiHostName() {
|
| 139 |
+
return $this->hostName(self::API_HOST_NAME_ENV, self::API_HOST_NAME);
|
| 140 |
+
}
|
| 141 |
+
|
| 142 |
+
|
| 143 |
+
/**
|
| 144 |
+
* Save a configuration variable and delete it if null
|
| 145 |
+
*
|
| 146 |
+
* @param string $path
|
| 147 |
+
* @param string $value
|
| 148 |
+
* @param Mage_Core_Model_Store $store
|
| 149 |
+
*/
|
| 150 |
+
private function _save($path, $value, $store = null) {
|
| 151 |
+
if(is_null($store)) {
|
| 152 |
+
$store = Mage::app()->getStore();
|
| 153 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 154 |
|
| 155 |
+
//Delete value if null
|
| 156 |
+
if(is_null($value)) {
|
| 157 |
+
Mage::getConfig()->deleteConfig($path, 'stores', $store->getId());
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 158 |
}
|
| 159 |
+
else {
|
| 160 |
+
Mage::getConfig()->saveConfig($path, $value, 'stores', $store->getId());
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 161 |
}
|
| 162 |
+
}
|
| 163 |
+
|
| 164 |
+
/**
|
| 165 |
+
* @param string $env environment variable name
|
| 166 |
+
* @param string $default default host name
|
| 167 |
+
* @return string host name to use
|
| 168 |
+
*/
|
| 169 |
+
private function hostName($env, $default) {
|
| 170 |
+
$value = $this->getEnvironmentVariable($env);
|
| 171 |
+
if(empty($value)) {
|
| 172 |
+
$value = $default;
|
| 173 |
+
}
|
| 174 |
+
return $value;
|
| 175 |
+
}
|
| 176 |
+
|
| 177 |
+
/**
|
| 178 |
+
* @param string $varname
|
| 179 |
+
* @return string value of environment variable
|
| 180 |
+
*/
|
| 181 |
+
private function getEnvironmentVariable($varname) {
|
| 182 |
+
$value = null;
|
| 183 |
+
if(function_exists('apache_getenv')) {
|
| 184 |
+
$value = apache_getenv($varname, true);
|
| 185 |
+
}
|
| 186 |
+
if(empty($value)) {
|
| 187 |
+
$value = getenv($varname);
|
| 188 |
+
}
|
| 189 |
+
return $value;
|
| 190 |
+
}
|
| 191 |
}
|
app/code/community/Autorespondermax/Autorespondermax/Helper/Track.php
CHANGED
|
@@ -1,7 +1,7 @@
|
|
| 1 |
<?php
|
| 2 |
|
| 3 |
class Autorespondermax_Autorespondermax_Helper_Track extends Mage_Core_Helper_Abstract {
|
| 4 |
-
const VERSION = '
|
| 5 |
const FORMAT = 'js';
|
| 6 |
|
| 7 |
protected $_helper = null;
|
| 1 |
<?php
|
| 2 |
|
| 3 |
class Autorespondermax_Autorespondermax_Helper_Track extends Mage_Core_Helper_Abstract {
|
| 4 |
+
const VERSION = 'v5';
|
| 5 |
const FORMAT = 'js';
|
| 6 |
|
| 7 |
protected $_helper = null;
|
app/code/community/Autorespondermax/Autorespondermax/Model/Observer.php
CHANGED
|
@@ -15,7 +15,7 @@ class Autorespondermax_Autorespondermax_Model_Observer {
|
|
| 15 |
$helper->refresh($store);
|
| 16 |
}
|
| 17 |
catch(Exception $e) {
|
| 18 |
-
Mage::
|
| 19 |
}
|
| 20 |
}
|
| 21 |
}
|
| 15 |
$helper->refresh($store);
|
| 16 |
}
|
| 17 |
catch(Exception $e) {
|
| 18 |
+
Mage::logException($e);
|
| 19 |
}
|
| 20 |
}
|
| 21 |
}
|
app/code/community/Autorespondermax/Autorespondermax/Model/System/Config/Form/Field/Button.php
CHANGED
|
@@ -1,21 +1,21 @@
|
|
| 1 |
<?php
|
| 2 |
|
| 3 |
class Autorespondermax_Autorespondermax_Model_System_Config_Form_Field_Button extends Varien_Data_Form_Element_Abstract {
|
| 4 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 5 |
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
|
| 9 |
-
|
| 10 |
-
|
| 11 |
-
|
| 12 |
-
|
| 13 |
-
|
| 14 |
-
|
| 15 |
-
|
| 16 |
-
}
|
| 17 |
-
|
| 18 |
-
public function setButtonData($data) {
|
| 19 |
-
$this->_buttonData = $data;
|
| 20 |
-
}
|
| 21 |
}
|
| 1 |
<?php
|
| 2 |
|
| 3 |
class Autorespondermax_Autorespondermax_Model_System_Config_Form_Field_Button extends Varien_Data_Form_Element_Abstract {
|
| 4 |
+
protected $_buttonData = array();
|
| 5 |
+
|
| 6 |
+
public function getElementHtml() {
|
| 7 |
+
$buttonBlock = $this->getForm()->getParent()->getLayout()->createBlock('adminhtml/widget_button');
|
| 8 |
+
$buttonBlock->setBlockId('test');
|
| 9 |
+
$html = $buttonBlock->setData($this->_buttonData)->toHtml();
|
| 10 |
|
| 11 |
+
return $html;
|
| 12 |
+
}
|
| 13 |
+
|
| 14 |
+
public function getButtonData() {
|
| 15 |
+
return $this->_buttonData;
|
| 16 |
+
}
|
| 17 |
+
|
| 18 |
+
public function setButtonData($data) {
|
| 19 |
+
$this->_buttonData = $data;
|
| 20 |
+
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 21 |
}
|
package.xml
CHANGED
|
@@ -1,18 +1,18 @@
|
|
| 1 |
<?xml version="1.0"?>
|
| 2 |
<package>
|
| 3 |
<name>Autorespondermax_Autorespondermax</name>
|
| 4 |
-
<version>11.
|
| 5 |
<stability>stable</stability>
|
| 6 |
<license uri="https://autorespondermax.com/terms-of-service/">Autoresponder Max Terms Of Service</license>
|
| 7 |
<channel>community</channel>
|
| 8 |
<extends/>
|
| 9 |
<summary>Automatic email remarketing made easy</summary>
|
| 10 |
<description>Provides an integration with Autoresponder Max to send remarketing emails.</description>
|
| 11 |
-
<notes>Version 11.
|
| 12 |
<authors><author><name>Carson Reinke</name><user>armax1</user><email>it@autorespondermax.com</email></author></authors>
|
| 13 |
-
<date>
|
| 14 |
-
<time>16:
|
| 15 |
-
<contents><target name="magecommunity"><dir name="Autorespondermax"><dir name="Autorespondermax"><dir name="Block"><file name="Cart.php" hash="4d400b601aa4da5327ef6addec79e80b"/><dir name="Convert"><file name="Multishipping.php" hash="dc9c73cc1bdf747dcd5fae0a57dc175b"/><file name="Onepage.php" hash="011f0ec852171ca4b8ec84f895edf084"/></dir><dir name="System"><dir name="Config"><file name="AutocompleteOff.php" hash="
|
| 16 |
<compatible/>
|
| 17 |
<dependencies><required><php><min>5.0.0</min><max>6.0.0</max></php></required></dependencies>
|
| 18 |
</package>
|
| 1 |
<?xml version="1.0"?>
|
| 2 |
<package>
|
| 3 |
<name>Autorespondermax_Autorespondermax</name>
|
| 4 |
+
<version>11.1.5</version>
|
| 5 |
<stability>stable</stability>
|
| 6 |
<license uri="https://autorespondermax.com/terms-of-service/">Autoresponder Max Terms Of Service</license>
|
| 7 |
<channel>community</channel>
|
| 8 |
<extends/>
|
| 9 |
<summary>Automatic email remarketing made easy</summary>
|
| 10 |
<description>Provides an integration with Autoresponder Max to send remarketing emails.</description>
|
| 11 |
+
<notes>Version 11.1.5</notes>
|
| 12 |
<authors><author><name>Carson Reinke</name><user>armax1</user><email>it@autorespondermax.com</email></author></authors>
|
| 13 |
+
<date>2015-02-03</date>
|
| 14 |
+
<time>16:15:08</time>
|
| 15 |
+
<contents><target name="magecommunity"><dir name="Autorespondermax"><dir name="Autorespondermax"><dir name="Block"><file name="Cart.php" hash="4d400b601aa4da5327ef6addec79e80b"/><dir name="Convert"><file name="Multishipping.php" hash="dc9c73cc1bdf747dcd5fae0a57dc175b"/><file name="Onepage.php" hash="011f0ec852171ca4b8ec84f895edf084"/></dir><dir name="System"><dir name="Config"><file name="AutocompleteOff.php" hash="c97112f20af5feea10c1560e7f21f72a"/><file name="ConnectOrDisconnect.php" hash="de0f5fcbae957b28deb9e4c2672d31b4"/><file name="Readonly.php" hash="4856c9b22a42fd258d21e0894aed1347"/></dir></dir></dir><dir name="Helper"><file name="Api.php" hash="3381c0aef723d2a895924363437c45db"/><file name="Curl.php" hash="980a7950f2b61ec981304d6b33139577"/><file name="Dashboard.php" hash="6982a8d8a0b1184aed2b7c1186091cd5"/><file name="Data.php" hash="98d8f5ee1fddd392f4b5ee6bf05f2b19"/><file name="Track.php" hash="74a32e50d94afee5ef87cd23ac1e2acb"/></dir><dir name="Model"><file name="Api.php" hash="422a06e29b4e4807bacf32b42dedd848"/><dir name="Customer"><file name="Api.php" hash="4065f5a9bae528a1d2f38a44c5980bae"/></dir><dir name="General"><file name="Api.php" hash="be418a45090aaff6692e16f1ac2621d3"/></dir><file name="Observer.php" hash="af01ad29ece540b642fc24bed3a1b22b"/><dir name="Product"><file name="Api.php" hash="cbc598d40e048ef98d5830e3b2232509"/></dir><dir name="Sales"><dir name="Order"><file name="Api.php" hash="23c8d41e5e5de6693f50da385b3aea78"/></dir><dir name="Quote"><file name="Api.php" hash="6382889ea9b658060e2b3604d42a7b8b"/></dir></dir><dir name="System"><dir name="Config"><file name="ConnectOrDisconnect.php" hash="bfeaeb7152944d04e31f2a7cd487a158"/><dir name="Form"><dir name="Field"><file name="Button.php" hash="62196c755745cccdc308f80862f4e1bd"/></dir></dir></dir></dir></dir><dir name="etc"><file name="adminhtml.xml" hash="59bd9b7e4e9dc58762915abe70a7ff11"/><file name="api.xml" hash="bcd37cd4e51595bb3e5328c255c51070"/><file name="config.xml" hash="a2a67122e7a53d5ac772170eaf7bc673"/><file name="system.xml" hash="d4c9c969f0c4071cb1259a438909b631"/></dir></dir></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="autorespondermax.xml" hash="09e47d31eb920a33ecaded8a93e15b9d"/></dir><dir name="template"><dir name="autorespondermax"><file name="cart.phtml" hash="e4d40ee73e8f493074836235ecc39c89"/><file name="convert.phtml" hash="3f6dbfa1d8ded02fb0bebf2d50cc0ce6"/></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Autorespondermax_Autorespondermax.xml" hash="3cbd2eb6af9c8b2c938934a0fb4481ab"/></dir></target></contents>
|
| 16 |
<compatible/>
|
| 17 |
<dependencies><required><php><min>5.0.0</min><max>6.0.0</max></php></required></dependencies>
|
| 18 |
</package>
|
