Listrak_Remarketing - Version 1.0.3

Version Notes

Stable build

Download this release

Release Info

Developer Listrak
Extension Listrak_Remarketing
Version 1.0.3
Comparing to
See all releases


Version 1.0.3

Files changed (59) hide show
  1. app/code/community/Listrak/Remarketing/Block/Adminhtml/Abandonedcartreport.php +15 -0
  2. app/code/community/Listrak/Remarketing/Block/Adminhtml/Abandonedcartreport/Grid.php +111 -0
  3. app/code/community/Listrak/Remarketing/Block/Adminhtml/Emailcapture.php +15 -0
  4. app/code/community/Listrak/Remarketing/Block/Adminhtml/Emailcapture/Edit.php +27 -0
  5. app/code/community/Listrak/Remarketing/Block/Adminhtml/Emailcapture/Edit/Form.php +20 -0
  6. app/code/community/Listrak/Remarketing/Block/Adminhtml/Emailcapture/Edit/Tab/Form.php +38 -0
  7. app/code/community/Listrak/Remarketing/Block/Adminhtml/Emailcapture/Edit/Tabs.php +26 -0
  8. app/code/community/Listrak/Remarketing/Block/Adminhtml/Emailcapture/Grid.php +53 -0
  9. app/code/community/Listrak/Remarketing/Block/Adminhtml/Notifications.php +20 -0
  10. app/code/community/Listrak/Remarketing/Block/Ecjs.php +122 -0
  11. app/code/community/Listrak/Remarketing/Helper/Data.php +33 -0
  12. app/code/community/Listrak/Remarketing/Model/Abandonedcart.php +40 -0
  13. app/code/community/Listrak/Remarketing/Model/Abandonedcart/Api.php +50 -0
  14. app/code/community/Listrak/Remarketing/Model/Abandonedcart/Api/V2.php +8 -0
  15. app/code/community/Listrak/Remarketing/Model/Apiextension.php +12 -0
  16. app/code/community/Listrak/Remarketing/Model/Apiextension/Api.php +185 -0
  17. app/code/community/Listrak/Remarketing/Model/Apiextension/Api/V2.php +8 -0
  18. app/code/community/Listrak/Remarketing/Model/Click.php +31 -0
  19. app/code/community/Listrak/Remarketing/Model/Click/Api.php +49 -0
  20. app/code/community/Listrak/Remarketing/Model/Click/Api/V2.php +8 -0
  21. app/code/community/Listrak/Remarketing/Model/Emailcapture.php +12 -0
  22. app/code/community/Listrak/Remarketing/Model/Log.php +35 -0
  23. app/code/community/Listrak/Remarketing/Model/Log/Api.php +52 -0
  24. app/code/community/Listrak/Remarketing/Model/Log/Api/V2.php +8 -0
  25. app/code/community/Listrak/Remarketing/Model/Mysql4/Abandonedcart.php +57 -0
  26. app/code/community/Listrak/Remarketing/Model/Mysql4/Abandonedcart/Collection.php +44 -0
  27. app/code/community/Listrak/Remarketing/Model/Mysql4/Apiextension.php +54 -0
  28. app/code/community/Listrak/Remarketing/Model/Mysql4/Click.php +64 -0
  29. app/code/community/Listrak/Remarketing/Model/Mysql4/Click/Collection.php +20 -0
  30. app/code/community/Listrak/Remarketing/Model/Mysql4/Emailcapture.php +17 -0
  31. app/code/community/Listrak/Remarketing/Model/Mysql4/Emailcapture/Collection.php +11 -0
  32. app/code/community/Listrak/Remarketing/Model/Mysql4/Log.php +17 -0
  33. app/code/community/Listrak/Remarketing/Model/Mysql4/Log/Collection.php +17 -0
  34. app/code/community/Listrak/Remarketing/Model/Mysql4/Session.php +94 -0
  35. app/code/community/Listrak/Remarketing/Model/Mysql4/Session/Collection.php +25 -0
  36. app/code/community/Listrak/Remarketing/Model/Mysql4/Subscriberupdate.php +17 -0
  37. app/code/community/Listrak/Remarketing/Model/Mysql4/Subscriberupdate/Collection.php +11 -0
  38. app/code/community/Listrak/Remarketing/Model/Observer.php +79 -0
  39. app/code/community/Listrak/Remarketing/Model/Session.php +69 -0
  40. app/code/community/Listrak/Remarketing/Model/Subscriber.php +22 -0
  41. app/code/community/Listrak/Remarketing/Model/Subscriberupdate.php +12 -0
  42. app/code/community/Listrak/Remarketing/controllers/Adminhtml/AbandonedcartreportController.php +35 -0
  43. app/code/community/Listrak/Remarketing/controllers/Adminhtml/EmailcaptureController.php +125 -0
  44. app/code/community/Listrak/Remarketing/controllers/CartController.php +60 -0
  45. app/code/community/Listrak/Remarketing/controllers/ConfigController.php +30 -0
  46. app/code/community/Listrak/Remarketing/controllers/EmailController.php +55 -0
  47. app/code/community/Listrak/Remarketing/controllers/TroubleshootingController.php +10 -0
  48. app/code/community/Listrak/Remarketing/etc/adminhtml.xml +60 -0
  49. app/code/community/Listrak/Remarketing/etc/api.xml +152 -0
  50. app/code/community/Listrak/Remarketing/etc/config.xml +168 -0
  51. app/code/community/Listrak/Remarketing/etc/system.xml +67 -0
  52. app/code/community/Listrak/Remarketing/etc/wsdl.xml +624 -0
  53. app/code/community/Listrak/Remarketing/etc/wsi.xml +82 -0
  54. app/code/community/Listrak/Remarketing/sql/listrak_remarketing_setup/mysql4-install-1.0.0.php +85 -0
  55. app/code/community/Listrak/Remarketing/sql/listrak_remarketing_setup/mysql4-upgrade-1.0.0-1.0.1.php +17 -0
  56. app/design/adminhtml/default/default/layout/remarketing.xml +13 -0
  57. app/design/frontend/base/default/layout/remarketing.xml +13 -0
  58. app/etc/modules/Listrak_Remarketing.xml +14 -0
  59. package.xml +26 -0
app/code/community/Listrak/Remarketing/Block/Adminhtml/Abandonedcartreport.php ADDED
@@ -0,0 +1,15 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Block_Adminhtml_Abandonedcartreport extends Mage_Adminhtml_Block_Widget_Grid_Container
6
+ {
7
+ public function __construct()
8
+ {
9
+ $this->_controller = 'adminhtml_abandonedcartreport';
10
+ $this->_blockGroup = 'remarketing';
11
+ $this->_headerText = Mage::helper('remarketing')->__('Abandoned Carts');
12
+ parent::__construct();
13
+ $this->_removeButton('add');
14
+ }
15
+ }
app/code/community/Listrak/Remarketing/Block/Adminhtml/Abandonedcartreport/Grid.php ADDED
@@ -0,0 +1,111 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Block_Adminhtml_Abandonedcartreport_Grid extends Mage_Adminhtml_Block_Widget_Grid
6
+ {
7
+ public function __construct()
8
+ {
9
+ parent::__construct();
10
+ $this->setId('abandonedCartsGrid');
11
+ $this->setDefaultSort('updated_at');
12
+ $this->setDefaultDir('DESC');
13
+ $this->setSaveParametersInSession(true);
14
+ }
15
+
16
+ protected function _prepareCollection()
17
+ {
18
+ $reportTimeout = Mage::getStoreConfig('remarketing/abandonedcarts/abandoned_cart_report_timeout') * 60;
19
+
20
+ $startDate = gmdate('Y-m-d H:i:s', time() - $reportTimeout);
21
+ $collection = Mage::getModel('listrak/abandonedcart')->getCollection()
22
+ ->addFieldToFilter('main_table.updated_at',array('lt'=>$startDate));
23
+ $collection->_prepareForReport = true;
24
+
25
+ $this->setCollection($collection);
26
+ return parent::_prepareCollection();
27
+ }
28
+
29
+ protected function _prepareColumns()
30
+ {
31
+ $this->addColumn('is_customer', array(
32
+ 'header' =>Mage::helper('remarketing')->__('Registered'),
33
+ 'index' =>'is_customer',
34
+ 'width' =>'75px',
35
+ 'sortable' => false,
36
+ 'filter' => false
37
+ ));
38
+
39
+ $this->addColumn('session_id', array(
40
+ 'header' =>Mage::helper('remarketing')->__('Session Id'),
41
+ 'index' =>'session_id',
42
+ 'width' =>'250px',
43
+ 'sortable' => false,
44
+ 'filter' => false
45
+ ));
46
+
47
+ $this->addColumn('customer_name', array(
48
+ 'header' =>Mage::helper('remarketing')->__('Customer Name'),
49
+ 'index' =>'customer_name',
50
+ 'sortable' => false,
51
+ 'filter' => false
52
+ ));
53
+
54
+ $this->addColumn('email', array(
55
+ 'header' =>Mage::helper('remarketing')->__('Email'),
56
+ 'index' =>'email',
57
+ 'sortable' => false,
58
+ 'filter' => false
59
+ ));
60
+
61
+ $this->addColumn('items_count', array(
62
+ 'header' =>Mage::helper('remarketing')->__('# Items'),
63
+ 'width' =>'80px',
64
+ 'align' =>'right',
65
+ 'index' =>'items_qty',
66
+ 'sortable' =>false,
67
+ 'type' =>'number',
68
+ 'filter' => false
69
+ ));
70
+
71
+ $this->addColumn('total', array(
72
+ 'header' =>Mage::helper('remarketing')->__('Total'),
73
+ 'width' =>'80px',
74
+ 'type' =>'currency',
75
+ 'currency_code' => (string) Mage::getStoreConfig(Mage_Directory_Model_Currency::XML_PATH_CURRENCY_DEFAULT),
76
+ 'index' =>'grand_total',
77
+ 'sortable' =>false,
78
+ 'renderer' =>'adminhtml/report_grid_column_renderer_currency',
79
+ 'filter' => false
80
+ ));
81
+
82
+ $this->addColumn('created_at', array(
83
+ 'header' =>Mage::helper('remarketing')->__('Creation Date'),
84
+ 'width' =>'170px',
85
+ 'type' =>'datetime',
86
+ 'index' =>'created_at',
87
+ //'filter_index'=>'main_table.created_at',
88
+ 'sortable' =>false,
89
+ 'filter' => false
90
+ ));
91
+
92
+ $this->addColumn('updated_at', array(
93
+ 'header' =>Mage::helper('remarketing')->__('Abandon Date'),
94
+ 'width' =>'170px',
95
+ 'type' =>'datetime',
96
+ 'index' =>'updated_at',
97
+ //'filter_index'=>'main_table.updated_at',
98
+ 'sortable' =>false,
99
+ 'filter' => false
100
+ ));
101
+
102
+ return parent::_prepareColumns();
103
+ }
104
+
105
+ public function getRowUrl($row)
106
+ {
107
+ return FALSE;
108
+ }
109
+
110
+
111
+ }
app/code/community/Listrak/Remarketing/Block/Adminhtml/Emailcapture.php ADDED
@@ -0,0 +1,15 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Block_Adminhtml_EmailCapture extends Mage_Adminhtml_Block_Widget_Grid_Container
6
+ {
7
+ public function __construct()
8
+ {
9
+ $this->_controller = 'adminhtml_emailcapture';
10
+ $this->_blockGroup = 'remarketing';
11
+ $this->_headerText = Mage::helper('remarketing')->__('Field Manager');
12
+ $this->_addButtonLabel = Mage::helper('remarketing')->__('Add Field');
13
+ parent::__construct();
14
+ }
15
+ }
app/code/community/Listrak/Remarketing/Block/Adminhtml/Emailcapture/Edit.php ADDED
@@ -0,0 +1,27 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Block_Adminhtml_EmailCapture_Edit extends Mage_Adminhtml_Block_Widget_Form_Container
6
+ {
7
+ public function __construct()
8
+ {
9
+ parent::__construct();
10
+
11
+ $this->_objectId = 'id';
12
+ $this->_blockGroup = 'remarketing';
13
+ $this->_controller = 'adminhtml_emailcapture';
14
+
15
+ $this->_updateButton('save', 'label', Mage::helper('remarketing')->__('Save Field'));
16
+ $this->_updateButton('delete', 'label', Mage::helper('remarketing')->__('Delete Field'));
17
+ }
18
+
19
+ public function getHeaderText()
20
+ {
21
+ if( Mage::registry('emailcapture_data') && Mage::registry('emailcapture_data')->getId() ) {
22
+ return Mage::helper('remarketing')->__("Edit Field");
23
+ } else {
24
+ return Mage::helper('remarketing')->__('Add Field');
25
+ }
26
+ }
27
+ }
app/code/community/Listrak/Remarketing/Block/Adminhtml/Emailcapture/Edit/Form.php ADDED
@@ -0,0 +1,20 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Block_Adminhtml_EmailCapture_Edit_Form extends Mage_Adminhtml_Block_Widget_Form
6
+ {
7
+ protected function _prepareForm()
8
+ {
9
+ $form = new Varien_Data_Form(array(
10
+ 'id' => 'edit_form',
11
+ 'action' => $this->getUrl('*/*/save', array('id' => $this->getRequest()->getParam('id'))),
12
+ 'method' => 'post',
13
+ )
14
+ );
15
+
16
+ $form->setUseContainer(true);
17
+ $this->setForm($form);
18
+ return parent::_prepareForm();
19
+ }
20
+ }
app/code/community/Listrak/Remarketing/Block/Adminhtml/Emailcapture/Edit/Tab/Form.php ADDED
@@ -0,0 +1,38 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Block_Adminhtml_EmailCapture_Edit_Tab_Form extends Mage_Adminhtml_Block_Widget_Form
6
+ {
7
+ protected function _prepareForm()
8
+ {
9
+ $form = new Varien_Data_Form();
10
+ $this->setForm($form);
11
+ $fieldset = $form->addFieldset('emailcapture_form', array('legend'=>Mage::helper('remarketing')->__('Field information')));
12
+
13
+ $fieldset->addField('page', 'text', array(
14
+ 'label' => Mage::helper('remarketing')->__('Page'),
15
+ 'class' => 'required-entry',
16
+ 'required' => true,
17
+ 'name' => 'page',
18
+ 'after_element_html' => '<p class="note"><span>For example: /checkout/onepage/index. Each URL has 3 parts. If yours does not have 3 parts, fill the last with "index". You can also use wildcard character "*" to capture field on all pages in the store.</span></p>'
19
+ ));
20
+
21
+ $fieldset->addField('field_id', 'text', array(
22
+ 'label' => Mage::helper('remarketing')->__('Field ID'),
23
+ 'name' => 'field_id',
24
+ 'required' => true,
25
+ 'class' => 'required-entry',
26
+ 'after_element_html' => '<p class="note"><span>Field id attribute. You can check it in HTML code preview.</span></p>'
27
+ ));
28
+
29
+ if (Mage::getSingleton('adminhtml/session')->getEmailCaptureData())
30
+ {
31
+ $form->setValues(Mage::getSingleton('adminhtml/session')->getEmailCaptureData());
32
+ Mage::getSingleton('adminhtml/session')->setEmailCaptureData(null);
33
+ } elseif (Mage::registry('emailcapture_data')) {
34
+ $form->setValues(Mage::registry('emailcapture_data')->getData());
35
+ }
36
+ return parent::_prepareForm();
37
+ }
38
+ }
app/code/community/Listrak/Remarketing/Block/Adminhtml/Emailcapture/Edit/Tabs.php ADDED
@@ -0,0 +1,26 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Block_Adminhtml_EmailCapture_Edit_Tabs extends Mage_Adminhtml_Block_Widget_Tabs
6
+ {
7
+
8
+ public function __construct()
9
+ {
10
+ parent::__construct();
11
+ $this->setId('emailcapture_tabs');
12
+ $this->setDestElementId('edit_form');
13
+ $this->setTitle(Mage::helper('remarketing')->__('Field Information'));
14
+ }
15
+
16
+ protected function _beforeToHtml()
17
+ {
18
+ $this->addTab('form_section', array(
19
+ 'label' => Mage::helper('remarketing')->__('Field Information'),
20
+ 'title' => Mage::helper('remarketing')->__('Field Information'),
21
+ 'content' => $this->getLayout()->createBlock('remarketing/adminhtml_emailcapture_edit_tab_form')->toHtml(),
22
+ ));
23
+
24
+ return parent::_beforeToHtml();
25
+ }
26
+ }
app/code/community/Listrak/Remarketing/Block/Adminhtml/Emailcapture/Grid.php ADDED
@@ -0,0 +1,53 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Block_Adminhtml_EmailCapture_Grid extends Mage_Adminhtml_Block_Widget_Grid
6
+ {
7
+ public function __construct()
8
+ {
9
+ parent::__construct();
10
+ $this->setId('emailcaptureGrid');
11
+ $this->setDefaultSort('emailcapture_id');
12
+ $this->setDefaultDir('ASC');
13
+ $this->setSaveParametersInSession(true);
14
+ }
15
+
16
+ protected function _prepareCollection()
17
+ {
18
+ $collection = Mage::getModel('listrak/emailcapture')->getCollection();
19
+ $this->setCollection($collection);
20
+ return parent::_prepareCollection();
21
+ }
22
+
23
+ protected function _prepareColumns()
24
+ {
25
+ $this->addColumn('emailcapture_id', array(
26
+ 'header' => Mage::helper('remarketing')->__('ID'),
27
+ 'align' =>'right',
28
+ 'width' => '50px',
29
+ 'index' => 'emailcapture_id',
30
+ ));
31
+
32
+ $this->addColumn('page', array(
33
+ 'header' => Mage::helper('remarketing')->__('Page'),
34
+ 'align' =>'left',
35
+ 'index' => 'page',
36
+ ));
37
+
38
+ $this->addColumn('field_id', array(
39
+ 'header' => Mage::helper('remarketing')->__('Field ID'),
40
+ 'align' => 'left',
41
+ 'index' => 'field_id',
42
+ ));
43
+
44
+ return parent::_prepareColumns();
45
+ }
46
+
47
+ public function getRowUrl($row)
48
+ {
49
+ return $this->getUrl('*/*/edit', array('id' => $row->getId()));
50
+ }
51
+
52
+
53
+ }
app/code/community/Listrak/Remarketing/Block/Adminhtml/Notifications.php ADDED
@@ -0,0 +1,20 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Block_Adminhtml_Notifications extends Mage_Core_Block_Text
6
+ {
7
+ protected function _toHtml()
8
+ {
9
+ $html = "";
10
+
11
+ if(!Mage::helper('remarketing')->checkSetupStatus()) {
12
+ $html = "<div class='notification-global'>The Listrak module requires a Listrak account. Please " .
13
+ "<a href='http://www.listrak.com/partners/magento-extension.aspx'>fill out our form</a> to get an account. ".
14
+ "If you already have a Listrak account, please contact your account manager " .
15
+ "or <a href='mailto:support@listrak.com'>support@listrak.com</a>.</div>";
16
+ }
17
+
18
+ return $html;
19
+ }
20
+ }
app/code/community/Listrak/Remarketing/Block/Ecjs.php ADDED
@@ -0,0 +1,122 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+ /**
5
+ arrEcjs = [];
6
+ arrEcjs.push({id:'billing:email', fn:function() _ecjs(1, $(this).value)});
7
+ arrEcjs.push({id:'login:email', fn:function() _ecjs(2, $(this).value)});
8
+
9
+ function ecjsInit() {
10
+ for(var i = 0; i < arrEcjs.length; i++) {
11
+ $(arrEcjs[i].id).stopObserving('change', arrEcjs[i].fn);
12
+ $(arrEcjs[i].id).observe('change', arrEcjs[i].fn);
13
+ }
14
+ }
15
+
16
+ Ajax.Responders.register({
17
+ onComplete: function() {
18
+ ecjsInit();
19
+ }
20
+ });
21
+
22
+
23
+ */
24
+
25
+ class Listrak_Remarketing_Block_Ecjs extends Mage_Core_Block_Text
26
+ {
27
+
28
+ public function getPageName()
29
+ {
30
+ return $this->_getData('page_name');
31
+ }
32
+
33
+ public function getMatchingPages()
34
+ {
35
+ $fullMatches = array();
36
+
37
+ try {
38
+ $route = Mage::app()->getRequest()->getRouteName();
39
+ $controller = Mage::app()->getRequest()->getControllerName();
40
+ $action = Mage::app()->getRequest()->getActionName();
41
+
42
+ $matches = array();
43
+ $matches[] = '/' . $route . '/' . $controller . '/' . $action . '/';
44
+ $matches[] = '/' . $route . '/' . $controller . '/' . $action;
45
+ $matches[] = '/' . $route . '/' . $controller . '/*';
46
+ $matches[] = '/' . $route . '/' . $controller . '/';
47
+ $matches[] = '/' . $route . '/*/*';
48
+ $matches[] = '/' . $route . '/*';
49
+ $matches[] = '/*/*/*';
50
+ $matches[] = '/*/*';
51
+ $matches[] = '/*';
52
+ $matches[] = '';
53
+
54
+ if(strtolower($action) == 'index') {
55
+ $matches[] = '/' . $route . '/' . $controller;
56
+ }
57
+ if(strtolower($action) == 'index' && strtolower($controller) == 'index') {
58
+ $matches[] = '/' . $route;
59
+ }
60
+
61
+ foreach($matches as $match) {
62
+ $fullMatches[] = $match;
63
+ if($match && $match{0} && $match{0} == '/') {
64
+ $fullMatches[] = substr($match, 1);
65
+ }
66
+ }
67
+ }
68
+ catch(Exception $ex) {
69
+ Mage::getModel("listrak/log")->addException($ex);
70
+ }
71
+
72
+ return $fullMatches;
73
+ }
74
+
75
+ protected function _toHtml()
76
+ {
77
+ $collections = Mage::getModel('listrak/emailcapture')->getCollection()->addFieldToFilter('page', $this->getMatchingPages());
78
+
79
+ if($collections && $collections->count()) {
80
+ $html = array();
81
+ $observed = array();
82
+
83
+ $html[] = '<script type="text/javascript">';
84
+ $html[] = 'arrEcjs = [];';
85
+ $html[] = 'function _ecjs(ecid,email) { new Ajax.Request("' . $this->getAjaxUrl() . '", {parameters:{cid: ecid, email: email}}); }';
86
+ $html[] = 'function ecjsInit() {' .
87
+ 'for(var ecjsi = 0; ecjsi < arrEcjs.length; ecjsi++) {' .
88
+ '$(arrEcjs[ecjsi].id).stopObserving("change", arrEcjs[ecjsi].fn);' .
89
+ '$(arrEcjs[ecjsi].id).observe("change", arrEcjs[ecjsi].fn);' .
90
+ '}' .
91
+ '}';
92
+
93
+ foreach($collections as $observer) {
94
+ if(!in_array($observer->getFieldId(), $observed)) {
95
+ $html[] = 'arrEcjs.push({id:"'. $observer->getFieldId() .'", fn: function() { _ecjs('. $observer->getEmailcaptureId() . ', $(this).value);}});';
96
+ $observed[] = $observer->getFieldId();
97
+ }
98
+ }
99
+
100
+ $html[] = 'document.observe("dom:loaded", function() { ecjsInit(); ';
101
+ $html[] = 'Ajax.Responders.register({' .
102
+ 'onComplete: function() {' .
103
+ 'ecjsInit();' .
104
+ '}' .
105
+ '});});';
106
+
107
+ if($observed && count($observed) === 0) {
108
+ return "";
109
+ }
110
+
111
+ $html[] = '</script>';
112
+ return implode("\n", $html);
113
+ }
114
+
115
+ return "";
116
+ }
117
+
118
+ public function getAjaxUrl()
119
+ {
120
+ return Mage::getUrl('remarketing/email', array('_secure' => Mage::app()->getStore()->isCurrentlySecure()));
121
+ }
122
+ }
app/code/community/Listrak/Remarketing/Helper/Data.php ADDED
@@ -0,0 +1,33 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Helper_Data extends Mage_Core_Helper_Abstract
6
+ {
7
+ public function gen_uuid() {
8
+ return sprintf( '%04x%04x-%04x-%04x-%04x-%04x%04x%04x',
9
+ // 32 bits for "time_low"
10
+ mt_rand( 0, 0xffff ), mt_rand( 0, 0xffff ),
11
+
12
+ // 16 bits for "time_mid"
13
+ mt_rand( 0, 0xffff ),
14
+
15
+ // 16 bits for "time_hi_and_version",
16
+ // four most significant bits holds version number 4
17
+ mt_rand( 0, 0x0fff ) | 0x4000,
18
+
19
+ // 16 bits, 8 bits for "clk_seq_hi_res",
20
+ // 8 bits for "clk_seq_low",
21
+ // two most significant bits holds zero and one for variant DCE1.1
22
+ mt_rand( 0, 0x3fff ) | 0x8000,
23
+
24
+ // 48 bits for "node"
25
+ mt_rand( 0, 0xffff ), mt_rand( 0, 0xffff ), mt_rand( 0, 0xffff )
26
+ );
27
+ }
28
+
29
+ public function checkSetupStatus() {
30
+ return Mage::getStoreConfig('remarketing/config/account_created');
31
+ }
32
+ }
33
+
app/code/community/Listrak/Remarketing/Model/Abandonedcart.php ADDED
@@ -0,0 +1,40 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Abandonedcart extends Mage_Core_Model_Abstract
6
+ {
7
+ public function _construct()
8
+ {
9
+ parent::_construct();
10
+ $this->_init('listrak/abandonedcart');
11
+ }
12
+
13
+ public function prepareForReport() {
14
+ $session = $this->getSession();
15
+ $customer = $session->getCustomer();
16
+ $this->setSessionId($session->getSessionId());
17
+
18
+ if($customer && $customer->getId()) {
19
+ $this->setCustomerName($customer->getFirstname() . ' ' . $customer->getLastname());
20
+ $this->setEmail($customer->getEmail());
21
+ $this->setIsCustomer('true');
22
+ }
23
+ else {
24
+ $this->setCustomerName('');
25
+ $this->setIsCustomer('false');
26
+
27
+ if(is_array($session->getEmails()) && count($session->getEmails()) > 0) {
28
+ foreach($session->getEmails() as $email) {
29
+ $this->setEmail($this->getEmail() . $email["email"] . ', ');
30
+ }
31
+
32
+ $this->setEmail(trim($this->getEmail(),", "));
33
+ }
34
+ else {
35
+
36
+ }
37
+ }
38
+
39
+ }
40
+ }
app/code/community/Listrak/Remarketing/Model/Abandonedcart/Api.php ADDED
@@ -0,0 +1,50 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Abandonedcart_Api extends Mage_Api_Model_Resource_Abstract {
6
+
7
+ public function items($storeId = 1, $startDate = NULL, $endDate = NULL, $perPage, $page) {
8
+
9
+ if ($startDate === NULL || !strtotime($startDate)) {
10
+ $this->_fault('incorrect_date');
11
+ }
12
+
13
+ if ($endDate === NULL || !strtotime($endDate)) {
14
+ $this->_fault('incorrect_date');
15
+ }
16
+
17
+ $collection = Mage::getModel('listrak/abandonedcart')
18
+ ->getCollection()
19
+ ->addFieldToFilter('main_table.updated_at',array('from'=>$startDate, 'to'=>$endDate))
20
+ ->setPageSize($perPage)->setCurPage($page)
21
+ ->addStoreFilter($storeId)
22
+ ->setOrder('updated_at', 'ASC');
23
+
24
+ $result = array();
25
+
26
+ foreach($collection as $item) {
27
+ $result[] = $item;
28
+ }
29
+
30
+ return $result;
31
+ }
32
+
33
+ public function purge($storeId = 1, $endDate = NULL) {
34
+ if ($endDate === NULL || !strtotime($endDate)) {
35
+ $this->_fault('incorrect_date');
36
+ }
37
+
38
+ $sessions = Mage::getModel("listrak/session")->getCollection()
39
+ ->addFieldToFilter('main_table.updated_at', array('lt' => $endDate))
40
+ ->addStoreFilter($storeId);
41
+
42
+ $count = $sessions->count();
43
+
44
+ foreach($sessions as $s) {
45
+ $s->delete();
46
+ }
47
+
48
+ return $count;
49
+ }
50
+ }
app/code/community/Listrak/Remarketing/Model/Abandonedcart/Api/V2.php ADDED
@@ -0,0 +1,8 @@
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Abandonedcart_Api_V2 extends Listrak_Remarketing_Model_Abandonedcart_Api {
6
+
7
+ }
8
+
app/code/community/Listrak/Remarketing/Model/Apiextension.php ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Apiextension extends Mage_Core_Model_Abstract
6
+ {
7
+ public function _construct()
8
+ {
9
+ parent::_construct();
10
+ $this->_init('listrak/apiextension');
11
+ }
12
+ }
app/code/community/Listrak/Remarketing/Model/Apiextension/Api.php ADDED
@@ -0,0 +1,185 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Apiextension_Api extends Mage_Api_Model_Resource_Abstract {
6
+
7
+ public function products($storeId = 1, $perPage = 50, $page = 1) {
8
+ $collection = Mage::getModel('catalog/product')->getCollection()
9
+ ->addStoreFilter($storeId)
10
+ ->addAttributeToSelect('*')
11
+ ->addFieldToFilter('type_id', array('neq'=>'configurable'))
12
+ ->setPageSize($perPage)
13
+ ->setCurPage($page);
14
+
15
+ $result = array();
16
+ $productInfo = array('entity_id' => '', 'sku' => '', 'name' => '', 'price' => '',
17
+ 'special_price' => '', 'special_from_date' => '', 'special_to_date' => '',
18
+ 'cost' => '', 'description' => '', 'short_description' => '', 'weight' => '',
19
+ 'url_key' => '', 'url_path' => '', 'image' => '', 'small_image' => '', 'thumbnail' => '');
20
+
21
+ foreach ($collection as $product) {
22
+ $item = array_intersect_key($product->toArray(), $productInfo);
23
+ $result[] = $item;
24
+ }
25
+
26
+ return $result;
27
+ }
28
+
29
+ public function subscribers($storeId = 1, $startDate = NULL, $perPage = 50, $page = 1) {
30
+ if ($startDate === NULL || !strtotime($startDate)) {
31
+ $this->_fault('incorrect_date');
32
+ }
33
+
34
+ $result = array();
35
+
36
+ $collection = Mage::getModel("listrak/apiextension")->getResource()->subscribers($storeId, $startDate, $perPage, $page);
37
+
38
+ foreach($collection as $item) {
39
+ $result[] = $item;
40
+ }
41
+
42
+ return $result;
43
+ }
44
+
45
+ public function subscribersPurge($endDate = NULL) {
46
+ if ($endDate === NULL || !strtotime($endDate)) {
47
+ $this->_fault('incorrect_date');
48
+ }
49
+
50
+ $collection = Mage::getModel("listrak/subscriberupdate")->getCollection()
51
+ ->addFieldToFilter('updated_at', array('lt' => $endDate));
52
+
53
+ $count = $collection->count();
54
+
55
+ foreach($collection as $c) {
56
+ $c->delete();
57
+ }
58
+
59
+ return $count;
60
+ }
61
+
62
+ public function customers($storeId = 1, $websiteId = 1, $perPage = 50, $page = 1) {
63
+ $collection = Mage::getModel('customer/customer')->getCollection()
64
+ ->addFieldToFilter('store_id',$storeId)
65
+ ->addAttributeToSelect('*')
66
+ ->setPageSize($perPage)
67
+ ->setCurPage($page);
68
+
69
+ $results = array();
70
+ $fields = array('entity_id' => '', 'firstname' => '', 'lastname' => '', 'email' => '', 'website_id' => '', 'store_id' => '');
71
+
72
+ foreach($collection as $customer) {
73
+ $item = $customer->toArray();
74
+ $results[] = array_intersect_key($item, $fields);
75
+ }
76
+
77
+ return $results;
78
+ }
79
+
80
+ public function orderStatus($storeId = 1, $startDate = NULL, $endDate = NULL, $perPage = 50, $page = 1, $filters = NULL) {
81
+ $collection = Mage::getModel("sales/order")->getCollection()
82
+ ->addFieldToFilter('store_id', $storeId)
83
+ ->addAttributeToSelect('increment_id')
84
+ ->addAttributeToSelect('updated_at')
85
+ ->addAttributeToSelect('status')
86
+ ->addFieldToFilter('updated_at',array('from'=>$startDate, 'to'=>$endDate))
87
+ ->addFieldToFilter('status', array('neq'=>'pending'))
88
+ ->setPageSize($perPage)->setCurPage($page)
89
+ ->setOrder('created_at', 'ASC');
90
+
91
+ if (is_array($filters)) {
92
+ try {
93
+ foreach ($filters as $field => $value) {
94
+ if (isset($this->_attributesMap['order'][$field])) {
95
+ $field = $this->_attributesMap['order'][$field];
96
+ }
97
+
98
+ $collection->addFieldToFilter($field, $value);
99
+ }
100
+ } catch (Mage_Core_Exception $e) {
101
+ $this->_fault('filters_invalid', $e->getMessage());
102
+ }
103
+ }
104
+
105
+ $results = array();
106
+
107
+ foreach($collection as $collectionItem) {
108
+ $results[] = $collectionItem;
109
+ }
110
+
111
+ return $results;
112
+ }
113
+
114
+ public function orders($storeId = 1, $startDate = NULL, $endDate = NULL, $perPage = 50, $page = 1) {
115
+ if ($startDate === NULL || !strtotime($startDate)) {
116
+ $this->_fault('incorrect_date');
117
+ }
118
+
119
+ if ($endDate === NULL || !strtotime($endDate)) {
120
+ $this->_fault('incorrect_date');
121
+ }
122
+
123
+ $collection = Mage::getModel("sales/order")->getCollection()
124
+ ->addAttributeToSelect('increment_id')
125
+ ->addFieldToFilter('created_at',array('from'=>$startDate, 'to'=>$endDate))
126
+ ->setPageSize($perPage)->setCurPage($page)
127
+ ->addFieldToFilter('store_id', $storeId)
128
+ ->setOrder('created_at', 'ASC');
129
+
130
+
131
+ $apiModel = Mage::getModel("sales/order_api");
132
+
133
+ $results = array();
134
+
135
+ $info_fields = array('created_at'=>'', 'status'=>'', 'customer_firstname'=>'', 'customer_lastname'=>'',
136
+ 'customer_email'=>'', 'order_id'=>'', 'subtotal'=>'', 'tax_amount'=>'', 'grand_total'=>'',
137
+ 'shipping_amount'=>'', 'billing_firstname'=>'');
138
+
139
+ $address_fields = array('firstname' => '', 'lastname' => '', 'company' => '', 'address1' => '',
140
+ 'address2' => '', 'city' => '', 'region' => '', 'postcode' => '', 'country' => '');
141
+
142
+ foreach($collection as $collectionItem) {
143
+ $res = array();
144
+ $item = $apiModel->info($collectionItem->getIncrementId());
145
+ $res["info"] = array_intersect_key($item, $info_fields);
146
+ $res["info"]["order_id"] = $collectionItem->getIncrementId();
147
+ $res["shipping_address"] = array_intersect_key($item["shipping_address"], $address_fields);
148
+ $res["billing_address"] = array_intersect_key($item["billing_address"], $address_fields);
149
+ $res["product"] = array();
150
+ foreach($item["items"] as $orderItem) {
151
+ if($orderItem["product_type"] != "configurable")
152
+ $res["product"][] = $orderItem;
153
+ }
154
+ $res["session"] = Mage::getModel("listrak/session")->load($item["quote_id"], 'quote_id');
155
+ $results[] = $res;
156
+ }
157
+
158
+ return $results;
159
+ }
160
+
161
+ public function info() {
162
+ $result = array();
163
+ $result["ini"] = array();
164
+
165
+ $subModel = Mage::getModel("newsletter/subscriber");
166
+ $result["subscriberClass"] = get_class($subModel);
167
+
168
+ $result["modules"] = array();
169
+ $modules = (array)Mage::getConfig()->getNode('modules')->children();
170
+
171
+ foreach($modules as $key => $value) {
172
+ $valueArray = $value->asCanonicalArray();
173
+ $result["modules"][] = "name=$key, version=" . $valueArray["version"] .", isActive=" . $valueArray["active"];
174
+ }
175
+
176
+ $ini = array("session.gc_maxlifetime", "session.cookie_lifetime", "session.gc_divisor", "session.gc_probability");
177
+
178
+ foreach($ini as $iniParam) {
179
+ $result["ini"][] = "$iniParam=" . ini_get($iniParam);
180
+ }
181
+
182
+ return $result;
183
+ }
184
+ }
185
+
app/code/community/Listrak/Remarketing/Model/Apiextension/Api/V2.php ADDED
@@ -0,0 +1,8 @@
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Apiextension_Api_V2 extends Listrak_Remarketing_Model_Apiextension_Api {
6
+
7
+ }
8
+
app/code/community/Listrak/Remarketing/Model/Click.php ADDED
@@ -0,0 +1,31 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Click extends Mage_Core_Model_Abstract
6
+ {
7
+ public function _construct()
8
+ {
9
+ parent::_construct();
10
+ $this->_init('listrak/click');
11
+ }
12
+
13
+ public function checkForClick() {
14
+ foreach($_GET as $key => $value) {
15
+ if(stripos($key, 'trk_') !== false) {
16
+ $this->recordClick();
17
+ break;
18
+ }
19
+ }
20
+ }
21
+
22
+ private function recordClick() {
23
+ $this->setTokenUid(Mage::helper('remarketing')->gen_uuid());
24
+ $this->setClickDate(gmdate('Y-m-d H:i:s'));
25
+ $this->setSessionId(Mage::getSingleton('listrak/session')->getId());
26
+ $this->setQuerystring($_SERVER['QUERY_STRING']);
27
+ $this->save();
28
+
29
+ Mage::getModel('core/cookie')->set('ltktrk', $this->getTokenUid(), TRUE, NULL, NULL, NULL, TRUE);
30
+ }
31
+ }
app/code/community/Listrak/Remarketing/Model/Click/Api.php ADDED
@@ -0,0 +1,49 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Click_Api extends Mage_Api_Model_Resource_Abstract {
6
+
7
+ public function items($storeId = 1, $startDate = NULL, $endDate = NULL, $perPage = 50, $page = 1) {
8
+
9
+ if ($startDate === NULL || !strtotime($startDate)) {
10
+ $this->_fault('incorrect_date');
11
+ }
12
+
13
+ if ($endDate === NULL || !strtotime($endDate)) {
14
+ $this->_fault('incorrect_date');
15
+ }
16
+
17
+ $clicks = Mage::getModel("listrak/click")->getCollection()
18
+ ->addFieldToFilter('click_date',array('from'=>$startDate, 'to'=>$endDate))
19
+ ->setPageSize($perPage)->setCurPage($page);
20
+
21
+ $clicks->addStoreFilter($storeId);
22
+
23
+ $result = array();
24
+
25
+ foreach($clicks as $item) {
26
+ $result[] = $item;
27
+ }
28
+
29
+ return $result;
30
+ }
31
+
32
+ public function purge($storeId = 1, $endDate) {
33
+ if($endDate === NULL || !strtotime($endDate)) {
34
+ $this->_fault('incorrect_date');
35
+ }
36
+
37
+ $clicks = Mage::getModel("listrak/click")->getCollection()
38
+ ->addFieldToFilter('click_date', array('lt' => $endDate))
39
+ ->addStoreFilter($storeId);
40
+
41
+ $count = $clicks->count();
42
+
43
+ foreach($clicks as $click){
44
+ $click->delete();
45
+ }
46
+
47
+ return $count;
48
+ }
49
+ }
app/code/community/Listrak/Remarketing/Model/Click/Api/V2.php ADDED
@@ -0,0 +1,8 @@
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Click_Api_V2 extends Listrak_Remarketing_Model_Click_Api {
6
+
7
+ }
8
+
app/code/community/Listrak/Remarketing/Model/Emailcapture.php ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Emailcapture extends Mage_Core_Model_Abstract {
6
+
7
+ public function _construct()
8
+ {
9
+ parent::_construct();
10
+ $this->_init('listrak/emailcapture');
11
+ }
12
+ }
app/code/community/Listrak/Remarketing/Model/Log.php ADDED
@@ -0,0 +1,35 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Log extends Mage_Core_Model_Abstract
6
+ {
7
+ const LOGTYPE_MESSAGE = 1;
8
+ const LOGTYPE_EXCEPTION = 2;
9
+
10
+ public function _construct()
11
+ {
12
+ parent::_construct();
13
+ $this->_init('listrak/log');
14
+ }
15
+
16
+ public function addMessage($msg, $storeId = NULL) {
17
+ if($storeId == NULL) {
18
+ $storeId = Mage::app()->getStore()->getStoreId();
19
+ }
20
+ $this->setMessage($msg);
21
+ $this->setLogTypeId(self::LOGTYPE_MESSAGE);
22
+ $this->setStoreId($storeId);
23
+ $this->save();
24
+ }
25
+
26
+ public function addException($msg, $storeId = NULL) {
27
+ if($storeId == NULL) {
28
+ $storeId = Mage::app()->getStore()->getStoreId();
29
+ }
30
+ $this->setMessage($msg);
31
+ $this->setLogTypeId(self::LOGTYPE_EXCEPTION);
32
+ $this->setStoreId($storeId);
33
+ $this->save();
34
+ }
35
+ }
app/code/community/Listrak/Remarketing/Model/Log/Api.php ADDED
@@ -0,0 +1,52 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Log_Api extends Mage_Api_Model_Resource_Abstract {
6
+
7
+ public function items($storeId = 1, $startDate = NULL, $endDate = NULL, $perPage = 50, $page = 1, $logTypeId = 0) {
8
+
9
+ if ($startDate === NULL || !strtotime($startDate)) {
10
+ $this->_fault('incorrect_date');
11
+ }
12
+
13
+ if ($endDate === NULL || !strtotime($endDate)) {
14
+ $this->_fault('incorrect_date');
15
+ }
16
+
17
+ $logs = Mage::getModel("listrak/log")->getCollection()
18
+ ->addFieldToFilter('date_entered',array('from'=>$startDate, 'to'=>$endDate))
19
+ ->setPageSize($perPage)->setCurPage($page)
20
+ ->addStoreFilter($storeId);
21
+
22
+ $result = array();
23
+
24
+ foreach($logs as $item) {
25
+ $result[] = $item;
26
+ }
27
+
28
+ return $result;
29
+ }
30
+
31
+ public function purge($storeId = 1, $endDate = NULL) {
32
+ if($endDate === NULL || !strtotime($endDate)) {
33
+ $this->_fault('incorrect_date');
34
+ }
35
+
36
+ $logs = Mage::getModel("listrak/log")->getCollection()
37
+ ->addFieldToFilter('date_entered', array('lt' => $endDate))
38
+ ->addStoreFilter($storeId);
39
+
40
+ $count = $logs->count();
41
+
42
+ foreach($logs as $log){
43
+ $log->delete();
44
+ }
45
+
46
+ return $count;
47
+ }
48
+
49
+ public function toggle($storeId = 1, $onOff) {
50
+ return $onOff;
51
+ }
52
+ }
app/code/community/Listrak/Remarketing/Model/Log/Api/V2.php ADDED
@@ -0,0 +1,8 @@
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Log_Api_V2 extends Listrak_Remarketing_Model_Log_Api {
6
+
7
+ }
8
+
app/code/community/Listrak/Remarketing/Model/Mysql4/Abandonedcart.php ADDED
@@ -0,0 +1,57 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Mysql4_Abandonedcart extends Mage_Core_Model_Mysql4_Abstract
6
+ {
7
+ protected $_read;
8
+
9
+ protected $_write;
10
+
11
+ public function _construct()
12
+ {
13
+ $this->_init('listrak/session','id');
14
+ $this->_read = $this->_getReadAdapter();
15
+ $this->_write = $this->_getWriteAdapter();
16
+ }
17
+
18
+ protected function _afterLoad(Mage_Core_Model_Abstract $object) {
19
+ $object->setSession(Mage::getModel("listrak/session")->load($object->getId()));
20
+
21
+ $this->loadCart($object);
22
+
23
+ return parent::_afterLoad($object);
24
+ }
25
+
26
+ protected function loadCart(Mage_Core_Model_Abstract $object) {
27
+ $product_fields = array(
28
+ 'entity_id'=>'', 'sku'=>'', 'name'=>'', 'price'=>'', 'special_price'=>'',
29
+ 'special_from_date'=>'', 'special_to_date'=>'', 'cost'=>'', 'description'=>'',
30
+ 'short_description'=>'', 'weight'=>'', 'url_key'=>'', 'url_path'=>'',
31
+ 'image'=>'', 'small_image'=>'', 'thumbnail'=>'', 'qty'=>'');
32
+
33
+ $fields = array(
34
+ 'item_id' => 'q.item_id',
35
+ 'quote_id' => 'q.quote_id',
36
+ 'product_id' => 'q.product_id',
37
+ 'qty' => 'q.qty');
38
+
39
+ $products = array();
40
+
41
+ $qiSelect = $this->_read->select()
42
+ ->from(array('q' => $this->getTable('sales/quote_item')), $fields)
43
+ ->where('q.quote_id = ?', $object->getQuoteId())
44
+ ->where('q.product_type <> "configurable"');
45
+
46
+ $qiResult = $this->_read->fetchAll($qiSelect);
47
+
48
+ foreach($qiResult as $qi) {
49
+ $product = Mage::getModel('catalog/product')->load($qi['product_id']);
50
+ $qitem = array_intersect_key($product->toArray(),$product_fields);
51
+ $qitem["qty"] = $qi["qty"];
52
+ $products[] = $qitem;
53
+ }
54
+
55
+ $object->setProducts($products);
56
+ }
57
+ }
app/code/community/Listrak/Remarketing/Model/Mysql4/Abandonedcart/Collection.php ADDED
@@ -0,0 +1,44 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Mysql4_Abandonedcart_Collection extends Mage_Core_Model_Mysql4_Collection_Abstract
6
+ {
7
+ public $_prepareForReport = false;
8
+
9
+ protected function _construct()
10
+ {
11
+ $this->_init('listrak/abandonedcart');
12
+ }
13
+
14
+ protected function _initSelect()
15
+ {
16
+ parent::_initSelect();
17
+
18
+ $this->getSelect()
19
+ ->join(array('q'=>$this->getTable('sales/quote')),
20
+ 'main_table.quote_id = q.entity_id',
21
+ array('items_qty','grand_total'))
22
+ ->joinLeft(array('qa' => $this->getTable('sales/quote_address')),
23
+ 'q.entity_id=qa.quote_id AND qa.address_type="billing"',
24
+ array('qa.firstname AS customer_firstName', 'qa.lastname AS customer_lastName'))
25
+ ->where('q.items_count > 0 AND q.is_active = 1');
26
+ }
27
+
28
+ public function addStoreFilter($storeIds)
29
+ {
30
+ $this->getSelect()->where('main_table.store_id IN (?)', $storeIds);
31
+ return $this;
32
+ }
33
+
34
+ protected function _afterLoad() {
35
+ foreach ($this->_items as $item) {
36
+ $item->afterLoad();
37
+ if($this->_prepareForReport === true) {
38
+ $item->prepareForReport();
39
+ }
40
+ }
41
+
42
+ return parent::_afterLoad();
43
+ }
44
+ }
app/code/community/Listrak/Remarketing/Model/Mysql4/Apiextension.php ADDED
@@ -0,0 +1,54 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Mysql4_Apiextension extends Mage_Core_Model_Mysql4_Abstract {
6
+
7
+ protected $_read;
8
+
9
+ protected $_write;
10
+
11
+ protected function _construct()
12
+ {
13
+ $this->_init('listrak/session', 'id');
14
+ $this->_read = $this->_getReadAdapter();
15
+ $this->_write = $this->_getWriteAdapter();
16
+ }
17
+
18
+ public function subscribers($storeId = 1, $startDate = NULL, $perPage = 50, $page = 1) {
19
+
20
+ $collection = Mage::getModel("newsletter/subscriber")->getCollection()
21
+ ->addStoreFilter($storeId)
22
+ ->setPageSize($perPage)
23
+ ->setCurPage($page);
24
+
25
+ $collection->getSelect()
26
+ ->join(array('su'=>$collection->getTable('listrak/subscriber_update')),
27
+ 'main_table.subscriber_id = su.subscriber_id',
28
+ array())
29
+ ->where('su.updated_at > ?', $startDate);
30
+
31
+ $collection->setOrder('su.updated_at', 'ASC');
32
+
33
+ foreach($collection as $c) {
34
+ switch($c->getSubscriberStatus()) {
35
+ case "1":
36
+ $c->setSubscriberStatus("subscribed");
37
+ break;
38
+ case "2":
39
+ $c->setSubscriberStatus("inactive");
40
+ break;
41
+ case "3":
42
+ $c->setSubscriberStatus("unsubscribed");
43
+ break;
44
+ case "4":
45
+ $c->setSubscriberStatus("unconfirmed");
46
+ break;
47
+ default:
48
+ break;
49
+ }
50
+ }
51
+
52
+ return $collection;
53
+ }
54
+ }
app/code/community/Listrak/Remarketing/Model/Mysql4/Click.php ADDED
@@ -0,0 +1,64 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Mysql4_Click extends Mage_Core_Model_Mysql4_Abstract {
6
+
7
+ protected $_read;
8
+
9
+ protected $_write;
10
+
11
+ protected function _construct()
12
+ {
13
+ $this->_init('listrak/click', 'click_id');
14
+ $this->_read = $this->_getReadAdapter();
15
+ $this->_write = $this->_getWriteAdapter();
16
+ }
17
+
18
+ public function loadByQuoteId($quoteId) {
19
+ $select = $this->_read->select()
20
+ ->from($this->getTable('listrak/session'))
21
+ ->where('quote_id=?',$quoteId)
22
+ ->join(array('c'=>$this->getTable('listrak/click')),
23
+ 'id = c.session_id',
24
+ array());
25
+
26
+ if($result = $this->_read->fetchAll($select)) {
27
+ return $result;
28
+ }
29
+
30
+ return array();
31
+ }
32
+
33
+ public function loadLatestByQuoteId($quoteId) {
34
+ $select = $this->_read->select()
35
+ ->from(array('c'=>$this->getTable('listrak/click')))
36
+ ->joinInner(array('s'=>$this->getTable('listrak/session')), 's.id = c.session_id', array())
37
+ ->where('s.quote_id = ?', $quoteId)
38
+ ->order('click_id', 'desc')
39
+ ->limit(0,1);
40
+
41
+ if($result = $this->_read->fetchRow($select)) {
42
+ return $result;
43
+ }
44
+ else {
45
+ return NULL;
46
+ }
47
+ }
48
+
49
+ public function loadLatestBySessionId($sid) {
50
+ $select = $this->_read->select()
51
+ ->from(array('c'=>$this->getTable('listrak/click')))
52
+ ->joinInner(array('s'=>$this->getTable('listrak/session')), 's.id = c.session_id', array())
53
+ ->where('s.session_id = ?', $sid)
54
+ ->order('click_id', 'desc')
55
+ ->limit(0,1);
56
+
57
+ if($result = $this->_read->fetchRow($select)) {
58
+ return $result;
59
+ }
60
+ else {
61
+ return NULL;
62
+ }
63
+ }
64
+ }
app/code/community/Listrak/Remarketing/Model/Mysql4/Click/Collection.php ADDED
@@ -0,0 +1,20 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Mysql4_Click_Collection extends Mage_Core_Model_Mysql4_Collection_Abstract
6
+ {
7
+
8
+ protected function _construct()
9
+ {
10
+ $this->_init('listrak/click');
11
+ }
12
+
13
+ public function addStoreFilter($storeId)
14
+ {
15
+ $this->getSelect()
16
+ ->join(array('s'=>$this->getTable('listrak/session')), 'main_table.session_id = s.id', array('store_id', 'session_id as session_uid'))
17
+ ->where('s.store_id IN (?)',$storeId);
18
+ return $this;
19
+ }
20
+ }
app/code/community/Listrak/Remarketing/Model/Mysql4/Emailcapture.php ADDED
@@ -0,0 +1,17 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Mysql4_Emailcapture extends Mage_Core_Model_Mysql4_Abstract {
6
+
7
+ protected $_read;
8
+
9
+ protected $_write;
10
+
11
+ protected function _construct()
12
+ {
13
+ $this->_init('listrak/emailcapture', 'emailcapture_id');
14
+ $this->_read = $this->_getReadAdapter();
15
+ $this->_write = $this->_getWriteAdapter();
16
+ }
17
+ }
app/code/community/Listrak/Remarketing/Model/Mysql4/Emailcapture/Collection.php ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Mysql4_Emailcapture_Collection extends Mage_Core_Model_Mysql4_Collection_Abstract {
6
+
7
+ protected function _construct()
8
+ {
9
+ $this->_init('listrak/emailcapture');
10
+ }
11
+ }
app/code/community/Listrak/Remarketing/Model/Mysql4/Log.php ADDED
@@ -0,0 +1,17 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Mysql4_Log extends Mage_Core_Model_Mysql4_Abstract {
6
+
7
+ protected $_read;
8
+
9
+ protected $_write;
10
+
11
+ protected function _construct()
12
+ {
13
+ $this->_init('listrak/log', 'id');
14
+ $this->_read = $this->_getReadAdapter();
15
+ $this->_write = $this->_getWriteAdapter();
16
+ }
17
+ }
app/code/community/Listrak/Remarketing/Model/Mysql4/Log/Collection.php ADDED
@@ -0,0 +1,17 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Mysql4_Log_Collection extends Mage_Core_Model_Mysql4_Collection_Abstract
6
+ {
7
+ protected function _construct()
8
+ {
9
+ $this->_init('listrak/log');
10
+ }
11
+
12
+ public function addStoreFilter($storeIds)
13
+ {
14
+ $this->getSelect()->where('main_table.store_id IN (?)', $storeIds);
15
+ return $this;
16
+ }
17
+ }
app/code/community/Listrak/Remarketing/Model/Mysql4/Session.php ADDED
@@ -0,0 +1,94 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Mysql4_Session extends Mage_Core_Model_Mysql4_Abstract {
6
+
7
+ protected $_read;
8
+
9
+ protected $_write;
10
+
11
+ protected function _construct()
12
+ {
13
+ $this->_init('listrak/session', 'id');
14
+ $this->_read = $this->_getReadAdapter();
15
+ $this->_write = $this->_getWriteAdapter();
16
+ }
17
+
18
+ protected function _afterLoad(Mage_Core_Model_Abstract $object) {
19
+ if($object->getCustomerId()) {
20
+ $cust = Mage::getModel("customer/customer")->load($object->getCustomerId());
21
+ if($cust) {
22
+ $object->setCustomer($cust);
23
+ }
24
+ }
25
+
26
+ if($object->getId()) {
27
+ $this->loadEmails($object);
28
+ $this->loadClicks($object);
29
+ }
30
+ return parent::_afterLoad($object);
31
+ }
32
+
33
+ public function loadBySessionId(Listrak_Remarketing_Model_Session $session) {
34
+ $select = $this->_read->select()
35
+ ->from($this->getTable('listrak/session'))
36
+ ->where('session_id=?',$session->getSessionId());
37
+
38
+ if($result = $this->_read->fetchRow($select)) {
39
+ $session->addData($result);
40
+ $session->loadEmails();
41
+ }
42
+ }
43
+
44
+ public function loadByQuoteId(Listrak_Remarketing_Model_Session $session) {
45
+ $select = $this->_read->select()
46
+ ->from($this->getTable('listrak/session'))
47
+ ->where('quote_id=?',$session->getQuoteId());
48
+
49
+ if($result = $this->_read->fetchRow($select)) {
50
+ $session->addData($result);
51
+ $session->loadEmails();
52
+ }
53
+ }
54
+
55
+ public function insertEmail(Listrak_Remarketing_Model_Session $session, $email, $emailcaptureId) {
56
+ if($session->getId()) {
57
+ $data = array();
58
+ $data['session_id'] = $session->getId();
59
+ $data['email'] = $email;
60
+ $data['emailcapture_id'] = $emailcaptureId;
61
+ $data['created_at'] = gmdate('Y-m-d H:i:s');
62
+ $this->_write->insert($this->getTable('listrak/session_email'), $data);
63
+ }
64
+ }
65
+
66
+ public function loadEmails(Listrak_Remarketing_Model_Session $session) {
67
+ $select = $this->_read->select()
68
+ ->from(array('se'=>$this->getTable('listrak/session_email')))
69
+ ->joinLeft(array('ec'=>$this->getTable('listrak/emailcapture')),
70
+ 'se.emailcapture_id = ec.emailcapture_id',
71
+ array('*'))
72
+ ->where('session_id=?',$session->getId());
73
+
74
+ $emails = $this->_read->fetchAll($select);
75
+ $session->setEmails($emails);
76
+ }
77
+
78
+ public function loadClicks(Listrak_Remarketing_Model_Session $session) {
79
+ $clicks = Mage::getModel("listrak/click")->getCollection()
80
+ ->addFieldToFilter('session_id',array('eq'=>$session->getId()));
81
+
82
+ $sessionClicks = array();
83
+
84
+ foreach($clicks as $click) {
85
+ $sessionClicks[] = $click;
86
+ }
87
+
88
+ $session->setClicks($sessionClicks);
89
+ }
90
+
91
+ public function deleteEmails($id) {
92
+ $del = $this->_write->delete($this->getTable("listrak/session_email"), "session_id = $id");
93
+ }
94
+ }
app/code/community/Listrak/Remarketing/Model/Mysql4/Session/Collection.php ADDED
@@ -0,0 +1,25 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Mysql4_Session_Collection extends Mage_Core_Model_Mysql4_Collection_Abstract {
6
+
7
+ protected function _construct()
8
+ {
9
+ $this->_init('listrak/session');
10
+ }
11
+
12
+ public function addStoreFilter($storeIds)
13
+ {
14
+ $this->getSelect()->where('main_table.store_id IN (?)', $storeIds);
15
+ return $this;
16
+ }
17
+
18
+ protected function _afterLoad() {
19
+ foreach($this->_items as $i) {
20
+ $i->afterLoad();
21
+ }
22
+
23
+ return parent::_afterLoad();
24
+ }
25
+ }
app/code/community/Listrak/Remarketing/Model/Mysql4/Subscriberupdate.php ADDED
@@ -0,0 +1,17 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Mysql4_Subscriberupdate extends Mage_Core_Model_Mysql4_Abstract {
6
+
7
+ protected $_read;
8
+
9
+ protected $_write;
10
+
11
+ protected function _construct()
12
+ {
13
+ $this->_init('listrak/subscriber_update', 'id');
14
+ $this->_read = $this->_getReadAdapter();
15
+ $this->_write = $this->_getWriteAdapter();
16
+ }
17
+ }
app/code/community/Listrak/Remarketing/Model/Mysql4/Subscriberupdate/Collection.php ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Mysql4_Subscriberupdate_Collection extends Mage_Core_Model_Mysql4_Collection_Abstract
6
+ {
7
+ protected function _construct()
8
+ {
9
+ $this->_init('listrak/subscriberupdate');
10
+ }
11
+ }
app/code/community/Listrak/Remarketing/Model/Observer.php ADDED
@@ -0,0 +1,79 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Observer {
6
+
7
+ public function sessionInit($observer) {
8
+ try {
9
+ $session = Mage::getSingleton('listrak/session');
10
+ $session->init();
11
+
12
+ $click = Mage::getModel('listrak/click');
13
+ $click->checkForClick();
14
+ }
15
+ catch(Exception $ex) {
16
+ Mage::getModel("listrak/log")->addException($ex);
17
+ }
18
+
19
+ return $this;
20
+ }
21
+
22
+ public function orderPlaced($observer) {
23
+ try {
24
+ $cs = Mage::getSingleton('core/session');
25
+ $cs->setIsListrakOrderMade(true);
26
+ }
27
+ catch(Exception $ex) {
28
+ Mage::getModel("listrak/log")->addException($ex);
29
+ }
30
+
31
+ return $this;
32
+ }
33
+
34
+ public function subscriberSaved($observer) {
35
+ try {
36
+ $s = $observer->getSubscriber();
37
+ $su = Mage::getModel("listrak/subscriberupdate")->load($s->getSubscriberId(), 'subscriber_id');
38
+
39
+ if(!$su->getData()) {
40
+ $su->setSubscriberId($s->getSubscriberId());
41
+ }
42
+
43
+ $su->setUpdatedAt(gmdate('Y-m-d H:i:s'));
44
+ $su->save();
45
+ }
46
+ catch(Exception $ex) {
47
+ Mage::getModel("listrak/log")->addException($ex);
48
+ }
49
+
50
+ return $this;
51
+ }
52
+
53
+ public function adminPageLoad($observer) {
54
+ try {
55
+ if(Mage::getSingleton('admin/session')->isFirstPageAfterLogin() && !Mage::helper('remarketing')->checkSetupStatus()) {
56
+ $ae = Mage::getModel("listrak/apiextension_api");
57
+ $sc = $ae->subscribersPurge(gmdate("Y-m-d H:i:s", time() - 604800));
58
+ Mage::getModel("listrak/log")->addMessage("Purged $sc subscriber update entries.");
59
+
60
+ foreach (Mage::app()->getStores() as $storeId => $store) {
61
+ $msg = "";
62
+ $ab = Mage::getModel("listrak/abandonedcart_api");
63
+ $cl = Mage::getModel("listrak/click_api");
64
+ $l = Mage::getModel("listrak/log_api");
65
+
66
+ $msg .= "Purged " . $ab->purge($storeId, gmdate("Y-m-d H:i:s", time() - 604800)) . " abandoned carts/sessions\n";
67
+ $msg .= "Purged " . $cl->purge($storeId, gmdate("Y-m-d H:i:s", time() - 604800)) . " clicks\n";
68
+ $msg .= "Purged " . $l->purge($storeId, gmdate("Y-m-d H:i:s", time() - 604800)) . " log entries";
69
+ Mage::getModel("listrak/log")->addMessage($msg, $storeId);
70
+ }
71
+ }
72
+ }
73
+ catch(Exception $ex) {
74
+ Mage::getModel("listrak/log")->addException($ex);
75
+ }
76
+
77
+ return $this;
78
+ }
79
+ }
app/code/community/Listrak/Remarketing/Model/Session.php ADDED
@@ -0,0 +1,69 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Session extends Mage_Core_Model_Abstract {
6
+
7
+ public function _construct()
8
+ {
9
+ parent::_construct();
10
+ $this->_init('listrak/session');
11
+ }
12
+
13
+ public function init() {
14
+ $ltksid = Mage::getModel('core/cookie')->get('ltksid');
15
+ $cust_session = Mage::getSingleton("customer/session");
16
+
17
+ if(!empty($ltksid)) {
18
+ $this->setSessionId($ltksid);
19
+ $this->getResource()->loadBySessionId($this);
20
+ }
21
+
22
+ if(!$this->getId()) {
23
+ $this->setSessionId(Mage::helper('remarketing')->gen_uuid());
24
+ $this->setCreatedAt(gmdate('Y-m-d H:i:s'));
25
+ $this->setIsNew(true);
26
+ Mage::getModel('core/cookie')->set('ltksid', $this->getSessionId(), TRUE, NULL, NULL, NULL, FALSE);
27
+ }
28
+
29
+ if($cust_session->isLoggedIn()) {
30
+ $this->setCustomerId($cust_session->getId());
31
+ }
32
+
33
+ $quoteId = Mage::helper('checkout/cart')->getQuote()->getId();
34
+
35
+ if($quoteId)
36
+ $this->setQuoteId($quoteId);
37
+
38
+ $this->setStoreId(Mage::app()->getStore()->getStoreId());
39
+ $this->setUpdatedAt(gmdate('Y-m-d H:i:s'));
40
+
41
+ if(strlen($this->getIps()) > 0) {
42
+ if(strpos($this->getIps(), $_SERVER["REMOTE_ADDR"]) === FALSE)
43
+ $this->setIps($this->getIps() . "," . $_SERVER["REMOTE_ADDR"]);
44
+ }
45
+ else {
46
+ $this->setIps($_SERVER["REMOTE_ADDR"]);
47
+ }
48
+
49
+ $this->save();
50
+
51
+ $cs = Mage::getSingleton('core/session');
52
+
53
+ if($cs->getIsListrakOrderMade()) {
54
+ Mage::getModel('core/cookie')->delete('ltksid');
55
+ $cs->setIsListrakOrderMade(false);
56
+ }
57
+
58
+ return $this;
59
+ }
60
+
61
+ public function loadEmails() {
62
+ $this->getResource()->loadEmails($this);
63
+ }
64
+
65
+ public function delete() {
66
+ $del = $this->getResource()->deleteEmails($this->getId());
67
+ parent::delete();
68
+ }
69
+ }
app/code/community/Listrak/Remarketing/Model/Subscriber.php ADDED
@@ -0,0 +1,22 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Subscriber extends Mage_Newsletter_Model_Subscriber {
6
+
7
+ public function sendConfirmationSuccessEmail() {
8
+ if(!Mage::getStoreConfig('remarketing/subscription/signup_success_email')) {
9
+ return $this;
10
+ }
11
+
12
+ return parent::sendConfirmationSuccessEmail();
13
+ }
14
+
15
+ public function sendUnsubscriptionEmail() {
16
+ if(!Mage::getStoreConfig('remarketing/subscription/unsubscribe_email')) {
17
+ return $this;
18
+ }
19
+
20
+ return parent::sendUnsubscriptionEmail();
21
+ }
22
+ }
app/code/community/Listrak/Remarketing/Model/Subscriberupdate.php ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Model_Subscriberupdate extends Mage_Core_Model_Abstract
6
+ {
7
+ public function _construct()
8
+ {
9
+ parent::_construct();
10
+ $this->_init('listrak/subscriberupdate');
11
+ }
12
+ }
app/code/community/Listrak/Remarketing/controllers/Adminhtml/AbandonedcartreportController.php ADDED
@@ -0,0 +1,35 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Adminhtml_AbandonedcartreportController extends Mage_Adminhtml_Controller_Action
6
+ {
7
+ protected function _initAction()
8
+ {
9
+ $this->loadLayout()
10
+ ->_setActiveMenu('listrak_menu');
11
+ return $this;
12
+ }
13
+
14
+ public function indexAction() {
15
+ try {
16
+ $this->_initAction();
17
+ $this->_addContent($this->getLayout()->createBlock('remarketing/adminhtml_abandonedcartreport'));
18
+ $this->renderLayout();
19
+ } catch(Exception $e) {
20
+ Mage::getSingleton('adminhtml/session')->addError($e->getMessage());
21
+ Mage::getSingleton('adminhtml/session')->setEmailCaptureData($this->getRequest()->getPost());
22
+ $this->_redirect('adminhtml/dashboard');
23
+ return;
24
+ }
25
+
26
+ }
27
+
28
+ public function gridAction()
29
+ {
30
+ $this->loadLayout();
31
+ $this->getResponse()->setBody(
32
+ $this->getLayout()->createBlock('importedit/adminhtml_abandonedcartreport_grid')->toHtml()
33
+ );
34
+ }
35
+ }
app/code/community/Listrak/Remarketing/controllers/Adminhtml/EmailcaptureController.php ADDED
@@ -0,0 +1,125 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_Adminhtml_EmailCaptureController extends Mage_Adminhtml_Controller_Action
6
+ {
7
+
8
+ protected function _initAction()
9
+ {
10
+ $this->loadLayout()
11
+ ->_setActiveMenu('emailcapture')
12
+ ->_addBreadcrumb(Mage::helper('adminhtml')->__('Fields Manager'), Mage::helper('adminhtml')->__('Field Manager'));
13
+ return $this;
14
+ }
15
+
16
+ public function indexAction() {
17
+ try {
18
+ $this->_initAction();
19
+ $this->_addContent($this->getLayout()->createBlock('remarketing/adminhtml_emailcapture'));
20
+ $this->renderLayout();
21
+ } catch(Exception $e) {
22
+ Mage::getSingleton('adminhtml/session')->addError($e->getMessage());
23
+ Mage::getSingleton('adminhtml/session')->setEmailCaptureData($this->getRequest()->getPost());
24
+ $this->_redirect('adminhtml/dashboard');
25
+ return;
26
+ }
27
+
28
+ }
29
+
30
+ public function editAction()
31
+ {
32
+ try {
33
+ $emailcaptureId = $this->getRequest()->getParam('id');
34
+ $emailcaptureModel = Mage::getModel('listrak/emailcapture')->load($emailcaptureId);
35
+
36
+ if ($emailcaptureModel->getId() || $emailcaptureId == 0) {
37
+
38
+ Mage::register('emailcapture_data', $emailcaptureModel);
39
+
40
+ $this->loadLayout();
41
+ $this->_setActiveMenu('emailcapture');
42
+
43
+ $this->_addBreadcrumb(Mage::helper('adminhtml')->__('Item Manager'), Mage::helper('adminhtml')->__('Item Manager'));
44
+ $this->_addBreadcrumb(Mage::helper('adminhtml')->__('Item News'), Mage::helper('adminhtml')->__('Item News'));
45
+
46
+ $this->getLayout()->getBlock('head')->setCanLoadExtJs(true);
47
+
48
+ $this->_addContent($this->getLayout()->createBlock('remarketing/adminhtml_emailcapture_edit'))
49
+ ->_addLeft($this->getLayout()->createBlock('remarketing/adminhtml_emailcapture_edit_tabs'));
50
+
51
+ $this->renderLayout();
52
+ } else {
53
+ Mage::getSingleton('adminhtml/session')->addError(Mage::helper('remarketing')->__('Item does not exist'));
54
+ $this->_redirect('*/*/');
55
+ }
56
+ } catch (Exception $e) {
57
+ Mage::getSingleton('adminhtml/session')->addError($e->getMessage());
58
+ Mage::getSingleton('adminhtml/session')->setEmailCaptureData($this->getRequest()->getPost());
59
+ $this->_redirect('*/*/index', array('id' => $this->getRequest()->getParam('id')));
60
+ return;
61
+ }
62
+ }
63
+
64
+ public function newAction()
65
+ {
66
+ $this->_forward('edit');
67
+ }
68
+
69
+ public function saveAction()
70
+ {
71
+ if ( $this->getRequest()->getPost() ) {
72
+ try {
73
+ $postData = $this->getRequest()->getPost();
74
+ $emailcaptureModel = Mage::getModel('listrak/emailcapture');
75
+
76
+ $emailcaptureModel->setId($this->getRequest()->getParam('id'))
77
+ ->setPage($postData['page'])
78
+ ->setFieldId($postData['field_id'])
79
+ ->save();
80
+
81
+ Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('adminhtml')->__('Item was successfully saved'));
82
+ Mage::getSingleton('adminhtml/session')->setEmailCaptureData(false);
83
+
84
+ $this->_redirect('*/*/');
85
+ return;
86
+ } catch (Exception $e) {
87
+ Mage::getSingleton('adminhtml/session')->addError($e->getMessage());
88
+ Mage::getSingleton('adminhtml/session')->setEmailCaptureData($this->getRequest()->getPost());
89
+ $this->_redirect('*/*/edit', array('id' => $this->getRequest()->getParam('id')));
90
+ return;
91
+ }
92
+ }
93
+ $this->_redirect('*/*/');
94
+ }
95
+
96
+ public function deleteAction()
97
+ {
98
+ if( $this->getRequest()->getParam('id') > 0 ) {
99
+ try {
100
+ $emailcaptureModel = Mage::getModel('listrak/emailcapture');
101
+
102
+ $emailcaptureModel->setId($this->getRequest()->getParam('id'))
103
+ ->delete();
104
+
105
+ Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('adminhtml')->__('Item was successfully deleted'));
106
+ $this->_redirect('*/*/');
107
+ } catch (Exception $e) {
108
+ Mage::getSingleton('adminhtml/session')->addError($e->getMessage());
109
+ $this->_redirect('*/*/edit', array('id' => $this->getRequest()->getParam('id')));
110
+ }
111
+ }
112
+ $this->_redirect('*/*/');
113
+ }
114
+ /**
115
+ * Product grid for AJAX request.
116
+ * Sort and filter result for example.
117
+ */
118
+ public function gridAction()
119
+ {
120
+ $this->loadLayout();
121
+ $this->getResponse()->setBody(
122
+ $this->getLayout()->createBlock('importedit/adminhtml_emailcapture_grid')->toHtml()
123
+ );
124
+ }
125
+ }
app/code/community/Listrak/Remarketing/controllers/CartController.php ADDED
@@ -0,0 +1,60 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_CartController extends Mage_Core_Controller_Front_Action
6
+ {
7
+ public function indexAction() {
8
+ return $this;
9
+ }
10
+
11
+ public function reloadAction() {
12
+ $session = Mage::getSingleton('core/session');
13
+ $checkout = Mage::getSingleton('checkout/session');
14
+ $cust = Mage::getSingleton('customer/session');
15
+ $ltksid = $this->getRequest()->getParam('ltksid');
16
+ $ltksession = Mage::getModel("listrak/session");
17
+ $ltksidcookie = Mage::getModel('core/cookie')->get('ltksid');
18
+
19
+ try {
20
+ if(!$ltksid) {
21
+ return $this->_redirect('checkout/cart/');
22
+ }
23
+
24
+ if(!empty($ltksidcookie) && $ltksidcookie == $ltksid) {
25
+ return $this->_redirect('checkout/cart/');
26
+ }
27
+
28
+ $ltksession->setSessionId($ltksid);
29
+ $ltksession->getResource()->loadBySessionId($ltksession);
30
+
31
+ if(!$ltksession->getId()) {
32
+ die("");
33
+ }
34
+
35
+ if(!$ltksession->getQuoteId()) {
36
+ die("");
37
+ }
38
+
39
+ if($cust && $cust->isLoggedIn()) {
40
+ if($cust->getId() === $ltksession->getCustomerId()) {
41
+ return $this->_redirect('checkout/cart/');
42
+ }
43
+ }
44
+
45
+ $quote = Mage::getModel('sales/quote')->load($ltksession->getQuoteId());
46
+
47
+ if($quote->getId() && $quote->getIsActive()) {
48
+ $checkout->setQuoteId($ltksession->getQuoteId());
49
+ }
50
+ else {
51
+ }
52
+ }
53
+ catch(Exception $ex) {
54
+ Mage::getModel("listrak/log")->addException($e);
55
+ }
56
+
57
+ return $this->_redirect('checkout/cart/');
58
+ }
59
+ }
60
+
app/code/community/Listrak/Remarketing/controllers/ConfigController.php ADDED
@@ -0,0 +1,30 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_ConfigController extends Mage_Core_Controller_Front_Action
6
+ {
7
+ public function indexAction() {
8
+ return $this;
9
+ }
10
+
11
+ public function registerAction() {
12
+ $reg = Mage::getStoreConfig('remarketing/config/account_created');
13
+
14
+ if(!$reg) {
15
+ $gv = array();
16
+ $gv['config']['fields']['account_created']['value'] = '1';
17
+ Mage::getModel('adminhtml/config_data')
18
+ ->setSection('remarketing')
19
+ ->setWebsite(null)
20
+ ->setStore(null)
21
+ ->setGroups($gv)
22
+ ->save();
23
+ Mage::getConfig()->cleanCache();
24
+ }
25
+ }
26
+
27
+ public function checkAction() {
28
+ die(Mage::getStoreConfig('remarketing/config/account_created'));
29
+ }
30
+ }
app/code/community/Listrak/Remarketing/controllers/EmailController.php ADDED
@@ -0,0 +1,55 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_EmailController extends Mage_Core_Controller_Front_Action
6
+ {
7
+ public function indexAction() {
8
+ try {
9
+ $email = $this->getRequest()->getParam('email');
10
+
11
+ if(!Zend_Validate::is($email, 'EmailAddress')) {
12
+ die("");
13
+ }
14
+
15
+ $emailcaptureId = $this->getRequest()->getParam('cid');
16
+ $session = Mage::getSingleton('listrak/session')->init();
17
+
18
+ if($session->getIsNew() === true) {
19
+ die("");
20
+ }
21
+
22
+ $emailcapture = Mage::getModel('listrak/emailcapture')->load($emailcaptureId);
23
+
24
+ if($emailcapture->getId()) {
25
+ $session->getResource()->insertEmail($session, $email, $emailcaptureId);
26
+
27
+ $result = array('status' => true);
28
+ } else {
29
+ $result = array('status' => false);
30
+ }
31
+
32
+ header('Content-type: application/json');
33
+ die(json_encode($result));
34
+ } catch (Exception $e) {
35
+ Mage::getModel("listrak/log")->addException($e);
36
+ die("");
37
+ }
38
+ }
39
+
40
+ public function fsidAction() {
41
+ $email = $this->getRequest()->getParam('email');
42
+
43
+ if(!Zend_Validate::is($email, 'EmailAddress')) {
44
+ die("invalid");
45
+ }
46
+
47
+ $emailcaptureId = $this->getRequest()->getParam('cid');
48
+ $session = Mage::getModel('listrak/session');
49
+ $session->setSessionId($this->getRequest()->getParam('ltksid'));
50
+ $session->getResource()->loadBySessionId($session);
51
+ $session->getResource()->insertEmail($session, $email, $emailcaptureId);
52
+
53
+ die(json_encode(array('status' => true)));
54
+ }
55
+ }
app/code/community/Listrak/Remarketing/controllers/TroubleshootingController.php ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ class Listrak_Remarketing_TroubleshootingController extends Mage_Core_Controller_Front_Action
6
+ {
7
+ public function indexAction() {
8
+
9
+ }
10
+ }
app/code/community/Listrak/Remarketing/etc/adminhtml.xml ADDED
@@ -0,0 +1,60 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0"?>
2
+ <!--
3
+ /**
4
+ * Listrak Remarketing Magento Extension Ver. 1.0.0 - © 2011 Listrak, Inc.
5
+ */
6
+ -->
7
+ <config>
8
+ <menu>
9
+ <remarketing module="remarketing">
10
+ <title>Listrak</title>
11
+ <sort_order>71</sort_order>
12
+ <children>
13
+ <emailcapture module="remarketing">
14
+ <title>Email Capture</title>
15
+ <sort_order>0</sort_order>
16
+ <action>remarketing/adminhtml_emailcapture</action>
17
+ </emailcapture>
18
+ <abandonedcartreport module="remarketing">
19
+ <title>Abandoned Carts</title>
20
+ <sort_order>0</sort_order>
21
+ <action>remarketing/adminhtml_abandonedcartreport</action>
22
+ </abandonedcartreport>
23
+ </children>
24
+ </remarketing>
25
+ </menu>
26
+ <acl>
27
+ <resources>
28
+ <admin>
29
+ <children>
30
+ <remarketing translate="title" module="remarketing">
31
+ <title>Listrak Remarketing</title>
32
+ <sort_order>200</sort_order>
33
+ <children>
34
+ <emailcapture translate="title">
35
+ <title>Email Capture</title>
36
+ <sort_order>200</sort_order>
37
+ </emailcapture>
38
+ <abandonedcartreport translate="title">
39
+ <title>Abandoned Carts</title>
40
+ <sort_order>200</sort_order>
41
+ </abandonedcartreport>
42
+ </children>
43
+ </remarketing>
44
+ <system>
45
+ <children>
46
+ <config>
47
+ <children>
48
+ <remarketing translate="title">
49
+ <title>Listrak Newsletter</title>
50
+ <sort_order>40</sort_order>
51
+ </remarketing>
52
+ </children>
53
+ </config>
54
+ </children>
55
+ </system>
56
+ </children>
57
+ </admin>
58
+ </resources>
59
+ </acl>
60
+ </config>
app/code/community/Listrak/Remarketing/etc/api.xml ADDED
@@ -0,0 +1,152 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0"?>
2
+ <!--
3
+ /**
4
+ * Listrak Remarketing Magento Extension Ver. 1.0.0 - © 2011 Listrak, Inc.
5
+ */
6
+ -->
7
+ <config>
8
+ <api>
9
+ <resources>
10
+ <listrak_remarketing_abandonedcart translate="title" module="listrak_remarketing">
11
+ <title>Listrak Remarketing API</title>
12
+ <model>listrak/abandonedcart_api</model>
13
+ <methods>
14
+ <list translate="title" module="listrak_remarketing">
15
+ <title>Get Abandoned Carts</title>
16
+ <method>items</method>
17
+ </list>
18
+ <purge translate="title" module="listrak_remarketing">
19
+ <title>Purge old data</title>
20
+ <method>purge</method>
21
+ </purge>
22
+ </methods>
23
+ </listrak_remarketing_abandonedcart>
24
+ <listrak_remarketing_click translate="title" module="listrak_remarketing">
25
+ <title>Listrak Remarketing API</title>
26
+ <model>listrak/click_api</model>
27
+ <methods>
28
+ <list translate="title" module="listrak_remarketing">
29
+ <title>Get clicks</title>
30
+ <method>items</method>
31
+ </list>
32
+ <purge translate="title" module="listrak_remarketing">
33
+ <title>Purge old data</title>
34
+ <method>purge</method>
35
+ </purge>
36
+ </methods>
37
+ </listrak_remarketing_click>
38
+ <listrak_remarketing_log translate="title" module="listrak_remarketing">
39
+ <title>Listrak Remarketing API</title>
40
+ <model>listrak/log_api</model>
41
+ <methods>
42
+ <list translate="title" module="listrak_remarketing">
43
+ <title>Get log entries</title>
44
+ <method>items</method>
45
+ </list>
46
+ <purge translate="title" module="listrak_remarketing">
47
+ <title>Purge old data</title>
48
+ <method>purge</method>
49
+ </purge>
50
+ <toggle translate="title" module="listrak_remarketing">
51
+ <title>toggle logging</title>
52
+ <method>toggle</method>
53
+ </toggle>
54
+ </methods>
55
+ </listrak_remarketing_log>
56
+ <listrak_remarketing_order translate="title" module="listrak_remarketing">
57
+ <title>Listrak Remarketing API</title>
58
+ <model>listrak/apiextension_api</model>
59
+ <methods>
60
+ <list translate="title" module="listrak_remarketing">
61
+ <title>Get orders</title>
62
+ <method>orders</method>
63
+ </list>
64
+ </methods>
65
+ </listrak_remarketing_order>
66
+ <listrak_remarketing_order_status translate="title" module="listrak_remarketing">
67
+ <title>Listrak Remarketing API</title>
68
+ <model>listrak/apiextension_api</model>
69
+ <methods>
70
+ <list translate="title" module="listrak_remarketing">
71
+ <title>Get order status changes</title>
72
+ <method>orderStatus</method>
73
+ </list>
74
+ </methods>
75
+ </listrak_remarketing_order_status>
76
+ <listrak_remarketing_product translate="title" module="listrak_remarketing">
77
+ <title>Listrak Remarketing API</title>
78
+ <model>listrak/apiextension_api</model>
79
+ <methods>
80
+ <list translate="title" module="listrak_remarketing">
81
+ <title>Get products</title>
82
+ <method>products</method>
83
+ </list>
84
+ </methods>
85
+ </listrak_remarketing_product>
86
+ <listrak_remarketing_subscriber translate="title" module="listrak_remarketing">
87
+ <title>Listrak Remarketing API</title>
88
+ <model>listrak/apiextension_api</model>
89
+ <methods>
90
+ <list translate="title" module="listrak_remarketing">
91
+ <title>Get subscribers and unsubscribers</title>
92
+ <method>subscribers</method>
93
+ </list>
94
+ <purge translate="title" module="listrak_remarketing">
95
+ <title>Purge old data</title>
96
+ <method>subscribersPurge</method>
97
+ </purge>
98
+ </methods>
99
+ </listrak_remarketing_subscriber>
100
+ <listrak_remarketing_customer translate="title" module="listrak_remarketing">
101
+ <title>Listrak Remarketing API</title>
102
+ <model>listrak/apiextension_api</model>
103
+ <methods>
104
+ <list translate="title" module="listrak_remarketing">
105
+ <title>Get customers</title>
106
+ <method>customers</method>
107
+ </list>
108
+ </methods>
109
+ </listrak_remarketing_customer>
110
+ <listrak_remarketing_info translate="title" module="listrak_remarketing">
111
+ <title>Listrak Remarketing API</title>
112
+ <model>listrak/apiextension_api</model>
113
+ <methods>
114
+ <list translate="title" module="listrak_remarketing">
115
+ <title>Get info</title>
116
+ <method>info</method>
117
+ </list>
118
+ </methods>
119
+ </listrak_remarketing_info>
120
+ </resources>
121
+ <resources_alias>
122
+ <abandonedcart>listrak_remarketing_abandonedcart</abandonedcart>
123
+ <click>listrak_remarketing_click</click>
124
+ <log>listrak_remarketing_log</log>
125
+ <listrakorder>listrak_remarketing_order</listrakorder>
126
+ <listrakorderstatus>listrak_remarketing_order_status</listrakorderstatus>
127
+ <listrakproduct>listrak_remarketing_product</listrakproduct>
128
+ <listraksubscriber>listrak_remarketing_subscriber</listraksubscriber>
129
+ <listrakcustomer>listrak_remarketing_customer</listrakcustomer>
130
+ <listrakinfo>listrak_remarketing_info</listrakinfo>
131
+ </resources_alias>
132
+ <v2>
133
+ <resources_function_prefix>
134
+ <abandonedcart>listrakRemarketingAbandonedCart</abandonedcart>
135
+ <click>listrakRemarketingClick</click>
136
+ <log>listrakRemarketingLog</log>
137
+ <listrakorder>listrakRemarketingOrder</listrakorder>
138
+ <listrakorderstatus>listrakRemarketingOrderStatus</listrakorderstatus>
139
+ <listrakproduct>listrakRemarketingProduct</listrakproduct>
140
+ <listraksubscriber>listrakRemarketingSubscriber</listraksubscriber>
141
+ <listrakcustomer>listrakRemarketingCustomer</listrakcustomer>
142
+ <listrakinfo>listrakRemarketingInfo</listrakinfo>
143
+ </resources_function_prefix>
144
+ </v2>
145
+ <faults>
146
+ <incorrect_date>
147
+ <code>12</code>
148
+ <message>INCORRECT DATE FORMAT [YYYY-MM-DD HH:MM:SS]</message>
149
+ </incorrect_date>
150
+ </faults>
151
+ </api>
152
+ </config>
app/code/community/Listrak/Remarketing/etc/config.xml ADDED
@@ -0,0 +1,168 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <!--
3
+ /**
4
+ * Listrak Remarketing Magento Extension Ver. 1.0.0 - © 2011 Listrak, Inc.
5
+ */
6
+ -->
7
+ <config>
8
+ <modules>
9
+ <Listrak_Remarketing>
10
+ <version>1.0.3</version>
11
+ </Listrak_Remarketing>
12
+ </modules>
13
+ <frontend>
14
+ <routers>
15
+ <listrak_remarketing>
16
+ <use>standard</use>
17
+ <args>
18
+ <module>Listrak_Remarketing</module>
19
+ <frontName>remarketing</frontName>
20
+ </args>
21
+ </listrak_remarketing>
22
+ </routers>
23
+ <layout>
24
+ <updates>
25
+ <remarketing>
26
+ <file>remarketing.xml</file>
27
+ </remarketing>
28
+ </updates>
29
+ </layout>
30
+ <events>
31
+ <controller_action_layout_render_before>
32
+ <observers>
33
+ <listrak_remarketing_observer>
34
+ <type>singleton</type>
35
+ <class>Listrak_Remarketing_Model_Observer</class>
36
+ <method>sessionInit</method>
37
+ </listrak_remarketing_observer>
38
+ </observers>
39
+ </controller_action_layout_render_before>
40
+ <sales_order_place_after>
41
+ <observers>
42
+ <listrak_remarketing_observer>
43
+ <type>singleton</type>
44
+ <class>Listrak_Remarketing_Model_Observer</class>
45
+ <method>orderPlaced</method>
46
+ </listrak_remarketing_observer>
47
+ </observers>
48
+ </sales_order_place_after>
49
+ <newsletter_subscriber_save_after>
50
+ <observers>
51
+ <listrak_remarketing_observer>
52
+ <type>singleton</type>
53
+ <class>Listrak_Remarketing_Model_Observer</class>
54
+ <method>subscriberSaved</method>
55
+ </listrak_remarketing_observer>
56
+ </observers>
57
+ </newsletter_subscriber_save_after>
58
+ </events>
59
+ </frontend>
60
+ <global>
61
+ <models>
62
+ <listrak>
63
+ <class>Listrak_Remarketing_Model</class>
64
+ <resourceModel>listrak_mysql4</resourceModel>
65
+ </listrak>
66
+ <listrak_mysql4>
67
+ <class>Listrak_Remarketing_Model_Mysql4</class>
68
+ <entities>
69
+ <click>
70
+ <table>listrak_remarketing_click</table>
71
+ </click>
72
+ <log>
73
+ <table>listrak_remarketing_log</table>
74
+ </log>
75
+ <session>
76
+ <table>listrak_remarketing_session</table>
77
+ </session>
78
+ <session_email>
79
+ <table>listrak_remarketing_session_email</table>
80
+ </session_email>
81
+ <emailcapture>
82
+ <table>listrak_remarketing_emailcapture</table>
83
+ </emailcapture>
84
+ <subscriber_update>
85
+ <table>listrak_remarketing_subscriber_update</table>
86
+ </subscriber_update>
87
+ </entities>
88
+ </listrak_mysql4>
89
+ <newsletter>
90
+ <rewrite>
91
+ <subscriber>Listrak_Remarketing_Model_Subscriber</subscriber>
92
+ </rewrite>
93
+ </newsletter>
94
+ </models>
95
+ <resources>
96
+ <listrak_remarketing_setup>
97
+ <setup>
98
+ <module>Listrak_Remarketing</module>
99
+ </setup>
100
+ <connection>
101
+ <use>core_setup</use>
102
+ </connection>
103
+ </listrak_remarketing_setup>
104
+ <listrak_write>
105
+ <connection>
106
+ <use>core_write</use>
107
+ </connection>
108
+ </listrak_write>
109
+ <listrak_read>
110
+ <connection>
111
+ <use>core_read</use>
112
+ </connection>
113
+ </listrak_read>
114
+ </resources>
115
+ <helpers>
116
+ <remarketing>
117
+ <class>Listrak_Remarketing_Helper</class>
118
+ </remarketing>
119
+ </helpers>
120
+ <blocks>
121
+ <remarketing>
122
+ <class>Listrak_Remarketing_Block</class>
123
+ </remarketing>
124
+ </blocks>
125
+ </global>
126
+ <admin>
127
+ <routers>
128
+ <remarketing>
129
+ <use>admin</use>
130
+ <args>
131
+ <module>Listrak_Remarketing</module>
132
+ <frontName>remarketing</frontName>
133
+ </args>
134
+ </remarketing>
135
+ </routers>
136
+ </admin>
137
+ <adminhtml>
138
+ <layout>
139
+ <updates>
140
+ <remarketing>
141
+ <file>remarketing.xml</file>
142
+ </remarketing>
143
+ </updates>
144
+ </layout>
145
+ <events>
146
+ <admin_user_load_before>
147
+ <observers>
148
+ <listrak_remarketing_observer>
149
+ <type>singleton</type>
150
+ <class>Listrak_Remarketing_Model_Observer</class>
151
+ <method>adminPageLoad</method>
152
+ </listrak_remarketing_observer>
153
+ </observers>
154
+ </admin_user_load_before>
155
+ </events>
156
+ </adminhtml>
157
+ <default>
158
+ <remarketing>
159
+ <subscription>
160
+ <signup_success_email>0</signup_success_email>
161
+ <unsubscribe_email>0</unsubscribe_email>
162
+ </subscription>
163
+ <abandonedcarts>
164
+ <abandoned_cart_report_timeout>60</abandoned_cart_report_timeout>
165
+ </abandonedcarts>
166
+ </remarketing>
167
+ </default>
168
+ </config>
app/code/community/Listrak/Remarketing/etc/system.xml ADDED
@@ -0,0 +1,67 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0"?>
2
+ <!--
3
+ /**
4
+ * Listrak Remarketing Magento Extension Ver. 1.0.0 - © 2011 Listrak, Inc.
5
+ */
6
+ -->
7
+ <config>
8
+ <sections>
9
+ <remarketing translate="label" module="remarketing">
10
+ <label>Listrak</label>
11
+ <tab>customer</tab>
12
+ <frontend_type>text</frontend_type>
13
+ <sort_order>100</sort_order>
14
+ <show_in_default>1</show_in_default>
15
+ <show_in_website>1</show_in_website>
16
+ <show_in_store>1</show_in_store>
17
+ <groups>
18
+ <subscription translate="label">
19
+ <label>Newsletter Options</label>
20
+ <frontend_type>text</frontend_type>
21
+ <sort_order>1</sort_order>
22
+ <show_in_default>1</show_in_default>
23
+ <show_in_website>1</show_in_website>
24
+ <show_in_store>1</show_in_store>
25
+ <fields>
26
+ <signup_success_email translate="label">
27
+ <label>Signup Success Email</label>
28
+ <frontend_type>select</frontend_type>
29
+ <source_model>adminhtml/system_config_source_enabledisable</source_model>
30
+ <sort_order>2</sort_order>
31
+ <show_in_default>1</show_in_default>
32
+ <show_in_website>1</show_in_website>
33
+ <show_in_store>1</show_in_store>
34
+ </signup_success_email>
35
+ <unsubscribe_email translate="label">
36
+ <label>Unsubscribe Email</label>
37
+ <frontend_type>select</frontend_type>
38
+ <source_model>adminhtml/system_config_source_enabledisable</source_model>
39
+ <sort_order>3</sort_order>
40
+ <show_in_default>1</show_in_default>
41
+ <show_in_website>1</show_in_website>
42
+ <show_in_store>1</show_in_store>
43
+ </unsubscribe_email>
44
+ </fields>
45
+ </subscription>
46
+ <abandonedcarts translate="label">
47
+ <label>Abandoned Carts</label>
48
+ <frontend_type>text</frontend_type>
49
+ <sort_order>2</sort_order>
50
+ <show_in_default>1</show_in_default>
51
+ <show_in_website>1</show_in_website>
52
+ <show_in_store>1</show_in_store>
53
+ <fields>
54
+ <abandoned_cart_report_timeout translate="label">
55
+ <label>Abandoned Cart Report Timeout</label>
56
+ <frontend_type>text</frontend_type>
57
+ <sort_order>2</sort_order>
58
+ <show_in_default>1</show_in_default>
59
+ <show_in_website>1</show_in_website>
60
+ <show_in_store>1</show_in_store>
61
+ </abandoned_cart_report_timeout>
62
+ </fields>
63
+ </abandonedcarts>
64
+ </groups>
65
+ </remarketing>
66
+ </sections>
67
+ </config>
app/code/community/Listrak/Remarketing/etc/wsdl.xml ADDED
@@ -0,0 +1,624 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <!--
3
+ /**
4
+ * Listrak Remarketing Magento Extension Ver. 1.0.0 - © 2011 Listrak, Inc.
5
+ */
6
+ -->
7
+ <definitions xmlns:typens="urn:{{var wsdl.name}}" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
8
+ xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns="http://schemas.xmlsoap.org/wsdl/"
9
+ name="{{var wsdl.name}}" targetNamespace="urn:{{var wsdl.name}}">
10
+ <types>
11
+ <schema xmlns="http://www.w3.org/2001/XMLSchema" targetNamespace="urn:Magento">
12
+ <import namespace="http://schemas.xmlsoap.org/soap/encoding/" schemaLocation="http://schemas.xmlsoap.org/soap/encoding/" />
13
+ <complexType name="ArrayOfString">
14
+ <complexContent>
15
+ <restriction base="soapenc:Array">
16
+ <attribute ref="soapenc:arrayType" wsdl:arrayType="xsd:string[]"/>
17
+ </restriction>
18
+ </complexContent>
19
+ </complexType>
20
+ <!-- session -->
21
+ <complexType name="ListrakRemarketingSessionEntity">
22
+ <all>
23
+ <element name="session_id" type="xsd:string" minOccurs="0"/>
24
+ <element name="store_id" type="xsd:string" minOccurs="0"/>
25
+ <element name="created_at" type="xsd:string" minOccurs="0"/>
26
+ <element name="updated_at" type="xsd:string" minOccurs="0"/>
27
+ <element name="quote_id" type="xsd:string" minOccurs="0"/>
28
+ <element name="customer" type="typens:ListrakRemarketingCustomerEntity" minOccurs="0"/>
29
+ <element name="emails" type="typens:ArrayOfListrakRemarketingSessionEmail" minOccurs="0"/>
30
+ <element name="clicks" type="typens:ArrayOfListrakRemarketingClick" minOccurs="0"/>
31
+ </all>
32
+ </complexType>
33
+ <complexType name="ListrakRemarketingSessionEmailEntity">
34
+ <all>
35
+ <element name="email" type="xsd:string" minOccurs="0"/>
36
+ <element name="created_at" type="xsd:string" minOccurs="0"/>
37
+ <element name="page" type="xsd:string" minOccurs="0"/>
38
+ <element name="field_id" type="xsd:string" minOccurs="0"/>
39
+ </all>
40
+ </complexType>
41
+ <complexType name="ArrayOfListrakRemarketingSessionEmail">
42
+ <complexContent>
43
+ <restriction base="soapenc:Array">
44
+ <attribute ref="soapenc:arrayType" wsdl:arrayType="typens:ListrakRemarketingSessionEmailEntity[]"/>
45
+ </restriction>
46
+ </complexContent>
47
+ </complexType>
48
+
49
+ <!-- abandoned cart -->
50
+ <complexType name="ListrakRemarketingAbandonedCartEntity">
51
+ <all>
52
+ <element name="store_id" type="xsd:string" minOccurs="0"/>
53
+ <element name="session" type="typens:ListrakRemarketingSessionEntity" minOccurs="0"/>
54
+ <element name="products" type="typens:ArrayOfListrakRemarketingAbandonedCartProduct" minOccurs="0"/>
55
+ </all>
56
+ </complexType>
57
+ <complexType name="ArrayOfListrakRemarketingAbandonedCart">
58
+ <complexContent>
59
+ <restriction base="soapenc:Array">
60
+ <attribute ref="soapenc:arrayType" wsdl:arrayType="typens:ListrakRemarketingAbandonedCartEntity[]"/>
61
+ </restriction>
62
+ </complexContent>
63
+ </complexType>
64
+ <complexType name="ListrakRemarketingAbandonedCartProductEntity">
65
+ <all>
66
+ <element name="entity_id" type="xsd:string" minOccurs="0"/>
67
+ <element name="sku" type="xsd:string" minOccurs="0"/>
68
+ <element name="name" type="xsd:string" minOccurs="0"/>
69
+ <element name="price" type="xsd:string" minOccurs="0"/>
70
+ <element name="special_price" type="xsd:string" minOccurs="0"/>
71
+ <element name="special_from_date" type="xsd:string" minOccurs="0"/>
72
+ <element name="special_to_date" type="xsd:string" minOccurs="0"/>
73
+ <element name="cost" type="xsd:string" minOccurs="0"/>
74
+ <element name="description" type="xsd:string" minOccurs="0"/>
75
+ <element name="short_description" type="xsd:string" minOccurs="0"/>
76
+ <element name="weight" type="xsd:string" minOccurs="0"/>
77
+ <element name="url_key" type="xsd:string" minOccurs="0"/>
78
+ <element name="url_path" type="xsd:string" minOccurs="0"/>
79
+ <element name="image" type="xsd:string" minOccurs="0"/>
80
+ <element name="small_image" type="xsd:string" minOccurs="0"/>
81
+ <element name="thumbnail" type="xsd:string" minOccurs="0"/>
82
+ <element name="qty" type="xsd:string" minOccurs="0"/>
83
+ </all>
84
+ </complexType>
85
+ <complexType name="ArrayOfListrakRemarketingAbandonedCartProduct">
86
+ <complexContent>
87
+ <restriction base="soapenc:Array">
88
+ <attribute ref="soapenc:arrayType" wsdl:arrayType="typens:ListrakRemarketingAbandonedCartProductEntity[]"/>
89
+ </restriction>
90
+ </complexContent>
91
+ </complexType>
92
+
93
+ <!-- product -->
94
+ <complexType name="ListrakRemarketingProductEntity">
95
+ <all>
96
+ <element name="entity_id" type="xsd:string" minOccurs="0"/>
97
+ <element name="sku" type="xsd:string" minOccurs="0"/>
98
+ <element name="name" type="xsd:string" minOccurs="0"/>
99
+ <element name="price" type="xsd:string" minOccurs="0"/>
100
+ <element name="special_price" type="xsd:string" minOccurs="0"/>
101
+ <element name="special_from_date" type="xsd:string" minOccurs="0"/>
102
+ <element name="special_to_date" type="xsd:string" minOccurs="0"/>
103
+ <element name="cost" type="xsd:string" minOccurs="0"/>
104
+ <element name="description" type="xsd:string" minOccurs="0"/>
105
+ <element name="short_description" type="xsd:string" minOccurs="0"/>
106
+ <element name="weight" type="xsd:string" minOccurs="0"/>
107
+ <element name="url_key" type="xsd:string" minOccurs="0"/>
108
+ <element name="url_path" type="xsd:string" minOccurs="0"/>
109
+ <element name="image" type="xsd:string" minOccurs="0"/>
110
+ <element name="small_image" type="xsd:string" minOccurs="0"/>
111
+ <element name="thumbnail" type="xsd:string" minOccurs="0"/>
112
+ <element name="qty" type="xsd:string" minOccurs="0"/>
113
+ </all>
114
+ </complexType>
115
+ <complexType name="ArrayOfListrakRemarketingProduct">
116
+ <complexContent>
117
+ <restriction base="soapenc:Array">
118
+ <attribute ref="soapenc:arrayType" wsdl:arrayType="typens:ListrakRemarketingProductEntity[]"/>
119
+ </restriction>
120
+ </complexContent>
121
+ </complexType>
122
+
123
+ <!-- click -->
124
+ <complexType name="ListrakRemarketingClickEntity">
125
+ <all>
126
+ <element name="store_id" type="xsd:string" minOccurs="0"/>
127
+ <element name="customer_id" type="xsd:string" minOccurs="0"/>
128
+ <element name="customer_email" type="xsd:string" minOccurs="0"/>
129
+ <element name="querystring" type="xsd:string" minOccurs="0"/>
130
+ <element name="click_date" type="xsd:string" minOccurs="0"/>
131
+ <element name="token_uid" type="xsd:string" minOccurs="0"/>
132
+ <element name="session_uid" type="xsd:string" minOccurs="0"/>
133
+ </all>
134
+ </complexType>
135
+ <complexType name="ArrayOfListrakRemarketingClick">
136
+ <complexContent>
137
+ <restriction base="soapenc:Array">
138
+ <attribute ref="soapenc:arrayType" wsdl:arrayType="typens:ListrakRemarketingClickEntity[]"/>
139
+ </restriction>
140
+ </complexContent>
141
+ </complexType>
142
+
143
+ <!-- log -->
144
+ <complexType name="ListrakRemarketingLogEntity">
145
+ <all>
146
+ <element name="store_id" type="xsd:string" minOccurs="0"/>
147
+ <element name="message" type="xsd:string" minOccurs="0"/>
148
+ <element name="date_entered" type="xsd:string" minOccurs="0"/>
149
+ <element name="log_type_id" type="xsd:string" minOccurs="0"/>
150
+ </all>
151
+ </complexType>
152
+ <complexType name="ArrayOfListrakRemarketingLog">
153
+ <complexContent>
154
+ <restriction base="soapenc:Array">
155
+ <attribute ref="soapenc:arrayType" wsdl:arrayType="typens:ListrakRemarketingLogEntity[]"/>
156
+ </restriction>
157
+ </complexContent>
158
+ </complexType>
159
+
160
+ <!-- order -->
161
+ <complexType name="ListrakRemarketingOrderEntity">
162
+ <all>
163
+ <element name="info" type="typens:ListrakRemarketingOrderInfoEntity" minOccurs="0"/>
164
+ <element name="billing_address" type="typens:ListrakRemarketingOrderAddressEntity" minOccurs="0"/>
165
+ <element name="shipping_address" type="typens:ListrakRemarketingOrderAddressEntity" minOccurs="0"/>
166
+ <element name="product" type="typens:ArrayOfListrakRemarketingProductShort" minOccurs="0"/>
167
+ <element name="session" type="typens:ListrakRemarketingSessionEntity" minOccurs="0"/>
168
+ </all>
169
+ </complexType>
170
+ <complexType name="ArrayOfListrakRemarketingOrder">
171
+ <complexContent>
172
+ <restriction base="soapenc:Array">
173
+ <attribute ref="soapenc:arrayType" wsdl:arrayType="typens:ListrakRemarketingOrderEntity[]" />
174
+ </restriction>
175
+ </complexContent>
176
+ </complexType>
177
+ <complexType name="ListrakRemarketingOrderInfoEntity">
178
+ <all>
179
+ <element name="entity_id" type="xsd:string" minOccurs="0"/>
180
+ <element name="order_id" type="xsd:string" minOccurs="0"/>
181
+ <element name="status" type="xsd:string" minOccurs="0" />
182
+ <element name="customer_firstname" type="xsd:string" minOccurs="0"/>
183
+ <element name="customer_lastname" type="xsd:string" minOccurs="0"/>
184
+ <element name="customer_email" type="xsd:string" minOccurs="0"/>
185
+ <element name="subtotal" type="xsd:string" minOccurs="0"/>
186
+ <element name="tax_amount" type="xsd:string" minOccurs="0"/>
187
+ <element name="shipping_amount" type="xsd:string" minOccurs="0"/>
188
+ <element name="grand_total" type="xsd:string" minOccurs="0"/>
189
+ <element name="billing_firstname" type="xsd:string" minOccurs="0"/>
190
+ <element name="created_at" type="xsd:string" minOccurs="0"/>
191
+ <element name="updated_at" type="xsd:string" minOccurs="0"/>
192
+ </all>
193
+ </complexType>
194
+ <complexType name="ListrakRemarketingOrderAddressEntity">
195
+ <all>
196
+ <element name="firstname" type="xsd:string" minOccurs="0"/>
197
+ <element name="lastname" type="xsd:string" minOccurs="0"/>
198
+ <element name="company" type="xsd:string" minOccurs="0"/>
199
+ <element name="street" type="xsd:string" minOccurs="0"/>
200
+ <element name="city" type="xsd:string" minOccurs="0"/>
201
+ <element name="region" type="xsd:string" minOccurs="0"/>
202
+ <element name="postcode" type="xsd:string" minOccurs="0"/>
203
+ <element name="country" type="xsd:string" minOccurs="0"/>
204
+ </all>
205
+ </complexType>
206
+ <complexType name="ListrakRemarketingProductShortEntity">
207
+ <all>
208
+ <element name="sku" type="xsd:string" minOccurs="0"/>
209
+ <element name="name" type="xsd:string" minOccurs="0"/>
210
+ <element name="price" type="xsd:string" minOccurs="0"/>
211
+ <element name="qty_ordered" type="xsd:string" minOccurs="0"/>
212
+ </all>
213
+ </complexType>
214
+ <complexType name="ArrayOfListrakRemarketingProductShort">
215
+ <complexContent>
216
+ <restriction base="soapenc:Array">
217
+ <attribute ref="soapenc:arrayType" wsdl:arrayType="typens:ListrakRemarketingProductShortEntity[]"/>
218
+ </restriction>
219
+ </complexContent>
220
+ </complexType>
221
+
222
+ <!-- order status -->
223
+ <complexType name="ListrakRemarketingOrderStatusEntity">
224
+ <all>
225
+ <element name="increment_id" type="xsd:string" minOccurs="0"/>
226
+ <element name="status" type="xsd:string" minOccurs="0" />
227
+ <element name="updated_at" type="xsd:string" minOccurs="0"/>
228
+ </all>
229
+ </complexType>
230
+ <complexType name="ArrayOfListrakRemarketingOrderStatus">
231
+ <complexContent>
232
+ <restriction base="soapenc:Array">
233
+ <attribute ref="soapenc:arrayType" wsdl:arrayType="typens:ListrakRemarketingOrderStatusEntity[]" />
234
+ </restriction>
235
+ </complexContent>
236
+ </complexType>
237
+
238
+ <!-- customer -->
239
+ <complexType name="ListrakRemarketingCustomerEntity">
240
+ <all>
241
+ <element name="entity_id" type="xsd:string" minOccurs="0"/>
242
+ <element name="firstname" type="xsd:string" minOccurs="0"/>
243
+ <element name="lastname" type="xsd:string" minOccurs="0"/>
244
+ <element name="email" type="xsd:string" minOccurs="0"/>
245
+ <element name="website_id" type="xsd:string" minOccurs="0"/>
246
+ <element name="store_id" type="xsd:string" minOccurs="0"/>
247
+ </all>
248
+ </complexType>
249
+ <complexType name="ArrayOfListrakRemarketingCustomer">
250
+ <complexContent>
251
+ <restriction base="soapenc:Array">
252
+ <attribute ref="soapenc:arrayType" wsdl:arrayType="typens:ListrakRemarketingCustomerEntity[]"/>
253
+ </restriction>
254
+ </complexContent>
255
+ </complexType>
256
+
257
+ <!-- subscriber -->
258
+ <complexType name="ListrakRemarketingSubscriberEntity">
259
+ <all>
260
+ <element name="subscriber_id" type="xsd:string" minOccurs="0"/>
261
+ <element name="store_id" type="xsd:string" minOccurs="0"/>
262
+ <element name="customer_id" type="xsd:string" minOccurs="0"/>
263
+ <element name="change_status_at" type="xsd:string" minOccurs="0"/>
264
+ <element name="subscriber_email" type="xsd:string" minOccurs="0"/>
265
+ <element name="subscriber_status" type="xsd:string" minOccurs="0"/>
266
+ <element name="updated_at" type="xsd:string" minOccurs="0"/>
267
+ </all>
268
+ </complexType>
269
+ <complexType name="ArrayOfListrakRemarketingSubscriber">
270
+ <complexContent>
271
+ <restriction base="soapenc:Array">
272
+ <attribute ref="soapenc:arrayType" wsdl:arrayType="typens:ListrakRemarketingSubscriberEntity[]"/>
273
+ </restriction>
274
+ </complexContent>
275
+ </complexType>
276
+
277
+ <complexType name="ListrakRemarketingInfoEntity">
278
+ <all>
279
+ <element name="modules" type="typens:ArrayOfString" minOccurs="0"/>
280
+ <element name="ini" type="typens:ArrayOfString" minOccurs="0"/>
281
+ <element name="subscriberClass" type="xsd:string" minOccurs="0"/>
282
+ </all>
283
+ </complexType>
284
+ </schema>
285
+ </types>
286
+ <message name="listrakRemarketingAbandonedCartListRequest">
287
+ <part name="sessionId" type="xsd:string" />
288
+ <part name="storeId" type="xsd:int" />
289
+ <part name="startDate" type="xsd:string" />
290
+ <part name="endDate" type="xsd:string" />
291
+ <part name="perPage" type="xsd:int" />
292
+ <part name="page" type="xsd:int" />
293
+ </message>
294
+ <message name="listrakRemarketingAbandonedCartListResponse">
295
+ <part name="result" type="typens:ArrayOfListrakRemarketingAbandonedCart" />
296
+ </message>
297
+ <message name="listrakRemarketingAbandonedCartPurgeRequest">
298
+ <part name="sessionId" type="xsd:string" />
299
+ <part name="storeId" type="xsd:int" />
300
+ <part name="endDate" type="xsd:string" />
301
+ </message>
302
+ <message name="listrakRemarketingAbandonedCartPurgeResponse">
303
+ <part name="result" type="xsd:string" />
304
+ </message>
305
+ <message name="listrakRemarketingClickListRequest">
306
+ <part name="sessionId" type="xsd:string" />
307
+ <part name="storeId" type="xsd:int" />
308
+ <part name="startDate" type="xsd:string" />
309
+ <part name="endDate" type="xsd:string" />
310
+ <part name="perPage" type="xsd:int" />
311
+ <part name="page" type="xsd:int" />
312
+ </message>
313
+ <message name="listrakRemarketingClickListResponse">
314
+ <part name="result" type="typens:ArrayOfListrakRemarketingClick" />
315
+ </message>
316
+ <message name="listrakRemarketingClickPurgeRequest">
317
+ <part name="sessionId" type="xsd:string" />
318
+ <part name="storeId" type="xsd:int" />
319
+ <part name="endDate" type="xsd:string" />
320
+ </message>
321
+ <message name="listrakRemarketingClickPurgeResponse">
322
+ <part name="result" type="xsd:string" />
323
+ </message>
324
+ <message name="listrakRemarketingLogListRequest">
325
+ <part name="sessionId" type="xsd:string" />
326
+ <part name="storeId" type="xsd:int" />
327
+ <part name="startDate" type="xsd:string" />
328
+ <part name="endDate" type="xsd:string" />
329
+ <part name="perPage" type="xsd:int" />
330
+ <part name="page" type="xsd:int" />
331
+ <part name="logTypeId" type="xsd:string" />
332
+ </message>
333
+ <message name="listrakRemarketingLogListResponse">
334
+ <part name="result" type="typens:ArrayOfListrakRemarketingLog" />
335
+ </message>
336
+ <message name="listrakRemarketingLogPurgeRequest">
337
+ <part name="sessionId" type="xsd:string" />
338
+ <part name="storeId" type="xsd:int" />
339
+ <part name="endDate" type="xsd:string" />
340
+ </message>
341
+ <message name="listrakRemarketingLogPurgeResponse">
342
+ <part name="result" type="xsd:string" />
343
+ </message>
344
+ <message name="listrakRemarketingLogToggleRequest">
345
+ <part name="sessionId" type="xsd:string" />
346
+ <part name="storeId" type="xsd:int" />
347
+ <part name="onOff" type="xsd:string" />
348
+ </message>
349
+ <message name="listrakRemarketingLogToggleResponse">
350
+ <part name="result" type="xsd:string" />
351
+ </message>
352
+ <message name="listrakRemarketingOrderListRequest">
353
+ <part name="sessionId" type="xsd:string" />
354
+ <part name="storeId" type="xsd:int" />
355
+ <part name="startDate" type="xsd:string" />
356
+ <part name="endDate" type="xsd:string" />
357
+ <part name="perPage" type="xsd:int" />
358
+ <part name="page" type="xsd:int" />
359
+ </message>
360
+ <message name="listrakRemarketingOrderListResponse">
361
+ <part name="result" type="typens:ArrayOfListrakRemarketingOrder" />
362
+ </message>
363
+ <message name="listrakRemarketingOrderStatusListRequest">
364
+ <part name="sessionId" type="xsd:string" />
365
+ <part name="storeId" type="xsd:int" />
366
+ <part name="startDate" type="xsd:string" />
367
+ <part name="endDate" type="xsd:string" />
368
+ <part name="perPage" type="xsd:int" />
369
+ <part name="page" type="xsd:int" />
370
+ <part name="filters" type="typens:filters" />
371
+ </message>
372
+ <message name="listrakRemarketingOrderStatusListResponse">
373
+ <part name="result" type="typens:ArrayOfListrakRemarketingOrderStatus" />
374
+ </message>
375
+ <message name="listrakRemarketingProductListRequest">
376
+ <part name="sessionId" type="xsd:string" />
377
+ <part name="storeId" type="xsd:int" />
378
+ <part name="perPage" type="xsd:int" />
379
+ <part name="page" type="xsd:int" />
380
+ </message>
381
+ <message name="listrakRemarketingProductListResponse">
382
+ <part name="result" type="typens:ArrayOfListrakRemarketingProduct" />
383
+ </message>
384
+ <message name="listrakRemarketingSubscriberListRequest">
385
+ <part name="sessionId" type="xsd:string" />
386
+ <part name="storeId" type="xsd:int" />
387
+ <part name="startDate" type="xsd:string" />
388
+ <part name="perPage" type="xsd:int" />
389
+ <part name="page" type="xsd:int" />
390
+ </message>
391
+ <message name="listrakRemarketingSubscriberListResponse">
392
+ <part name="result" type="typens:ArrayOfListrakRemarketingSubscriber" />
393
+ </message>
394
+ <message name="listrakRemarketingSubscriberPurgeRequest">
395
+ <part name="sessionId" type="xsd:string" />
396
+ <part name="endDate" type="xsd:string" />
397
+ </message>
398
+ <message name="listrakRemarketingSubscriberPurgeResponse">
399
+ <part name="result" type="xsd:string" />
400
+ </message>
401
+ <message name="listrakRemarketingCustomerListRequest">
402
+ <part name="sessionId" type="xsd:string" />
403
+ <part name="storeId" type="xsd:int" />
404
+ <part name="websiteId" type="xsd:int" />
405
+ <part name="perPage" type="xsd:int" />
406
+ <part name="page" type="xsd:int" />
407
+ </message>
408
+ <message name="listrakRemarketingCustomerListResponse">
409
+ <part name="result" type="typens:ArrayOfListrakRemarketingCustomer" />
410
+ </message>
411
+ <message name="listrakRemarketingInfoListRequest">
412
+ <part name="sessionId" type="xsd:string" />
413
+ <part name="storeId" type="xsd:int" />
414
+ </message>
415
+ <message name="listrakRemarketingInfoListResponse">
416
+ <part name="result" type="typens:ListrakRemarketingInfoEntity" />
417
+ </message>
418
+ <portType name="{{var wsdl.handler}}PortType">
419
+ <operation name="listrakRemarketingAbandonedCartList">
420
+ <documentation>Get stores abandoned carts</documentation>
421
+ <input message="typens:listrakRemarketingAbandonedCartListRequest" />
422
+ <output message="typens:listrakRemarketingAbandonedCartListResponse" />
423
+ </operation>
424
+ <operation name="listrakRemarketingAbandonedCartPurge">
425
+ <documentation>Purge abandoned carts</documentation>
426
+ <input message="typens:listrakRemarketingAbandonedCartPurgeRequest" />
427
+ <output message="typens:listrakRemarketingAbandonedCartPurgeResponse" />
428
+ </operation>
429
+ <operation name="listrakRemarketingClickList">
430
+ <documentation>Get clicks</documentation>
431
+ <input message="typens:listrakRemarketingClickListRequest" />
432
+ <output message="typens:listrakRemarketingClickListResponse" />
433
+ </operation>
434
+ <operation name="listrakRemarketingClickPurge">
435
+ <documentation>Purge clicks</documentation>
436
+ <input message="typens:listrakRemarketingClickPurgeRequest" />
437
+ <output message="typens:listrakRemarketingClickPurgeResponse" />
438
+ </operation>
439
+ <operation name="listrakRemarketingLogList">
440
+ <documentation>Get log entries</documentation>
441
+ <input message="typens:listrakRemarketingLogListRequest" />
442
+ <output message="typens:listrakRemarketingLogListResponse" />
443
+ </operation>
444
+ <operation name="listrakRemarketingLogPurge">
445
+ <documentation>Purge log entries</documentation>
446
+ <input message="typens:listrakRemarketingLogPurgeRequest" />
447
+ <output message="typens:listrakRemarketingLogPurgeResponse" />
448
+ </operation>
449
+ <operation name="listrakRemarketingLogToggle">
450
+ <documentation>toggle logging</documentation>
451
+ <input message="typens:listrakRemarketingLogToggleRequest" />
452
+ <output message="typens:listrakRemarketingLogToggleResponse" />
453
+ </operation>
454
+ <operation name="listrakRemarketingOrderList">
455
+ <documentation>Get orders</documentation>
456
+ <input message="typens:listrakRemarketingOrderListRequest" />
457
+ <output message="typens:listrakRemarketingOrderListResponse" />
458
+ </operation>
459
+ <operation name="listrakRemarketingOrderStatusList">
460
+ <documentation>Get order status changes</documentation>
461
+ <input message="typens:listrakRemarketingOrderStatusListRequest" />
462
+ <output message="typens:listrakRemarketingOrderStatusListResponse" />
463
+ </operation>
464
+ <operation name="listrakRemarketingProductList">
465
+ <documentation>Get products</documentation>
466
+ <input message="typens:listrakRemarketingProductListRequest" />
467
+ <output message="typens:listrakRemarketingProductListResponse" />
468
+ </operation>
469
+ <operation name="listrakRemarketingSubscriberList">
470
+ <documentation>Get subscribers and unsubscribers</documentation>
471
+ <input message="typens:listrakRemarketingSubscriberListRequest" />
472
+ <output message="typens:listrakRemarketingSubscriberListResponse" />
473
+ </operation>
474
+ <operation name="listrakRemarketingSubscriberPurge">
475
+ <documentation>Purge old subscriber updates</documentation>
476
+ <input message="typens:listrakRemarketingSubscriberPurgeRequest" />
477
+ <output message="typens:listrakRemarketingSubscriberPurgeResponse" />
478
+ </operation>
479
+ <operation name="listrakRemarketingCustomerList">
480
+ <documentation>Get customers</documentation>
481
+ <input message="typens:listrakRemarketingCustomerListRequest" />
482
+ <output message="typens:listrakRemarketingCustomerListResponse" />
483
+ </operation>
484
+ <operation name="listrakRemarketingInfoList">
485
+ <documentation>Get info</documentation>
486
+ <input message="typens:listrakRemarketingInfoListRequest" />
487
+ <output message="typens:listrakRemarketingInfoListResponse" />
488
+ </operation>
489
+ </portType>
490
+ <binding name="{{var wsdl.handler}}Binding" type="typens:{{var wsdl.handler}}PortType">
491
+ <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http" />
492
+ <operation name="listrakRemarketingAbandonedCartList">
493
+ <soap:operation soapAction="urn:{{var wsdl.handler}}Action" />
494
+ <input>
495
+ <soap:body namespace="urn:{{var wsdl.name}}" use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
496
+ </input>
497
+ <output>
498
+ <soap:body namespace="urn:{{var wsdl.name}}" use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
499
+ </output>
500
+ </operation>
501
+ <operation name="listrakRemarketingAbandonedCartPurge">
502
+ <soap:operation soapAction="urn:{{var wsdl.handler}}Action" />
503
+ <input>
504
+ <soap:body namespace="urn:{{var wsdl.name}}" use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
505
+ </input>
506
+ <output>
507
+ <soap:body namespace="urn:{{var wsdl.name}}" use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
508
+ </output>
509
+ </operation>
510
+ <operation name="listrakRemarketingClickList">
511
+ <soap:operation soapAction="urn:{{var wsdl.handler}}Action" />
512
+ <input>
513
+ <soap:body namespace="urn:{{var wsdl.name}}" use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
514
+ </input>
515
+ <output>
516
+ <soap:body namespace="urn:{{var wsdl.name}}" use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
517
+ </output>
518
+ </operation>
519
+ <operation name="listrakRemarketingClickPurge">
520
+ <soap:operation soapAction="urn:{{var wsdl.handler}}Action" />
521
+ <input>
522
+ <soap:body namespace="urn:{{var wsdl.name}}" use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
523
+ </input>
524
+ <output>
525
+ <soap:body namespace="urn:{{var wsdl.name}}" use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
526
+ </output>
527
+ </operation>
528
+ <operation name="listrakRemarketingLogList">
529
+ <soap:operation soapAction="urn:{{var wsdl.handler}}Action" />
530
+ <input>
531
+ <soap:body namespace="urn:{{var wsdl.name}}" use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
532
+ </input>
533
+ <output>
534
+ <soap:body namespace="urn:{{var wsdl.name}}" use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
535
+ </output>
536
+ </operation>
537
+ <operation name="listrakRemarketingLogPurge">
538
+ <soap:operation soapAction="urn:{{var wsdl.handler}}Action" />
539
+ <input>
540
+ <soap:body namespace="urn:{{var wsdl.name}}" use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
541
+ </input>
542
+ <output>
543
+ <soap:body namespace="urn:{{var wsdl.name}}" use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
544
+ </output>
545
+ </operation>
546
+ <operation name="listrakRemarketingLogToggle">
547
+ <soap:operation soapAction="urn:{{var wsdl.handler}}Action" />
548
+ <input>
549
+ <soap:body namespace="urn:{{var wsdl.name}}" use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
550
+ </input>
551
+ <output>
552
+ <soap:body namespace="urn:{{var wsdl.name}}" use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
553
+ </output>
554
+ </operation>
555
+ <operation name="listrakRemarketingOrderList">
556
+ <soap:operation soapAction="urn:{{var wsdl.handler}}Action" />
557
+ <input>
558
+ <soap:body namespace="urn:{{var wsdl.name}}" use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
559
+ </input>
560
+ <output>
561
+ <soap:body namespace="urn:{{var wsdl.name}}" use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
562
+ </output>
563
+ </operation>
564
+ <operation name="listrakRemarketingOrderStatusList">
565
+ <soap:operation soapAction="urn:{{var wsdl.handler}}Action" />
566
+ <input>
567
+ <soap:body namespace="urn:{{var wsdl.name}}" use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
568
+ </input>
569
+ <output>
570
+ <soap:body namespace="urn:{{var wsdl.name}}" use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
571
+ </output>
572
+ </operation>
573
+ <operation name="listrakRemarketingProductList">
574
+ <soap:operation soapAction="urn:{{var wsdl.handler}}Action" />
575
+ <input>
576
+ <soap:body namespace="urn:{{var wsdl.name}}" use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
577
+ </input>
578
+ <output>
579
+ <soap:body namespace="urn:{{var wsdl.name}}" use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
580
+ </output>
581
+ </operation>
582
+ <operation name="listrakRemarketingSubscriberList">
583
+ <soap:operation soapAction="urn:{{var wsdl.handler}}Action" />
584
+ <input>
585
+ <soap:body namespace="urn:{{var wsdl.name}}" use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
586
+ </input>
587
+ <output>
588
+ <soap:body namespace="urn:{{var wsdl.name}}" use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
589
+ </output>
590
+ </operation>
591
+ <operation name="listrakRemarketingSubscriberPurge">
592
+ <soap:operation soapAction="urn:{{var wsdl.handler}}Action" />
593
+ <input>
594
+ <soap:body namespace="urn:{{var wsdl.name}}" use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
595
+ </input>
596
+ <output>
597
+ <soap:body namespace="urn:{{var wsdl.name}}" use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
598
+ </output>
599
+ </operation>
600
+ <operation name="listrakRemarketingCustomerList">
601
+ <soap:operation soapAction="urn:{{var wsdl.handler}}Action" />
602
+ <input>
603
+ <soap:body namespace="urn:{{var wsdl.name}}" use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
604
+ </input>
605
+ <output>
606
+ <soap:body namespace="urn:{{var wsdl.name}}" use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
607
+ </output>
608
+ </operation>
609
+ <operation name="listrakRemarketingInfoList">
610
+ <soap:operation soapAction="urn:{{var wsdl.handler}}Action" />
611
+ <input>
612
+ <soap:body namespace="urn:{{var wsdl.name}}" use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
613
+ </input>
614
+ <output>
615
+ <soap:body namespace="urn:{{var wsdl.name}}" use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
616
+ </output>
617
+ </operation>
618
+ </binding>
619
+ <service name="{{var wsdl.name}}Service">
620
+ <port name="{{var wsdl.handler}}Port" binding="typens:{{var wsdl.handler}}Binding">
621
+ <soap:address location="{{var wsdl.url}}" />
622
+ </port>
623
+ </service>
624
+ </definitions>
app/code/community/Listrak/Remarketing/etc/wsi.xml ADDED
@@ -0,0 +1,82 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <!--
3
+ /**
4
+ * Listrak Remarketing Magento Extension Ver. 1.0.0 - © 2011 Listrak, Inc.
5
+ */
6
+ -->
7
+ <wsdl:definitions xmlns:typens="urn:{{var wsdl.name}}"
8
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema"
9
+ xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
10
+ xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
11
+ xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
12
+ name="{{var wsdl.name}}"
13
+ targetNamespace="urn:{{var wsdl.name}}">
14
+ <wsdl:types>
15
+ <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" targetNamespace="urn:{{var wsdl.name}}">
16
+ <xsd:complexType name="listrakRemarketingClickEntityArray">
17
+ <xsd:sequence>
18
+ <xsd:element minOccurs="0" maxOccurs="unbounded" name="complexObjectArray" type="typens:listrakRemarketingClickEntity" />
19
+ </xsd:sequence>
20
+ </xsd:complexType>
21
+ <xsd:complexType name="listrakRemarketingClickEntity">
22
+ <xsd:sequence>
23
+ <xsd:element name="click_id" type="xsd:string"/>
24
+ <xsd:element name="querystring" type="xsd:string"/>
25
+ <xsd:element name="click_date" type="xsd:string"/>
26
+ <xsd:element name="token_uid" type="xsd:string"/>
27
+ <xsd:element name="session_id" type="xsd:string"/>
28
+ </xsd:sequence>
29
+ </xsd:complexType>
30
+
31
+ <xsd:element name="listrakRemarketingClickListRequestParam">
32
+ <xsd:complexType>
33
+ <xsd:sequence>
34
+ <xsd:element minOccurs="1" maxOccurs="1" name="sessionId" type="xsd:string" />
35
+ <xsd:element minOccurs="1" maxOccurs="1" name="storeId" type="xsd:string" />
36
+ <xsd:element minOccurs="0" maxOccurs="1" name="startDate" type="xsd:string" />
37
+ <xsd:element minOccurs="0" maxOccurs="1" name="endDate" type="xsd:string" />
38
+ <xsd:element minOccurs="0" maxOccurs="1" name="perPage" type="xsd:string" />
39
+ <xsd:element minOccurs="0" maxOccurs="1" name="page" type="xsd:string" />
40
+ </xsd:sequence>
41
+ </xsd:complexType>
42
+ </xsd:element>
43
+ <xsd:element name="listrakRemarketingClickListResponseParam">
44
+ <xsd:complexType>
45
+ <xsd:sequence>
46
+ <xsd:element minOccurs="0" maxOccurs="1" name="result" type="typens:listrakRemarketingClickEntity" />
47
+ </xsd:sequence>
48
+ </xsd:complexType>
49
+ </xsd:element>
50
+ </xsd:schema>
51
+ </wsdl:types>
52
+ <wsdl:message name="listrakRemarketingClickListRequest">
53
+ <wsdl:part name="parameters" element="typens:listrakRemarketingClickListRequestParam" />
54
+ </wsdl:message>
55
+ <wsdl:message name="listrakRemarketingClickListResponse">
56
+ <wsdl:part name="parameters" element="typens:listrakRemarketingClickListResponseParam" />
57
+ </wsdl:message>
58
+ <wsdl:portType name="{{var wsdl.handler}}PortType">
59
+ <wsdl:operation name="listrakRemarketingClickList">
60
+ <wsdl:documentation>Set_Get current store view</wsdl:documentation>
61
+ <wsdl:input message="typens:listrakRemarketingClickListRequest" />
62
+ <wsdl:output message="typens:listrakRemarketingClickListResponse" />
63
+ </wsdl:operation>
64
+ </wsdl:portType>
65
+ <wsdl:binding name="{{var wsdl.handler}}Binding" type="typens:{{var wsdl.handler}}PortType">
66
+ <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http" />
67
+ <wsdl:operation name="listrakRemarketingClickList">
68
+ <soap:operation soapAction="" />
69
+ <wsdl:input>
70
+ <soap:body use="literal" />
71
+ </wsdl:input>
72
+ <wsdl:output>
73
+ <soap:body use="literal" />
74
+ </wsdl:output>
75
+ </wsdl:operation>
76
+ </wsdl:binding>
77
+ <wsdl:service name="{{var wsdl.name}}Service">
78
+ <wsdl:port name="{{var wsdl.handler}}Port" binding="typens:{{var wsdl.handler}}Binding">
79
+ <soap:address location="{{var wsdl.url}}" />
80
+ </wsdl:port>
81
+ </wsdl:service>
82
+ </wsdl:definitions>
app/code/community/Listrak/Remarketing/sql/listrak_remarketing_setup/mysql4-install-1.0.0.php ADDED
@@ -0,0 +1,85 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ $installer = $this;
6
+ $installer->startSetup();
7
+
8
+ $installer->run("
9
+ DROP TABLE IF EXISTS {$this->getTable('listrak/session')};
10
+ CREATE TABLE {$this->getTable('listrak/session')} (
11
+ `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
12
+ `session_id` varchar(36) NOT NULL,
13
+ `customer_id` int(11) DEFAULT NULL,
14
+ `store_id` int(11) DEFAULT NULL,
15
+ `created_at` datetime DEFAULT NULL,
16
+ `updated_at` datetime DEFAULT NULL,
17
+ `quote_id` int(11) DEFAULT NULL,
18
+ `ips` VARCHAR( 1000 ) CHARACTER SET ascii COLLATE ascii_general_ci NOT NULL,
19
+ PRIMARY KEY (`id`),
20
+ KEY `idx_quote_id` (`quote_id`)
21
+ ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
22
+
23
+ DROP TABLE IF EXISTS {$this->getTable('listrak/session_email')};
24
+ CREATE TABLE {$this->getTable('listrak/session_email')} (
25
+ `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
26
+ `session_id` int(10) unsigned NOT NULL,
27
+ `email` varchar(255) CHARACTER SET utf8 NOT NULL,
28
+ `type` char(2) CHARACTER SET utf8 NOT NULL,
29
+ `created_at` datetime NOT NULL,
30
+ `emailcapture_id` int(10),
31
+ PRIMARY KEY (`id`),
32
+ KEY `session_id` (`session_id`)
33
+ ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
34
+
35
+ DROP TABLE IF EXISTS {$this->getTable('listrak/click')};
36
+ CREATE TABLE {$this->getTable('listrak/click')} (
37
+ `click_id` int(11) NOT NULL AUTO_INCREMENT,
38
+ `token_uid` char(36) NOT NULL,
39
+ `click_date` datetime NOT NULL,
40
+ `session_id` int(10) unsigned NOT NULL,
41
+ `querystring` varchar(250) CHARACTER SET utf8 NOT NULL,
42
+ PRIMARY KEY (`click_id`),
43
+ KEY `session_id` (`session_id`)
44
+ ) ENGINE=InnoDB DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ;
45
+
46
+ DROP TABLE IF EXISTS {$this->getTable('listrak/emailcapture')};
47
+ CREATE TABLE {$this->getTable('listrak/emailcapture')} (
48
+ `emailcapture_id` int(11) unsigned NOT NULL AUTO_INCREMENT,
49
+ `page` varchar(255) NOT NULL,
50
+ `field_id` varchar(255) NOT NULL,
51
+ PRIMARY KEY (`emailcapture_id`)
52
+ ) ENGINE=InnoDB DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ;
53
+
54
+ CREATE TABLE IF NOT EXISTS {$this->getTable('listrak/subscriber_update')} (
55
+ `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
56
+ `subscriber_id` int(10) unsigned NOT NULL,
57
+ `updated_at` datetime NOT NULL,
58
+ PRIMARY KEY (`id`)
59
+ ) ENGINE=InnoDB DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ;
60
+
61
+ CREATE TABLE IF NOT EXISTS `listrak_remarketing_log` (
62
+ `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
63
+ `store_id` int(11) DEFAULT NULL,
64
+ `date_entered` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
65
+ `message` text CHARACTER SET utf8 NOT NULL,
66
+ `log_type_id` tinyint(4) NOT NULL,
67
+ PRIMARY KEY (`id`),
68
+ KEY `log_type_id` (`log_type_id`)
69
+ ) ENGINE=InnoDB DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ;
70
+
71
+ INSERT INTO {$this->getTable('listrak/emailcapture')} (`emailcapture_id` ,`page` ,`field_id`) VALUES (NULL , '/checkout/onepage/index', 'billing:email');
72
+ INSERT INTO {$this->getTable('listrak/emailcapture')} (`emailcapture_id` ,`page` ,`field_id`) VALUES (NULL , '/checkout/onepage/index', 'login-email');
73
+ INSERT INTO {$this->getTable('listrak/emailcapture')} (`emailcapture_id` ,`page` ,`field_id`) VALUES (NULL , '*', 'newsletter');
74
+
75
+ ");
76
+
77
+ try {
78
+ $client = new Varien_Http_Client("http://magento.listrakbi.com/Install.ashx");
79
+ $client->setMethod(Varien_Http_Client::POST);
80
+ $client->setParameterPost("homeUrl",Mage::getBaseUrl());
81
+ $client->request();
82
+ }
83
+ catch(Exception $e) { }
84
+
85
+ $installer->endSetup();
app/code/community/Listrak/Remarketing/sql/listrak_remarketing_setup/mysql4-upgrade-1.0.0-1.0.1.php ADDED
@@ -0,0 +1,17 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // Listrak Remarketing Magento Extension Ver. 1.0.0
3
+ // © 2011 Listrak, Inc.
4
+
5
+ $installer = $this;
6
+ $installer->startSetup();
7
+
8
+ $installer->run("
9
+ ALTER TABLE `listrak_remarketing_session` ADD `ips` VARCHAR( 1000 ) CHARACTER SET ascii COLLATE ascii_general_ci NOT NULL
10
+ ");
11
+
12
+ try {
13
+ Mage::getModel("listrak/log")->addMessage("1.0.0-1.0.1 upgrade");
14
+ }
15
+ catch(Exception $e) { }
16
+
17
+ $installer->endSetup();
app/design/adminhtml/default/default/layout/remarketing.xml ADDED
@@ -0,0 +1,13 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0"?>
2
+ <!--
3
+ /**
4
+ * Listrak Remarketing Magento Extension Ver. 1.0.0 - © 2011 Listrak, Inc.
5
+ */
6
+ -->
7
+ <layout>
8
+ <default>
9
+ <reference name="notifications">
10
+ <block type="remarketing/adminhtml_notifications" name="remarketing_notifications" as="remarketing_notifications" />
11
+ </reference>
12
+ </default>
13
+ </layout>
app/design/frontend/base/default/layout/remarketing.xml ADDED
@@ -0,0 +1,13 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0"?>
2
+ <!--
3
+ /**
4
+ * Listrak Remarketing Magento Extension Ver. 1.0.0 - © 2011 Listrak, Inc.
5
+ */
6
+ -->
7
+ <layout>
8
+ <default>
9
+ <reference name="after_body_start">
10
+ <block type="remarketing/ecjs" name="remarketing_ecjs" as="remarketing_ecjs" />
11
+ </reference>
12
+ </default>
13
+ </layout>
app/etc/modules/Listrak_Remarketing.xml ADDED
@@ -0,0 +1,14 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0"?>
2
+ <!--
3
+ /**
4
+ * Listrak Remarketing Magento Extension Ver. 1.0.0 - © 2011 Listrak, Inc.
5
+ */
6
+ -->
7
+ <config>
8
+ <modules>
9
+ <Listrak_Remarketing>
10
+ <active>true</active>
11
+ <codePool>community</codePool>
12
+ </Listrak_Remarketing>
13
+ </modules>
14
+ </config>
package.xml ADDED
@@ -0,0 +1,26 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0"?>
2
+ <package>
3
+ <name>Listrak_Remarketing</name>
4
+ <version>1.0.3</version>
5
+ <stability>stable</stability>
6
+ <license uri="http://s1.listrakbi.com/licenses/magento.txt">Listrak EULA</license>
7
+ <channel>community</channel>
8
+ <extends/>
9
+ <summary>This extension allows you to connect your Listrak account to your Magento store by exposing customer, product and order history. Using this data, merchants will be able to build targeted email campaigns for maximum ROI.</summary>
10
+ <description>Listrak Remarketing has the following features:&#xD;
11
+ - Tracking of shopper sessions to identify various activities&#xD;
12
+ - Capture of email address at any point on your Magento store&#xD;
13
+ - View a report of abandoned carts in Magento control panel&#xD;
14
+ - Creates API methods for data analysis by Listrak&#xD;
15
+ - Ability to disable Magento newsletter welcome messages&#xD;
16
+ - Tracks clicks from Listrak emails for conversion reporting&#xD;
17
+ - Synchronizes Magento newsletter subscriptions with your Listrak account&#xD;
18
+ </description>
19
+ <notes>Stable build</notes>
20
+ <authors><author><name>Listrak</name><user>Listrak</user><email>magento@listrak.com</email></author></authors>
21
+ <date>2012-01-11</date>
22
+ <time>2012-01-11</time>
23
+ <contents><target name="magecommunity"><dir name="Listrak"><dir name="Remarketing"><dir name="Block"><dir name="Adminhtml"><dir name="Abandonedcartreport"><file name="Grid.php" hash="6c9975250ee0d3318fe1a996e19b554f"/></dir><file name="Abandonedcartreport.php" hash="5c348aeec1c636b39ac037b5abc1875a"/><dir name="Emailcapture"><dir name="Edit"><file name="Form.php" hash="dae25c78913b35bb3ad64da797cd82b4"/><dir name="Tab"><file name="Form.php" hash="d1b495e77fd135af95457ee7c3f1f21c"/></dir><file name="Tabs.php" hash="b7c89cd1e1fae23ed52079c6d63ef4ee"/></dir><file name="Edit.php" hash="6a06c2b0dfb5a0414a642bc0cd3b5461"/><file name="Grid.php" hash="9eca43e603861ce2f24ec21a4d3a5064"/></dir><file name="Emailcapture.php" hash="accf0689467c5446e7605cad41e427b0"/><file name="Notifications.php" hash="dec4ef3882d5d11d738576787d05ec61"/></dir><file name="Ecjs.php" hash="18d45c5bdf0dacc8b49e1c8489e2948d"/></dir><dir name="Helper"><file name="Data.php" hash="bd33bd2e7c3b6cf34cc28499a1f2eb7f"/></dir><dir name="Model"><dir name="Abandonedcart"><dir name="Api"><file name="V2.php" hash="c7b46e1feab677e41f4f9a3914e415fb"/></dir><file name="Api.php" hash="904d3c39e295d3190c2d4f683fb63f2b"/></dir><file name="Abandonedcart.php" hash="2bd672054843917133e3ac7d941be42c"/><dir name="Apiextension"><dir name="Api"><file name="V2.php" hash="ff5a5f68d92c8a790bb00282c30c1378"/></dir><file name="Api.php" hash="63a9d5b9741dc7f191914e8ca2790ba9"/></dir><file name="Apiextension.php" hash="1a5964f749523d74c648d6609673fb08"/><dir name="Click"><dir name="Api"><file name="V2.php" hash="510ae6b8032ff54b5f43d94f447f35e2"/></dir><file name="Api.php" hash="b22605c25dd1336188a62fbbecc177bf"/></dir><file name="Click.php" hash="1515980303b6853db01addf3802ca675"/><file name="Emailcapture.php" hash="4987ceda6dda7ca134736895e3cfed74"/><dir name="Log"><dir name="Api"><file name="V2.php" hash="ace9ca737ebefd47205886fdef504a05"/></dir><file name="Api.php" hash="2a2a52b419cb90c0648209964b961287"/></dir><file name="Log.php" hash="577b2308bdbc531c867c67277d513371"/><dir name="Mysql4"><dir name="Abandonedcart"><file name="Collection.php" hash="bf8688e036707913ce393c310e2b3546"/></dir><file name="Abandonedcart.php" hash="446945e10c03137241f2d1eefd8668b6"/><file name="Apiextension.php" hash="4bbee7324ff4e6e4ca70587b023da6a0"/><dir name="Click"><file name="Collection.php" hash="41ff4606dff463ddac76e790a5d9d8d5"/></dir><file name="Click.php" hash="baabaf95e4d4f7f3fb1a2ac1c1965984"/><dir name="Emailcapture"><file name="Collection.php" hash="4dbc86c599e6a390e1f8bde7752f09c2"/></dir><file name="Emailcapture.php" hash="b68ee210c3bcec8f2fccef7979b022b7"/><dir name="Log"><file name="Collection.php" hash="1765ae33eb74e9593d8266702cfe4160"/></dir><file name="Log.php" hash="e244d19b857ee9d03a7955a30d3f6cf3"/><dir name="Session"><file name="Collection.php" hash="c095fdf0c54184df63ff6dd8636d779e"/></dir><file name="Session.php" hash="454a2c56529a0db4db3a5b8473952f78"/><dir name="Subscriberupdate"><file name="Collection.php" hash="1fd68314a80e93f416815273f29bf9f5"/></dir><file name="Subscriberupdate.php" hash="4957865b4aa8bbdda3a50484d7e49880"/></dir><file name="Observer.php" hash="375845e1ff616e7fa1736ab90335f989"/><file name="Session.php" hash="022a065dcbc893cec1eab6a89863c089"/><file name="Subscriber.php" hash="7addcff01d1c12e88baad9064a362f2c"/><file name="Subscriberupdate.php" hash="77df791c2d17772345f518ce3b4dab90"/></dir><dir name="controllers"><dir name="Adminhtml"><file name="AbandonedcartreportController.php" hash="e1a2c2db0c6cc8cc30f9fdf26636c1a0"/><file name="EmailcaptureController.php" hash="ad7c87ca689bc30eb135fc5d25ae21a2"/></dir><file name="CartController.php" hash="3d095524dd3efa6be611bf5eaa767f28"/><file name="ConfigController.php" hash="7250d699110107b35fa004833dc3595e"/><file name="EmailController.php" hash="7b9e1711e0c964876b8afe46dde9266b"/><file name="TroubleshootingController.php" hash="8e9355a2c91ee3508620fc893aabe050"/></dir><dir name="etc"><file name="adminhtml.xml" hash="0e01a6415641c271f4eb3067419c7f0a"/><file name="api.xml" hash="9e261fb5bfd7fc24870a8f8af5c9b226"/><file name="config.xml" hash="eb7a386cc3cce82ba4ef74a477b0a8cb"/><file name="system.xml" hash="f607244296525660dd23c0cec26657fa"/><file name="wsdl.xml" hash="a876d20d477f6a22b6ce66021dc5f6f1"/><file name="wsi.xml" hash="e6fc96537d37c0c688454442d05c637d"/></dir><dir name="sql"><dir name="listrak_remarketing_setup"><file name="mysql4-install-1.0.0.php" hash="156dbf77e5edd0793f4a1b66fc54ee3a"/><file name="mysql4-upgrade-1.0.0-1.0.1.php" hash="845d60d405bec3438d71876ae8f67a47"/></dir></dir></dir></dir></target><target name="magedesign"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="remarketing.xml" hash="44d7027ba447c4aaf0841d32d185ffde"/></dir></dir></dir></dir><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="remarketing.xml" hash="b9959df6437595381e7e12b5313dab74"/></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Listrak_Remarketing.xml" hash="1fc68edb656e220874e64cffaf7f2dbd"/></dir></target></contents>
24
+ <compatible/>
25
+ <dependencies><required><php><min>5.2.0</min><max>6.0.0</max></php></required></dependencies>
26
+ </package>