Ebizmarts_MageMonkey - Version 1.2.5

Version Notes

1.2.5
--------
Bug Fixes:
Fixed Back end order creation process exception when creating new customer.
Fixed Remove from quote when no stock available for Abandoned Cart Recovery emails. It still sends the email if backorders is enabled.
Fixed redundant code and set it to set the first name and last name of the configured settings if none other available.
Fixed cookie handling to delete the campaign cookie when order is made.
Fixed Feed Update error for admin notifications.
Removed Auto-login feature from Abandoned Carts Recovery.
Fixed compatibility problem with SagePay checkout subscription with some payment methods.
Fixed problem for order emails when Mandrill configured per store view.

Enhancements:
Added configuration to enable/disable webhook creation.
Webhook handle process asynchronous to remove some stress from the server when big changes are made on the MailChimp List.
Added compatibility with Fire checkout subscription.

Download this release

Release Info

Developer Ebizmarts Development Team
Extension Ebizmarts_MageMonkey
Version 1.2.5
Comparing to
See all releases


Code changes from version 1.2.3 to 1.2.5

Files changed (37) hide show
  1. app/code/community/Ebizmarts/AbandonedCart/Model/Config.php +0 -1
  2. app/code/community/Ebizmarts/AbandonedCart/Model/Cron.php +3 -2
  3. app/code/community/Ebizmarts/AbandonedCart/controllers/AbandonedController.php +0 -14
  4. app/code/community/Ebizmarts/AbandonedCart/etc/config.xml +1 -1
  5. app/code/community/Ebizmarts/AbandonedCart/etc/system.xml +0 -13
  6. app/code/community/Ebizmarts/Autoresponder/Model/Cron.php +8 -1
  7. app/code/community/Ebizmarts/Autoresponder/Model/System/Config/Registeredcustomergroup.php +23 -0
  8. app/code/community/Ebizmarts/Autoresponder/etc/config.xml +1 -1
  9. app/code/community/Ebizmarts/Autoresponder/etc/system.xml +1 -1
  10. app/code/community/Ebizmarts/MageMonkey/Helper/Data.php +81 -27
  11. app/code/community/Ebizmarts/MageMonkey/Model/Asyncwebhooks.php +22 -0
  12. app/code/community/Ebizmarts/MageMonkey/Model/Config.php +2 -0
  13. app/code/community/Ebizmarts/MageMonkey/Model/Cron.php +303 -0
  14. app/code/community/Ebizmarts/MageMonkey/Model/Ecommerce360.php +17 -2
  15. app/code/community/Ebizmarts/MageMonkey/Model/Monkey.php +6 -243
  16. app/code/community/Ebizmarts/MageMonkey/Model/Mysql4/Asyncwebhooks.php +22 -0
  17. app/code/community/Ebizmarts/MageMonkey/Model/Mysql4/Asyncwebhooks/Collection.php +23 -0
  18. app/code/community/Ebizmarts/MageMonkey/Model/Observer.php +98 -64
  19. app/code/community/Ebizmarts/MageMonkey/controllers/WebhookController.php +0 -1
  20. app/code/community/Ebizmarts/MageMonkey/etc/config.xml +30 -2
  21. app/code/community/Ebizmarts/MageMonkey/etc/system.xml +23 -12
  22. app/code/community/Ebizmarts/MageMonkey/sql/monkey_setup/mysql4-upgrade-1.1.23-1.1.24.php +5 -1
  23. app/code/community/Ebizmarts/MageMonkey/sql/monkey_setup/mysql4-upgrade-1.2.4-1.2.5.php +21 -0
  24. app/code/community/Ebizmarts/Mandrill/Model/Email/Queue.php +88 -39
  25. app/code/community/Ebizmarts/Mandrill/Model/Email/Template.php +3 -2
  26. app/code/community/Ebizmarts/Mandrill/etc/config.xml +1 -1
  27. app/design/adminhtml/default/default/template/ebizmarts/abandonedcart/system/config/fieldset/hint.phtml +1 -1
  28. app/design/adminhtml/default/default/template/ebizmarts/autoresponder/system/config/fieldset/hint.phtml +1 -1
  29. app/design/adminhtml/default/default/template/ebizmarts/mandrill/system/config/fieldset/hint.phtml +1 -1
  30. app/design/adminhtml/default/default/template/magemonkey/system/config/fieldset/hint.phtml +1 -1
  31. app/design/adminhtml/default/default/template/sweetmonkey/system/config/fieldset/hint.phtml +1 -1
  32. app/design/frontend/base/default/template/ebizmarts_abandonedcart/email/order/.DS_Store +0 -0
  33. app/design/frontend/base/default/template/ebizmarts_abandonedcart/email/order/items/order/.DS_Store +0 -0
  34. app/design/frontend/base/default/template/ebizmarts_abandonedcart/popup/emailcatcher.phtml +30 -27
  35. js/ebizmarts/magemonkey/campaignCatcher.js +28 -27
  36. package.xml +18 -17
  37. skin/adminhtml/default/default/ebizmarts/Logo_Ebizmarts.png +0 -0
app/code/community/Ebizmarts/AbandonedCart/Model/Config.php CHANGED
@@ -33,7 +33,6 @@ class Ebizmarts_AbandonedCart_Model_Config
33
  const FOURTH_SUBJECT = "ebizmarts_abandonedcart/general/subject4";
34
  const FIFTH_SUBJECT = "ebizmarts_abandonedcart/general/subject5";
35
  const LOG = "ebizmarts_abandonedcart/general/log";
36
- const AUTOLOGIN = "ebizmarts_abandonedcart/general/autologin";
37
  const ABANDONED_TAGS = 'global/ebizmarts_abandonedcart/mandrill-tag';
38
  const IN_DAYS = 0;
39
  const IN_HOURS = 1;
33
  const FOURTH_SUBJECT = "ebizmarts_abandonedcart/general/subject4";
34
  const FIFTH_SUBJECT = "ebizmarts_abandonedcart/general/subject5";
35
  const LOG = "ebizmarts_abandonedcart/general/log";
 
36
  const ABANDONED_TAGS = 'global/ebizmarts_abandonedcart/mandrill-tag';
37
  const IN_DAYS = 0;
38
  const IN_HOURS = 1;
app/code/community/Ebizmarts/AbandonedCart/Model/Cron.php CHANGED
@@ -162,7 +162,7 @@ class Ebizmarts_AbandonedCart_Model_Cron
162
  }
163
  // for each cart of the current run
164
  foreach ($collection as $quote) {
165
- $this->_proccessCollection($quote, $storeId);
166
 
167
  if (count($quote->getAllVisibleItems()) < 1) {
168
  $quote2 = Mage::getModel('sales/quote')->loadByIdWithoutStore($quote->getId());
@@ -335,7 +335,7 @@ class Ebizmarts_AbandonedCart_Model_Cron
335
  is_object($stock) && ($stock->getManageStock() ||
336
  ($stock->getUseConfigManageStock() && Mage::getStoreConfig('cataloginventory/item_options/manage_stock', $quote->getStoreId())))
337
  )
338
- && $stockQty < $item->getQty() && (!$inventory->getBackorders() || $stockItem->getBackorders())
339
  ) {
340
  Mage::log('AbandonedCart; ' . $product->getSku() . ' is no longer in stock; remove from quote ' . $quote->getId() . ' for email', null, 'Ebizmarts_AbandonedCart.log');
341
  $removeFromQuote = true;
@@ -344,6 +344,7 @@ class Ebizmarts_AbandonedCart_Model_Cron
344
  $quote->removeItem($item->getId());
345
  }
346
  }
 
347
  }
348
  protected function _sendPopupCoupon($storeId)
349
  {
162
  }
163
  // for each cart of the current run
164
  foreach ($collection as $quote) {
165
+ $quote = $this->_proccessCollection($quote, $storeId);
166
 
167
  if (count($quote->getAllVisibleItems()) < 1) {
168
  $quote2 = Mage::getModel('sales/quote')->loadByIdWithoutStore($quote->getId());
335
  is_object($stock) && ($stock->getManageStock() ||
336
  ($stock->getUseConfigManageStock() && Mage::getStoreConfig('cataloginventory/item_options/manage_stock', $quote->getStoreId())))
337
  )
338
+ && $stockQty < $item->getQty() && (!$inventory->getBackorders() || !$stockItem->getBackorders())
339
  ) {
340
  Mage::log('AbandonedCart; ' . $product->getSku() . ' is no longer in stock; remove from quote ' . $quote->getId() . ' for email', null, 'Ebizmarts_AbandonedCart.log');
341
  $removeFromQuote = true;
344
  $quote->removeItem($item->getId());
345
  }
346
  }
347
+ return $quote;
348
  }
349
  protected function _sendPopupCoupon($storeId)
350
  {
app/code/community/Ebizmarts/AbandonedCart/controllers/AbandonedController.php CHANGED
@@ -48,10 +48,6 @@ class Ebizmarts_AbandonedCart_AbandonedController extends Mage_Checkout_CartCont
48
  $quote->setCouponCode($params['coupon']);
49
  $quote->save();
50
  }
51
- if ((!isset($params['token']) || (isset($params['token']) && $params['token'] != $quote->getEbizmartsAbandonedcartToken())) && Mage::getStoreConfig(Ebizmarts_AbandonedCart_Model_Config::AUTOLOGIN, $quote->getStoreId())) {
52
- Mage::getSingleton('customer/session')->addNotice("Your token cart is incorrect");
53
- $this->_redirect($url);
54
- } else {
55
  $url = Mage::getUrl(Mage::getStoreConfig(Ebizmarts_AbandonedCart_Model_Config::PAGE, $quote->getStoreId()));
56
  $first = true;
57
  foreach($analytics as $key => $value) {
@@ -71,14 +67,6 @@ class Ebizmarts_AbandonedCart_AbandonedController extends Mage_Checkout_CartCont
71
  $this->getResponse()
72
  ->setRedirect($url, 301);
73
  } else {
74
- if (Mage::getStoreConfig(Ebizmarts_AbandonedCart_Model_Config::AUTOLOGIN, $quote->getStoreId())) {
75
- $customer = Mage::getModel('customer/customer')->load($quote->getCustomerId());
76
- if ($customer->getId()) {
77
- Mage::getSingleton('customer/session')->setCustomerAsLoggedIn($customer);
78
- }
79
- $this->getResponse()
80
- ->setRedirect($url, 301);
81
- } else {
82
  if (Mage::helper('customer')->isLoggedIn()) {
83
  $this->getResponse()
84
  ->setRedirect($url, 301);
@@ -86,9 +74,7 @@ class Ebizmarts_AbandonedCart_AbandonedController extends Mage_Checkout_CartCont
86
  Mage::getSingleton('customer/session')->addNotice("Login to complete your order");
87
  $this->_redirect('customer/account');
88
  }
89
- }
90
  }
91
- }
92
  }
93
  // $this->_redirect('checkout/cart');
94
  }
48
  $quote->setCouponCode($params['coupon']);
49
  $quote->save();
50
  }
 
 
 
 
51
  $url = Mage::getUrl(Mage::getStoreConfig(Ebizmarts_AbandonedCart_Model_Config::PAGE, $quote->getStoreId()));
52
  $first = true;
53
  foreach($analytics as $key => $value) {
67
  $this->getResponse()
68
  ->setRedirect($url, 301);
69
  } else {
 
 
 
 
 
 
 
 
70
  if (Mage::helper('customer')->isLoggedIn()) {
71
  $this->getResponse()
72
  ->setRedirect($url, 301);
74
  Mage::getSingleton('customer/session')->addNotice("Login to complete your order");
75
  $this->_redirect('customer/account');
76
  }
 
77
  }
 
78
  }
79
  // $this->_redirect('checkout/cart');
80
  }
app/code/community/Ebizmarts/AbandonedCart/etc/config.xml CHANGED
@@ -10,7 +10,7 @@
10
  <config>
11
  <modules>
12
  <Ebizmarts_AbandonedCart>
13
- <version>1.2.2.1</version>
14
  </Ebizmarts_AbandonedCart>
15
  </modules>
16
  <global>
10
  <config>
11
  <modules>
12
  <Ebizmarts_AbandonedCart>
13
+ <version>1.2.3</version>
14
  </Ebizmarts_AbandonedCart>
15
  </modules>
16
  <global>
app/code/community/Ebizmarts/AbandonedCart/etc/system.xml CHANGED
@@ -356,19 +356,6 @@
356
  <active>1</active>
357
  </depends>
358
  </customer>
359
- <autologin translate="label comment">
360
- <label>Auto Login link</label>
361
- <frontend_type>select</frontend_type>
362
- <source_model>adminhtml/system_config_source_yesno</source_model>
363
- <sort_order>65</sort_order>
364
- <show_in_default>1</show_in_default>
365
- <show_in_website>1</show_in_website>
366
- <show_in_store>1</show_in_store>
367
- <comment><![CDATA[The client will be autologed when click on mail link]]></comment>
368
- <depends>
369
- <active>1</active>
370
- </depends>
371
- </autologin>
372
  </fields>
373
  </general>
374
  <coupon>
356
  <active>1</active>
357
  </depends>
358
  </customer>
 
 
 
 
 
 
 
 
 
 
 
 
 
359
  </fields>
360
  </general>
361
  <coupon>
app/code/community/Ebizmarts/Autoresponder/Model/Cron.php CHANGED
@@ -615,7 +615,14 @@ class Ebizmarts_Autoresponder_Model_Cron
615
  $senderId = Mage::getStoreConfig(Ebizmarts_Autoresponder_Model_Config::GENERAL_SENDER, $storeId);
616
  $sender = array('name' => Mage::getStoreConfig("trans_email/ident_$senderId/name", $storeId), 'email' => Mage::getStoreConfig("trans_email/ident_$senderId/email", $storeId));
617
  $templateId = Mage::getStoreConfig(Ebizmarts_Autoresponder_Model_Config::VISITED_TEMPLATE, $storeId);
618
- $url = Mage::getModel('core/url')->setStore($storeId)->getUrl() . 'ebizautoresponder/autoresponder/unsubscribe?list=visitedproducts&email=' . $email . '&store=' . $storeId;
 
 
 
 
 
 
 
619
  $vars = array('name' => $name, 'tags' => array($tags), 'products' => $products, 'url' => $url);
620
 
621
  $customer = Mage::getModel('customer/customer')
615
  $senderId = Mage::getStoreConfig(Ebizmarts_Autoresponder_Model_Config::GENERAL_SENDER, $storeId);
616
  $sender = array('name' => Mage::getStoreConfig("trans_email/ident_$senderId/name", $storeId), 'email' => Mage::getStoreConfig("trans_email/ident_$senderId/email", $storeId));
617
  $templateId = Mage::getStoreConfig(Ebizmarts_Autoresponder_Model_Config::VISITED_TEMPLATE, $storeId);
618
+ $store=Mage::getModel('core/store')->load($storeId);
619
+ $storeCode=$store->getCode();
620
+ $storeCodeUrl = Mage::getStoreConfig('web/url/use_store', $storeId);
621
+ if($storeCodeUrl){
622
+ $url = Mage::getModel('core/url')->setStore($storeId)->getUrl() . $storeCode . '/ebizautoresponder/autoresponder/unsubscribe?list=visitedproducts&email=' . $email . '&store=' . $storeId;
623
+ }else {
624
+ $url = Mage::getModel('core/url')->setStore($storeId)->getUrl() . 'ebizautoresponder/autoresponder/unsubscribe?list=visitedproducts&email=' . $email . '&store=' . $storeId;
625
+ }
626
  $vars = array('name' => $name, 'tags' => array($tags), 'products' => $products, 'url' => $url);
627
 
628
  $customer = Mage::getModel('customer/customer')
app/code/community/Ebizmarts/Autoresponder/Model/System/Config/Registeredcustomergroup.php ADDED
@@ -0,0 +1,23 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ *
5
+ * @category Ebizmarts
6
+ * @package Ebizmarts_Autoresponder
7
+ * @author Ebizmarts Team <info@ebizmarts.com>
8
+ * @license http://opensource.org/licenses/osl-3.0.php
9
+ */
10
+ class Ebizmarts_Autoresponder_Model_System_Config_Registeredcustomergroup
11
+ {
12
+ protected $_options;
13
+
14
+ public function toOptionArray()
15
+ {
16
+ if (!$this->_options) {
17
+ $this->_options = Mage::getResourceModel('customer/group_collection')
18
+ ->loadData()->toOptionArray();
19
+ }
20
+ unset($this->_options[0]);
21
+ return $this->_options;
22
+ }
23
+ }
app/code/community/Ebizmarts/Autoresponder/etc/config.xml CHANGED
@@ -10,7 +10,7 @@
10
  <config>
11
  <modules>
12
  <Ebizmarts_Autoresponder>
13
- <version>1.2.1.1</version>
14
  </Ebizmarts_Autoresponder>
15
  </modules>
16
  <global>
10
  <config>
11
  <modules>
12
  <Ebizmarts_Autoresponder>
13
+ <version>1.2.2</version>
14
  </Ebizmarts_Autoresponder>
15
  </modules>
16
  <global>
app/code/community/Ebizmarts/Autoresponder/etc/system.xml CHANGED
@@ -552,7 +552,7 @@
552
  <customer_coupon translate="label comment">
553
  <label>Customer Groups for coupon</label>
554
  <frontend_type>multiselect</frontend_type>
555
- <source_model>ebizmarts_autoresponder/system_config_customergroup</source_model>
556
  <sort_order>110</sort_order>
557
  <show_in_default>1</show_in_default>
558
  <show_in_website>1</show_in_website>
552
  <customer_coupon translate="label comment">
553
  <label>Customer Groups for coupon</label>
554
  <frontend_type>multiselect</frontend_type>
555
+ <source_model>ebizmarts_autoresponder/system_config_registeredcustomergroup</source_model>
556
  <sort_order>110</sort_order>
557
  <show_in_default>1</show_in_default>
558
  <show_in_website>1</show_in_website>
app/code/community/Ebizmarts/MageMonkey/Helper/Data.php CHANGED
@@ -437,7 +437,7 @@ class Ebizmarts_MageMonkey_Helper_Data extends Mage_Core_Helper_Abstract
437
  if($customer->getSubscriberFirstname()){
438
  $guestFirstName = $this->config('guest_name', $customer->getStoreId());
439
  }elseif($this->config('guest_name', $customer->getStoreId())) {
440
- $guestFirstName = $customer->getSubscriberFirstname();
441
  }
442
 
443
  if ($guestFirstName) {
@@ -449,7 +449,7 @@ class Ebizmarts_MageMonkey_Helper_Data extends Mage_Core_Helper_Abstract
449
  if($customer->getSubscriberLastname()){
450
  $guestLastName = $this->config('guest_lastname', $customer->getStoreId());
451
  }elseif($this->config('guest_lastname', $customer->getStoreId())){
452
- $guestLastName = $customer->getSubscriberLastname();
453
  }
454
 
455
  if ($guestLastName) {
@@ -498,6 +498,49 @@ class Ebizmarts_MageMonkey_Helper_Data extends Mage_Core_Helper_Abstract
498
  //magemonkey_mergevars_after
499
  return $merge_vars;
500
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
501
  private function _setMaps($maps,$customer,$merge_vars, $websiteId)
502
  {
503
  foreach ($maps as $map) {
@@ -593,14 +636,19 @@ class Ebizmarts_MageMonkey_Helper_Data extends Mage_Core_Helper_Abstract
593
  }
594
  return $merge_vars;
595
  }
596
- protected function _setAddress($customAtt,$merge_vars, $customer, $key)
597
  {
598
-
599
- $addr = explode('_', $customAtt);
600
- $address = $customer->{'getPrimary' . ucfirst($addr[0]) . 'Address'}();
601
- if (!$address) {
602
- if ($customer->{'getDefault' . ucfirst($addr[0])}()) {
603
- $address = Mage::getModel('customer/address')->load($customer->{'getDefault' . ucfirst($addr[0])}());
 
 
 
 
 
604
  }
605
  }
606
  if ($address) {
@@ -917,26 +965,27 @@ class Ebizmarts_MageMonkey_Helper_Data extends Mage_Core_Helper_Abstract
917
  *
918
  * @param $object
919
  * @param $db
 
920
  */
921
- public function listsSubscription($object, $db)
922
  {
923
  $monkeyPost = Mage::getSingleton('core/session')->getMonkeyPost();
924
  $post = unserialize($monkeyPost);
925
  if (isset($post['magemonkey_force'])) {
926
  foreach ($post['list'] as $list) {
927
  $listId = $list['subscribed'];
928
- $this->subscribeToList($object, $db, $listId);
929
  }
930
  } elseif (isset($post['magemonkey_subscribe']) && $post['magemonkey_subscribe']) {
931
  $lists = explode(',', $post['magemonkey_subscribe']);
932
  foreach ($lists as $listId) {
933
- $this->subscribeToList($object, $db, $listId);
934
  }
935
  //Subscription for One Step Checkout with force subscription
936
  } elseif (Mage::getSingleton('core/session')->getIsOneStepCheckout() && Mage::helper('monkey')->config('checkout_subscribe') > 2 && !Mage::getSingleton('core/session')->getIsUpdateCustomer()) {
937
- $this->subscribeToList($object, $db);
938
  } elseif(!Mage::getSingleton('core/session')->getMonkeyCheckout()){
939
- $this->subscribeToList($object, $db, NULL, TRUE);
940
  }
941
 
942
  }
@@ -947,8 +996,10 @@ class Ebizmarts_MageMonkey_Helper_Data extends Mage_Core_Helper_Abstract
947
  * @param $object
948
  * @param $db
949
  * @param null $listId
 
 
950
  */
951
- public function subscribeToList($object, $db, $listId = NULL, $forceSubscribe = FALSE)
952
  {
953
  $email = $object->getEmail();
954
  $storeId = $object->getStoreId();
@@ -964,8 +1015,16 @@ class Ebizmarts_MageMonkey_Helper_Data extends Mage_Core_Helper_Abstract
964
  $listId = $defaultList;
965
  }
966
  $alreadySubscribed = Mage::getSingleton('newsletter/subscriber')->loadByEmail($email);
 
 
 
 
 
 
 
967
  if ($listId == $defaultList && !Mage::getSingleton('core/session')->getIsHandleSubscriber() && !$forceSubscribe && (!$alreadySubscribed || !$alreadySubscribed->getId())) {
968
  $subscriber->setStoreId($storeId)->subscribe($email);
 
969
  } else {
970
  $alreadyOnList = Mage::getSingleton('monkey/asyncsubscribers')->getCollection()
971
  ->addFieldToFilter('lists', $listId)
@@ -973,19 +1032,12 @@ class Ebizmarts_MageMonkey_Helper_Data extends Mage_Core_Helper_Abstract
973
  ->addFieldToFilter('processed', 0);
974
  //if not in magemonkey_async_subscribers with processed 0 add list
975
  if (count($alreadyOnList) == 0) {
976
- $isConfirmNeed = FALSE;
977
- if (!Mage::helper('monkey')->isAdmin() &&
978
- (Mage::getStoreConfig(Mage_Newsletter_Model_Subscriber::XML_PATH_CONFIRMATION_FLAG, $object->getStoreId()) == 1 && !Mage::getStoreConfig(Ebizmarts_MageMonkey_Model_Config::GENERAL_CONFIRMATION_EMAIL, $object->getStoreId()) || $forceSubscribe && Mage::getSingleton('core/session')->getMonkeyCheckout())
979
- ) {
980
- $isConfirmNeed = TRUE;
981
- }
982
 
983
  $isOnMailChimp = Mage::helper('monkey')->subscribedToList($email, $listId);
984
  //if( TRUE === $subscriber->getIsStatusChanged() ){
985
  if ($isOnMailChimp == 1) {
986
  if(Mage::getSingleton('core/session')->getIsOneStepCheckout() || Mage::getSingleton('core/session')->getMonkeyCheckout()) {
987
- $mergeVars = Mage::helper('monkey')->mergeVars($object, FALSE, $listId);
988
- $this->_subscribe($listId, $email, $mergeVars, 0, 1);
989
  }
990
  return;
991
  }
@@ -994,9 +1046,9 @@ class Ebizmarts_MageMonkey_Helper_Data extends Mage_Core_Helper_Abstract
994
  $subscriber->setStatus(Mage_Newsletter_Model_Subscriber::STATUS_UNCONFIRMED);
995
  }
996
 
997
- $mergeVars = Mage::helper('monkey')->mergeVars($object, FALSE, $listId);
998
- $this->_subscribe($listId, $email, $mergeVars, $isConfirmNeed, $db);
999
- if(Mage::getSingleton('core/session')->getMonkeyCheckout()){
1000
  $subscriber->subscribe($email);
1001
  }
1002
  }
@@ -1012,8 +1064,9 @@ class Ebizmarts_MageMonkey_Helper_Data extends Mage_Core_Helper_Abstract
1012
  * @param $mergeVars
1013
  * @param $isConfirmNeed
1014
  * @param $db
 
1015
  */
1016
- public function _subscribe($listId, $email, $mergeVars, $isConfirmNeed, $db)
1017
  {
1018
  if ($db) {
1019
  if ($isConfirmNeed) {
@@ -1026,6 +1079,7 @@ class Ebizmarts_MageMonkey_Helper_Data extends Mage_Core_Helper_Abstract
1026
  ->setConfirm($isConfirmNeed)
1027
  ->setProcessed(0)
1028
  ->setCreatedAt(Mage::getModel('core/date')->gmtDate())
 
1029
  ->save();
1030
  } else {
1031
  if ($isConfirmNeed) {
437
  if($customer->getSubscriberFirstname()){
438
  $guestFirstName = $this->config('guest_name', $customer->getStoreId());
439
  }elseif($this->config('guest_name', $customer->getStoreId())) {
440
+ $guestFirstName = $this->config('guest_name', $customer->getStoreId());
441
  }
442
 
443
  if ($guestFirstName) {
449
  if($customer->getSubscriberLastname()){
450
  $guestLastName = $this->config('guest_lastname', $customer->getStoreId());
451
  }elseif($this->config('guest_lastname', $customer->getStoreId())){
452
+ $guestLastName = $this->config('guest_lastname', $customer->getStoreId());
453
  }
454
 
455
  if ($guestLastName) {
498
  //magemonkey_mergevars_after
499
  return $merge_vars;
500
  }
501
+
502
+ public function getMergeVarsFromOrder($maps, $order, $merge_vars){
503
+
504
+ foreach ($maps as $map) {
505
+
506
+ $customAtt = $map['magento'];
507
+ $chimpTag = $map['mailchimp'];
508
+
509
+ if ($chimpTag && $customAtt) {
510
+
511
+ $key = strtoupper($chimpTag);
512
+
513
+ switch ($customAtt) {
514
+
515
+ case 'billing_address':
516
+ case 'shipping_address':
517
+ $merge_vars = array_merge($merge_vars, $this->_setAddress($customAtt,$merge_vars, $order, $key));
518
+ break;
519
+ case 'date_of_purchase':
520
+
521
+ $merge_vars[$key] = $order->getUpdatedAt();
522
+
523
+ break;
524
+
525
+ case 'store_code':
526
+ $storeId = (string)$order->getData('store_id');
527
+ $storeCode = Mage::getModel('core/store')->load($storeId)->getCode();
528
+ if ($storeCode) {
529
+ $merge_vars[$key] = $storeCode;
530
+ }
531
+ break;
532
+ case 'fname':
533
+ $merge_vars[$key] = $order->getCustomerFirstname();
534
+ break;
535
+ case 'lname':
536
+ $merge_vars[$key] = $order->getCustomerLastname();
537
+ break;
538
+ }
539
+
540
+ }
541
+ }
542
+ return $merge_vars;
543
+ }
544
  private function _setMaps($maps,$customer,$merge_vars, $websiteId)
545
  {
546
  foreach ($maps as $map) {
636
  }
637
  return $merge_vars;
638
  }
639
+ protected function _setAddress($customAtt,$merge_vars, $object, $key)
640
  {
641
+ if($object instanceof Mage_Sales_Model_Order){
642
+ $addr = explode('_', $customAtt);
643
+ $address = $object->{'get' . ucfirst($addr[0]) . 'Address'}();
644
+ }else {
645
+
646
+ $addr = explode('_', $customAtt);
647
+ $address = $object->{'getPrimary' . ucfirst($addr[0]) . 'Address'}();
648
+ if (!$address) {
649
+ if ($object->{'getDefault' . ucfirst($addr[0])}()) {
650
+ $address = Mage::getModel('customer/address')->load($object->{'getDefault' . ucfirst($addr[0])}());
651
+ }
652
  }
653
  }
654
  if ($address) {
965
  *
966
  * @param $object
967
  * @param $db
968
+ * @param $orderId
969
  */
970
+ public function listsSubscription($object, $db, $orderId = null)
971
  {
972
  $monkeyPost = Mage::getSingleton('core/session')->getMonkeyPost();
973
  $post = unserialize($monkeyPost);
974
  if (isset($post['magemonkey_force'])) {
975
  foreach ($post['list'] as $list) {
976
  $listId = $list['subscribed'];
977
+ $this->subscribeToList($object, $db, $listId, false, $orderId);
978
  }
979
  } elseif (isset($post['magemonkey_subscribe']) && $post['magemonkey_subscribe']) {
980
  $lists = explode(',', $post['magemonkey_subscribe']);
981
  foreach ($lists as $listId) {
982
+ $this->subscribeToList($object, $db, $listId, false, $orderId);
983
  }
984
  //Subscription for One Step Checkout with force subscription
985
  } elseif (Mage::getSingleton('core/session')->getIsOneStepCheckout() && Mage::helper('monkey')->config('checkout_subscribe') > 2 && !Mage::getSingleton('core/session')->getIsUpdateCustomer()) {
986
+ $this->subscribeToList($object, $db, null, false, $orderId);
987
  } elseif(!Mage::getSingleton('core/session')->getMonkeyCheckout()){
988
+ $this->subscribeToList($object, $db, NULL, TRUE, $orderId);
989
  }
990
 
991
  }
996
  * @param $object
997
  * @param $db
998
  * @param null $listId
999
+ * @param $forceSubscribe
1000
+ * @param $orderId
1001
  */
1002
+ public function subscribeToList($object, $db, $listId = NULL, $forceSubscribe = FALSE, $orderId = null)
1003
  {
1004
  $email = $object->getEmail();
1005
  $storeId = $object->getStoreId();
1015
  $listId = $defaultList;
1016
  }
1017
  $alreadySubscribed = Mage::getSingleton('newsletter/subscriber')->loadByEmail($email);
1018
+ $mergeVars = Mage::helper('monkey')->mergeVars($object, FALSE, $listId);
1019
+ $isConfirmNeed = FALSE;
1020
+ if (!Mage::helper('monkey')->isAdmin() &&
1021
+ (Mage::getStoreConfig(Mage_Newsletter_Model_Subscriber::XML_PATH_CONFIRMATION_FLAG, $object->getStoreId()) == 1 && !Mage::getStoreConfig(Ebizmarts_MageMonkey_Model_Config::GENERAL_CONFIRMATION_EMAIL, $object->getStoreId()) || $forceSubscribe && Mage::getSingleton('core/session')->getMonkeyCheckout())
1022
+ ) {
1023
+ $isConfirmNeed = TRUE;
1024
+ }
1025
  if ($listId == $defaultList && !Mage::getSingleton('core/session')->getIsHandleSubscriber() && !$forceSubscribe && (!$alreadySubscribed || !$alreadySubscribed->getId())) {
1026
  $subscriber->setStoreId($storeId)->subscribe($email);
1027
+ $this->_subscribe($listId, $email, $mergeVars, $isConfirmNeed, $db, $orderId);
1028
  } else {
1029
  $alreadyOnList = Mage::getSingleton('monkey/asyncsubscribers')->getCollection()
1030
  ->addFieldToFilter('lists', $listId)
1032
  ->addFieldToFilter('processed', 0);
1033
  //if not in magemonkey_async_subscribers with processed 0 add list
1034
  if (count($alreadyOnList) == 0) {
 
 
 
 
 
 
1035
 
1036
  $isOnMailChimp = Mage::helper('monkey')->subscribedToList($email, $listId);
1037
  //if( TRUE === $subscriber->getIsStatusChanged() ){
1038
  if ($isOnMailChimp == 1) {
1039
  if(Mage::getSingleton('core/session')->getIsOneStepCheckout() || Mage::getSingleton('core/session')->getMonkeyCheckout()) {
1040
+ $this->_subscribe($listId, $email, $mergeVars, 0, 1, $orderId);
 
1041
  }
1042
  return;
1043
  }
1046
  $subscriber->setStatus(Mage_Newsletter_Model_Subscriber::STATUS_UNCONFIRMED);
1047
  }
1048
 
1049
+ $this->_subscribe($listId, $email, $mergeVars, $isConfirmNeed, $db, $orderId);
1050
+ $subscriberExists = Mage::getModel('newsletter/subscriber')->loadbyEmail($email);
1051
+ if(Mage::getSingleton('core/session')->getMonkeyCheckout() && !$subscriberExists->getId()){
1052
  $subscriber->subscribe($email);
1053
  }
1054
  }
1064
  * @param $mergeVars
1065
  * @param $isConfirmNeed
1066
  * @param $db
1067
+ * @param $orderId
1068
  */
1069
+ public function _subscribe($listId, $email, $mergeVars, $isConfirmNeed, $db, $orderId = null)
1070
  {
1071
  if ($db) {
1072
  if ($isConfirmNeed) {
1079
  ->setConfirm($isConfirmNeed)
1080
  ->setProcessed(0)
1081
  ->setCreatedAt(Mage::getModel('core/date')->gmtDate())
1082
+ ->setOrderId($orderId)
1083
  ->save();
1084
  } else {
1085
  if ($isConfirmNeed) {
app/code/community/Ebizmarts/MageMonkey/Model/Asyncwebhooks.php ADDED
@@ -0,0 +1,22 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ * Author : Ebizmarts <info@ebizmarts.com>
5
+ * Date : 9/15/14
6
+ * Time : 12:46 PM
7
+ * File : Asyncwebhooks.php
8
+ * Module : Ebizmarts_MageMonkey
9
+ */
10
+ class Ebizmarts_MageMonkey_Model_Asyncwebhooks extends Mage_Core_Model_Abstract
11
+ {
12
+ /**
13
+ * Initialize model
14
+ *
15
+ * @return void
16
+ */
17
+ public function _construct()
18
+ {
19
+ parent::_construct();
20
+ $this->_init('monkey/asyncwebhooks');
21
+ }
22
+ }
app/code/community/Ebizmarts/MageMonkey/Model/Config.php CHANGED
@@ -35,6 +35,8 @@ class Ebizmarts_MageMonkey_Model_Config
35
  const GENERAL_ADMINHTML_NOTIFICATION = 'monkey/general/adminhtml_notification';
36
  const GENERAL_ENABLE_LOG = 'monkey/general/enable_log';
37
 
 
 
38
 
39
  const ECOMMERCE360_ACTIVE = 'monkey/ecommerce360/active';
40
  const ECOMMERCE360_ORDER_STATUS = 'monkey/ecommerce360/order_status';
35
  const GENERAL_ADMINHTML_NOTIFICATION = 'monkey/general/adminhtml_notification';
36
  const GENERAL_ENABLE_LOG = 'monkey/general/enable_log';
37
 
38
+ const GENERAL_CHECKOUT_SUBSCRIBE_DATA = 'monkey/general/checkout_subscribe_data';
39
+
40
 
41
  const ECOMMERCE360_ACTIVE = 'monkey/ecommerce360/active';
42
  const ECOMMERCE360_ORDER_STATUS = 'monkey/ecommerce360/order_status';
app/code/community/Ebizmarts/MageMonkey/Model/Cron.php CHANGED
@@ -487,6 +487,9 @@ class Ebizmarts_MageMonkey_Model_Cron
487
  $oldList = $newList;
488
  }
489
  $mergeVars = unserialize($item->getMapfields());
 
 
 
490
  if ($newList != $oldList || $eachIsConfirmNeed != $isConfirmNeed) {
491
  if (count($batch) > 0) {
492
  Mage::getSingleton('monkey/api')->listBatchSubscribe($oldList, $batch, $isConfirmNeed, TRUE, FALSE);
@@ -512,6 +515,13 @@ class Ebizmarts_MageMonkey_Model_Cron
512
 
513
  }
514
 
 
 
 
 
 
 
 
515
  public function cleanSubscribersAsync()
516
  {
517
  $collection = Mage::getModel('monkey/asyncsubscribers')->getCollection();
@@ -520,4 +530,297 @@ class Ebizmarts_MageMonkey_Model_Cron
520
  $item->delete();
521
  }
522
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
523
  }
487
  $oldList = $newList;
488
  }
489
  $mergeVars = unserialize($item->getMapfields());
490
+ if($item->getOrderId()){
491
+ $mergeVars = $this->_addOrderData($item->getOrderId(), $mergeVars);
492
+ }
493
  if ($newList != $oldList || $eachIsConfirmNeed != $isConfirmNeed) {
494
  if (count($batch) > 0) {
495
  Mage::getSingleton('monkey/api')->listBatchSubscribe($oldList, $batch, $isConfirmNeed, TRUE, FALSE);
515
 
516
  }
517
 
518
+ protected function _addOrderData($orderId, $mergeVars){
519
+ $order = Mage::getModel('sales/order')->load($orderId);
520
+ $maps = Mage::helper('monkey')->getMergeMaps($order->getStoreId());
521
+ $mergeVars = Mage::helper('monkey')->getMergeVarsFromOrder($maps, $order, $mergeVars);
522
+ return $mergeVars;
523
+ }
524
+
525
  public function cleanSubscribersAsync()
526
  {
527
  $collection = Mage::getModel('monkey/asyncsubscribers')->getCollection();
530
  $item->delete();
531
  }
532
  }
533
+
534
+
535
+ public function processWebhookData()
536
+ {
537
+
538
+ $collection = Mage::getModel('monkey/asyncwebhooks')->getCollection();
539
+ $collection->addFieldToFilter('processed', array('eq' => 0));
540
+
541
+ foreach ($collection as $item) {
542
+ $data=json_decode($item->getWebhookData(), true);
543
+ $listId = $data['data']['list_id']; //According to the docs, the events are always related to a list_id
544
+ // $store = Mage::helper('monkey')->getStoreByList($listId);
545
+ $subscriber = Mage::getModel('newsletter/subscriber')
546
+ ->loadByEmail(isset($data['data']['email']));
547
+ $storeId = $subscriber->getStoreId();
548
+ $store = Mage::getModel('core/store')->load($storeId);
549
+ if (!is_null($store)) {
550
+ $curstore = Mage::app()->getStore();
551
+ Mage::app()->setCurrentStore($store);
552
+ }
553
+ // Object for cache clean
554
+ $object = new stdClass();
555
+ $object->requestParams = array();
556
+ $object->requestParams['id'] = $listId;
557
+
558
+ if (isset($data['data']['email'])) {
559
+ $object->requestParams['email_address'] = $data['data']['email'];
560
+ }
561
+ $cacheHelper = Mage::helper('monkey/cache');
562
+
563
+ switch ($item->getWebhookType()) {
564
+ case 'subscribe':
565
+ $this->_subscribe($data);
566
+ $cacheHelper->clearCache('listSubscribe', $object);
567
+ break;
568
+ case 'unsubscribe':
569
+ $this->_unsubscribe($data);
570
+ $cacheHelper->clearCache('listUnsubscribe', $object);
571
+ break;
572
+ case 'cleaned':
573
+ $this->_cleaned($data);
574
+ $cacheHelper->clearCache('listUnsubscribe', $object);
575
+ break;
576
+ case 'campaign':
577
+ $this->_campaign($data);
578
+ break;
579
+ //case 'profile': Cuando se actualiza email en MC como merchant, te manda un upmail y un profile (no siempre en el mismo órden)
580
+ case 'upemail':
581
+ $this->_updateEmail($data);
582
+ $cacheHelper->clearCache('listUpdateMember', $object);
583
+ break;
584
+ case 'profile':
585
+ $this->_profile($data);
586
+ $cacheHelper->clearCache('listUpdateMember', $object);
587
+ break;
588
+ }
589
+
590
+ if (!is_null($store)) {
591
+ Mage::app()->setCurrentStore($curstore);
592
+ }
593
+ $item->setProcessed(1)->save();
594
+
595
+ }
596
+
597
+
598
+ }
599
+
600
+
601
+ /**
602
+ * Subscribe email to Magento list
603
+ *
604
+ * @param array $data
605
+ * @return void
606
+ */
607
+
608
+ protected function _subscribe(array $data)
609
+ {
610
+ try {
611
+
612
+ $subscriber = Mage::getSingleton('newsletter/subscriber')
613
+ ->loadByEmail($data['data']['email']);
614
+ if ($subscriber->getId()) {
615
+
616
+ $subscriber->setStatus(Mage_Newsletter_Model_Subscriber::STATUS_SUBSCRIBED)
617
+ ->save();
618
+ } else {
619
+ $subscriber = Mage::getModel('newsletter/subscriber')->setImportMode(TRUE);
620
+ if(isset($data['data']['fname'])){
621
+ $subscriber->setSubscriberFirstname($data['data']['fname']);
622
+ }
623
+ if(isset($data['data']['lname'])){
624
+ $subscriber->setSubscriberLastname($data['data']['lname']);
625
+ }
626
+ if(isset($data['data']['merges']['STOREID'])){
627
+ $subscriberStoreId=$data['data']['merges']['STOREID'];
628
+ }else {
629
+ $subscriberStoreId = Mage::helper('monkey')->getStoreByList($data['data']['id']);
630
+ }
631
+ Mage::app()->setCurrentStore($subscriberStoreId);
632
+ $subscriber->subscribe($data['data']['email']);
633
+ Mage::app()->setCurrentStore(0);
634
+
635
+ }
636
+ $customerExist = Mage::getSingleton('customer/customer')
637
+ ->getCollection()
638
+ ->addAttributeToFilter('email', array('eq' => $data['data']['email']) )
639
+ ->getFirstItem();
640
+ if($customerExist){
641
+ $storeId = $customerExist->getStoreId();
642
+ }
643
+ if($customerExist && Mage::getStoreConfig('sweetmonkey/general/active', $storeId)){
644
+ Mage::helper('sweetmonkey')->pushVars($customerExist);
645
+ }
646
+ } catch (Exception $e) {
647
+ Mage::logException($e);
648
+ }
649
+ }
650
+
651
+
652
+ /**
653
+ * Unsubscribe or delete email from Magento list
654
+ *
655
+ * @param array $data
656
+ * @return void
657
+ */
658
+
659
+ protected function _unsubscribe(array $data)
660
+ {
661
+ $subscriber = Mage::getSingleton('newsletter/subscriber')
662
+ ->loadByEmail($data['data']['email']);
663
+
664
+ if (!$subscriber->getId()) {
665
+ $subscriber = Mage::getModel('newsletter/subscriber')
666
+ ->loadByEmail($data['data']['email']);
667
+ }
668
+ if($subscriber->getId()){
669
+ try {
670
+ if(!Mage::getStoreConfig(Ebizmarts_MageMonkey_Model_Config::GENERAL_CONFIRMATION_EMAIL, $subscriber->getStoreId())){
671
+ $subscriber->setImportMode(true);
672
+ }
673
+
674
+ switch ($data['data']['action']) {
675
+ case 'delete' :
676
+ //if config setting "Webhooks Delete action" is set as "Delete customer account"
677
+ if (Mage::getStoreConfig("monkey/general/webhook_delete") == 1) {
678
+ $subscriber->delete();
679
+ } else {
680
+ $subscriber->unsubscribe();
681
+ }
682
+ break;
683
+ case 'unsub':
684
+ $subscriber->unsubscribe();
685
+ break;
686
+ }
687
+ } catch (Exception $e) {
688
+ Mage::logException($e);
689
+ }
690
+ }
691
+ }
692
+
693
+ /**
694
+ * Add "Cleaned Emails" notification to Adminnotification Inbox <cleaned>
695
+ *
696
+ * @param array $data
697
+ * @return void
698
+ */
699
+
700
+
701
+ protected function _cleaned(array $data)
702
+ {
703
+ if (Mage::helper('monkey')->isAdminNotificationEnabled()) { //This 'if' returns false even if Admin Notification is enabled on the module sometimes, must check why
704
+ $text = Mage::helper('monkey')->__('MailChimp Cleaned Emails: %s %s at %s reason: %s', $data['data']['email'], $data['type'], $data['fired_at'], $data['data']['reason']);
705
+ $temp1=$this->_getInbox()
706
+ ->setTitle($text)
707
+ ->setDescription($text)
708
+ ->save();
709
+
710
+ }
711
+
712
+ //Delete subscriber from Magento
713
+ $s = Mage::getSingleton('newsletter/subscriber')
714
+ ->loadByEmail($data['data']['email']);
715
+
716
+ if ($s->getId()) {
717
+ try {
718
+ $s->delete();
719
+ } catch (Exception $e) {
720
+ Mage::logException($e);
721
+ }
722
+ }
723
+ }
724
+
725
+
726
+ /**
727
+ * Add "Campaign Sending Status" notification to Adminnotification Inbox <campaign>
728
+ *
729
+ * @param array $data
730
+ * @return void
731
+ */
732
+
733
+ protected function _campaign(array $data)
734
+ {
735
+ if (Mage::helper('monkey')->isAdminNotificationEnabled()) {
736
+ $text = Mage::helper('monkey')->__('MailChimp Campaign Send: %s %s at %s', $data['data']['subject'], $data['data']['status'], $data['fired_at']);
737
+ $this->_getInbox()
738
+ ->setTitle($text)
739
+ ->setDescription($text)
740
+ ->save();
741
+ }
742
+
743
+ }
744
+
745
+
746
+
747
+
748
+ protected function _profile(array $data)
749
+ {
750
+ $email = $data['data']['email'];
751
+ $subscriber = Mage::getSingleton('newsletter/subscriber')
752
+ ->loadByEmail($data['data']['email']);
753
+
754
+ $customerCollection = Mage::getModel('customer/customer')->getCollection()
755
+ ->addFieldToFilter('email', array('eq' => $email));
756
+ if (count($customerCollection) > 0) {
757
+ $toUpdate = $customerCollection->getFirstItem();
758
+ if(isset($data['data']['merges']['FNAME'])) {
759
+ $toUpdate->setFirstname($data['data']['merges']['FNAME']);
760
+ }
761
+ if(isset($data['data']['merges']['LNAME'])) {
762
+ $toUpdate->setLastname($data['data']['merges']['LNAME']);
763
+ }
764
+ }else {
765
+ $toUpdate = $subscriber;
766
+ if(isset($data['data']['merges']['FNAME'])) {
767
+ $toUpdate->setSubscriberFirstname($data['data']['merges']['FNAME']);
768
+ }
769
+ if(isset($data['data']['merges']['LNAME'])) {
770
+ $toUpdate->setSubscriberLastname($data['data']['merges']['LNAME']);
771
+ }
772
+ }
773
+
774
+ $toUpdate->save();
775
+ }
776
+
777
+ /**
778
+ * Update customer email <upemail>
779
+ *
780
+ * @param array $data
781
+ * @return void
782
+ */
783
+ protected function _updateEmail(array $data)
784
+ {
785
+ $old = $data['data']['old_email'];
786
+ $new = $data['data']['new_email'];
787
+
788
+
789
+ $oldSubscriber = Mage::getSingleton('newsletter/subscriber')->loadByEmail($old);
790
+ $newSubscriber = Mage::getSingleton('newsletter/subscriber')->loadByEmail($new);
791
+
792
+
793
+ $subscriberStoreId = Mage::helper('monkey')->getStoreByList($data['data']['list_id']);
794
+
795
+ Mage::app()->setCurrentStore($subscriberStoreId);
796
+
797
+
798
+ if ($oldSubscriber->getId()) {
799
+ $oldSubscriber->setSubscriberEmail($new)
800
+ ->save();
801
+ Mage::app()->setCurrentStore(0);
802
+ } elseif (!$newSubscriber->getId() && !$oldSubscriber->getId()) {
803
+ Mage::getModel('newsletter/subscriber')
804
+ ->setImportMode(TRUE)
805
+ ->setStoreId(Mage::app()->getStore()->getId())
806
+ ->subscribe($new);
807
+ Mage::app()->setCurrentStore(0);
808
+ }
809
+ }
810
+
811
+
812
+
813
+ /**
814
+ * Return Inbox model instance
815
+ *
816
+ * @return Mage_AdminNotification_Model_Inbox
817
+ */
818
+ protected function _getInbox()
819
+ {
820
+ return Mage::getModel('adminnotification/inbox')
821
+ ->setSeverity(4)//Notice
822
+ ->setDateAdded(Mage::getModel('core/date')->gmtDate());
823
+ }
824
+
825
+
826
  }
app/code/community/Ebizmarts/MageMonkey/Model/Ecommerce360.php CHANGED
@@ -95,10 +95,11 @@ class Ebizmarts_MageMonkey_Model_Ecommerce360
95
  $order = $observer->getEvent()->getOrder();
96
  if (is_object($order) && $order->getId()) {
97
  //Set Campaign Id if exist
98
- $campaign_id = Mage::getModel('monkey/ecommerce360')->getCookie()->get('magemonkey_campaign_id');
99
  if ($campaign_id && $order->getEbizmartsMagemonkeyCampaignId() == null) {
100
  $order->setEbizmartsMagemonkeyCampaignId($campaign_id)->save();
101
  }
 
102
  $customerEmail = $order->getCustomerEmail();
103
  $collection = Mage::getModel('monkey/lastorder')->getCollection()
104
  ->addFieldToFilter('email', array('eq' => $customerEmail));
@@ -313,7 +314,21 @@ class Ebizmarts_MageMonkey_Model_Ecommerce360
313
  */
314
  protected function _getCampaignCookie()
315
  {
316
- return $this->getCookie()->get('magemonkey_campaign_id');
 
 
 
 
 
 
 
 
 
 
 
 
 
 
317
  }
318
 
319
  /**
95
  $order = $observer->getEvent()->getOrder();
96
  if (is_object($order) && $order->getId()) {
97
  //Set Campaign Id if exist
98
+ $campaign_id = $this->_getCampaignCookie();
99
  if ($campaign_id && $order->getEbizmartsMagemonkeyCampaignId() == null) {
100
  $order->setEbizmartsMagemonkeyCampaignId($campaign_id)->save();
101
  }
102
+ $this->_deleteCampaignCookie();
103
  $customerEmail = $order->getCustomerEmail();
104
  $collection = Mage::getModel('monkey/lastorder')->getCollection()
105
  ->addFieldToFilter('email', array('eq' => $customerEmail));
314
  */
315
  protected function _getCampaignCookie()
316
  {
317
+ $cookie = Mage::getModel('core/cookie')->get('magemonkey_campaign_id');
318
+ if($cookie && Mage::getModel('core/cookie')->getLifetime('magemonkey_campaign_id') == 3600) {
319
+ return $cookie;
320
+ }
321
+ else {
322
+ return null;
323
+ }
324
+ }
325
+
326
+ protected function _deleteCampaignCookie()
327
+ {
328
+ if($this->_getCampaignCookie())
329
+ {
330
+ Mage::getModel('core/cookie')->delete('magemonkey_campaign_id');
331
+ }
332
  }
333
 
334
  /**
app/code/community/Ebizmarts/MageMonkey/Model/Monkey.php CHANGED
@@ -26,254 +26,17 @@ class Ebizmarts_MageMonkey_Model_Monkey
26
  */
27
  public function processWebhookData(array $data)
28
  {
29
- $listId = $data['data']['list_id']; //According to the docs, the events are always related to a list_id
30
- // $store = Mage::helper('monkey')->getStoreByList($listId);
31
- $subscriber = Mage::getModel('newsletter/subscriber')
32
- ->loadByEmail($data['data']['email']);
33
- $storeId = $subscriber->getStoreId();
34
- $store = Mage::getModel('core/store')->load($storeId);
35
- if (!is_null($store)) {
36
- $curstore = Mage::app()->getStore();
37
- Mage::app()->setCurrentStore($store);
38
- }
39
 
40
- //Object for cache clean
41
- $object = new stdClass();
42
- $object->requestParams = array();
43
- $object->requestParams['id'] = $listId;
44
 
45
- if (isset($data['data']['email'])) {
46
- $object->requestParams['email_address'] = $data['data']['email'];
47
- }
48
- $cacheHelper = Mage::helper('monkey/cache');
49
-
50
- switch ($data['type']) {
51
- case 'subscribe':
52
- $this->_subscribe($data);
53
- $cacheHelper->clearCache('listSubscribe', $object);
54
- break;
55
- case 'unsubscribe':
56
- $this->_unsubscribe($data);
57
- $cacheHelper->clearCache('listUnsubscribe', $object);
58
- break;
59
- case 'cleaned':
60
- $this->_clean($data);
61
- $cacheHelper->clearCache('listUnsubscribe', $object);
62
- break;
63
- case 'campaign':
64
- $this->_campaign($data);
65
- break;
66
- //case 'profile': Cuando se actualiza email en MC como merchant, te manda un upmail y un profile (no siempre en el mismo órden)
67
- case 'upemail':
68
- $this->_updateEmail($data);
69
- $cacheHelper->clearCache('listUpdateMember', $object);
70
- break;
71
- case 'profile':
72
- $this->_profile($data);
73
- $cacheHelper->clearCache('listUpdateMember', $object);
74
- break;
75
- }
76
-
77
- if (!is_null($store)) {
78
- Mage::app()->setCurrentStore($curstore);
79
- }
80
- }
81
-
82
- /**
83
- * Update customer email <upemail>
84
- *
85
- * @param array $data
86
- * @return void
87
- */
88
- protected function _updateEmail(array $data)
89
- {
90
-
91
- $old = $data['data']['old_email'];
92
- $new = $data['data']['new_email'];
93
-
94
- $oldSubscriber = $this->loadByEmail($old);
95
- $newSubscriber = $this->loadByEmail($new);
96
-
97
- if (!$newSubscriber->getId() && $oldSubscriber->getId()) {
98
- $oldSubscriber->setSubscriberEmail($new)
99
- ->save();
100
- } elseif (!$newSubscriber->getId() && !$oldSubscriber->getId()) {
101
-
102
- Mage::getModel('newsletter/subscriber')
103
- ->setImportMode(TRUE)
104
- ->setStoreId(Mage::app()->getStore()->getId())
105
- ->subscribe($new);
106
- }
107
- }
108
-
109
- /**
110
- * Add "Cleaned Emails" notification to Adminnotification Inbox <cleaned>
111
- *
112
- * @param array $data
113
- * @return void
114
- */
115
- protected function _clean(array $data)
116
- {
117
-
118
- if (Mage::helper('monkey')->isAdminNotificationEnabled()) {
119
- $text = Mage::helper('monkey')->__('MailChimp Cleaned Emails: %s %s at %s reason: %s', $data['data']['email'], $data['type'], $data['fired_at'], $data['data']['reason']);
120
-
121
- $this->_getInbox()
122
- ->setTitle($text)
123
- ->setDescription($text)
124
- ->save();
125
- }
126
-
127
- //Delete subscriber from Magento
128
- $s = $this->loadByEmail($data['data']['email']);
129
-
130
- if ($s->getId()) {
131
- try {
132
- $s->delete();
133
- } catch (Exception $e) {
134
- Mage::logException($e);
135
- }
136
- }
137
- }
138
-
139
- /**
140
- * Add "Campaign Sending Status" notification to Adminnotification Inbox <campaign>
141
- *
142
- * @param array $data
143
- * @return void
144
- */
145
- protected function _campaign(array $data)
146
- {
147
-
148
- if (Mage::helper('monkey')->isAdminNotificationEnabled()) {
149
- $text = Mage::helper('monkey')->__('MailChimp Campaign Send: %s %s at %s', $data['data']['subject'], $data['data']['status'], $data['fired_at']);
150
-
151
- $this->_getInbox()
152
- ->setTitle($text)
153
- ->setDescription($text)
154
- ->save();
155
- }
156
 
157
  }
158
 
159
- /**
160
- * Subscribe email to Magento list, store aware
161
- *
162
- * @param array $data
163
- * @return void
164
- */
165
- protected function _subscribe(array $data)
166
- {
167
- try {
168
-
169
- //TODO: El método subscribe de Subscriber (Magento) hace un load by email
170
- // entonces si existe en un store, lo acutaliza y lo cambia de store, no lo agrega a otra store
171
- //VALIDAR si es lo que se requiere
172
-
173
- $subscriber = Mage::getModel('newsletter/subscriber')
174
- ->loadByEmail($data['data']['email']);
175
- if ($subscriber->getId()) {
176
- $subscriber->setStatus(Mage_Newsletter_Model_Subscriber::STATUS_SUBSCRIBED)
177
- ->save();
178
- } else {
179
- $subscriber = Mage::getModel('newsletter/subscriber')->setImportMode(TRUE);
180
- if(isset($data['data']['fname'])){
181
- $subscriber->setSubscriberFirstname($data['data']['fname']);
182
- }
183
- if(isset($data['data']['lname'])){
184
- $subscriber->setSubscriberLastname($data['data']['lname']);
185
- }
186
- $subscriber->subscribe($data['data']['email']);
187
-
188
- }
189
- $customerExist = Mage::getSingleton('customer/customer')
190
- ->getCollection()
191
- ->addAttributeToFilter('email', array('eq' => $data['data']['email']) )
192
- ->getFirstItem();
193
- if($customerExist){
194
- $storeId = $customerExist->getStoreId();
195
- }
196
- if($customerExist && Mage::getStoreConfig('sweetmonkey/general/active', $storeId)){
197
- Mage::helper('sweetmonkey')->pushVars($customerExist);
198
- }
199
- } catch (Exception $e) {
200
- Mage::logException($e);
201
- }
202
- }
203
-
204
- /**
205
- * Unsubscribe or delete email from Magento list, store aware
206
- *
207
- * @param array $data
208
- * @return void
209
- */
210
- protected function _unsubscribe(array $data)
211
- {
212
- $subscriber = $this->loadByEmail($data['data']['email']);
213
-
214
- if (!$subscriber->getId()) {
215
- $subscriber = Mage::getModel('newsletter/subscriber')
216
- ->loadByEmail($data['data']['email']);
217
- }
218
-
219
- if ($subscriber->getId()) {
220
- try {
221
- if(!Mage::getStoreConfig(Ebizmarts_MageMonkey_Model_Config::GENERAL_CONFIRMATION_EMAIL, $subscriber->getStoreId())){
222
- $subscriber->setImportMode(true);
223
- }
224
-
225
- switch ($data['data']['action']) {
226
- case 'delete' :
227
- //if config setting "Webhooks Delete action" is set as "Delete customer account"
228
- if (Mage::getStoreConfig("monkey/general/webhook_delete") == 1) {
229
- $subscriber->delete();
230
- } else {
231
- $subscriber->unsubscribe();
232
- }
233
- break;
234
- case 'unsub':
235
- $subscriber->unsubscribe();
236
- break;
237
- }
238
- } catch (Exception $e) {
239
- Mage::logException($e);
240
- }
241
- }
242
- }
243
-
244
- protected function _profile(array $data)
245
- {
246
- $email = $data['data']['email'];
247
- $subscriber = $this->loadByEmail($email);
248
- $storeId = $subscriber->getStoreId();
249
-
250
- $customerCollection = Mage::getModel('customer/customer')->getCollection()
251
- ->addFieldToFilter('email', array('eq' => $email));
252
- if (count($customerCollection) > 0) {
253
- $toUpdate = $customerCollection->getFirstItem();
254
- } else {
255
- $toUpdate = $subscriber;
256
- }
257
- $toUpdate->setFirstname($data['data']['merges']['FNAME']);
258
- $toUpdate->setLastname($data['data']['merges']['LNAME']);
259
- $toUpdate->save();
260
-
261
-
262
- }
263
-
264
- /**
265
- * Return Inbox model instance
266
- *
267
- * @return Mage_AdminNotification_Model_Inbox
268
- */
269
- protected function _getInbox()
270
- {
271
- return Mage::getModel('adminnotification/inbox')
272
- ->setSeverity(4)//Notice
273
- ->setDateAdded(Mage::getModel('core/date')->gmtDate());
274
- }
275
-
276
- /**
277
  * Load newsletter_subscriber by email
278
  *
279
  * @param string $email
26
  */
27
  public function processWebhookData(array $data)
28
  {
 
 
 
 
 
 
 
 
 
 
29
 
 
 
 
 
30
 
31
+ Mage::getModel('monkey/asyncwebhooks')
32
+ ->setWebhookType($data['type'])
33
+ ->setWebhookData(json_encode($data))
34
+ ->setProcessed(0)
35
+ ->save();
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
36
 
37
  }
38
 
39
+ /**
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
40
  * Load newsletter_subscriber by email
41
  *
42
  * @param string $email
app/code/community/Ebizmarts/MageMonkey/Model/Mysql4/Asyncwebhooks.php ADDED
@@ -0,0 +1,22 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ * Author : Ebizmarts <info@ebizmarts.com>
5
+ * Date : 9/12/14
6
+ * Time : 1:09 AM
7
+ * File : AsyncWebhooks.php
8
+ * Module : Ebizmarts_MageMonkey
9
+ */
10
+ class Ebizmarts_MageMonkey_Model_Mysql4_Asyncwebhooks extends Mage_Core_Model_Mysql4_Abstract
11
+ {
12
+
13
+ /**
14
+ * Initialize
15
+ *
16
+ * @return void
17
+ */
18
+ public function _construct()
19
+ {
20
+ $this->_init('monkey/asyncwebhooks', 'id');
21
+ }
22
+ }
app/code/community/Ebizmarts/MageMonkey/Model/Mysql4/Asyncwebhooks/Collection.php ADDED
@@ -0,0 +1,23 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ * Author : Ebizmarts <info@ebizmarts.com>
5
+ * Date : 9/12/14
6
+ * Time : 1:17 AM
7
+ * File : Collection.php
8
+ * Module : Ebizmarts_MageMonkey
9
+ */
10
+ class Ebizmarts_MageMonkey_Model_Mysql4_Asyncwebhooks_Collection extends Mage_Core_Model_Mysql4_Collection_Abstract
11
+ {
12
+
13
+ /**
14
+ * Set resource type
15
+ *
16
+ * @return void
17
+ */
18
+ public function _construct()
19
+ {
20
+ parent::_construct();
21
+ $this->_init('monkey/asyncwebhooks');
22
+ }
23
+ }
app/code/community/Ebizmarts/MageMonkey/Model/Observer.php CHANGED
@@ -193,31 +193,36 @@ class Ebizmarts_MageMonkey_Model_Observer
193
  }
194
 
195
  $webhooksKey = Mage::helper('monkey')->getWebhooksKey();
 
196
 
197
  //Generating Webhooks URL
198
- $hookUrl = '';
199
- try {
200
- $hookUrl = Mage::getModel('core/url')->setStore($store)->getUrl(Ebizmarts_MageMonkey_Model_Monkey::WEBHOOKS_PATH, array('wkey' => $webhooksKey));
201
- } catch (Exception $e) {
202
- $hookUrl = Mage::getModel('core/url')->getUrl(Ebizmarts_MageMonkey_Model_Monkey::WEBHOOKS_PATH, array('wkey' => $webhooksKey));
203
- }
 
204
 
205
- if (FALSE != strstr($hookUrl, '?', true)) {
206
- $hookUrl = strstr($hookUrl, '?', true);
207
- }
208
 
209
- $api = Mage::getSingleton('monkey/api', array('apikey' => $apiKey));
210
 
211
- //Validate API KEY
212
- $api->ping();
213
- if ($api->errorCode) {
214
- Mage::getSingleton('adminhtml/session')->addError($api->errorMessage);
215
- return $observer;
216
- }
 
 
217
 
218
- $lists = $api->lists();
 
219
 
220
- $this->_saveCustomerGroups($lists,$api,$selectedLists,$hookUrl);
221
 
222
  }
223
  protected function _saveCustomerGroups($lists,$api,$selectedLists,$hookUrl)
@@ -263,13 +268,11 @@ class Ebizmarts_MageMonkey_Model_Observer
263
 
264
  //If webhook was not added, add a message on Admin panel
265
  if ($api->errorCode && Mage::helper('monkey')->isAdmin()) {
266
-
267
  //Don't show an error if webhook already in, otherwise, show error message and code
268
  if ($api->errorMessage !== "Setting up multiple WebHooks for one URL is not allowed.") {
269
  $message = Mage::helper('monkey')->__('Could not add Webhook "%s" for list "%s", error code %s, %s', $hookUrl, $list['name'], $api->errorCode, $api->errorMessage);
270
  Mage::getSingleton('adminhtml/session')->addError($message);
271
  }
272
-
273
  }
274
  /**
275
  * Adding Webhooks
@@ -293,7 +296,7 @@ class Ebizmarts_MageMonkey_Model_Observer
293
  $request = Mage::app()->getRequest();
294
  $isAdmin = $request->getActionName() == 'save' && $request->getControllerName() == 'customer' && $request->getModuleName() == (string)Mage::getConfig()->getNode('admin/routers/adminhtml/args/frontName');
295
  $customer = $observer->getEvent()->getCustomer();
296
- $isCheckout = $request->getModuleName() == 'checkout' || $request->getModuleName() == 'sgps' || Mage::getSingleton('core/session')->getIsOneStepCheckout() || Mage::getSingleton('core/session')->getMonkeyCheckout();
297
  // $isConfirmNeed = FALSE;
298
  // if (!Mage::helper('monkey')->isAdmin() &&
299
  // (Mage::getStoreConfig(Mage_Newsletter_Model_Subscriber::XML_PATH_CONFIRMATION_FLAG, $customer->getStoreId()) == 1)
@@ -352,6 +355,24 @@ class Ebizmarts_MageMonkey_Model_Observer
352
  return $observer;
353
  }
354
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
355
  /**
356
  * Add flag on session to tell the module if on success page should subscribe customer
357
  *
@@ -363,19 +384,26 @@ class Ebizmarts_MageMonkey_Model_Observer
363
  if (!Mage::helper('monkey')->canMonkey()) {
364
  return $observer;
365
  }
366
-
367
- $oneStep = Mage::app()->getRequest()->getModuleName() == 'onestepcheckout';
368
- if (Mage::app()->getRequest()->isPost()) {
369
- $subscribe = Mage::app()->getRequest()->getPost('magemonkey_subscribe');
370
- $force = Mage::app()->getRequest()->getPost('magemonkey_force');
371
-
372
- Mage::getSingleton('core/session')->setMonkeyPost(serialize(Mage::app()->getRequest()->getPost()));
373
- if (!is_null($subscribe) || Mage::getStoreConfig(Ebizmarts_MageMonkey_Model_Config::GENERAL_CHECKOUT_SUBSCRIBE) >= 3) {
374
- Mage::getSingleton('core/session')->setMonkeyCheckout(true);
 
 
 
 
 
 
 
 
 
 
375
  }
376
- }
377
- if ($oneStep) {
378
- Mage::getSingleton('core/session')->setIsOneStepCheckout(true);
379
  }
380
  return $observer;
381
  }
@@ -401,8 +429,40 @@ class Ebizmarts_MageMonkey_Model_Observer
401
  if ($orderId) {
402
  $order = Mage::getModel('sales/order')->load($orderId);
403
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
404
 
405
- if (is_object($order) && $order->getId()) {
 
 
 
 
 
 
406
  //Set Campaign Id if exist
407
  $campaign_id = Mage::getModel('monkey/ecommerce360')->getCookie()->get('magemonkey_campaign_id');
408
  if ($campaign_id) {
@@ -426,10 +486,12 @@ class Ebizmarts_MageMonkey_Model_Observer
426
  ->setSubscriberFirstname($order->getCustomerFirstname())
427
  ->setSubscriberLastname($order->getCustomerLastname())
428
  ->setEmail($order->getCustomerEmail());
 
429
  }
 
430
 
431
  if(Mage::getSingleton('core/session')->getMonkeyCheckout() || Mage::getSingleton('core/session')->getIsOneStepCheckout()) {
432
- Mage::helper('monkey')->listsSubscription($toSubscribe, $saveOnDb);
433
  }
434
 
435
  }
@@ -437,34 +499,6 @@ class Ebizmarts_MageMonkey_Model_Observer
437
  Mage::getSingleton('core/session')->setMonkeyPost(NULL);
438
  Mage::getSingleton('core/session')->setIsOneStepCheckout(FALSE);
439
  Mage::getSingleton('core/session')->setRegisterCheckoutSuccess(FALSE);
440
- return $observer;
441
- }
442
-
443
- /** Add mass action option to Sales -> Order grid in admin panel to send orders to MC (Ecommerce360)
444
- *
445
- * @param Varien_Event_Observer $observer
446
- * @return void
447
- */
448
- public function massActionOption(Varien_Event_Observer $observer)
449
- {
450
- $stores = Mage::app()->getStores();
451
- if (!Mage::helper('monkey')->canMonkey($stores)) {
452
- return $observer;
453
- }
454
- $block = $observer->getEvent()->getBlock();
455
-
456
- if ($block instanceof Mage_Adminhtml_Block_Widget_Grid_Massaction || $block instanceof Enterprise_SalesArchive_Block_Adminhtml_Sales_Order_Grid_Massaction) {
457
-
458
- if ($block->getRequest()->getControllerName() == 'sales_order') {
459
-
460
- $block->addItem('magemonkey_ecommerce360', array(
461
- 'label' => Mage::helper('monkey')->__('Send to MailChimp'),
462
- 'url' => Mage::getModel('adminhtml/url')->getUrl('adminhtml/ecommerce/masssend', Mage::app()->getStore()->isCurrentlySecure() ? array('_secure' => true) : array()),
463
- ));
464
-
465
- }
466
- }
467
- return $observer;
468
  }
469
 
470
  public function alterNewsletterGrid(Varien_Event_Observer $observer){
@@ -479,7 +513,7 @@ class Ebizmarts_MageMonkey_Model_Observer
479
  'header' => Mage::helper('newsletter')->__('Customer First Name'),
480
  'index' => 'customer_firstname',
481
  'renderer' => 'monkey/adminhtml_newsletter_subscriber_renderer_firstname',
482
- ), 'type'
483
  );
484
 
485
  $block->addColumnAfter('lastname', array(
193
  }
194
 
195
  $webhooksKey = Mage::helper('monkey')->getWebhooksKey();
196
+ $allowWebhooks = Mage::getStoreConfig('monkey/general/enable_webhooks', $store);
197
 
198
  //Generating Webhooks URL
199
+ if($allowWebhooks) {
200
+ $hookUrl = '';
201
+ try {
202
+ $hookUrl = Mage::getModel('core/url')->setStore($store)->getUrl(Ebizmarts_MageMonkey_Model_Monkey::WEBHOOKS_PATH, array('wkey' => $webhooksKey));
203
+ } catch (Exception $e) {
204
+ $hookUrl = Mage::getModel('core/url')->getUrl(Ebizmarts_MageMonkey_Model_Monkey::WEBHOOKS_PATH, array('wkey' => $webhooksKey));
205
+ }
206
 
207
+ if (FALSE != strstr($hookUrl, '?', true)) {
208
+ $hookUrl = strstr($hookUrl, '?', true);
209
+ }
210
 
211
+ $api = Mage::getSingleton('monkey/api', array('apikey' => $apiKey));
212
 
213
+ //Validate API KEY
214
+ $api->ping();
215
+ if ($api->errorCode) {
216
+ Mage::getSingleton('adminhtml/session')->addError($api->errorMessage);
217
+ return $observer;
218
+ }
219
+
220
+ $lists = $api->lists();
221
 
222
+ $this->_saveCustomerGroups($lists,$api,$selectedLists,$hookUrl);
223
+ }
224
 
225
+ return $observer;
226
 
227
  }
228
  protected function _saveCustomerGroups($lists,$api,$selectedLists,$hookUrl)
268
 
269
  //If webhook was not added, add a message on Admin panel
270
  if ($api->errorCode && Mage::helper('monkey')->isAdmin()) {
 
271
  //Don't show an error if webhook already in, otherwise, show error message and code
272
  if ($api->errorMessage !== "Setting up multiple WebHooks for one URL is not allowed.") {
273
  $message = Mage::helper('monkey')->__('Could not add Webhook "%s" for list "%s", error code %s, %s', $hookUrl, $list['name'], $api->errorCode, $api->errorMessage);
274
  Mage::getSingleton('adminhtml/session')->addError($message);
275
  }
 
276
  }
277
  /**
278
  * Adding Webhooks
296
  $request = Mage::app()->getRequest();
297
  $isAdmin = $request->getActionName() == 'save' && $request->getControllerName() == 'customer' && $request->getModuleName() == (string)Mage::getConfig()->getNode('admin/routers/adminhtml/args/frontName');
298
  $customer = $observer->getEvent()->getCustomer();
299
+ $isCheckout = $request->getControllerName() == 'sales_order_create' || $request->getModuleName() == 'firecheckout' || $request->getModuleName() == 'checkout' || $request->getModuleName() == 'sgps' || Mage::getSingleton('core/session')->getIsOneStepCheckout() || Mage::getSingleton('core/session')->getMonkeyCheckout();
300
  // $isConfirmNeed = FALSE;
301
  // if (!Mage::helper('monkey')->isAdmin() &&
302
  // (Mage::getStoreConfig(Mage_Newsletter_Model_Subscriber::XML_PATH_CONFIRMATION_FLAG, $customer->getStoreId()) == 1)
355
  return $observer;
356
  }
357
 
358
+ public function registerCheckoutSubscribeWithSagePay(Varien_Event_Observer $observer){
359
+ if (!Mage::helper('monkey')->canMonkey()) {
360
+ return $observer;
361
+ }
362
+ $post = $observer->getEvent()->getPost();
363
+ $oneStep = Mage::app()->getRequest()->getModuleName() == 'onestepcheckout';
364
+ $subscribe = $post['magemonkey_subscribe'];
365
+
366
+ Mage::getSingleton('core/session')->setMonkeyPost(serialize($post));
367
+ if (!is_null($subscribe) || Mage::getStoreConfig(Ebizmarts_MageMonkey_Model_Config::GENERAL_CHECKOUT_SUBSCRIBE, Mage::app()->getStore()->getId()) >= 3) {
368
+ Mage::getSingleton('core/session')->setMonkeyCheckout(true);
369
+ }
370
+ if ($oneStep) {
371
+ Mage::getSingleton('core/session')->setIsOneStepCheckout(true);
372
+ }
373
+ return $observer;
374
+ }
375
+
376
  /**
377
  * Add flag on session to tell the module if on success page should subscribe customer
378
  *
384
  if (!Mage::helper('monkey')->canMonkey()) {
385
  return $observer;
386
  }
387
+ if (Mage::getSingleton('core/session')->getMonkeyPost()){
388
+ $order = $observer->getEvent()->getOrder();
389
+ $this->_handleCheckoutSubscription($order, true);
390
+ }else {
391
+ $oneStep = Mage::app()->getRequest()->getModuleName() == 'onestepcheckout';
392
+ if (Mage::app()->getRequest()->isPost()) {
393
+ $subscribe = Mage::app()->getRequest()->getPost('magemonkey_subscribe');
394
+
395
+ Mage::getSingleton('core/session')->setMonkeyPost(serialize(Mage::app()->getRequest()->getPost()));
396
+ if (!is_null($subscribe) || Mage::getStoreConfig(Ebizmarts_MageMonkey_Model_Config::GENERAL_CHECKOUT_SUBSCRIBE, Mage::app()->getStore()->getId()) >= 3) {
397
+ Mage::getSingleton('core/session')->setMonkeyCheckout(true);
398
+ }
399
+ }
400
+ if ($oneStep) {
401
+ Mage::getSingleton('core/session')->setIsOneStepCheckout(true);
402
+ }
403
+ if (Mage::getSingleton('core/session')->getMonkeyPost()){
404
+ $order = $observer->getEvent()->getOrder();
405
+ $this->_handleCheckoutSubscription($order, true);
406
  }
 
 
 
407
  }
408
  return $observer;
409
  }
429
  if ($orderId) {
430
  $order = Mage::getModel('sales/order')->load($orderId);
431
  }
432
+ $this->_handleCheckoutSubscription($order, false);
433
+
434
+ return $observer;
435
+ }
436
+
437
+ /** Add mass action option to Sales -> Order grid in admin panel to send orders to MC (Ecommerce360)
438
+ *
439
+ * @param Varien_Event_Observer $observer
440
+ * @return void
441
+ */
442
+ public function massActionOption(Varien_Event_Observer $observer)
443
+ {
444
+ $stores = Mage::app()->getStores();
445
+ if (!Mage::helper('monkey')->canMonkey($stores)) {
446
+ return $observer;
447
+ }
448
+ $block = $observer->getEvent()->getBlock();
449
+
450
+ if ($block instanceof Mage_Adminhtml_Block_Widget_Grid_Massaction || $block instanceof Enterprise_SalesArchive_Block_Adminhtml_Sales_Order_Grid_Massaction) {
451
+
452
+ if ($block->getRequest()->getControllerName() == 'sales_order') {
453
+
454
+ $block->addItem('magemonkey_ecommerce360', array(
455
+ 'label' => Mage::helper('monkey')->__('Send to MailChimp'),
456
+ 'url' => Mage::getModel('adminhtml/url')->getUrl('adminhtml/ecommerce/masssend', Mage::app()->getStore()->isCurrentlySecure() ? array('_secure' => true) : array()),
457
+ ));
458
 
459
+ }
460
+ }
461
+ return $observer;
462
+ }
463
+
464
+ protected function _handleCheckoutSubscription($order, $isSaveOrderBefore = false){
465
+ if (is_object($order) && ($order->getId() || $isSaveOrderBefore)) {
466
  //Set Campaign Id if exist
467
  $campaign_id = Mage::getModel('monkey/ecommerce360')->getCookie()->get('magemonkey_campaign_id');
468
  if ($campaign_id) {
486
  ->setSubscriberFirstname($order->getCustomerFirstname())
487
  ->setSubscriberLastname($order->getCustomerLastname())
488
  ->setEmail($order->getCustomerEmail());
489
+
490
  }
491
+ $orderId = $order->getId();
492
 
493
  if(Mage::getSingleton('core/session')->getMonkeyCheckout() || Mage::getSingleton('core/session')->getIsOneStepCheckout()) {
494
+ Mage::helper('monkey')->listsSubscription($toSubscribe, $saveOnDb, $orderId);
495
  }
496
 
497
  }
499
  Mage::getSingleton('core/session')->setMonkeyPost(NULL);
500
  Mage::getSingleton('core/session')->setIsOneStepCheckout(FALSE);
501
  Mage::getSingleton('core/session')->setRegisterCheckoutSuccess(FALSE);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
502
  }
503
 
504
  public function alterNewsletterGrid(Varien_Event_Observer $observer){
513
  'header' => Mage::helper('newsletter')->__('Customer First Name'),
514
  'index' => 'customer_firstname',
515
  'renderer' => 'monkey/adminhtml_newsletter_subscriber_renderer_firstname',
516
+ ), 'type'
517
  );
518
 
519
  $block->addColumnAfter('lastname', array(
app/code/community/Ebizmarts/MageMonkey/controllers/WebhookController.php CHANGED
@@ -17,7 +17,6 @@ class Ebizmarts_MageMonkey_WebhookController extends Mage_Core_Controller_Front_
17
  public function indexAction()
18
  {
19
  $requestKey = $this->getRequest()->getParam('wkey');
20
-
21
  //Checking if "wkey" para is present on request, we cannot check for !isPost()
22
  //because Mailchimp pings the URL (GET request) to validate webhook
23
  if (!$requestKey) {
17
  public function indexAction()
18
  {
19
  $requestKey = $this->getRequest()->getParam('wkey');
 
20
  //Checking if "wkey" para is present on request, we cannot check for !isPost()
21
  //because Mailchimp pings the URL (GET request) to validate webhook
22
  if (!$requestKey) {
app/code/community/Ebizmarts/MageMonkey/etc/config.xml CHANGED
@@ -10,7 +10,7 @@
10
  <config>
11
  <modules>
12
  <Ebizmarts_MageMonkey>
13
- <version>1.2.3</version>
14
  </Ebizmarts_MageMonkey>
15
  </modules>
16
  <global>
@@ -69,6 +69,9 @@
69
  <lastorder>
70
  <table>magemonkey_last_order</table>
71
  </lastorder>
 
 
 
72
  </entities>
73
  </monkey_mysql4>
74
  <newsletter>
@@ -135,6 +138,14 @@
135
  </updates>
136
  </layout>
137
  <events>
 
 
 
 
 
 
 
 
138
  <controller_action_predispatch_onestepcheckout_index_index>
139
  <observers>
140
  <monkey_subscribe_checkout>
@@ -143,6 +154,14 @@
143
  </monkey_subscribe_checkout>
144
  </observers>
145
  </controller_action_predispatch_onestepcheckout_index_index>
 
 
 
 
 
 
 
 
146
  <sales_order_place_before>
147
  <observers>
148
  <monkey_subscribe_checkout>
@@ -267,13 +286,14 @@
267
  <enable_log>1</enable_log>
268
  <checkout_async>1</checkout_async>
269
  <markfield>HASCLICKED</markfield>
 
270
  </general>
271
  <ecommerce360>
272
  <active>0</active>
273
  <order_status>all_status</order_status>
274
  </ecommerce360>
275
  <notifications>
276
- <updates_url><![CDATA[http://store.ebizmarts.com/media/feeds/]]></updates_url>
277
  <check_frequency>86400</check_frequency>
278
  </notifications>
279
  </monkey>
@@ -336,6 +356,14 @@
336
  <model>monkey/cron::cleanSubscribersAsync</model>
337
  </run>
338
  </magemonkey_cleansubscribers_asynch>
 
 
 
 
 
 
 
 
339
  </jobs>
340
  </crontab>
341
  </config>
10
  <config>
11
  <modules>
12
  <Ebizmarts_MageMonkey>
13
+ <version>1.2.5</version>
14
  </Ebizmarts_MageMonkey>
15
  </modules>
16
  <global>
69
  <lastorder>
70
  <table>magemonkey_last_order</table>
71
  </lastorder>
72
+ <asyncwebhooks>
73
+ <table>magemonkey_async_webhooks</table>
74
+ </asyncwebhooks>
75
  </entities>
76
  </monkey_mysql4>
77
  <newsletter>
138
  </updates>
139
  </layout>
140
  <events>
141
+ <sagepaysuite_place_order>
142
+ <observers>
143
+ <monkey_subscribe_checkout_with_sagepay>
144
+ <class>monkey/observer</class>
145
+ <method>registerCheckoutSubscribeWithSagePay</method>
146
+ </monkey_subscribe_checkout_with_sagepay>
147
+ </observers>
148
+ </sagepaysuite_place_order>
149
  <controller_action_predispatch_onestepcheckout_index_index>
150
  <observers>
151
  <monkey_subscribe_checkout>
154
  </monkey_subscribe_checkout>
155
  </observers>
156
  </controller_action_predispatch_onestepcheckout_index_index>
157
+ <controller_action_postdispatch_firecheckout_index_saveOrder>
158
+ <observers>
159
+ <monkey_subscribe_checkout>
160
+ <class>monkey/observer</class>
161
+ <method>registerCheckoutSubscribe</method>
162
+ </monkey_subscribe_checkout>
163
+ </observers>
164
+ </controller_action_postdispatch_firecheckout_index_saveOrder>
165
  <sales_order_place_before>
166
  <observers>
167
  <monkey_subscribe_checkout>
286
  <enable_log>1</enable_log>
287
  <checkout_async>1</checkout_async>
288
  <markfield>HASCLICKED</markfield>
289
+ <enable_webhooks>1</enable_webhooks>
290
  </general>
291
  <ecommerce360>
292
  <active>0</active>
293
  <order_status>all_status</order_status>
294
  </ecommerce360>
295
  <notifications>
296
+ <updates_url><![CDATA[https://store.ebizmarts.com/media/feeds/]]></updates_url>
297
  <check_frequency>86400</check_frequency>
298
  </notifications>
299
  </monkey>
356
  <model>monkey/cron::cleanSubscribersAsync</model>
357
  </run>
358
  </magemonkey_cleansubscribers_asynch>
359
+ <magemonkey_webhooks_asynch>
360
+ <schedule>
361
+ <cron_expr>*/15 * * * *</cron_expr>
362
+ </schedule>
363
+ <run>
364
+ <model>monkey/cron::processWebhookData</model>
365
+ </run>
366
+ </magemonkey_webhooks_asynch>
367
  </jobs>
368
  </crontab>
369
  </config>
app/code/community/Ebizmarts/MageMonkey/etc/system.xml CHANGED
@@ -125,7 +125,7 @@
125
  <show_in_website>0</show_in_website>
126
  <show_in_store>1</show_in_store>
127
  <can_be_empty>1</can_be_empty>
128
- <comment><![CDATA[Synchronize Magento's General Subscription List with this MailChimp list]]></comment>
129
  </list>
130
  <cutomergroup translate="label comment">
131
  <label>Subscriber Group</label>
@@ -167,7 +167,7 @@
167
  <show_in_website>0</show_in_website>
168
  <show_in_store>1</show_in_store>
169
  <can_be_empty>1</can_be_empty>
170
- <comment>All selected lists will be available to customers as additionals lists</comment>
171
  </additional_lists>
172
  <confirmation_email translate="label comment">
173
  <label>Use Magento's confirmation email</label>
@@ -187,7 +187,7 @@
187
  <show_in_default>1</show_in_default>
188
  <show_in_website>0</show_in_website>
189
  <show_in_store>1</show_in_store>
190
- <comment><![CDATA[<b>IMPORTANT</b>: Should be set to <b>Yes</b>. Abusing this may cause your account to be suspended.<br/><a target='_blank' href='http://kb.mailchimp.com/article/how-does-confirmed-optin-or-double-optin-work/'>How does double opt-in work?</a>]]></comment>
191
  </double_optin>
192
  <map_fields translate="label comment">
193
  <label>Customer Fields Mapping</label>
@@ -206,7 +206,7 @@
206
  <show_in_default>1</show_in_default>
207
  <show_in_website>0</show_in_website>
208
  <show_in_store>1</show_in_store>
209
- <comment>This value will be sent as FNAME to MailChimp</comment>
210
  </guest_name>
211
  <guest_lastname translate="label comment">
212
  <label>Last Name for Guests subscribers</label>
@@ -215,7 +215,7 @@
215
  <show_in_default>1</show_in_default>
216
  <show_in_website>0</show_in_website>
217
  <show_in_store>1</show_in_store>
218
- <comment>This value will be sent as LNAME to MailChimp</comment>
219
  </guest_lastname>
220
  <checkout_subscribe translate="label comment">
221
  <label>Subscribe On Checkout</label>
@@ -225,7 +225,7 @@
225
  <show_in_default>1</show_in_default>
226
  <show_in_website>0</show_in_website>
227
  <show_in_store>1</show_in_store>
228
- <comment>Show Newsletter Subscribe checkbox in the last Checkout Step (Order Review)</comment>
229
  </checkout_subscribe>
230
  <markfield translate="label comment">
231
  <label>Map field to mark</label>
@@ -234,7 +234,7 @@
234
  <show_in_default>1</show_in_default>
235
  <show_in_website>0</show_in_website>
236
  <show_in_store>1</show_in_store>
237
- <comment>Field to distinguish if the user subscribe</comment>
238
  </markfield>
239
  <checkout_async translate="label comment">
240
  <label>Use Async subscribe in checkout</label>
@@ -268,6 +268,16 @@
268
  <show_in_store>1</show_in_store>
269
  <comment></comment>
270
  </cron_export>
 
 
 
 
 
 
 
 
 
 
271
  <webhook_delete translate="label comment">
272
  <label>Webhooks Delete action</label>
273
  <frontend_type>select</frontend_type>
@@ -277,6 +287,7 @@
277
  <show_in_website>0</show_in_website>
278
  <show_in_store>1</show_in_store>
279
  <comment></comment>
 
280
  </webhook_delete>
281
  <adminhtml_notification translate="label comment">
282
  <label>Show Admin Notifications</label>
@@ -286,7 +297,7 @@
286
  <show_in_default>1</show_in_default>
287
  <show_in_website>0</show_in_website>
288
  <show_in_store>1</show_in_store>
289
- <comment>Notifications related to campaigns sent, cleaned emails, etc</comment>
290
  </adminhtml_notification>
291
  <enable_log translate="label comment">
292
  <label>Enable Log</label>
@@ -296,7 +307,7 @@
296
  <show_in_default>1</show_in_default>
297
  <show_in_website>0</show_in_website>
298
  <show_in_store>1</show_in_store>
299
- <comment>File is {{base_dir}}/var/log/MageMonkey_ApiCall.log</comment>
300
  </enable_log>
301
  </fields>
302
  </general>
@@ -317,7 +328,7 @@
317
  <show_in_website>1</show_in_website>
318
  <show_in_store>1</show_in_store>
319
  <can_be_empty>1</can_be_empty>
320
- <comment><![CDATA[Send new orders to MailChimp using Ecommerce360.<br/><a target='_blank' href='http://kb.mailchimp.com/article/how-do-i-turn-on-ecommerce360-tracking-on-my-campaigns/'>How do I turn on Ecommerce360 tracking on my campaigns?</a><br/><a target='_blank' href='http://kb.mailchimp.com/article/how-to-segment-your-list-based-on-your-customers-purchase-activity'>How to segment your list based on your customers purchase activity</a>]]></comment>
321
  </active>
322
  <order_status translate="label comment">
323
  <label>Order Status</label>
@@ -327,7 +338,7 @@
327
  <show_in_default>1</show_in_default>
328
  <show_in_website>0</show_in_website>
329
  <show_in_store>1</show_in_store>
330
- <comment><![CDATA[<b>IMPORTANT</b>: By default this function run every one hour. If you want to edit this value visit our <a target='_blank' href='http://wiki.ebizmarts.com/installation/configuration/faq#TOC-How-I-set-up-the-Magento-cron-'>wiki</a>]]></comment>
331
  <depends>
332
  <active>3</active>
333
  </depends>
@@ -354,7 +365,7 @@
354
  <show_in_website>0</show_in_website>
355
  <show_in_store>1</show_in_store>
356
  <can_be_empty>1</can_be_empty>
357
- <comment>All selected attributes will be sent on the product name to MailChimp for segmentation purposes</comment>
358
  <depends>
359
  <active separator=",">1,2,3</active>
360
  </depends>
125
  <show_in_website>0</show_in_website>
126
  <show_in_store>1</show_in_store>
127
  <can_be_empty>1</can_be_empty>
128
+ <comment><![CDATA[Synchronize Magento's General Subscription List with this MailChimp list.]]></comment>
129
  </list>
130
  <cutomergroup translate="label comment">
131
  <label>Subscriber Group</label>
167
  <show_in_website>0</show_in_website>
168
  <show_in_store>1</show_in_store>
169
  <can_be_empty>1</can_be_empty>
170
+ <comment><![CDATA[All selected lists will be available to customers as additionals lists.]]></comment>
171
  </additional_lists>
172
  <confirmation_email translate="label comment">
173
  <label>Use Magento's confirmation email</label>
187
  <show_in_default>1</show_in_default>
188
  <show_in_website>0</show_in_website>
189
  <show_in_store>1</show_in_store>
190
+ <comment><![CDATA[<b>IMPORTANT</b>: Should be set to <b>Yes</b>. Abusing this may cause your account to be suspended.<br/><a target='_blank' href='http://kb.mailchimp.com/article/how-does-confirmed-optin-or-double-optin-work/'>How does double opt-in work?</a>.]]></comment>
191
  </double_optin>
192
  <map_fields translate="label comment">
193
  <label>Customer Fields Mapping</label>
206
  <show_in_default>1</show_in_default>
207
  <show_in_website>0</show_in_website>
208
  <show_in_store>1</show_in_store>
209
+ <comment><![CDATA[This value will be sent as FNAME to MailChimp.]]></comment>
210
  </guest_name>
211
  <guest_lastname translate="label comment">
212
  <label>Last Name for Guests subscribers</label>
215
  <show_in_default>1</show_in_default>
216
  <show_in_website>0</show_in_website>
217
  <show_in_store>1</show_in_store>
218
+ <comment><![CDATA[This value will be sent as LNAME to MailChimp.]]></comment>
219
  </guest_lastname>
220
  <checkout_subscribe translate="label comment">
221
  <label>Subscribe On Checkout</label>
225
  <show_in_default>1</show_in_default>
226
  <show_in_website>0</show_in_website>
227
  <show_in_store>1</show_in_store>
228
+ <comment><![CDATA[Show Newsletter Subscribe checkbox in the last Checkout Step (Order Review).]]></comment>
229
  </checkout_subscribe>
230
  <markfield translate="label comment">
231
  <label>Map field to mark</label>
234
  <show_in_default>1</show_in_default>
235
  <show_in_website>0</show_in_website>
236
  <show_in_store>1</show_in_store>
237
+ <comment><![CDATA[Field to distinguish if the user subscribe.]]></comment>
238
  </markfield>
239
  <checkout_async translate="label comment">
240
  <label>Use Async subscribe in checkout</label>
268
  <show_in_store>1</show_in_store>
269
  <comment></comment>
270
  </cron_export>
271
+ <enable_webhooks translate="label comment">
272
+ <label>Enable two way sync via webhook</label>
273
+ <frontend_type>select</frontend_type>
274
+ <source_model>adminhtml/system_config_source_yesno</source_model>
275
+ <sort_order>140</sort_order>
276
+ <show_in_default>1</show_in_default>
277
+ <show_in_website>0</show_in_website>
278
+ <show_in_store>1</show_in_store>
279
+ <comment><![CDATA[A Webhook associated to the configured list is created inside your MailChimp Account and is used to sync data back to your site.]]></comment>
280
+ </enable_webhooks>
281
  <webhook_delete translate="label comment">
282
  <label>Webhooks Delete action</label>
283
  <frontend_type>select</frontend_type>
287
  <show_in_website>0</show_in_website>
288
  <show_in_store>1</show_in_store>
289
  <comment></comment>
290
+ <depends><enable_webhooks>1</enable_webhooks></depends>
291
  </webhook_delete>
292
  <adminhtml_notification translate="label comment">
293
  <label>Show Admin Notifications</label>
297
  <show_in_default>1</show_in_default>
298
  <show_in_website>0</show_in_website>
299
  <show_in_store>1</show_in_store>
300
+ <comment><![CDATA[Notifications related to campaigns sent, cleaned emails, etc.]]></comment>
301
  </adminhtml_notification>
302
  <enable_log translate="label comment">
303
  <label>Enable Log</label>
307
  <show_in_default>1</show_in_default>
308
  <show_in_website>0</show_in_website>
309
  <show_in_store>1</show_in_store>
310
+ <comment><![CDATA[File is {{base_dir}}/var/log/MageMonkey_ApiCall.log.]]></comment>
311
  </enable_log>
312
  </fields>
313
  </general>
328
  <show_in_website>1</show_in_website>
329
  <show_in_store>1</show_in_store>
330
  <can_be_empty>1</can_be_empty>
331
+ <comment><![CDATA[Send new orders to MailChimp using Ecommerce360.<br/><a target='_blank' href='http://kb.mailchimp.com/article/how-do-i-turn-on-ecommerce360-tracking-on-my-campaigns/'>How do I turn on Ecommerce360 tracking on my campaigns?</a><br/><a target='_blank' href='http://kb.mailchimp.com/article/how-to-segment-your-list-based-on-your-customers-purchase-activity'>How to segment your list based on your customers purchase activity</a>.]]></comment>
332
  </active>
333
  <order_status translate="label comment">
334
  <label>Order Status</label>
338
  <show_in_default>1</show_in_default>
339
  <show_in_website>0</show_in_website>
340
  <show_in_store>1</show_in_store>
341
+ <comment><![CDATA[<b>IMPORTANT</b>: By default this function run every one hour. If you want to edit this value visit our <a target='_blank' href='http://wiki.ebizmarts.com/installation/configuration/faq#TOC-How-I-set-up-the-Magento-cron-'>wiki</a>.]]></comment>
342
  <depends>
343
  <active>3</active>
344
  </depends>
365
  <show_in_website>0</show_in_website>
366
  <show_in_store>1</show_in_store>
367
  <can_be_empty>1</can_be_empty>
368
+ <comment><![CDATA[All selected attributes will be sent on the product name to MailChimp for segmentation purposes.]]></comment>
369
  <depends>
370
  <active separator=",">1,2,3</active>
371
  </depends>
app/code/community/Ebizmarts/MageMonkey/sql/monkey_setup/mysql4-upgrade-1.1.23-1.1.24.php CHANGED
@@ -4,9 +4,13 @@ $installer = $this;
4
 
5
  $installer->startSetup();
6
 
7
- $installer->run("
 
8
  ALTER TABLE `{$this->getTable('magemonkey_async_subscribers')}` CHANGE `proccessed` `processed` INT;
9
  ALTER TABLE `{$this->getTable('magemonkey_async_orders')}` CHANGE `proccessed` `processed` INT;
10
  ");
 
 
 
11
 
12
  $installer->endSetup();
4
 
5
  $installer->startSetup();
6
 
7
+ try {
8
+ $installer->run("
9
  ALTER TABLE `{$this->getTable('magemonkey_async_subscribers')}` CHANGE `proccessed` `processed` INT;
10
  ALTER TABLE `{$this->getTable('magemonkey_async_orders')}` CHANGE `proccessed` `processed` INT;
11
  ");
12
+ }
13
+
14
+ catch(Exception $e){}
15
 
16
  $installer->endSetup();
app/code/community/Ebizmarts/MageMonkey/sql/monkey_setup/mysql4-upgrade-1.2.4-1.2.5.php ADDED
@@ -0,0 +1,21 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ $installer = $this;
4
+
5
+ $installer->startSetup();
6
+
7
+ $installer->getConnection()->addColumn(
8
+ $installer->getTable('magemonkey_async_subscribers'), 'order_id', 'smallint(5)'
9
+ );
10
+
11
+ $installer->run("
12
+ CREATE TABLE IF NOT EXISTS `{$this->getTable('magemonkey_async_webhooks')}` (
13
+ `id` INT(10) unsigned NOT NULL auto_increment,
14
+ `webhook_type` varchar(24),
15
+ `webhook_data` text,
16
+ `processed` INT(1) NOT NULL default 0,
17
+ PRIMARY KEY (`id`)
18
+ ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
19
+ ");
20
+
21
+ $installer->endSetup();
app/code/community/Ebizmarts/Mandrill/Model/Email/Queue.php CHANGED
@@ -18,9 +18,6 @@ class Ebizmarts_Mandrill_Model_Email_Queue extends Mage_Core_Model_Email_Queue
18
  */
19
  public function send()
20
  {
21
- if (!Mage::getStoreConfig(Ebizmarts_Mandrill_Model_System_Config::ENABLE)) {
22
- return parent::send();
23
- }
24
  /** @var $collection Mage_Core_Model_Resource_Email_Queue_Collection */
25
  $collection = Mage::getModel('core/email_queue')->getCollection()
26
  ->addOnlyForSendingFilter()
@@ -30,57 +27,109 @@ class Ebizmarts_Mandrill_Model_Email_Queue extends Mage_Core_Model_Email_Queue
30
  /** @var $message Mage_Core_Model_Email_Queue */
31
  foreach ($collection as $message) {
32
  if ($message->getId()) {
33
- $parameters = new Varien_Object($message->getMessageParameters());
34
- $mailer = $this->getMail();
35
- $mandrill = array(
36
- 'subject' => $parameters->getSubject(),
37
- 'to' => array(),
38
- 'from_email' => $parameters->getFromEmail(),
39
- 'from_name' => $parameters->getFromName(),
40
- 'headers' => $mailer->getHeaders(),
41
- 'html' => ($parameters->getIsPlain() ? "" : $message->getMessageBody()),
42
- 'text' => ($parameters->getIsPlain() ? $message->getMessageBody() : ""),
43
- );
44
- foreach ($message->getRecipients() as $recipient) {
45
- list($email, $name, $type) = $recipient;
46
- $mandrill['to'][] = array(
47
- 'type' => ($type == self::EMAIL_TYPE_BCC ? "bcc" : "to"),
48
- 'email' => $email,
49
- 'name' => $name
50
- );
51
- }
52
- if ($parameters->getReplyTo() !== null) {
53
- $mandrill['headers'] = array_merge($mandrill['headers'], array('Reply-To' => $parameters->getReplyTo()));
54
- }
55
- if ($parameters->getReturnTo() !== null) {
56
- $mailer->setReturnPath($parameters->getReturnTo());
57
- }
58
- try {
59
- $mailer->messages->send($mandrill);
60
- } catch (Exception $e) {
61
- Mage::logException($e);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
62
  }
63
- unset($mailer);
64
- unset($mandrill);
65
- $message->setProcessedAt(Varien_Date::formatDate(true));
66
- $message->save();
67
  }
68
  }
69
  return $this;
70
  }
 
71
  /**
 
72
  * @return Mandrill_Message|Zend_Mail
73
  */
74
- public function getMail()
75
  {
76
- $storeId = Mage::app()->getStore()->getId();
77
  if (!Mage::getStoreConfig(Ebizmarts_Mandrill_Model_System_Config::ENABLE, $storeId)) {
78
  return parent::getMail();
79
  }
80
  if ($this->_mail) {
81
  return $this->_mail;
82
  } else {
83
- $storeId = Mage::app()->getStore()->getId();
84
  Mage::helper('ebizmarts_mandrill')->log("store: $storeId API: " . Mage::getStoreConfig(Ebizmarts_Mandrill_Model_System_Config::APIKEY, $storeId));
85
  $this->_mail = new Mandrill_Message(Mage::getStoreConfig(Ebizmarts_Mandrill_Model_System_Config::APIKEY, $storeId));
86
  return $this->_mail;
18
  */
19
  public function send()
20
  {
 
 
 
21
  /** @var $collection Mage_Core_Model_Resource_Email_Queue_Collection */
22
  $collection = Mage::getModel('core/email_queue')->getCollection()
23
  ->addOnlyForSendingFilter()
27
  /** @var $message Mage_Core_Model_Email_Queue */
28
  foreach ($collection as $message) {
29
  if ($message->getId()) {
30
+ if ($message->getEntityType() == 'order') {
31
+ $order = Mage::getModel('sales/order')->load($message->getEntityId());
32
+ $storeId = $order->getStoreId();
33
+ if (Mage::getStoreConfig(Ebizmarts_Mandrill_Model_System_Config::ENABLE, $storeId)) {
34
+ $parameters = new Varien_Object($message->getMessageParameters());
35
+ $mailer = $this->getMail($storeId);
36
+ $mandrill = array(
37
+ 'subject' => $parameters->getSubject(),
38
+ 'to' => array(),
39
+ 'from_email' => $parameters->getFromEmail(),
40
+ 'from_name' => $parameters->getFromName(),
41
+ 'headers' => $mailer->getHeaders(),
42
+ 'html' => ($parameters->getIsPlain() ? "" : $message->getMessageBody()),
43
+ 'text' => ($parameters->getIsPlain() ? $message->getMessageBody() : ""),
44
+ );
45
+ foreach ($message->getRecipients() as $recipient) {
46
+ list($email, $name, $type) = $recipient;
47
+ $mandrill['to'][] = array(
48
+ 'type' => ($type == self::EMAIL_TYPE_BCC ? "bcc" : "to"),
49
+ 'email' => $email,
50
+ 'name' => $name
51
+ );
52
+ }
53
+ if ($parameters->getReplyTo() !== null) {
54
+ $mandrill['headers'] = array_merge($mandrill['headers'], array('Reply-To' => $parameters->getReplyTo()));
55
+ }
56
+ if ($parameters->getReturnTo() !== null) {
57
+ $mailer->setReturnPath($parameters->getReturnTo());
58
+ }
59
+ try {
60
+ $mailer->messages->send($mandrill);
61
+ } catch (Exception $e) {
62
+ Mage::logException($e);
63
+ }
64
+ unset($mailer);
65
+ unset($mandrill);
66
+ $message->setProcessedAt(Varien_Date::formatDate(true));
67
+ $message->save();
68
+ }else{
69
+ $parameters = new Varien_Object($message->getMessageParameters());
70
+ if ($parameters->getReturnPathEmail() !== null) {
71
+ $mailTransport = new Zend_Mail_Transport_Sendmail("-f" . $parameters->getReturnPathEmail());
72
+ Zend_Mail::setDefaultTransport($mailTransport);
73
+ }
74
+
75
+ $mailer = new Zend_Mail('utf-8');
76
+ foreach ($message->getRecipients() as $recipient) {
77
+ list($email, $name, $type) = $recipient;
78
+ switch ($type) {
79
+ case self::EMAIL_TYPE_BCC:
80
+ $mailer->addBcc($email, '=?utf-8?B?' . base64_encode($name) . '?=');
81
+ break;
82
+ case self::EMAIL_TYPE_TO:
83
+ case self::EMAIL_TYPE_CC:
84
+ default:
85
+ $mailer->addTo($email, '=?utf-8?B?' . base64_encode($name) . '?=');
86
+ break;
87
+ }
88
+ }
89
+
90
+ if ($parameters->getIsPlain()) {
91
+ $mailer->setBodyText($message->getMessageBody());
92
+ } else {
93
+ $mailer->setBodyHTML($message->getMessageBody());
94
+ }
95
+
96
+ $mailer->setSubject('=?utf-8?B?' . base64_encode($parameters->getSubject()) . '?=');
97
+ $mailer->setFrom($parameters->getFromEmail(), $parameters->getFromName());
98
+ if ($parameters->getReplyTo() !== null) {
99
+ $mailer->setReplyTo($parameters->getReplyTo());
100
+ }
101
+ if ($parameters->getReturnTo() !== null) {
102
+ $mailer->setReturnPath($parameters->getReturnTo());
103
+ }
104
+
105
+ try {
106
+ $mailer->send();
107
+ } catch (Exception $e) {
108
+ Mage::logException($e);
109
+ }
110
+
111
+ unset($mailer);
112
+ $message->setProcessedAt(Varien_Date::formatDate(true));
113
+ $message->save();
114
+ }
115
  }
 
 
 
 
116
  }
117
  }
118
  return $this;
119
  }
120
+
121
  /**
122
+ * @param $storeId
123
  * @return Mandrill_Message|Zend_Mail
124
  */
125
+ public function getMail($storeId)
126
  {
 
127
  if (!Mage::getStoreConfig(Ebizmarts_Mandrill_Model_System_Config::ENABLE, $storeId)) {
128
  return parent::getMail();
129
  }
130
  if ($this->_mail) {
131
  return $this->_mail;
132
  } else {
 
133
  Mage::helper('ebizmarts_mandrill')->log("store: $storeId API: " . Mage::getStoreConfig(Ebizmarts_Mandrill_Model_System_Config::APIKEY, $storeId));
134
  $this->_mail = new Mandrill_Message(Mage::getStoreConfig(Ebizmarts_Mandrill_Model_System_Config::APIKEY, $storeId));
135
  return $this->_mail;
app/code/community/Ebizmarts/Mandrill/Model/Email/Template.php CHANGED
@@ -20,8 +20,9 @@ class Ebizmarts_Mandrill_Model_Email_Template extends Mage_Core_Model_Email_Temp
20
  */
21
  public function send($email, $name = null, array $variables = array())
22
  {
23
- $storeId = Mage::app()->getStore()->getId();
24
- if (!Mage::getStoreConfig(Ebizmarts_Mandrill_Model_System_Config::ENABLE, $storeId)) {
 
25
  return parent::send($email, $name, $variables);
26
  }
27
  if (!$this->isValidForSend()) {
20
  */
21
  public function send($email, $name = null, array $variables = array())
22
  {
23
+ // $storeId = Mage::app()->getStore()->getId();
24
+ // $order = Mage::getModel('sales/order')->load
25
+ if (!Mage::getStoreConfig(Ebizmarts_Mandrill_Model_System_Config::ENABLE)) {
26
  return parent::send($email, $name, $variables);
27
  }
28
  if (!$this->isValidForSend()) {
app/code/community/Ebizmarts/Mandrill/etc/config.xml CHANGED
@@ -2,7 +2,7 @@
2
  <config>
3
  <modules>
4
  <Ebizmarts_Mandrill>
5
- <version>2.0.9</version>
6
  </Ebizmarts_Mandrill>
7
  </modules>
8
  <global>
2
  <config>
3
  <modules>
4
  <Ebizmarts_Mandrill>
5
+ <version>2.0.10</version>
6
  </Ebizmarts_Mandrill>
7
  </modules>
8
  <global>
app/design/adminhtml/default/default/template/ebizmarts/abandonedcart/system/config/fieldset/hint.phtml CHANGED
@@ -1,6 +1,6 @@
1
  <div style="background:#EAF0EE;border:1px solid #CCCCCC;margin-bottom:10px;padding:11px 0 0 10px;">
2
  <h4>
3
- <img src="http://ebizmarts.com/extension-logo.php?<?php echo $this->getPxParams(); ?>"/><br>
4
  <?php echo Mage::helper('ebizmarts_abandonedcart')->__('<strong style="color:#EA7601;">Ebizmarts Abandoned Cart v%s</strong> <br>Need help? See our <a href="http://wiki.ebizmarts.com/abandoned-carts/" target="_blank">Wiki</a> or browse our <a href="http://ebizmarts.com/forums/view/1" target="_blank">support forums</a> Got feedback? <a href="mailto:info@ebizmarts.com?Subject=Support Abandoned Cart Version %s">Email us</a>', $this->getVersion(), $this->getVersion()) ?>
5
  <?php if (!Mage::helper('ebizmarts_mandrill')->useTransactionalService()): ?>
6
  <div class="box error-msg" style="padding-left: 30px;">
1
  <div style="background:#EAF0EE;border:1px solid #CCCCCC;margin-bottom:10px;padding:11px 0 0 10px;">
2
  <h4>
3
+ <img width="244px" height="60px" src="https://ebizmarts-website.s3.amazonaws.com/Logo_Ebizmarts.png"/><br>
4
  <?php echo Mage::helper('ebizmarts_abandonedcart')->__('<strong style="color:#EA7601;">Ebizmarts Abandoned Cart v%s</strong> <br>Need help? See our <a href="http://wiki.ebizmarts.com/abandoned-carts/" target="_blank">Wiki</a> or browse our <a href="http://ebizmarts.com/forums/view/1" target="_blank">support forums</a> Got feedback? <a href="mailto:info@ebizmarts.com?Subject=Support Abandoned Cart Version %s">Email us</a>', $this->getVersion(), $this->getVersion()) ?>
5
  <?php if (!Mage::helper('ebizmarts_mandrill')->useTransactionalService()): ?>
6
  <div class="box error-msg" style="padding-left: 30px;">
app/design/adminhtml/default/default/template/ebizmarts/autoresponder/system/config/fieldset/hint.phtml CHANGED
@@ -1,6 +1,6 @@
1
  <div style="background:#EAF0EE;border:1px solid #CCCCCC;margin-bottom:10px;padding:11px 0 0 10px;">
2
  <h4>
3
- <img src="http://ebizmarts.com/extension-logo.php?<?php echo $this->getPxParams(); ?>"/><br>
4
  <?php echo Mage::helper('ebizmarts_autoresponder')->__('<strong style="color:#EA7601;">Ebizmarts Autoresponder v%s</strong> <br>Need help? See our <a href="http://wiki.ebizmarts.com/configuration" target="_blank">Wiki</a> or browse our <a href="http://ebizmarts.com/forums/view/1" target="_blank">support forums</a> Got feedback? <a href="mailto:info@ebizmarts.com?Subject=Support Autoresponder Version %s">Email us</a>', $this->getVersion(), $this->getVersion()) ?>
5
 
6
  <?php if (!Mage::helper('ebizmarts_mandrill')->useTransactionalService()): ?>
1
  <div style="background:#EAF0EE;border:1px solid #CCCCCC;margin-bottom:10px;padding:11px 0 0 10px;">
2
  <h4>
3
+ <img width="244px" height="60px" src="https://ebizmarts-website.s3.amazonaws.com/Logo_Ebizmarts.png"/><br>
4
  <?php echo Mage::helper('ebizmarts_autoresponder')->__('<strong style="color:#EA7601;">Ebizmarts Autoresponder v%s</strong> <br>Need help? See our <a href="http://wiki.ebizmarts.com/configuration" target="_blank">Wiki</a> or browse our <a href="http://ebizmarts.com/forums/view/1" target="_blank">support forums</a> Got feedback? <a href="mailto:info@ebizmarts.com?Subject=Support Autoresponder Version %s">Email us</a>', $this->getVersion(), $this->getVersion()) ?>
5
 
6
  <?php if (!Mage::helper('ebizmarts_mandrill')->useTransactionalService()): ?>
app/design/adminhtml/default/default/template/ebizmarts/mandrill/system/config/fieldset/hint.phtml CHANGED
@@ -1,5 +1,5 @@
1
  <div class="mandrill-notice">
2
- <img src="https://ebizmarts.com/extension-logo.php?<?php echo $this->getPxParams(); ?>"/>
3
  <h4>
4
  <?php echo $this->__('<strong style="color:#EA7601;">Mandrill v%s by</strong> <a target="_blank" href="http://ebizmarts.com"><strong>ebizmarts</strong></a>', $this->getMandrillVersion()) ?>
5
  <br>
1
  <div class="mandrill-notice">
2
+ <img width="244px" height="60px" src="https://ebizmarts-website.s3.amazonaws.com/Logo_Ebizmarts.png"/>
3
  <h4>
4
  <?php echo $this->__('<strong style="color:#EA7601;">Mandrill v%s by</strong> <a target="_blank" href="http://ebizmarts.com"><strong>ebizmarts</strong></a>', $this->getMandrillVersion()) ?>
5
  <br>
app/design/adminhtml/default/default/template/magemonkey/system/config/fieldset/hint.phtml CHANGED
@@ -4,7 +4,7 @@
4
  */
5
  ?>
6
  <div class="magemonkey-notice">
7
- <img src="https://ebizmarts.com/extension-logo.php?<?php echo $this->getPxParams(); ?>"/>
8
  <h4>
9
  <?php echo Mage::helper('monkey')->__('<strong style="color:#EA7601;">MageMonkey v%s by</strong> <a target="_blank" href="http://ebizmarts.com"><strong>ebizmarts</strong></a>', $this->getMageMonkeyVersion()) ?>
10
  <br>
4
  */
5
  ?>
6
  <div class="magemonkey-notice">
7
+ <img width="244px" height="60px" src="https://ebizmarts-website.s3.amazonaws.com/Logo_Ebizmarts.png"/>
8
  <h4>
9
  <?php echo Mage::helper('monkey')->__('<strong style="color:#EA7601;">MageMonkey v%s by</strong> <a target="_blank" href="http://ebizmarts.com"><strong>ebizmarts</strong></a>', $this->getMageMonkeyVersion()) ?>
10
  <br>
app/design/adminhtml/default/default/template/sweetmonkey/system/config/fieldset/hint.phtml CHANGED
@@ -4,7 +4,7 @@
4
  */
5
  ?>
6
  <div class="sweetmonkey-notice">
7
- <img src="http://ebizmarts.com/extension-logo.php?<?php echo $this->getPxParams(); ?>"/>
8
  <h4>
9
  <?php echo $this->__('<strong style="color:#EA7601;">Sweet Monkey v%s by</strong> <a target="_blank" href="http://ebizmarts.com"><strong>ebizmarts</strong></a>', $this->getSweetMonkeyVersion()) ?>
10
  </h4>
4
  */
5
  ?>
6
  <div class="sweetmonkey-notice">
7
+ <img width="244px" height="60px" src="https://ebizmarts-website.s3.amazonaws.com/Logo_Ebizmarts.png"/>
8
  <h4>
9
  <?php echo $this->__('<strong style="color:#EA7601;">Sweet Monkey v%s by</strong> <a target="_blank" href="http://ebizmarts.com"><strong>ebizmarts</strong></a>', $this->getSweetMonkeyVersion()) ?>
10
  </h4>
app/design/frontend/base/default/template/ebizmarts_abandonedcart/email/order/.DS_Store DELETED
Binary file
app/design/frontend/base/default/template/ebizmarts_abandonedcart/email/order/items/order/.DS_Store DELETED
Binary file
app/design/frontend/base/default/template/ebizmarts_abandonedcart/popup/emailcatcher.phtml CHANGED
@@ -83,26 +83,22 @@
83
  onCancel: function (win) {
84
  <?php if(isset($_COOKIE['counter'])):
85
  //check cookie counter for customer id and check actual counter
86
- $counterId = $_COOKIE['counter'];
87
- $counter = Mage::getModel('ebizmarts_abandonedcart/popup')->load($counterId);
88
  //if(counter en config == counter en db){
89
- if($counter->getCounter()+1 >= Mage::getStoreConfig(Ebizmarts_AbandonedCart_Model_Config::POPUP_INSIST, Mage::app()->getStore()->getId())):
90
  ?>
91
- document.cookie = 'counter=; expires=Thu, 01 Jan 1970 00:00:01 GMT';
92
- createCookie('email=none', <?php Print(json_encode(Mage::getStoreConfig(Ebizmarts_AbandonedCart_Model_Config::POPUP_COOKIE_TIME, $this->_getStoreId()))); ?>);
93
- <?php else :
94
- $counter->setCounter(($counter->getCounter()+1));
95
- $counter->save();
96
- endif; ?>
97
  <?php else:
98
  //create cookie counter in 0
99
  if (Mage::getStoreConfig(Ebizmarts_AbandonedCart_Model_Config::POPUP_INSIST, Mage::app()->getStore()->getId()) == 1): ?>
100
- createCookie('email=none', <?php Print(json_encode(Mage::getStoreConfig(Ebizmarts_AbandonedCart_Model_Config::POPUP_COOKIE_TIME, $this->_getStoreId()))); ?>);
101
- <?php else:
102
  $newCounter = Mage::getModel('ebizmarts_abandonedcart/popup');
103
- $newCounter->setCounter(1)->save();
104
- ?>
105
- createCookie('counter=' +<?php Print(json_encode($newCounter->getId())); ?>, <?php Print(json_encode(Mage::getStoreConfig(Ebizmarts_AbandonedCart_Model_Config::POPUP_COOKIE_TIME, $this->_getStoreId()))); ?>);
106
  <?php endif; ?>
107
  <?php endif; ?>
108
  },
@@ -121,10 +117,9 @@
121
  lname = inputFieldLName.value;
122
  }
123
  if (validateEmail(email)) {
124
- var cookie = 'email=' + email + '/' + fname + '/' + lname;
125
- createCookie(cookie, 365);
126
  <?php if($this->_modalSubscribe()): ?>
127
- createCookie('subscribe=true', 365);
128
  location.reload();
129
  <?php else: ?>
130
  win.close();
@@ -158,20 +153,28 @@
158
  return re.test(email);
159
  }
160
  function emailCookieExists() {
161
- var cookie = document.cookie;
162
- var cookieArr = cookie.split(';');
163
- var cookieStored = false;
164
- for (var i = 0; i < cookieArr.length; i++) {
165
- if (cookieArr[i].indexOf('email=') > -1) {
166
- cookieStored = true;
167
- }
 
 
 
 
 
 
 
168
  }
169
- return cookieStored;
170
  }
171
- function createCookie(cookie, expirationInDays) {
172
  var now = new Date();
173
  var expire = new Date(now.getTime() + (expirationInDays * 24 * 60) * 60000);//[(1 * 365 * 24 * 60) * 60000] == 1 year -- (Years * Days * Hours * Minutes) * 60000
174
- document.cookie = cookie + '; expires=' + expire + '; path=/';
 
 
175
  }
176
  </script>
177
  <?php endif; ?>
83
  onCancel: function (win) {
84
  <?php if(isset($_COOKIE['counter'])):
85
  //check cookie counter for customer id and check actual counter
86
+ $counter = $_COOKIE['counter'];
 
87
  //if(counter en config == counter en db){
88
+ if($counter+1 >= Mage::getStoreConfig(Ebizmarts_AbandonedCart_Model_Config::POPUP_INSIST, Mage::app()->getStore()->getId())):
89
  ?>
90
+ Mage.Cookies.clear('counter');
91
+ createCookie('email', 'none', <?php Print(json_encode(Mage::getStoreConfig(Ebizmarts_AbandonedCart_Model_Config::POPUP_COOKIE_TIME, $this->_getStoreId()))); ?>);
92
+ <?php else : ?>
93
+ createCookie('counter',<?php Print(json_encode((1+$counter))); ?>,<?php Print(json_encode(Mage::getStoreConfig(Ebizmarts_AbandonedCart_Model_Config::POPUP_COOKIE_TIME, $this->_getStoreId()))); ?>);
94
+ <?php endif; ?>
 
95
  <?php else:
96
  //create cookie counter in 0
97
  if (Mage::getStoreConfig(Ebizmarts_AbandonedCart_Model_Config::POPUP_INSIST, Mage::app()->getStore()->getId()) == 1): ?>
98
+ createCookie('email', 'none', <?php Print(json_encode(Mage::getStoreConfig(Ebizmarts_AbandonedCart_Model_Config::POPUP_COOKIE_TIME, $this->_getStoreId()))); ?>);
99
+ <?php else: ?>
100
  $newCounter = Mage::getModel('ebizmarts_abandonedcart/popup');
101
+ createCookie('counter',1,<?php Print(json_encode(Mage::getStoreConfig(Ebizmarts_AbandonedCart_Model_Config::POPUP_COOKIE_TIME, $this->_getStoreId()))); ?>);
 
 
102
  <?php endif; ?>
103
  <?php endif; ?>
104
  },
117
  lname = inputFieldLName.value;
118
  }
119
  if (validateEmail(email)) {
120
+ createCookie('email',email + '/' + fname + '/' + lname, 365);
 
121
  <?php if($this->_modalSubscribe()): ?>
122
+ createCookie('subscribe', 'true', 365);
123
  location.reload();
124
  <?php else: ?>
125
  win.close();
153
  return re.test(email);
154
  }
155
  function emailCookieExists() {
156
+ // var cookie = document.cookie;
157
+ // var cookieArr = cookie.split(';');
158
+ // var cookieStored = false;
159
+ // for (var i = 0; i < cookieArr.length; i++) {
160
+ // if (cookieArr[i].indexOf('email=') > -1) {
161
+ // cookieStored = true;
162
+ // }
163
+ // }
164
+ // return cookieStored;
165
+ if(Mage.Cookies.get('email')) {
166
+ return true
167
+ }
168
+ else {
169
+ return false
170
  }
 
171
  }
172
+ function createCookie(name, value, expirationInDays) {
173
  var now = new Date();
174
  var expire = new Date(now.getTime() + (expirationInDays * 24 * 60) * 60000);//[(1 * 365 * 24 * 60) * 60000] == 1 year -- (Years * Days * Hours * Minutes) * 60000
175
+ //document.cookie = cookie + '; expires=' + expire + '; path=/';
176
+ Mage.Cookies.expires = expire;
177
+ Mage.Cookies.set(name,value);
178
  }
179
  </script>
180
  <?php endif; ?>
js/ebizmarts/magemonkey/campaignCatcher.js CHANGED
@@ -1,32 +1,33 @@
1
-
2
- function getCampaign() {
3
- var params = location.search.substr(1).split('&');
4
- var cookies = new Array();
5
- for (var i = 0; i < params.length; i++) {
6
- var cookie = params[i].split('=');
7
- var key = cookie[0];
8
- var val = cookie[1];
9
- if (key && val) {
10
- cookies[key] = val;
11
- }
12
- }
13
-
14
- if (cookies['mc_cid']) {
15
- createCookie('magemonkey_campaign_id=' + cookies['mc_cid'], 30);
16
- }
17
- if (cookies['mc_eid']) {
18
- createCookie('magemonkey_email_id=' + cookies['mc_eid'], 30);
19
  }
20
  }
21
 
22
- function createCookie(cookie, expirationInDays) {
23
- var now = new Date();
24
- var expire = new Date(now.getTime() + (expirationInDays * 24 * 60) * 60000);//[(1 * 365 * 24 * 60) * 60000] == 1 year -- (Years * Days * Hours * Minutes) * 60000
25
- document.cookie = cookie + '; expires=' + expire + '; path=/';
 
26
  }
 
 
 
 
 
 
 
 
 
27
 
28
- if (document.loaded) {
29
- getCampaign;
30
- } else {
31
- document.observe('dom:loaded', getCampaign);
32
- }
1
+ function getCampaign() {
2
+ var urlparams = location.search.substr(1).split('&');
3
+ var params = new Array();
4
+ for (var i = 0; i < urlparams.length; i++) {
5
+ var param = urlparams[i].split('=');
6
+ var key = param[0];
7
+ var val = param[1];
8
+ if (key && val) {
9
+ params[key] = val;
 
 
 
 
 
 
 
 
 
10
  }
11
  }
12
 
13
+ if (params['mc_cid']) {
14
+ createCookie('magemonkey_campaign_id', params['mc_cid'], 3600);
15
+ }
16
+ if (params['mc_eid']) {
17
+ createCookie('magemonkey_email_id', params['mc_eid'], 3600);
18
  }
19
+ }
20
+
21
+ function createCookie(name, value, expirationInSec) {
22
+ var now = new Date();
23
+ var expire = new Date(now.getTime() + (expirationInSec * 1000));//[(1 * 365 * 24 * 60) * 60000] == 1 year -- (Years * Days * Hours * Minutes) * 60000
24
+ alert('creating cookie');
25
+ Mage.Cookies.expires = expire;
26
+ Mage.Cookies.set(name,value);
27
+ }
28
 
29
+ if (document.loaded) {
30
+ getCampaign;
31
+ } else {
32
+ document.observe('dom:loaded', getCampaign);
33
+ }
package.xml CHANGED
@@ -1,33 +1,34 @@
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>Ebizmarts_MageMonkey</name>
4
- <version>1.2.3</version>
5
  <stability>stable</stability>
6
  <license uri="http://www.opensource.org/licenses/osl-3.0.php">OSL v3.0</license>
7
  <channel>community</channel>
8
  <extends/>
9
  <summary>MailChimp integration for Magento by Ebizmarts</summary>
10
  <description>Full MailChimp integration, automatic webhooks, multiple lists, interest groups</description>
11
- <notes>1.2.3&#xD;
12
  --------&#xD;
13
  Bug Fixes:&#xD;
14
- Fixed compatibility issue with array creation for newer versions of php.&#xD;
15
- Curlopt Followlocation issue solved.&#xD;
16
- Checkout subscription problem solved.&#xD;
17
- Image issue with Abandoned cart emails solved.&#xD;
18
- Autoresponders for admin created customer working.&#xD;
19
- Problem with Wishlist Autoresponder solved.&#xD;
20
- Group subscription on account creation issue solved.&#xD;
21
- Bundled products showing properly on Abandoned Cart emails.&#xD;
22
- Problem for orders being sent even when not in the selected status solved.&#xD;
23
- Problem for groups not being loaded on particular store views when setting different API Keys.&#xD;
24
  &#xD;
25
- Enahncements:&#xD;
26
- Added support for Google Analytics on Abandoned Carts Recovery configuration.</notes>
 
 
 
27
  <authors><author><name>Ebizmarts Development Team</name><user>ebizmarts</user><email>info@ebizmarts.com</email></author></authors>
28
- <date>2016-06-17</date>
29
- <time>19:47:58</time>
30
- <contents><target name="magecommunity"><dir name="Ebizmarts"><dir name="MageMonkey"><dir name="Block"><dir name="Adminhtml"><dir name="Bulksync"><dir name="Export"><file name="Form.php" hash="43de22b1bd39304bcd60cd6eebc25d28"/></dir><file name="Export.php" hash="ab839a4011692b69b292fe59eb50100e"/><dir name="Import"><file name="Form.php" hash="8927f46053a203e491e2bc2cb25fea1a"/></dir><file name="Import.php" hash="9c7ba4a566038356e60e9482301d7cb7"/><dir name="Queue"><file name="Grid.php" hash="23b3edec3bc13fae8aee5b7292c4d4d1"/></dir><file name="Queue.php" hash="c3cea1da02e0a09d7876958058ee091e"/><dir name="QueueExport"><file name="Grid.php" hash="68ec401dc23cddf8a1362c53aaab69b2"/></dir><file name="QueueExport.php" hash="69536eee264346535f1c786d61b3cf84"/><dir name="QueueImport"><file name="Grid.php" hash="0e43409930757224fbfcb3734fea9c67"/></dir><file name="QueueImport.php" hash="d9fbc0d22f94df54f71116d0d484d1a3"/></dir><dir name="Customer"><dir name="Edit"><dir name="Tab"><file name="Memberactivity.php" hash="55fbb4519c6d862948dc4d8bf4416cfb"/></dir></dir></dir><dir name="Ecommerce"><file name="Grid.php" hash="b1ad37ffe9fe0752356d29a6548b0434"/></dir><file name="Ecommerce.php" hash="48c237e8cc1223ad26a88d2409679fec"/><dir name="Ecommerceapi"><file name="Grid.php" hash="ee1be42cb6c893e3c59cac784df67fb3"/><dir name="Renderer"><file name="Items.php" hash="d72cfedf0cafc938becf9bd52801ba3a"/></dir></dir><file name="Ecommerceapi.php" hash="a9f659502d96bcd1a69a88d15fcab4f9"/><dir name="Memberactivity"><file name="Grid.php" hash="2753517318120344d1f7694a6b7a278d"/></dir><dir name="Newsletter"><dir name="Subscriber"><dir name="Renderer"><file name="Firstname.php" hash="e814d3ba07b32e851585363b29e37b3a"/><file name="Lastname.php" hash="9a8b007c2db6add0572cf4012b28f63e"/></dir></dir></dir><dir name="Renderer"><file name="Date.php" hash="6e4e52403ec55df3aa2183fd4b51b095"/><file name="Importypes.php" hash="87c7a222e403781fcd8ee08cf0b489ba"/><file name="Lists.php" hash="2dbd23844a822d3406efae08e89ce0d7"/><file name="Progress.php" hash="31eaaa5a7e99b21a4ed705971fe1001d"/><file name="Yesno.php" hash="c3173a8e8ea2d5f03531e7d996bbd259"/></dir><dir name="System"><dir name="Config"><file name="Account.php" hash="fccf1faac2682d754655631e6451c026"/><file name="Date.php" hash="455120f4f2e8d7801f3c220e231b6789"/><dir name="Fieldset"><file name="Hint.php" hash="31bf492c4e6137312c55bc437bf226cf"/></dir><dir name="Form"><dir name="Field"><file name="Mapfields.php" hash="8f2a10ca1a1d239b3b231ca2cee5f96e"/></dir></dir><file name="OauthWizard.php" hash="bd79f8b43d71137337e732fbeb415ffb"/><file name="ResetLocalEcommerce.php" hash="493126ac056c3585ed2d3020d62c76e1"/><file name="ResetRemoteEcommerce.php" hash="40d54bb2d6e7dd7bf3a91c9346f988bf"/><file name="UpgradeForPatch.php" hash="d641d79e0ce65469e40c1b7eb81a2591"/></dir></dir></dir><dir name="Checkout"><file name="Subscribe.php" hash="14de0075005dafe3363716e3ffd10d20"/></dir><dir name="Customer"><dir name="Account"><file name="Lists.php" hash="64f0e5a8360750f6b19d8b5db0fcac23"/></dir></dir><file name="Lists.php" hash="bea29a7dc4e80337d85427a094af1316"/><file name="Signup.php" hash="93b0e787e63a90a5fb4bacba1e03bd05"/></dir><dir name="Helper"><file name="Cache.php" hash="4e6cd9724c2788056aacacd37f5699cc"/><file name="Data.php" hash="6de78747062148c252edadb8c582d82c"/><file name="Export.php" hash="91f24805e9cbbe124f0c99cb8f1f1272"/><file name="Oauth2.php" hash="684a7b71d97b438081ebf332057ec8ea"/></dir><dir name="Model"><file name="Api.php" hash="ea7c720767bc58cb740d2f70100f699b"/><file name="Asyncorders.php" hash="3f60d1a1c1885268ae7e2ddfb1772feb"/><file name="Asyncsubscribers.php" hash="b79a42df357267205d7e74bb7c220755"/><file name="BulksyncExport.php" hash="71af9a6134b415a324dc9c937a5b2f8e"/><file name="BulksyncImport.php" hash="fb3716e235bc22cf91c4c17edf10ec23"/><file name="Cache.php" hash="89ac2fac903a566e6f6a3c0951bf274d"/><file name="Config.php" hash="276026d2d6ac8af349b7f2f82dc17668"/><file name="Cron.php" hash="365efea2054464d913ca886f73f111d1"/><dir name="Custom"><file name="Collection.php" hash="304d372c1b8bd8d8d09dd743e03cdf66"/></dir><file name="Ecommerce.php" hash="f4581befe128963df3e3d062b1bc4d55"/><file name="Ecommerce360.php" hash="f08710f5b254669189f32e79b3b09b01"/><dir name="Email"><file name="Template.php" hash="81c9f040cf931dfb9e2a2484d9cc0b09"/></dir><dir name="Feed"><file name="Updates.php" hash="0a0da2a88047303d479584a773a51d26"/></dir><file name="Lastorder.php" hash="f2977e76892b0b1a5e031f8eabf93f18"/><file name="MCAPI.php" hash="1740a57c10a5d54aa4449f698e6dcd73"/><file name="MCEXPORTAPI.php" hash="810b1c7b0f6daf93e11c7fbbc90980a3"/><file name="Monkey.php" hash="249a3944c7f1c3707db016a16f189ac9"/><dir name="Mysql4"><dir name="Apidebug"><file name="Collection.php" hash="7cc3fe74a46da1a4770b49eb7ac47f97"/></dir><file name="Apidebug.php" hash="2699eec825e8fb88b1d572728c10b7bc"/><dir name="Asyncorders"><file name="Collection.php" hash="e7b17fac028f7116c762e120b0f3f0a8"/></dir><file name="Asyncorders.php" hash="3eb64d883705854ce7899fd891101c63"/><dir name="Asyncsubscribers"><file name="Collection.php" hash="3458134c9a1ced7359db40f7b79a133f"/></dir><file name="Asyncsubscribers.php" hash="a067c1e951ce61558e00f3aa8e5d15ef"/><dir name="Bulksync"><dir name="Export"><file name="Collection.php" hash="ac64bc652233136189c504f678062374"/></dir><file name="Export.php" hash="eedc5a3549b3815f0d290eca3e0579df"/><dir name="Import"><file name="Collection.php" hash="6cb3e09a817488f9bfa50f877a5c2b0b"/></dir><file name="Import.php" hash="487fc6c0335ebf352081185d9afe3f88"/></dir><dir name="Ecommerce"><file name="Collection.php" hash="80319b6c991c510f1569800c80d384f1"/></dir><file name="Ecommerce.php" hash="b3290a6170c8c8f275dcd4300840ea26"/><dir name="Lastorder"><file name="Collection.php" hash="38d6a7519cfe21caf7f5d22877aa1477"/></dir><file name="Lastorder.php" hash="f3987329cb78c978bcc94ba375d9f998"/></dir><file name="Observer.php" hash="875156238a6afd95b27a8c5502f913e4"/><file name="Subscriber.php" hash="26903cf8899d9cf1d2a0548d2a01a287"/><dir name="System"><dir name="Config"><dir name="Source"><file name="Account.php" hash="5bbf12b572234101af3e753ba74bcd41"/><file name="Attributes.php" hash="4ac1c98f3b3b84b2c93ddfcc3df5d817"/><file name="BulksyncDatasource.php" hash="36331ac3ecd034f914666a49e4d75cbc"/><file name="BulksyncStatus.php" hash="658f1f9d1ee7177d5dc094862bce155a"/><file name="Checkoutsubscribe.php" hash="28c8641a8fa4c336487af2227e152136"/><file name="CronProcessLimit.php" hash="3ca3a61f07b7aa84479eddda35efdde4"/><file name="CustomerGroup.php" hash="299b8514de098e02efe5393ebe7bdf65"/><file name="Ecommerce360.php" hash="24906da389cbf6b4a97c3edab5c7f020"/><file name="List.php" hash="acbffbbfe0a11566e745e01fce34ec51"/><file name="OrderProcessLimit.php" hash="bc3add48e125caa904774cb6b669ba0c"/><file name="OrderStatus.php" hash="d3eeeee5d614e8fa83e258ce53cbed79"/><file name="Status.php" hash="e1e5cf6252241f39d0ceaff6f94d3afb"/><file name="TransactionalEmails.php" hash="b2f0d564a59372cba59d3aac7e4fe9e0"/><file name="WebhookDelete.php" hash="c90bbf8b0cf2a546c0f72193f8c605cf"/></dir></dir></dir></dir><dir name="controllers"><dir name="Adminhtml"><file name="BulksyncController.php" hash="1e044f49bb90de5e2a2d9d0ec2feb73f"/><file name="ConfigController.php" hash="c62e1f6f54ac6a4fc33499c85f95948a"/><file name="EcommerceController.php" hash="4db500b32fb676705b4edad7ddb23e59"/></dir><dir name="Customer"><file name="AccountController.php" hash="14479dffeacd3c2421ce5822f7d7f190"/></dir><file name="SignupController.php" hash="e379f52f8ee0191a4c7289cd2afcd19d"/><file name="WebhookController.php" hash="319878266b5463d5d8591b6a4fb5e096"/></dir><dir name="etc"><file name="adminhtml.xml" hash="f203274d5b6522dd00f630a58bc18623"/><file name="config.xml" hash="fad6a414c7eb68025f322d051d2cc915"/><file name="system.xml" hash="b40934b302b5a10fc3926fa12567fb2c"/></dir><dir name="sql"><dir name="monkey_setup"><file name="mysql4-install-0.0.1.php" hash="4df34769f4d5a8ceca90fd582500e3a9"/><file name="mysql4-upgrade-0.0.1-0.0.2.php" hash="d81147dab407bc55c59cddb5a764c53e"/><file name="mysql4-upgrade-0.0.2-0.0.3.php" hash="ce1925ff2ab03aa9fd6cbe43283ea37d"/><file name="mysql4-upgrade-0.0.3-0.0.4.php" hash="7f1e38bcf030e6346a9fd8321f1a4362"/><file name="mysql4-upgrade-0.0.4-0.0.5.php" hash="bbe6b895320effca77cc2c23431f043f"/><file name="mysql4-upgrade-0.0.5-0.0.6.php" hash="98b72d9ef4ec8078c09a1f641fc35a39"/><file name="mysql4-upgrade-0.0.6-0.0.7.php" hash="ea15755fc072e7c82b78063589360779"/><file name="mysql4-upgrade-1.0.10-1.0.11.php" hash="b2ec497921eb2bd9a97a318554fd980b"/><file name="mysql4-upgrade-1.1.21-1.1.22.php" hash="738e3d3e33c1a3a02bb101b89743cc5c"/><file name="mysql4-upgrade-1.1.23-1.1.24.php" hash="5a1bfdc8014edbc8b8c728954405a9f5"/><file name="mysql4-upgrade-1.1.33-1.1.34.php" hash="68f74c77460e76ea6153ebc823d49990"/><file name="mysql4-upgrade-1.1.5-1.1.6.php" hash="14750274ece5816d6c1ab490f7d610ab"/><file name="mysql4-upgrade-1.2.1-1.2.2.php" hash="c622ec016eb8134492d6011007d82149"/></dir></dir></dir><dir name="Mandrill"><dir name="Block"><dir name="Adminhtml"><dir name="System"><dir name="Config"><dir name="Fieldset"><file name="Hint.php" hash="6ca5fb9bf9254323e1f2b4447203b562"/></dir><file name="Userinfo.php" hash="7cd34efc0231424c9e2f5e662154c41c"/></dir></dir><dir name="Templates"><dir name="Templates"><file name="Grid.php" hash="1ecdb6b04fbd16043de908f261353b8d"/></dir><file name="Templates.php" hash="1682fe6d39605a9839bf3cdb3c1185b7"/></dir><dir name="Users"><dir name="Senders"><file name="Grid.php" hash="292097a493de241540d3e3aea463241f"/></dir><file name="Senders.php" hash="4a4449652c495a9d4c12966ab007e7a4"/></dir></dir></dir><dir name="Helper"><file name="Data.php" hash="86fcaa6a66a5a628ded7215172448daf"/></dir><dir name="Model"><file name="Customcollection.php" hash="9b5766c0393a54b4356254725b4d78b2"/><dir name="Email"><file name="Queue.php" hash="69311da3ba95f395b44b8c3fef976009"/><file name="Template.php" hash="5794f1577c6db77e9a26e13be9023933"/></dir><dir name="System"><dir name="Config"><dir name="Source"><file name="Userinfo.php" hash="12a9c9c27c985efd021a4e6c7fdfcf5e"/></dir></dir><file name="Config.php" hash="2219d951bf6b2553ec0284b65d8d92a2"/></dir></dir><dir name="controllers"><dir name="Adminhtml"><dir name="Mandrill"><file name="UsersController.php" hash="72cb77b136fafaf5ef98e599ab8d5eb8"/></dir></dir></dir><dir name="etc"><file name="adminhtml.xml" hash="8ea87cce062596388f7e9507943e8bb5"/><file name="config.xml" hash="bb6bbb832249fbc5ceceb32387e96b73"/><file name="system.xml" hash="d05b90ca129297b6ffda52a4ba1fd26a"/></dir></dir><dir name="AbandonedCart"><dir name="Block"><dir name="Adminhtml"><dir name="Abandonedmails"><file name="Grid.php" hash="f2813a7ec47e20b78874a0dbb1461b3e"/></dir><file name="Abandonedmails.php" hash="c2714b5a6cb534c91564ebc340fe3f26"/><dir name="Abandonedorder"><file name="Grid.php" hash="5ab9e3884d3306d78e78133f09e22614"/></dir><file name="Abandonedorder.php" hash="1a14da87647612a8773f34f70bc05dea"/><dir name="Dashboard"><file name="Sales.php" hash="b0d6fce3a5f4ef5a891c8578eb36ef97"/><file name="Totals.php" hash="4cd3c1e0d8d357c79ec6e7a2ed98c6a0"/></dir><file name="Dashboard.php" hash="c27d5ec29455176fff7e2fac86fcce21"/><dir name="System"><dir name="Config"><file name="Date.php" hash="323a49af281f06dfa72c1d3512257e04"/><dir name="Fieldset"><file name="Hint.php" hash="6358bc58857011c08dedcbab885b461f"/></dir></dir></dir></dir><dir name="Email"><dir name="Order"><file name="Items.php" hash="08ba504f050dc955c213dc99b61dfddd"/></dir></dir><dir name="Popup"><file name="Emailcatcher.php" hash="1c04a8992ebf40cd2474d0db7ad48516"/></dir></dir><dir name="Helper"><file name="Data.php" hash="3e5a2e3d99b62936b0766313b9e62462"/></dir><dir name="Model"><file name="Abtesting.php" hash="fdf9df78b6656c898fd74fbcb3ec51e1"/><file name="Config.php" hash="9cf91d1c8f488a5607c301ab617d38f0"/><file name="Cron.php" hash="709e5d6b163d2fd4e7968dec024b20e7"/><file name="EventObserver.php" hash="57bb122fbd41fabbfa021d7a6ad96e0a"/><file name="Mailssent.php" hash="e238f4116cb473cdcfb3a909d08adaa4"/><file name="Popup.php" hash="d2a4922acc0c5c3994cbc0b2114658b8"/><dir name="Resource"><dir name="Abtesting"><file name="Collection.php" hash="f96fe4be550bef6daabc5d211c86aca0"/></dir><file name="Abtesting.php" hash="46e70f8507676e157ddec44f66094e59"/><dir name="Mailssent"><file name="Collection.php" hash="dc1e2c44eb53381d57d10a6bc08ad497"/></dir><file name="Mailssent.php" hash="80f0b4e3f29d10951362f07eb45a3ece"/><dir name="Order"><file name="Collection.php" hash="a079410c43e1afbb428b7163d1537482"/></dir><dir name="Popup"><file name="Collection.php" hash="af37502f9802c7574318ab28a8fb1b16"/></dir><file name="Popup.php" hash="446921e9b1da1973c83665e8f749bbbb"/></dir><dir name="System"><dir name="Config"><file name="Automatic.php" hash="a4f5e052810187fb824933e76ea8a1cf"/><file name="Cmspage.php" hash="89bfcbe90a7b2f396a56b3f1fe72dbd2"/><file name="Customergroup.php" hash="74af027c3fb6745d0e45938f83394489"/><file name="Discounttype.php" hash="55c251fafbd10821d6c18c381c307888"/><file name="Maxemails.php" hash="63b860ace056552d159ada056eebfbd7"/><file name="Unit.php" hash="07fa0c25182538e08479cc4f91c7ca16"/><file name="Yesnovariation.php" hash="d24e4bf79afe73e85422c53835de0012"/></dir></dir></dir><dir name="controllers"><file name="AbandonedController.php" hash="4f74460bdec500e1b18000fb20f9e2fe"/><dir name="Adminhtml"><file name="AbandonedmailsController.php" hash="060e46a386be3365ae23722c951de848"/><file name="AbandonedorderController.php" hash="3b74880847f1e33d06043eb673b6c39a"/></dir></dir><dir name="etc"><file name="adminhtml.xml" hash="62708e88154b231e694210cca0aa6c97"/><file name="config.xml" hash="0e1dd12a5d5bcf54d07287502faba1ec"/><file name="system.xml" hash="193f18d119bce269e9e4716bb45ff762"/></dir><dir name="sql"><dir name="ebizmarts_abandonedcart_setup"><file name="mysql4-install-0.1.0.php" hash="0e1a8c0391654c480773b78a50db5a83"/><file name="mysql4-upgrade-0.1.12-0.1.13.php" hash="4835436b744f8cbff61a66c2e345976f"/><file name="mysql4-upgrade-0.1.18-0.1.19.php" hash="e51b332cb70c81ee472b586fda4e8a7e"/><file name="mysql4-upgrade-0.1.2-0.1.3.php" hash="2e87d09a5008ac2f2432a25e08474c87"/><file name="mysql4-upgrade-0.1.20-0.1.21.php" hash="c461ba10961b4ee4e9385173d4264617"/><file name="mysql4-upgrade-0.1.29-0.1.30.php" hash="e9fdf4551cf19b488ed68ca0dd55ab67"/><file name="mysql4-upgrade-0.1.30-0.1.31.php" hash="2889ca071f7b974f2cd85a6b9405e541"/><file name="mysql4-upgrade-0.1.6-0.1.7.php" hash="60daa0d70a1af929a39d6e20ee52ee9c"/><file name="mysql4-upgrade-1.1.35-1.2.0.php" hash="58589b5e37eeb8069e08863f6b4c06e5"/></dir></dir></dir><dir name="Autoresponder"><dir name="Block"><dir name="Adminhtml"><dir name="System"><dir name="Config"><dir name="Backtostock"><dir name="Fieldset"><file name="Hint.php" hash="196c96e0bdfb853c42510d8cef4bf69a"/></dir></dir><dir name="Birthday"><dir name="Fieldset"><file name="Hint.php" hash="bff790a4ecf1f7ed7ac5d966cb8d516f"/></dir></dir><dir name="Fieldset"><file name="Hint.php" hash="eea231bb3f99b0f3708c2d43144e0f44"/></dir><dir name="Review"><dir name="Fieldset"><file name="Hint.php" hash="d9906e111824893ef363926dd2b485eb"/></dir></dir><dir name="Wishlist"><dir name="Fieldset"><file name="Hint.php" hash="75a66f64700f02eebfa391f953bc42d0"/></dir></dir></dir></dir></dir><dir name="Backtostock"><file name="Notice.php" hash="30efc30519a1ecb31d39a5fe59a6ae90"/></dir><dir name="Customer"><dir name="Account"><file name="List.php" hash="755d6d07d113450617bc31e8bc039df0"/></dir></dir><dir name="Email"><dir name="Backtostock"><file name="Item.php" hash="178b97ceae8c488bf49cb44b6f5f5d11"/></dir><dir name="Related"><file name="Items.php" hash="831fda241af415c53d47274ecc395299"/></dir><dir name="Review"><file name="Items.php" hash="de3dd88f0a2399314c746b08cbe4ab82"/></dir><dir name="Wishlist"><file name="Items.php" hash="5c712e43bca1a83bf7592e082acca863"/></dir></dir><dir name="Review"><file name="Form.php" hash="cb10cbe1702bc6261874ed68eec47a00"/></dir><file name="Unsubscribe.php" hash="bb945f9a63f38ca0b6cdd2a0daed5416"/></dir><dir name="Helper"><file name="Data.php" hash="45eec5e986cf0997ff5f97f7148f0ec3"/></dir><dir name="Model"><file name="Backtostock.php" hash="fa62a4685c70474a2ce3da394e68c597"/><file name="Backtostockalert.php" hash="eabe65c559ee1d93bc8b67dc0bb32a40"/><file name="Config.php" hash="75a65035e240a5154b2037feceb4d864"/><file name="Cron.php" hash="b45e7f9e6e7ad3226a5ba77073d8a9b0"/><file name="EventObserver.php" hash="b505ddedbaa6ead64992db00fd587d81"/><dir name="Resource"><dir name="Backtostock"><file name="Collection.php" hash="95a70c48dce1bac7fcb86447bb899057"/></dir><file name="Backtostock.php" hash="85c29c73ba30f2fdf819fc88f5e03098"/><dir name="Backtostockalert"><file name="Collection.php" hash="c0c5d87c559d2e4011697b1a0ccf4846"/></dir><file name="Backtostockalert.php" hash="148ae085ef93a7cf6e52cdd60f1ca9a2"/><dir name="Review"><file name="Collection.php" hash="098061d250555679c9f609d2087ef9d4"/></dir><file name="Review.php" hash="cf78994db6e262e42a589b6538a45a32"/><dir name="Unsubscribe"><file name="Collection.php" hash="11048027437c0a5bc1478e4f2cdcc51d"/></dir><file name="Unsubscribe.php" hash="3b9e4d09dbb7ba483a5d16b6312050e6"/><dir name="Visited"><file name="Collection.php" hash="b09c0ce08ac30cc30f974e5c744eabf1"/></dir><file name="Visited.php" hash="55f2d0c1f90b41e852ecbf964925dc10"/></dir><file name="Review.php" hash="c14806dfb106363262b9911e8d06f628"/><dir name="System"><dir name="Config"><file name="Automatic.php" hash="4de4d5c373fa1ea373751cbd5ed7efbc"/><file name="Couponcounter.php" hash="18049531633e26b8970935e6b9c73823"/><file name="Customergroup.php" hash="aa31f980b1d28248f137fe2a06b3ba2c"/><file name="Discounttype.php" hash="1228055f8abc3bffba6020f4bb4210e0"/><file name="Generaltype.php" hash="463210c06e00794b79df38a61dfa56c2"/><file name="Hours.php" hash="db8c055c1fc0628f5fad84fc15c6d389"/><file name="Newordertrigger.php" hash="757bcc13562d4a5b905d57920906411f"/><file name="Time.php" hash="4b491667d8ea9816b07f584e84556556"/></dir></dir><file name="Unsubscribe.php" hash="cb20baf948256b9b70a13ed52ab91bab"/><file name="Visited.php" hash="2e9f119fc630cefc50f5a2a21546ebfc"/></dir><dir name="controllers"><file name="AutoresponderController.php" hash="bd9c5001c6438f5b76e53371f6149798"/><file name="BacktostockController.php" hash="61f07f9bdc3951dbddeaf8161d55023d"/></dir><dir name="etc"><file name="adminhtml.xml" hash="59a240f12b496566f1a2b1de5f053e96"/><file name="config.xml" hash="ead4fa79e5a0db795d974f2bf3902c59"/><file name="system.xml" hash="790c6d43450e7a251c19e09a78cf9d93"/></dir><dir name="sql"><dir name="ebizmarts_autoresponder_setup"><file name="mysql4-install-0.1.0.php" hash="d2152df00146562b30910ebe36c9b4e8"/><file name="mysql4-upgrade-0.1.3-0.1.4.php" hash="2ab92d2cf0f5fa7ccf7b61d9ab142a01"/><file name="mysql4-upgrade-0.1.4-0.1.5.php" hash="4b3cace6f889e5d42606140628c26cc4"/><file name="mysql4-upgrade-0.1.5-0.1.6.php" hash="378accc07eb80b16029db84f56bed683"/><file name="mysql4-upgrade-0.1.9-0.1.10.php" hash="53cc6beed11e8631c11a008c5fd78ce1"/><file name="mysql4-upgrade-1.1.14-1.2.0.php" hash="3cd44860cc2b2df0a7c68c6ffbd64628"/><file name="mysql4-upgrade-1.2.0-1.2.1.php" hash="8ffeb3186d48743e6c24134ff6900953"/></dir></dir></dir><dir name="SweetMonkey"><dir name="Block"><dir name="Adminhtml"><dir name="System"><dir name="Config"><file name="Autovars.php" hash="fc3ebb5ffe5344ef74a294547614c28f"/><dir name="Fieldset"><file name="Hint.php" hash="a1d28320ed21eaa6c20aa98c0b4e3492"/></dir><dir name="Form"><dir name="Field"><file name="Mapfields.php" hash="a0dfcfa3e1e22bdb33005a999cb0867b"/></dir></dir></dir></dir></dir></dir><dir name="Helper"><file name="Data.php" hash="83c32ef3e5433e701a10ef9cc5370d04"/></dir><dir name="Model"><file name="Observer.php" hash="d293aae1eae63f787b78d310d3364e79"/></dir><dir name="controllers"><dir name="Adminhtml"><file name="MageMonkeyController.php" hash="f7d0e23ca908825800044a19ef68094a"/></dir></dir><dir name="etc"><file name="adminhtml.xml" hash="8a81e6639cd53c96717a6b993d5fcd93"/><file name="config.xml" hash="0550e8de5d4215aeb945d06514ae6959"/><file name="system.xml" hash="93e8f26427a0df9183f6680441ce23f6"/></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Ebizmarts_MageMonkey.xml" hash="951aa15bc51345726e05080bd5fc084b"/><file name="Ebizmarts_Mandrill.xml" hash="ea4b352b5a0233330ecde76a0f9113dd"/><file name="Ebizmarts_AbandonedCart.xml" hash="48c4cfe8246d5a995e2836c43ab38d74"/><file name="Ebizmarts_Autoresponder.xml" hash="97302f94f5893147db18c4034d135256"/><file name="Ebizmarts_SweetMonkey.xml" hash="05d9393c17c76a589fd7681ed668d53f"/></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="magemonkey.xml" hash="8eef43f9d728e252a5f7d7b6cea93a19"/><dir name="ebizmarts"><file name="abandonedcart.xml" hash="14282d8f8739578d51c57def5df1227a"/><file name="autoresponder.xml" hash="d8dfb68cfd7c838cf29e9281a9a76c36"/></dir></dir><dir name="template"><dir name="magemonkey"><dir name="checkout"><file name="subscribe.phtml" hash="6647c5e991170303f99b956dbbddd6c6"/></dir><file name="lists.phtml" hash="8562e11e1d5e60807e7d8d991b8d1fb1"/></dir><dir name="ebizmarts_abandonedcart"><dir name="email"><dir name="order"><dir name="items"><dir name="order"><file name="default.phtml" hash="c078d029b2065e8b1938c3cfb24e8219"/><file name=".DS_Store" hash="194577a7e20bdcc7afbb718f502c134c"/></dir></dir><file name="items.phtml" hash="87f18755675a13f6e91a56b562bcd0fe"/><file name=".DS_Store" hash="194577a7e20bdcc7afbb718f502c134c"/></dir></dir><dir name="popup"><file name="emailcatcher.phtml" hash="9c08d432e13c19aacab45c276a86db81"/></dir></dir><dir name="ebizmarts"><dir name="autoresponder"><dir name="backtostock"><dir name="catalog"><dir name="product"><file name="form.phtml" hash="c04b1aaf96617c47d1530538f2f9f5e0"/><file name="notice.phtml" hash="ba7963278c9ed51066c736cdc0b73978"/></dir></dir><file name="item.phtml" hash="9ff57a2867309f380525ad671a753f9e"/></dir><dir name="customer"><file name="list.phtml" hash="21d2f116e2f509943175c43bc5863582"/></dir><dir name="related"><file name="items.phtml" hash="b2a04397a22c9cdd421fe04b4c107dd7"/></dir><dir name="review"><file name="items.phtml" hash="1bc37dcc7087d375eed0849b76bcec64"/></dir><file name="unsubscribe.phtml" hash="ca8ed1c5810e07f1cdc91edb64420417"/><dir name="wishlist"><file name="items.phtml" hash="1e65bee4638cb557503b36e3224b853c"/></dir></dir></dir></dir></dir></dir></dir><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="magemonkey.xml" hash="4a2ba63a9d3002774b622e76339e6fbb"/><dir name="ebizmarts"><file name="mandrill.xml" hash="ba93e973a9019841c7d914ecd729983c"/><file name="abandonedcart.xml" hash="9ed91dab216911a13a2669bd81734180"/></dir></dir><dir name="template"><dir name="magemonkey"><dir name="bulksync"><dir name="export"><file name="form.phtml" hash="06a3c582f8469c11c644e688efb4e5a5"/></dir><dir name="import"><file name="form.phtml" hash="06a3c582f8469c11c644e688efb4e5a5"/></dir></dir><dir name="system"><dir name="config"><dir name="fieldset"><file name="hint.phtml" hash="d5613b376031fd67f883d64cfc20eb50"/></dir><file name="oauth_wizard.phtml" hash="91b3472b4e9a5bc26851b76bfcea59c5"/><file name="resetlocal360.phtml" hash="3347fad7cfb13e7b4c6647489bed1480"/><file name="resetremote360.phtml" hash="2a67ad95f8ffabdc1e2d1e572c4118ae"/><file name="upgradeforpatch.phtml" hash="6a0ed64653b65b4d0d206f86dcf29a9c"/></dir></dir></dir><dir name="ebizmarts"><dir name="mandrill"><dir name="system"><dir name="config"><dir name="fieldset"><file name="hint.phtml" hash="ae30b23b623555f4945c56292f004003"/></dir></dir></dir></dir><dir name="abandonedcart"><dir name="dashboard"><file name="index.phtml" hash="31a02b6aa63614bb2a52044195568f15"/><file name="salebar.phtml" hash="7a8c978ff415853550f9b1a3cbabfd1c"/><file name="totalbar.phtml" hash="95cb90a952f5548481c180004e39b7f1"/></dir><dir name="system"><dir name="config"><dir name="fieldset"><file name="hint.phtml" hash="ba6ebe4bb4a1e8ed5c964fc17b381785"/></dir></dir></dir></dir><dir name="autoresponder"><dir name="system"><dir name="config"><dir name="backtostock"><dir name="fieldset"><file name="hint.phtml" hash="623380a9c486eae57da00de6bd8b843d"/></dir></dir><dir name="birthday"><dir name="fieldset"><file name="hint.phtml" hash="d7f944a685769a46cb709f89c6e56f3b"/></dir></dir><dir name="fieldset"><file name="hint.phtml" hash="4f33fe2e4d8f997b6adca212450e4d9b"/></dir><dir name="review"><dir name="fieldset"><file name="hint.phtml" hash="205b3fac2bc9682cdbdc9e3a8ec688df"/></dir></dir><dir name="wishlist"><dir name="fieldset"><file name="hint.phtml" hash="563ece5feca65f3ff728b89929cb2339"/></dir></dir></dir></dir></dir></dir><dir name="sweetmonkey"><dir name="system"><dir name="config"><file name="autovars.phtml" hash="53da8402573546ecdcbe2f5e9b3ab57a"/><dir name="fieldset"><file name="hint.phtml" hash="9d3cbc62ce5f2afc38f5c1936a29484c"/></dir></dir></dir></dir></dir></dir></dir></dir></target><target name="magelocale"><dir name="en_US"><file name="Ebizmarts_MageMonkey.csv" hash="181e91ed91dfea5fe7dab66af5719af8"/><file name="Ebizmarts_Mandrill.csv" hash="3dac3af57664fd34f5eda8abf4098ee0"/><file name="Ebizmarts_AbandonedCart.csv" hash="214bcd0e8cd6153c48fab236dcfdba1b"/><dir name="template"><dir name="email"><dir name="ebizmarts"><dir name="abandonedcart"><file name="abandoned_cart_mail_1.html" hash="36ceaf0e511ecb2c785fb482c634ed2c"/><file name="abandoned_cart_mail_2.html" hash="ab628f7bf4f82d44d8d9a5b39c838e00"/><file name="abandoned_cart_mail_3.html" hash="c46eef13c346494f26f2e01ff7de9de2"/><file name="abandoned_cart_mail_generic.html" hash="c87513fa9e7fc18035c9b4421c51478e"/><file name="popup_coupon_template.html" hash="7411805f6751997e3de8a4f11196c14e"/></dir><dir name="autoresponder"><file name="backtostock.html" hash="fcccb77375b946faf13cf991b363ec3a"/><file name="birthday.html" hash="81132b642c9c1b8a6988e7e438384b48"/><file name="neworder.html" hash="0262dc0daedee87904ca7be1def4078a"/><file name="noactivity.html" hash="59347130b4bf761c6830397f7a6b817d"/><file name="relatedproducts.html" hash="9cd19f74d0c42967526d54a197453945"/><file name="review.html" hash="0d9d872e4a0d0290cea079ccec3658c5"/><file name="reviewcoupon.html" hash="51915e3ff4ef402093b402ea82ac3182"/><file name="visitedproducts.html" hash="31245a22c3decda3fd93c18f87d58284"/><file name="wishlist.html" hash="2bb0a835b2e0bffd3ac551266d52fb46"/></dir></dir></dir></dir><file name="Ebizmarts_Autoresponder.csv" hash="d41d8cd98f00b204e9800998ecf8427e"/><file name="Ebizmarts_SweetMonkey.csv" hash="f0cdb51ba2052ce7f7ec1c9885ee5d3c"/></dir><dir name="nl_NL"><dir name="template"><dir name="email"><dir name="ebizmarts"><dir name="abandonedcart"><file name="abandoned_cart_mail_1.html" hash="64df67da5c2759572c80c47677fc4244"/><file name="abandoned_cart_mail_2.html" hash="3e65ab1c4140408422b6fd7e190a2f4b"/><file name="abandoned_cart_mail_3.html" hash="de4cbef63748e20638017e04827d39b9"/><file name="abandoned_cart_mail_generic.html" hash="de90f1d4f52d4603e3c08ebd4c5aa4e5"/><file name="popup_coupon_template.html" hash="8059d68fce7783956033ff0cf27f2c0b"/></dir><dir name="autoresponder"><file name="backtostock.html" hash="d5feeeaaf9f7416dcfb072e1b39844fa"/><file name="birthday.html" hash="b7099ba5f0de5e8c7f56f1aca1ec8779"/><file name="neworder.html" hash="dd016910da8029a2b2266e9a82eac167"/><file name="noactivity.html" hash="6d3b63329f5d664a9f81b2aba55b5588"/><file name="relatedproducts.html" hash="5bb28d77374568fbab07519048edb301"/><file name="review.html" hash="a1116b4a34c72fb94d8945730096ed83"/><file name="reviewcoupon.html" hash="bdd27369d3e76d915489399d95a502fc"/><file name="visitedproducts.html" hash="74941796112fba1158707ab6bdf4b2d4"/><file name="wishlist.html" hash="e456275499caa1cc018d7da1da32d525"/></dir></dir></dir></dir><file name="Ebizmarts_MageMonkey.csv" hash="3e0b1485b10cf7c9f6f64437f870c7fe"/><file name="Ebizmarts_SweetMonkey.csv" hash="063c94afbaa6e2fbe2028580209bc09b"/><file name="Ebizmarts_AbandonedCart.csv" hash="099104a7a9492249c0e24909145abfa3"/></dir></target><target name="mageskin"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="magemonkey"><file name="magemonkey.css" hash="2072357ef844855f7a4607245b1e9a17"/><file name="magemonkey.js" hash="1a515d6697d533ee012754dd20e60345"/><file name="mailchimp-connected-ebizmarts-title.png" hash="c6bcb1aa606ecd3b0a9753bb48ddeb58"/><file name="mailchimp-ico.png" hash="14978ec398cede4060bc9b00365bb6c5"/><file name="mailchimp-section-background.png" hash="d4536261c6a3534fbb855428c0cca62c"/><file name="mailchimp-tab.png" hash="61972b4e063364071e81d8c9e10d8feb"/></dir><dir name="abandonedcart"><file name="abandonedcart.css" hash="bd6049fa8b17a1060e8a63fa29aefd94"/></dir><dir name="ebizmarts"><file name="ebizmarts-tab.png" hash="6dfa08c5cd4329d1df6e7b71fb1f925a"/><file name="ebizmarts.css" hash="a579734639953c1970ec26f56dda5837"/><dir name="mandrill"><file name="mandrill-tab.png" hash="d7eaf9deef355e4b8b55a96070b90ffe"/><file name="mandrill.css" hash="d93f1f52db38195a4f85d20de519151e"/></dir></dir></dir></dir></dir><dir name="frontend"><dir name="base"><dir name="default"><dir name="magemonkey"><file name="magemonkey.css" hash="8f25ca79fc6901215f713f0e048c4a9f"/><file name="monkey.js" hash="5984cd563aee48b7ba648066f733113a"/></dir></dir></dir></dir></target><target name="mage"><dir name="lib"><dir name="Mandrill"><dir name="Mandrill"><file name="Exceptions.php" hash="54d952267c004cddeedd8d9be07698c8"/><file name="Exports.php" hash="3ed368771a7174af0e01287e3a3e030f"/><file name="Inbound.php" hash="32378db89f2f47fe158577c256837896"/><file name="Internal.php" hash="fa680d47c780922a111078827cad1505"/><file name="Ips.php" hash="c70c08b34454d2e7aebc31101cfdca81"/><file name="Messages.php" hash="f1f3c20b6c872c72dcc33790d6a3adf4"/><file name="Metadata.php" hash="57820ae2032206334fb6e6d9b12f4df2"/><file name="Rejects.php" hash="f40f9ef016c338c6ae9d161c3112eea6"/><file name="Senders.php" hash="875ddbeff3f920397c73c2c2797f3eea"/><file name="Subaccounts.php" hash="9b6b61a8e0364c9f917952deffe0320c"/><file name="Tags.php" hash="ee2f9e328d4d49aa8b0289978f7375b0"/><file name="Templates.php" hash="9920cf5d10bdcb5416193435c425f123"/><file name="Urls.php" hash="184c17ebb031f1f6e6dad687a4bf767d"/><file name="Users.php" hash="826dac98663eefce2f5ccc4a5b0d38e9"/><file name="Webhooks.php" hash="37ea24a982630aa321444b85392f3397"/><file name="Whitelists.php" hash="d132144d50c3b713c98ad699984e4e38"/></dir><file name="Mandrill.php" hash="ac12db0139d483c2e3cf1da93aff1c96"/><file name="Message.php" hash="784920e095d8d9f0269b46f00071fcc9"/></dir></dir><dir name="js"><dir name="ebizmarts"><dir name="abandonedcart"><file name="popup.css" hash="2bf9fef85964298cc44143ef0fc78d21"/><file name="xmark.png" hash="6f14c834def36c1185347c49021030a4"/></dir><dir name="autoresponders"><file name="visitedproducts.js" hash="638a84c18b961879bc6d2196674661e0"/><file name="visitedproductsstorecodes.js" hash="a89a5b02ba597adb612d32dad74103dd"/></dir><dir name="magemonkey"><file name="campaignCatcher.js" hash="ff065dfee49e157e211f3724d2700bff"/></dir></dir></dir></target></contents>
31
  <compatible/>
32
  <dependencies><required><php><min>5.2.0</min><max>6.0.0</max></php></required></dependencies>
33
  </package>
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>Ebizmarts_MageMonkey</name>
4
+ <version>1.2.5</version>
5
  <stability>stable</stability>
6
  <license uri="http://www.opensource.org/licenses/osl-3.0.php">OSL v3.0</license>
7
  <channel>community</channel>
8
  <extends/>
9
  <summary>MailChimp integration for Magento by Ebizmarts</summary>
10
  <description>Full MailChimp integration, automatic webhooks, multiple lists, interest groups</description>
11
+ <notes>1.2.5&#xD;
12
  --------&#xD;
13
  Bug Fixes:&#xD;
14
+ Fixed Back end order creation process exception when creating new customer.&#xD;
15
+ Fixed Remove from quote when no stock available for Abandoned Cart Recovery emails. It still sends the email if backorders is enabled.&#xD;
16
+ Fixed redundant code and set it to set the first name and last name of the configured settings if none other available.&#xD;
17
+ Fixed cookie handling to delete the campaign cookie when order is made.&#xD;
18
+ Fixed Feed Update error for admin notifications.&#xD;
19
+ Removed Auto-login feature from Abandoned Carts Recovery.&#xD;
20
+ Fixed compatibility problem with SagePay checkout subscription with some payment methods.&#xD;
21
+ Fixed problem for order emails when Mandrill configured per store view.&#xD;
 
 
22
  &#xD;
23
+ &#xD;
24
+ Enhancements:&#xD;
25
+ Added configuration to enable/disable webhook creation.&#xD;
26
+ Webhook handle process asynchronous to remove some stress from the server when big changes are made on the MailChimp List.&#xD;
27
+ Added compatibility with Fire checkout subscription.</notes>
28
  <authors><author><name>Ebizmarts Development Team</name><user>ebizmarts</user><email>info@ebizmarts.com</email></author></authors>
29
+ <date>2016-08-10</date>
30
+ <time>18:24:08</time>
31
+ <contents><target name="magecommunity"><dir name="Ebizmarts"><dir name="MageMonkey"><dir name="Block"><dir name="Adminhtml"><dir name="Bulksync"><dir name="Export"><file name="Form.php" hash="43de22b1bd39304bcd60cd6eebc25d28"/></dir><file name="Export.php" hash="ab839a4011692b69b292fe59eb50100e"/><dir name="Import"><file name="Form.php" hash="8927f46053a203e491e2bc2cb25fea1a"/></dir><file name="Import.php" hash="9c7ba4a566038356e60e9482301d7cb7"/><dir name="Queue"><file name="Grid.php" hash="23b3edec3bc13fae8aee5b7292c4d4d1"/></dir><file name="Queue.php" hash="c3cea1da02e0a09d7876958058ee091e"/><dir name="QueueExport"><file name="Grid.php" hash="68ec401dc23cddf8a1362c53aaab69b2"/></dir><file name="QueueExport.php" hash="69536eee264346535f1c786d61b3cf84"/><dir name="QueueImport"><file name="Grid.php" hash="0e43409930757224fbfcb3734fea9c67"/></dir><file name="QueueImport.php" hash="d9fbc0d22f94df54f71116d0d484d1a3"/></dir><dir name="Customer"><dir name="Edit"><dir name="Tab"><file name="Memberactivity.php" hash="55fbb4519c6d862948dc4d8bf4416cfb"/></dir></dir></dir><dir name="Ecommerce"><file name="Grid.php" hash="b1ad37ffe9fe0752356d29a6548b0434"/></dir><file name="Ecommerce.php" hash="48c237e8cc1223ad26a88d2409679fec"/><dir name="Ecommerceapi"><file name="Grid.php" hash="ee1be42cb6c893e3c59cac784df67fb3"/><dir name="Renderer"><file name="Items.php" hash="d72cfedf0cafc938becf9bd52801ba3a"/></dir></dir><file name="Ecommerceapi.php" hash="a9f659502d96bcd1a69a88d15fcab4f9"/><dir name="Memberactivity"><file name="Grid.php" hash="2753517318120344d1f7694a6b7a278d"/></dir><dir name="Newsletter"><dir name="Subscriber"><dir name="Renderer"><file name="Firstname.php" hash="e814d3ba07b32e851585363b29e37b3a"/><file name="Lastname.php" hash="9a8b007c2db6add0572cf4012b28f63e"/></dir></dir></dir><dir name="Renderer"><file name="Date.php" hash="6e4e52403ec55df3aa2183fd4b51b095"/><file name="Importypes.php" hash="87c7a222e403781fcd8ee08cf0b489ba"/><file name="Lists.php" hash="2dbd23844a822d3406efae08e89ce0d7"/><file name="Progress.php" hash="31eaaa5a7e99b21a4ed705971fe1001d"/><file name="Yesno.php" hash="c3173a8e8ea2d5f03531e7d996bbd259"/></dir><dir name="System"><dir name="Config"><file name="Account.php" hash="fccf1faac2682d754655631e6451c026"/><file name="Date.php" hash="455120f4f2e8d7801f3c220e231b6789"/><dir name="Fieldset"><file name="Hint.php" hash="31bf492c4e6137312c55bc437bf226cf"/></dir><dir name="Form"><dir name="Field"><file name="Mapfields.php" hash="8f2a10ca1a1d239b3b231ca2cee5f96e"/></dir></dir><file name="OauthWizard.php" hash="bd79f8b43d71137337e732fbeb415ffb"/><file name="ResetLocalEcommerce.php" hash="493126ac056c3585ed2d3020d62c76e1"/><file name="ResetRemoteEcommerce.php" hash="40d54bb2d6e7dd7bf3a91c9346f988bf"/><file name="UpgradeForPatch.php" hash="d641d79e0ce65469e40c1b7eb81a2591"/></dir></dir></dir><dir name="Checkout"><file name="Subscribe.php" hash="14de0075005dafe3363716e3ffd10d20"/></dir><dir name="Customer"><dir name="Account"><file name="Lists.php" hash="64f0e5a8360750f6b19d8b5db0fcac23"/></dir></dir><file name="Lists.php" hash="bea29a7dc4e80337d85427a094af1316"/><file name="Signup.php" hash="93b0e787e63a90a5fb4bacba1e03bd05"/></dir><dir name="Helper"><file name="Cache.php" hash="4e6cd9724c2788056aacacd37f5699cc"/><file name="Data.php" hash="050df5865aa7abfcf9f32f032b0e7ea2"/><file name="Export.php" hash="91f24805e9cbbe124f0c99cb8f1f1272"/><file name="Oauth2.php" hash="684a7b71d97b438081ebf332057ec8ea"/></dir><dir name="Model"><file name="Api.php" hash="ea7c720767bc58cb740d2f70100f699b"/><file name="Asyncorders.php" hash="3f60d1a1c1885268ae7e2ddfb1772feb"/><file name="Asyncsubscribers.php" hash="b79a42df357267205d7e74bb7c220755"/><file name="Asyncwebhooks.php" hash="fc57fee18b5f9cc098318ca1242a082f"/><file name="BulksyncExport.php" hash="71af9a6134b415a324dc9c937a5b2f8e"/><file name="BulksyncImport.php" hash="fb3716e235bc22cf91c4c17edf10ec23"/><file name="Cache.php" hash="89ac2fac903a566e6f6a3c0951bf274d"/><file name="Config.php" hash="b6cccdaa6bab4a5d9ba4d1eafb26318c"/><file name="Cron.php" hash="df4be9915c8cfe3d7bf38435505965a2"/><dir name="Custom"><file name="Collection.php" hash="304d372c1b8bd8d8d09dd743e03cdf66"/></dir><file name="Ecommerce.php" hash="f4581befe128963df3e3d062b1bc4d55"/><file name="Ecommerce360.php" hash="8cd2aea43c32156160ad449ccc1bbaf2"/><dir name="Email"><file name="Template.php" hash="81c9f040cf931dfb9e2a2484d9cc0b09"/></dir><dir name="Feed"><file name="Updates.php" hash="0a0da2a88047303d479584a773a51d26"/></dir><file name="Lastorder.php" hash="f2977e76892b0b1a5e031f8eabf93f18"/><file name="MCAPI.php" hash="1740a57c10a5d54aa4449f698e6dcd73"/><file name="MCEXPORTAPI.php" hash="810b1c7b0f6daf93e11c7fbbc90980a3"/><file name="Monkey.php" hash="ed50cfa8528e149e1a635e691f1cad30"/><dir name="Mysql4"><dir name="Apidebug"><file name="Collection.php" hash="7cc3fe74a46da1a4770b49eb7ac47f97"/></dir><file name="Apidebug.php" hash="2699eec825e8fb88b1d572728c10b7bc"/><dir name="Asyncorders"><file name="Collection.php" hash="e7b17fac028f7116c762e120b0f3f0a8"/></dir><file name="Asyncorders.php" hash="3eb64d883705854ce7899fd891101c63"/><dir name="Asyncsubscribers"><file name="Collection.php" hash="3458134c9a1ced7359db40f7b79a133f"/></dir><file name="Asyncsubscribers.php" hash="a067c1e951ce61558e00f3aa8e5d15ef"/><dir name="Asyncwebhooks"><file name="Collection.php" hash="44170fc7219e1992c6cd0dbad863af4f"/></dir><file name="Asyncwebhooks.php" hash="79de544aaed58102758eeef01467b066"/><dir name="Bulksync"><dir name="Export"><file name="Collection.php" hash="ac64bc652233136189c504f678062374"/></dir><file name="Export.php" hash="eedc5a3549b3815f0d290eca3e0579df"/><dir name="Import"><file name="Collection.php" hash="6cb3e09a817488f9bfa50f877a5c2b0b"/></dir><file name="Import.php" hash="487fc6c0335ebf352081185d9afe3f88"/></dir><dir name="Ecommerce"><file name="Collection.php" hash="80319b6c991c510f1569800c80d384f1"/></dir><file name="Ecommerce.php" hash="b3290a6170c8c8f275dcd4300840ea26"/><dir name="Lastorder"><file name="Collection.php" hash="38d6a7519cfe21caf7f5d22877aa1477"/></dir><file name="Lastorder.php" hash="f3987329cb78c978bcc94ba375d9f998"/></dir><file name="Observer.php" hash="c63d1df9932f92cc77a78598803bf1b9"/><file name="Subscriber.php" hash="26903cf8899d9cf1d2a0548d2a01a287"/><dir name="System"><dir name="Config"><dir name="Source"><file name="Account.php" hash="5bbf12b572234101af3e753ba74bcd41"/><file name="Attributes.php" hash="4ac1c98f3b3b84b2c93ddfcc3df5d817"/><file name="BulksyncDatasource.php" hash="36331ac3ecd034f914666a49e4d75cbc"/><file name="BulksyncStatus.php" hash="658f1f9d1ee7177d5dc094862bce155a"/><file name="Checkoutsubscribe.php" hash="28c8641a8fa4c336487af2227e152136"/><file name="CronProcessLimit.php" hash="3ca3a61f07b7aa84479eddda35efdde4"/><file name="CustomerGroup.php" hash="299b8514de098e02efe5393ebe7bdf65"/><file name="Ecommerce360.php" hash="24906da389cbf6b4a97c3edab5c7f020"/><file name="List.php" hash="acbffbbfe0a11566e745e01fce34ec51"/><file name="OrderProcessLimit.php" hash="bc3add48e125caa904774cb6b669ba0c"/><file name="OrderStatus.php" hash="d3eeeee5d614e8fa83e258ce53cbed79"/><file name="Status.php" hash="e1e5cf6252241f39d0ceaff6f94d3afb"/><file name="TransactionalEmails.php" hash="b2f0d564a59372cba59d3aac7e4fe9e0"/><file name="WebhookDelete.php" hash="c90bbf8b0cf2a546c0f72193f8c605cf"/></dir></dir></dir></dir><dir name="controllers"><dir name="Adminhtml"><file name="BulksyncController.php" hash="1e044f49bb90de5e2a2d9d0ec2feb73f"/><file name="ConfigController.php" hash="c62e1f6f54ac6a4fc33499c85f95948a"/><file name="EcommerceController.php" hash="4db500b32fb676705b4edad7ddb23e59"/></dir><dir name="Customer"><file name="AccountController.php" hash="14479dffeacd3c2421ce5822f7d7f190"/></dir><file name="SignupController.php" hash="e379f52f8ee0191a4c7289cd2afcd19d"/><file name="WebhookController.php" hash="255278ff6da9c4383d1b58cf716eb974"/></dir><dir name="etc"><file name="adminhtml.xml" hash="f203274d5b6522dd00f630a58bc18623"/><file name="config.xml" hash="c2e9ba15aef199637175898cf99dc211"/><file name="system.xml" hash="c34f4b9f706815154982715ef4e50fb6"/></dir><dir name="sql"><dir name="monkey_setup"><file name="mysql4-install-0.0.1.php" hash="4df34769f4d5a8ceca90fd582500e3a9"/><file name="mysql4-upgrade-0.0.1-0.0.2.php" hash="d81147dab407bc55c59cddb5a764c53e"/><file name="mysql4-upgrade-0.0.2-0.0.3.php" hash="ce1925ff2ab03aa9fd6cbe43283ea37d"/><file name="mysql4-upgrade-0.0.3-0.0.4.php" hash="7f1e38bcf030e6346a9fd8321f1a4362"/><file name="mysql4-upgrade-0.0.4-0.0.5.php" hash="bbe6b895320effca77cc2c23431f043f"/><file name="mysql4-upgrade-0.0.5-0.0.6.php" hash="98b72d9ef4ec8078c09a1f641fc35a39"/><file name="mysql4-upgrade-0.0.6-0.0.7.php" hash="ea15755fc072e7c82b78063589360779"/><file name="mysql4-upgrade-1.0.10-1.0.11.php" hash="b2ec497921eb2bd9a97a318554fd980b"/><file name="mysql4-upgrade-1.1.21-1.1.22.php" hash="738e3d3e33c1a3a02bb101b89743cc5c"/><file name="mysql4-upgrade-1.1.23-1.1.24.php" hash="f3c48989465fc8683203bbbc2517a9e8"/><file name="mysql4-upgrade-1.1.33-1.1.34.php" hash="68f74c77460e76ea6153ebc823d49990"/><file name="mysql4-upgrade-1.1.5-1.1.6.php" hash="14750274ece5816d6c1ab490f7d610ab"/><file name="mysql4-upgrade-1.2.1-1.2.2.php" hash="c622ec016eb8134492d6011007d82149"/><file name="mysql4-upgrade-1.2.4-1.2.5.php" hash="853b7f2c7cc91394c325dc2524893c05"/></dir></dir></dir><dir name="Mandrill"><dir name="Block"><dir name="Adminhtml"><dir name="System"><dir name="Config"><dir name="Fieldset"><file name="Hint.php" hash="6ca5fb9bf9254323e1f2b4447203b562"/></dir><file name="Userinfo.php" hash="7cd34efc0231424c9e2f5e662154c41c"/></dir></dir><dir name="Templates"><dir name="Templates"><file name="Grid.php" hash="1ecdb6b04fbd16043de908f261353b8d"/></dir><file name="Templates.php" hash="1682fe6d39605a9839bf3cdb3c1185b7"/></dir><dir name="Users"><dir name="Senders"><file name="Grid.php" hash="292097a493de241540d3e3aea463241f"/></dir><file name="Senders.php" hash="4a4449652c495a9d4c12966ab007e7a4"/></dir></dir></dir><dir name="Helper"><file name="Data.php" hash="86fcaa6a66a5a628ded7215172448daf"/></dir><dir name="Model"><file name="Customcollection.php" hash="9b5766c0393a54b4356254725b4d78b2"/><dir name="Email"><file name="Queue.php" hash="284854bb98fde2bc8f267af3141e739e"/><file name="Template.php" hash="325764effab3765d61b1e6140b7b747c"/></dir><dir name="System"><dir name="Config"><dir name="Source"><file name="Userinfo.php" hash="12a9c9c27c985efd021a4e6c7fdfcf5e"/></dir></dir><file name="Config.php" hash="2219d951bf6b2553ec0284b65d8d92a2"/></dir></dir><dir name="controllers"><dir name="Adminhtml"><dir name="Mandrill"><file name="UsersController.php" hash="72cb77b136fafaf5ef98e599ab8d5eb8"/></dir></dir></dir><dir name="etc"><file name="adminhtml.xml" hash="8ea87cce062596388f7e9507943e8bb5"/><file name="config.xml" hash="edbf173f4b11075572f262352c2e805d"/><file name="system.xml" hash="d05b90ca129297b6ffda52a4ba1fd26a"/></dir></dir><dir name="AbandonedCart"><dir name="Block"><dir name="Adminhtml"><dir name="Abandonedmails"><file name="Grid.php" hash="f2813a7ec47e20b78874a0dbb1461b3e"/></dir><file name="Abandonedmails.php" hash="c2714b5a6cb534c91564ebc340fe3f26"/><dir name="Abandonedorder"><file name="Grid.php" hash="5ab9e3884d3306d78e78133f09e22614"/></dir><file name="Abandonedorder.php" hash="1a14da87647612a8773f34f70bc05dea"/><dir name="Dashboard"><file name="Sales.php" hash="b0d6fce3a5f4ef5a891c8578eb36ef97"/><file name="Totals.php" hash="4cd3c1e0d8d357c79ec6e7a2ed98c6a0"/></dir><file name="Dashboard.php" hash="c27d5ec29455176fff7e2fac86fcce21"/><dir name="System"><dir name="Config"><file name="Date.php" hash="323a49af281f06dfa72c1d3512257e04"/><dir name="Fieldset"><file name="Hint.php" hash="6358bc58857011c08dedcbab885b461f"/></dir></dir></dir></dir><dir name="Email"><dir name="Order"><file name="Items.php" hash="08ba504f050dc955c213dc99b61dfddd"/></dir></dir><dir name="Popup"><file name="Emailcatcher.php" hash="1c04a8992ebf40cd2474d0db7ad48516"/></dir></dir><dir name="Helper"><file name="Data.php" hash="3e5a2e3d99b62936b0766313b9e62462"/></dir><dir name="Model"><file name="Abtesting.php" hash="fdf9df78b6656c898fd74fbcb3ec51e1"/><file name="Config.php" hash="36a47f3d4db78d60d8a8f3e0db08aba4"/><file name="Cron.php" hash="83cb0f471f6b27269f4d7401895329c5"/><file name="EventObserver.php" hash="57bb122fbd41fabbfa021d7a6ad96e0a"/><file name="Mailssent.php" hash="e238f4116cb473cdcfb3a909d08adaa4"/><file name="Popup.php" hash="d2a4922acc0c5c3994cbc0b2114658b8"/><dir name="Resource"><dir name="Abtesting"><file name="Collection.php" hash="f96fe4be550bef6daabc5d211c86aca0"/></dir><file name="Abtesting.php" hash="46e70f8507676e157ddec44f66094e59"/><dir name="Mailssent"><file name="Collection.php" hash="dc1e2c44eb53381d57d10a6bc08ad497"/></dir><file name="Mailssent.php" hash="80f0b4e3f29d10951362f07eb45a3ece"/><dir name="Order"><file name="Collection.php" hash="a079410c43e1afbb428b7163d1537482"/></dir><dir name="Popup"><file name="Collection.php" hash="af37502f9802c7574318ab28a8fb1b16"/></dir><file name="Popup.php" hash="446921e9b1da1973c83665e8f749bbbb"/></dir><dir name="System"><dir name="Config"><file name="Automatic.php" hash="a4f5e052810187fb824933e76ea8a1cf"/><file name="Cmspage.php" hash="89bfcbe90a7b2f396a56b3f1fe72dbd2"/><file name="Customergroup.php" hash="74af027c3fb6745d0e45938f83394489"/><file name="Discounttype.php" hash="55c251fafbd10821d6c18c381c307888"/><file name="Maxemails.php" hash="63b860ace056552d159ada056eebfbd7"/><file name="Unit.php" hash="07fa0c25182538e08479cc4f91c7ca16"/><file name="Yesnovariation.php" hash="d24e4bf79afe73e85422c53835de0012"/></dir></dir></dir><dir name="controllers"><file name="AbandonedController.php" hash="87d24cbd4585401c783add69aa9adaaf"/><dir name="Adminhtml"><file name="AbandonedmailsController.php" hash="060e46a386be3365ae23722c951de848"/><file name="AbandonedorderController.php" hash="3b74880847f1e33d06043eb673b6c39a"/></dir></dir><dir name="etc"><file name="adminhtml.xml" hash="62708e88154b231e694210cca0aa6c97"/><file name="config.xml" hash="252466f28f076fa39ee900ec9f7dc9cf"/><file name="system.xml" hash="a475b2a528b5bbd7b38caf1607b7e733"/></dir><dir name="sql"><dir name="ebizmarts_abandonedcart_setup"><file name="mysql4-install-0.1.0.php" hash="0e1a8c0391654c480773b78a50db5a83"/><file name="mysql4-upgrade-0.1.12-0.1.13.php" hash="4835436b744f8cbff61a66c2e345976f"/><file name="mysql4-upgrade-0.1.18-0.1.19.php" hash="e51b332cb70c81ee472b586fda4e8a7e"/><file name="mysql4-upgrade-0.1.2-0.1.3.php" hash="2e87d09a5008ac2f2432a25e08474c87"/><file name="mysql4-upgrade-0.1.20-0.1.21.php" hash="c461ba10961b4ee4e9385173d4264617"/><file name="mysql4-upgrade-0.1.29-0.1.30.php" hash="e9fdf4551cf19b488ed68ca0dd55ab67"/><file name="mysql4-upgrade-0.1.30-0.1.31.php" hash="2889ca071f7b974f2cd85a6b9405e541"/><file name="mysql4-upgrade-0.1.6-0.1.7.php" hash="60daa0d70a1af929a39d6e20ee52ee9c"/><file name="mysql4-upgrade-1.1.35-1.2.0.php" hash="58589b5e37eeb8069e08863f6b4c06e5"/></dir></dir></dir><dir name="Autoresponder"><dir name="Block"><dir name="Adminhtml"><dir name="System"><dir name="Config"><dir name="Backtostock"><dir name="Fieldset"><file name="Hint.php" hash="196c96e0bdfb853c42510d8cef4bf69a"/></dir></dir><dir name="Birthday"><dir name="Fieldset"><file name="Hint.php" hash="bff790a4ecf1f7ed7ac5d966cb8d516f"/></dir></dir><dir name="Fieldset"><file name="Hint.php" hash="eea231bb3f99b0f3708c2d43144e0f44"/></dir><dir name="Review"><dir name="Fieldset"><file name="Hint.php" hash="d9906e111824893ef363926dd2b485eb"/></dir></dir><dir name="Wishlist"><dir name="Fieldset"><file name="Hint.php" hash="75a66f64700f02eebfa391f953bc42d0"/></dir></dir></dir></dir></dir><dir name="Backtostock"><file name="Notice.php" hash="30efc30519a1ecb31d39a5fe59a6ae90"/></dir><dir name="Customer"><dir name="Account"><file name="List.php" hash="755d6d07d113450617bc31e8bc039df0"/></dir></dir><dir name="Email"><dir name="Backtostock"><file name="Item.php" hash="178b97ceae8c488bf49cb44b6f5f5d11"/></dir><dir name="Related"><file name="Items.php" hash="831fda241af415c53d47274ecc395299"/></dir><dir name="Review"><file name="Items.php" hash="de3dd88f0a2399314c746b08cbe4ab82"/></dir><dir name="Wishlist"><file name="Items.php" hash="5c712e43bca1a83bf7592e082acca863"/></dir></dir><dir name="Review"><file name="Form.php" hash="cb10cbe1702bc6261874ed68eec47a00"/></dir><file name="Unsubscribe.php" hash="bb945f9a63f38ca0b6cdd2a0daed5416"/></dir><dir name="Helper"><file name="Data.php" hash="45eec5e986cf0997ff5f97f7148f0ec3"/></dir><dir name="Model"><file name="Backtostock.php" hash="fa62a4685c70474a2ce3da394e68c597"/><file name="Backtostockalert.php" hash="eabe65c559ee1d93bc8b67dc0bb32a40"/><file name="Config.php" hash="75a65035e240a5154b2037feceb4d864"/><file name="Cron.php" hash="75e26e3c53874ca34ef04b7eee78a5ce"/><file name="EventObserver.php" hash="b505ddedbaa6ead64992db00fd587d81"/><dir name="Resource"><dir name="Backtostock"><file name="Collection.php" hash="95a70c48dce1bac7fcb86447bb899057"/></dir><file name="Backtostock.php" hash="85c29c73ba30f2fdf819fc88f5e03098"/><dir name="Backtostockalert"><file name="Collection.php" hash="c0c5d87c559d2e4011697b1a0ccf4846"/></dir><file name="Backtostockalert.php" hash="148ae085ef93a7cf6e52cdd60f1ca9a2"/><dir name="Review"><file name="Collection.php" hash="098061d250555679c9f609d2087ef9d4"/></dir><file name="Review.php" hash="cf78994db6e262e42a589b6538a45a32"/><dir name="Unsubscribe"><file name="Collection.php" hash="11048027437c0a5bc1478e4f2cdcc51d"/></dir><file name="Unsubscribe.php" hash="3b9e4d09dbb7ba483a5d16b6312050e6"/><dir name="Visited"><file name="Collection.php" hash="b09c0ce08ac30cc30f974e5c744eabf1"/></dir><file name="Visited.php" hash="55f2d0c1f90b41e852ecbf964925dc10"/></dir><file name="Review.php" hash="c14806dfb106363262b9911e8d06f628"/><dir name="System"><dir name="Config"><file name="Automatic.php" hash="4de4d5c373fa1ea373751cbd5ed7efbc"/><file name="Couponcounter.php" hash="18049531633e26b8970935e6b9c73823"/><file name="Customergroup.php" hash="aa31f980b1d28248f137fe2a06b3ba2c"/><file name="Discounttype.php" hash="1228055f8abc3bffba6020f4bb4210e0"/><file name="Generaltype.php" hash="463210c06e00794b79df38a61dfa56c2"/><file name="Hours.php" hash="db8c055c1fc0628f5fad84fc15c6d389"/><file name="Newordertrigger.php" hash="757bcc13562d4a5b905d57920906411f"/><file name="Registeredcustomergroup.php" hash="f2f296748fba58d5f78659fa38c0f9a2"/><file name="Time.php" hash="4b491667d8ea9816b07f584e84556556"/></dir></dir><file name="Unsubscribe.php" hash="cb20baf948256b9b70a13ed52ab91bab"/><file name="Visited.php" hash="2e9f119fc630cefc50f5a2a21546ebfc"/></dir><dir name="controllers"><file name="AutoresponderController.php" hash="bd9c5001c6438f5b76e53371f6149798"/><file name="BacktostockController.php" hash="61f07f9bdc3951dbddeaf8161d55023d"/></dir><dir name="etc"><file name="adminhtml.xml" hash="59a240f12b496566f1a2b1de5f053e96"/><file name="config.xml" hash="1e7491909901c389668d4dcc9fb01c04"/><file name="system.xml" hash="e4e5ae3db49d9c0e2f3e618270e3cffe"/></dir><dir name="sql"><dir name="ebizmarts_autoresponder_setup"><file name="mysql4-install-0.1.0.php" hash="d2152df00146562b30910ebe36c9b4e8"/><file name="mysql4-upgrade-0.1.3-0.1.4.php" hash="2ab92d2cf0f5fa7ccf7b61d9ab142a01"/><file name="mysql4-upgrade-0.1.4-0.1.5.php" hash="4b3cace6f889e5d42606140628c26cc4"/><file name="mysql4-upgrade-0.1.5-0.1.6.php" hash="378accc07eb80b16029db84f56bed683"/><file name="mysql4-upgrade-0.1.9-0.1.10.php" hash="53cc6beed11e8631c11a008c5fd78ce1"/><file name="mysql4-upgrade-1.1.14-1.2.0.php" hash="3cd44860cc2b2df0a7c68c6ffbd64628"/><file name="mysql4-upgrade-1.2.0-1.2.1.php" hash="8ffeb3186d48743e6c24134ff6900953"/></dir></dir></dir><dir name="SweetMonkey"><dir name="Block"><dir name="Adminhtml"><dir name="System"><dir name="Config"><file name="Autovars.php" hash="fc3ebb5ffe5344ef74a294547614c28f"/><dir name="Fieldset"><file name="Hint.php" hash="a1d28320ed21eaa6c20aa98c0b4e3492"/></dir><dir name="Form"><dir name="Field"><file name="Mapfields.php" hash="a0dfcfa3e1e22bdb33005a999cb0867b"/></dir></dir></dir></dir></dir></dir><dir name="Helper"><file name="Data.php" hash="83c32ef3e5433e701a10ef9cc5370d04"/></dir><dir name="Model"><file name="Observer.php" hash="d293aae1eae63f787b78d310d3364e79"/></dir><dir name="controllers"><dir name="Adminhtml"><file name="MageMonkeyController.php" hash="f7d0e23ca908825800044a19ef68094a"/></dir></dir><dir name="etc"><file name="adminhtml.xml" hash="8a81e6639cd53c96717a6b993d5fcd93"/><file name="config.xml" hash="0550e8de5d4215aeb945d06514ae6959"/><file name="system.xml" hash="93e8f26427a0df9183f6680441ce23f6"/></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Ebizmarts_MageMonkey.xml" hash="951aa15bc51345726e05080bd5fc084b"/><file name="Ebizmarts_Mandrill.xml" hash="ea4b352b5a0233330ecde76a0f9113dd"/><file name="Ebizmarts_AbandonedCart.xml" hash="48c4cfe8246d5a995e2836c43ab38d74"/><file name="Ebizmarts_Autoresponder.xml" hash="97302f94f5893147db18c4034d135256"/><file name="Ebizmarts_SweetMonkey.xml" hash="05d9393c17c76a589fd7681ed668d53f"/></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="magemonkey.xml" hash="8eef43f9d728e252a5f7d7b6cea93a19"/><dir name="ebizmarts"><file name="abandonedcart.xml" hash="14282d8f8739578d51c57def5df1227a"/><file name="autoresponder.xml" hash="d8dfb68cfd7c838cf29e9281a9a76c36"/></dir></dir><dir name="template"><dir name="magemonkey"><dir name="checkout"><file name="subscribe.phtml" hash="6647c5e991170303f99b956dbbddd6c6"/></dir><file name="lists.phtml" hash="8562e11e1d5e60807e7d8d991b8d1fb1"/></dir><dir name="ebizmarts_abandonedcart"><dir name="email"><dir name="order"><dir name="items"><dir name="order"><file name="default.phtml" hash="c078d029b2065e8b1938c3cfb24e8219"/></dir></dir><file name="items.phtml" hash="87f18755675a13f6e91a56b562bcd0fe"/></dir></dir><dir name="popup"><file name="emailcatcher.phtml" hash="86e370dc654f430029ae5d4037883e59"/></dir></dir><dir name="ebizmarts"><dir name="autoresponder"><dir name="backtostock"><dir name="catalog"><dir name="product"><file name="form.phtml" hash="c04b1aaf96617c47d1530538f2f9f5e0"/><file name="notice.phtml" hash="ba7963278c9ed51066c736cdc0b73978"/></dir></dir><file name="item.phtml" hash="9ff57a2867309f380525ad671a753f9e"/></dir><dir name="customer"><file name="list.phtml" hash="21d2f116e2f509943175c43bc5863582"/></dir><dir name="related"><file name="items.phtml" hash="b2a04397a22c9cdd421fe04b4c107dd7"/></dir><dir name="review"><file name="items.phtml" hash="1bc37dcc7087d375eed0849b76bcec64"/></dir><file name="unsubscribe.phtml" hash="ca8ed1c5810e07f1cdc91edb64420417"/><dir name="wishlist"><file name="items.phtml" hash="1e65bee4638cb557503b36e3224b853c"/></dir></dir></dir></dir></dir></dir></dir><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="magemonkey.xml" hash="4a2ba63a9d3002774b622e76339e6fbb"/><dir name="ebizmarts"><file name="mandrill.xml" hash="ba93e973a9019841c7d914ecd729983c"/><file name="abandonedcart.xml" hash="9ed91dab216911a13a2669bd81734180"/></dir></dir><dir name="template"><dir name="magemonkey"><dir name="bulksync"><dir name="export"><file name="form.phtml" hash="06a3c582f8469c11c644e688efb4e5a5"/></dir><dir name="import"><file name="form.phtml" hash="06a3c582f8469c11c644e688efb4e5a5"/></dir></dir><dir name="system"><dir name="config"><dir name="fieldset"><file name="hint.phtml" hash="fb568722b009e63ac13714bd1465a413"/></dir><file name="oauth_wizard.phtml" hash="91b3472b4e9a5bc26851b76bfcea59c5"/><file name="resetlocal360.phtml" hash="3347fad7cfb13e7b4c6647489bed1480"/><file name="resetremote360.phtml" hash="2a67ad95f8ffabdc1e2d1e572c4118ae"/><file name="upgradeforpatch.phtml" hash="6a0ed64653b65b4d0d206f86dcf29a9c"/></dir></dir></dir><dir name="ebizmarts"><dir name="mandrill"><dir name="system"><dir name="config"><dir name="fieldset"><file name="hint.phtml" hash="954efb14abd386cfff5881e15cda9be2"/></dir></dir></dir></dir><dir name="abandonedcart"><dir name="dashboard"><file name="index.phtml" hash="31a02b6aa63614bb2a52044195568f15"/><file name="salebar.phtml" hash="7a8c978ff415853550f9b1a3cbabfd1c"/><file name="totalbar.phtml" hash="95cb90a952f5548481c180004e39b7f1"/></dir><dir name="system"><dir name="config"><dir name="fieldset"><file name="hint.phtml" hash="ce2c35827f741b243bb366003e8dd412"/></dir></dir></dir></dir><dir name="autoresponder"><dir name="system"><dir name="config"><dir name="backtostock"><dir name="fieldset"><file name="hint.phtml" hash="623380a9c486eae57da00de6bd8b843d"/></dir></dir><dir name="birthday"><dir name="fieldset"><file name="hint.phtml" hash="d7f944a685769a46cb709f89c6e56f3b"/></dir></dir><dir name="fieldset"><file name="hint.phtml" hash="4c3f34e11b35f8d98ba675d6d5643cfb"/></dir><dir name="review"><dir name="fieldset"><file name="hint.phtml" hash="205b3fac2bc9682cdbdc9e3a8ec688df"/></dir></dir><dir name="wishlist"><dir name="fieldset"><file name="hint.phtml" hash="563ece5feca65f3ff728b89929cb2339"/></dir></dir></dir></dir></dir></dir><dir name="sweetmonkey"><dir name="system"><dir name="config"><file name="autovars.phtml" hash="53da8402573546ecdcbe2f5e9b3ab57a"/><dir name="fieldset"><file name="hint.phtml" hash="c3ffcb12d9c132c02dbd22e27a1b4f36"/></dir></dir></dir></dir></dir></dir></dir></dir></target><target name="magelocale"><dir name="en_US"><file name="Ebizmarts_MageMonkey.csv" hash="181e91ed91dfea5fe7dab66af5719af8"/><file name="Ebizmarts_Mandrill.csv" hash="3dac3af57664fd34f5eda8abf4098ee0"/><file name="Ebizmarts_AbandonedCart.csv" hash="214bcd0e8cd6153c48fab236dcfdba1b"/><dir name="template"><dir name="email"><dir name="ebizmarts"><dir name="abandonedcart"><file name="abandoned_cart_mail_1.html" hash="36ceaf0e511ecb2c785fb482c634ed2c"/><file name="abandoned_cart_mail_2.html" hash="ab628f7bf4f82d44d8d9a5b39c838e00"/><file name="abandoned_cart_mail_3.html" hash="c46eef13c346494f26f2e01ff7de9de2"/><file name="abandoned_cart_mail_generic.html" hash="c87513fa9e7fc18035c9b4421c51478e"/><file name="popup_coupon_template.html" hash="7411805f6751997e3de8a4f11196c14e"/></dir><dir name="autoresponder"><file name="backtostock.html" hash="fcccb77375b946faf13cf991b363ec3a"/><file name="birthday.html" hash="81132b642c9c1b8a6988e7e438384b48"/><file name="neworder.html" hash="0262dc0daedee87904ca7be1def4078a"/><file name="noactivity.html" hash="59347130b4bf761c6830397f7a6b817d"/><file name="relatedproducts.html" hash="9cd19f74d0c42967526d54a197453945"/><file name="review.html" hash="0d9d872e4a0d0290cea079ccec3658c5"/><file name="reviewcoupon.html" hash="51915e3ff4ef402093b402ea82ac3182"/><file name="visitedproducts.html" hash="31245a22c3decda3fd93c18f87d58284"/><file name="wishlist.html" hash="2bb0a835b2e0bffd3ac551266d52fb46"/></dir></dir></dir></dir><file name="Ebizmarts_Autoresponder.csv" hash="d41d8cd98f00b204e9800998ecf8427e"/><file name="Ebizmarts_SweetMonkey.csv" hash="f0cdb51ba2052ce7f7ec1c9885ee5d3c"/></dir><dir name="nl_NL"><dir name="template"><dir name="email"><dir name="ebizmarts"><dir name="abandonedcart"><file name="abandoned_cart_mail_1.html" hash="64df67da5c2759572c80c47677fc4244"/><file name="abandoned_cart_mail_2.html" hash="3e65ab1c4140408422b6fd7e190a2f4b"/><file name="abandoned_cart_mail_3.html" hash="de4cbef63748e20638017e04827d39b9"/><file name="abandoned_cart_mail_generic.html" hash="de90f1d4f52d4603e3c08ebd4c5aa4e5"/><file name="popup_coupon_template.html" hash="8059d68fce7783956033ff0cf27f2c0b"/></dir><dir name="autoresponder"><file name="backtostock.html" hash="d5feeeaaf9f7416dcfb072e1b39844fa"/><file name="birthday.html" hash="b7099ba5f0de5e8c7f56f1aca1ec8779"/><file name="neworder.html" hash="dd016910da8029a2b2266e9a82eac167"/><file name="noactivity.html" hash="6d3b63329f5d664a9f81b2aba55b5588"/><file name="relatedproducts.html" hash="5bb28d77374568fbab07519048edb301"/><file name="review.html" hash="a1116b4a34c72fb94d8945730096ed83"/><file name="reviewcoupon.html" hash="bdd27369d3e76d915489399d95a502fc"/><file name="visitedproducts.html" hash="74941796112fba1158707ab6bdf4b2d4"/><file name="wishlist.html" hash="e456275499caa1cc018d7da1da32d525"/></dir></dir></dir></dir><file name="Ebizmarts_MageMonkey.csv" hash="3e0b1485b10cf7c9f6f64437f870c7fe"/><file name="Ebizmarts_SweetMonkey.csv" hash="063c94afbaa6e2fbe2028580209bc09b"/><file name="Ebizmarts_AbandonedCart.csv" hash="099104a7a9492249c0e24909145abfa3"/></dir></target><target name="mageskin"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="magemonkey"><file name="magemonkey.css" hash="2072357ef844855f7a4607245b1e9a17"/><file name="magemonkey.js" hash="1a515d6697d533ee012754dd20e60345"/><file name="mailchimp-connected-ebizmarts-title.png" hash="c6bcb1aa606ecd3b0a9753bb48ddeb58"/><file name="mailchimp-ico.png" hash="14978ec398cede4060bc9b00365bb6c5"/><file name="mailchimp-section-background.png" hash="d4536261c6a3534fbb855428c0cca62c"/><file name="mailchimp-tab.png" hash="61972b4e063364071e81d8c9e10d8feb"/></dir><dir name="abandonedcart"><file name="abandonedcart.css" hash="bd6049fa8b17a1060e8a63fa29aefd94"/></dir><dir name="ebizmarts"><file name="Logo_Ebizmarts.png" hash="7ab7b13bda23200752897259e910daab"/><file name="ebizmarts-tab.png" hash="6dfa08c5cd4329d1df6e7b71fb1f925a"/><file name="ebizmarts.css" hash="a579734639953c1970ec26f56dda5837"/><dir name="mandrill"><file name="mandrill-tab.png" hash="d7eaf9deef355e4b8b55a96070b90ffe"/><file name="mandrill.css" hash="d93f1f52db38195a4f85d20de519151e"/></dir></dir></dir></dir></dir><dir name="frontend"><dir name="base"><dir name="default"><dir name="magemonkey"><file name="magemonkey.css" hash="8f25ca79fc6901215f713f0e048c4a9f"/><file name="monkey.js" hash="5984cd563aee48b7ba648066f733113a"/></dir></dir></dir></dir></target><target name="mage"><dir name="lib"><dir name="Mandrill"><dir name="Mandrill"><file name="Exceptions.php" hash="54d952267c004cddeedd8d9be07698c8"/><file name="Exports.php" hash="3ed368771a7174af0e01287e3a3e030f"/><file name="Inbound.php" hash="32378db89f2f47fe158577c256837896"/><file name="Internal.php" hash="fa680d47c780922a111078827cad1505"/><file name="Ips.php" hash="c70c08b34454d2e7aebc31101cfdca81"/><file name="Messages.php" hash="f1f3c20b6c872c72dcc33790d6a3adf4"/><file name="Metadata.php" hash="57820ae2032206334fb6e6d9b12f4df2"/><file name="Rejects.php" hash="f40f9ef016c338c6ae9d161c3112eea6"/><file name="Senders.php" hash="875ddbeff3f920397c73c2c2797f3eea"/><file name="Subaccounts.php" hash="9b6b61a8e0364c9f917952deffe0320c"/><file name="Tags.php" hash="ee2f9e328d4d49aa8b0289978f7375b0"/><file name="Templates.php" hash="9920cf5d10bdcb5416193435c425f123"/><file name="Urls.php" hash="184c17ebb031f1f6e6dad687a4bf767d"/><file name="Users.php" hash="826dac98663eefce2f5ccc4a5b0d38e9"/><file name="Webhooks.php" hash="37ea24a982630aa321444b85392f3397"/><file name="Whitelists.php" hash="d132144d50c3b713c98ad699984e4e38"/></dir><file name="Mandrill.php" hash="ac12db0139d483c2e3cf1da93aff1c96"/><file name="Message.php" hash="784920e095d8d9f0269b46f00071fcc9"/></dir></dir><dir name="js"><dir name="ebizmarts"><dir name="abandonedcart"><file name="popup.css" hash="2bf9fef85964298cc44143ef0fc78d21"/><file name="xmark.png" hash="6f14c834def36c1185347c49021030a4"/></dir><dir name="autoresponders"><file name="visitedproducts.js" hash="638a84c18b961879bc6d2196674661e0"/><file name="visitedproductsstorecodes.js" hash="a89a5b02ba597adb612d32dad74103dd"/></dir><dir name="magemonkey"><file name="campaignCatcher.js" hash="73d913fdfbc07bb3a085afb40d89a9b5"/></dir></dir></dir></target></contents>
32
  <compatible/>
33
  <dependencies><required><php><min>5.2.0</min><max>6.0.0</max></php></required></dependencies>
34
  </package>
skin/adminhtml/default/default/ebizmarts/Logo_Ebizmarts.png ADDED
Binary file