Minematic_Connector - Version 1.2.0

Version Notes

minor bug fixes

Download this release

Release Info

Developer Minematic
Extension Minematic_Connector
Version 1.2.0
Comparing to
See all releases


Code changes from version 1.1.0 to 1.2.0

app/code/community/Minematic/.DS_Store CHANGED
Binary file
app/code/community/Minematic/Connector/.DS_Store CHANGED
Binary file
app/code/community/Minematic/Connector/Model/.DS_Store CHANGED
Binary file
app/code/community/Minematic/Connector/Model/Synchronization.php CHANGED
@@ -173,10 +173,10 @@ class Minematic_Connector_Model_Synchronization{
173
  $conn = $coreResource->getConnection('core_read');
174
 
175
  //Preparing query
176
- $sql = 'SELECT count(distinct entity_id) count, Month(`created_at`) as month, Year(`created_at`) as year
177
  FROM '.$cpe_table .
178
- ' GROUP BY Month(`created_at`), Year(created_at)
179
- ORDER BY created_at ASC';
180
 
181
  //Feth all items
182
  $_products = $conn->fetchAll($sql);
@@ -210,10 +210,10 @@ class Minematic_Connector_Model_Synchronization{
210
  $conn = $coreResource->getConnection('core_read');
211
 
212
  //Preparing query
213
- $sql = 'SELECT count(distinct entity_id) count, Month(`created_at`) as month, Year(`created_at`) as year
214
  FROM '.$ce_table .
215
- ' GROUP BY Month(`created_at`), Year(created_at)
216
- ORDER BY created_at ASC';
217
 
218
  //Fetch data
219
  $_customers = $conn->fetchAll($sql);
@@ -757,7 +757,7 @@ class Minematic_Connector_Model_Synchronization{
757
 
758
  //Get all ORDERS where status is different from "canceled" and "customer_id" field is set
759
  $ordersCollection = Mage::getModel('sales/order')->getCollection()
760
- ->addFieldToSelect('updated_at')
761
  ->addAttributeToFilter('status', array('nin' => array('canceled','complete')))
762
  ->addFieldToFilter('product_id', array('gt' => 0))
763
  ->addFieldToFilter('customer_id', array('gt' => 0))
@@ -797,7 +797,7 @@ class Minematic_Connector_Model_Synchronization{
797
  'type' => "ORDER",
798
  'user_id' => $order->getCustomerId(),
799
  'item_id' => $order->getProductId(),
800
- 'datetime' => strtotime($order->getUpdatedAt()),
801
  );
802
 
803
  //Adding orders
@@ -827,7 +827,7 @@ class Minematic_Connector_Model_Synchronization{
827
 
828
  //Get all PAID orders where status is "complete" and "customer_id" field is set
829
  $paidOrdersCollection = Mage::getModel('sales/order')->getCollection()
830
- ->addFieldToSelect('updated_at')
831
  ->addFieldToFilter('status', array('eq' => 'complete'))
832
  ->addFieldToFilter('product_id', array('gt' => 0))
833
  ->addFieldToFilter('customer_id', array('gt' => 0))
@@ -866,7 +866,7 @@ class Minematic_Connector_Model_Synchronization{
866
  'type' => "PAID",
867
  'user_id' => $paid_order->getCustomerId(),
868
  'item_id' => $paid_order->getProductId(),
869
- 'datetime' => strtotime($paid_order->getUpdatedAt()),
870
  );
871
 
872
  //Adding paid orders
173
  $conn = $coreResource->getConnection('core_read');
174
 
175
  //Preparing query
176
+ $sql = 'SELECT count(distinct entity_id) count, Month(`updated_at`) as month, Year(`updated_at`) as year
177
  FROM '.$cpe_table .
178
+ ' GROUP BY Month(`updated_at`), Year(updated_at)
179
+ ORDER BY updated_at ASC';
180
 
181
  //Feth all items
182
  $_products = $conn->fetchAll($sql);
210
  $conn = $coreResource->getConnection('core_read');
211
 
212
  //Preparing query
213
+ $sql = 'SELECT count(distinct entity_id) count, Month(`updated_at`) as month, Year(`updated_at`) as year
214
  FROM '.$ce_table .
215
+ ' GROUP BY Month(`updated_at`), Year(updated_at)
216
+ ORDER BY updated_at ASC';
217
 
218
  //Fetch data
219
  $_customers = $conn->fetchAll($sql);
757
 
758
  //Get all ORDERS where status is different from "canceled" and "customer_id" field is set
759
  $ordersCollection = Mage::getModel('sales/order')->getCollection()
760
+ ->addFieldToSelect('created_at')
761
  ->addAttributeToFilter('status', array('nin' => array('canceled','complete')))
762
  ->addFieldToFilter('product_id', array('gt' => 0))
763
  ->addFieldToFilter('customer_id', array('gt' => 0))
797
  'type' => "ORDER",
798
  'user_id' => $order->getCustomerId(),
799
  'item_id' => $order->getProductId(),
800
+ 'datetime' => strtotime($order->getCreatedAt()),
801
  );
802
 
803
  //Adding orders
827
 
828
  //Get all PAID orders where status is "complete" and "customer_id" field is set
829
  $paidOrdersCollection = Mage::getModel('sales/order')->getCollection()
830
+ ->addFieldToSelect('created_at')
831
  ->addFieldToFilter('status', array('eq' => 'complete'))
832
  ->addFieldToFilter('product_id', array('gt' => 0))
833
  ->addFieldToFilter('customer_id', array('gt' => 0))
866
  'type' => "PAID",
867
  'user_id' => $paid_order->getCustomerId(),
868
  'item_id' => $paid_order->getProductId(),
869
+ 'datetime' => strtotime($paid_order->getCreatedAt()),
870
  );
871
 
872
  //Adding paid orders
package.xml CHANGED
@@ -1,7 +1,7 @@
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>Minematic_Connector</name>
4
- <version>1.1.0</version>
5
  <stability>stable</stability>
6
  <license>Open Software License (OSL)</license>
7
  <channel>community</channel>
@@ -10,9 +10,9 @@
10
  <description>This module collects information about products, customers and events (e.g. ADD TO CART, PRODUCT PAGE VIEW, ADD TO WISHLIST, SHARE) and transfers the information to Minematic data collection API for data analysis and marketing.</description>
11
  <notes>minor bug fixes</notes>
12
  <authors><author><name>Minematic</name><user>minematic</user><email>magento@minematic.com</email></author></authors>
13
- <date>2015-07-04</date>
14
- <time>04:47:12</time>
15
- <contents><target name="magecommunity"><dir name="Minematic"><dir name="Connector"><dir name="Block"><file name="Connector.php" hash="8735289b0f9388955dda56de863cc7f0"/></dir><dir name="Helper"><file name="Data.php" hash="a008a987b46c28f46bf7de02dc7a5936"/><dir name="push_api"><file name="MinematicClient.php" hash="2466f46c03b4fc352e700c6ff287df46"/><file name=".DS_Store" hash="11d4264a26b39c74a6176b3feb5ddb56"/></dir><file name=".DS_Store" hash="166fc3c278a952701e9d4897bfbec1dc"/></dir><dir name="Model"><dir name="Config"><file name="Crondropdown.php" hash="d10f4d27b1edc0d24d3ee77564273ad6"/><file name="Storeviewsdropdown.php" hash="2642d1983e6e17c5233129fec5707fbc"/></dir><file name="Config.php" hash="fde17e756d5ebd6df6040bc874a42c46"/><file name="Observer.php" hash="27495887bfe154b51d9f11d8cd240286"/><file name="Synchronization.php" hash="3c6d6baca4bdd115131a5837bd54965a"/><dir name="System"><dir name="Config"><dir name="Backend"><file name="Cron.php" hash="52e119425813d464474474c15036375f"/><file name=".DS_Store" hash="194577a7e20bdcc7afbb718f502c134c"/></dir><file name=".DS_Store" hash="164f4d8848918d06a0b1de4041fdadd6"/></dir><file name=".DS_Store" hash="1a138f3b020c526173b9b06a9a2717df"/></dir><file name=".DS_Store" hash="757d100ddcfaf4555271fd117fcb5267"/></dir><dir name="controllers"><file name="MinematicController.php" hash="d579d4533a39629ede1549d15e728fa6"/><file name=".DS_Store" hash="a1ddf4e9ec2bec74d4ae1ce8b742675d"/></dir><dir name="etc"><file name="config.xml" hash="02c893b821f614e805a68a233cee6ad4"/><file name="system.xml" hash="4e6616f879f2826de2cd99e189faef4c"/><file name=".DS_Store" hash="d5c9ef4cc8915721d89f14aff358e204"/></dir><dir name="sql"><dir name="connector_setup"><file name="mysql4-install-0.1.0.php" hash="78df6c5b335e9c98a804eba5566a4108"/><file name=".DS_Store" hash="194577a7e20bdcc7afbb718f502c134c"/></dir><file name=".DS_Store" hash="e0ff3a55f14b180fe579834f1fd8d0e8"/></dir><file name=".DS_Store" hash="4d159dd3308a7fb20c154183c72b58d4"/></dir><file name=".DS_Store" hash="9841936103bf7036ac5f805c559210da"/></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="minematic_connector.xml" hash="ceae04cb1965c10562a4227be9eede40"/></dir><dir name="template"><dir name="minematic_connector"><file name="header_snippet.phtml" hash="1a972999363492611d3096aa1772cc44"/></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Minematic_Connector.xml" hash="78b1da5a65d9074dce12bc4d51fdb011"/></dir></target></contents>
16
  <compatible/>
17
  <dependencies><required><php><min>5.3.0</min><max>6.0.0</max></php></required></dependencies>
18
  </package>
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>Minematic_Connector</name>
4
+ <version>1.2.0</version>
5
  <stability>stable</stability>
6
  <license>Open Software License (OSL)</license>
7
  <channel>community</channel>
10
  <description>This module collects information about products, customers and events (e.g. ADD TO CART, PRODUCT PAGE VIEW, ADD TO WISHLIST, SHARE) and transfers the information to Minematic data collection API for data analysis and marketing.</description>
11
  <notes>minor bug fixes</notes>
12
  <authors><author><name>Minematic</name><user>minematic</user><email>magento@minematic.com</email></author></authors>
13
+ <date>2015-08-06</date>
14
+ <time>02:00:16</time>
15
+ <contents><target name="magecommunity"><dir name="Minematic"><dir name="Connector"><dir name="Block"><file name="Connector.php" hash="8735289b0f9388955dda56de863cc7f0"/></dir><dir name="Helper"><file name="Data.php" hash="a008a987b46c28f46bf7de02dc7a5936"/><dir name="push_api"><file name="MinematicClient.php" hash="2466f46c03b4fc352e700c6ff287df46"/><file name=".DS_Store" hash="11d4264a26b39c74a6176b3feb5ddb56"/></dir><file name=".DS_Store" hash="166fc3c278a952701e9d4897bfbec1dc"/></dir><dir name="Model"><dir name="Config"><file name="Crondropdown.php" hash="d10f4d27b1edc0d24d3ee77564273ad6"/><file name="Storeviewsdropdown.php" hash="2642d1983e6e17c5233129fec5707fbc"/></dir><file name="Config.php" hash="fde17e756d5ebd6df6040bc874a42c46"/><file name="Observer.php" hash="27495887bfe154b51d9f11d8cd240286"/><file name="Synchronization.php" hash="54fa4b6101f32eed3c642a4de6552927"/><dir name="System"><dir name="Config"><dir name="Backend"><file name="Cron.php" hash="52e119425813d464474474c15036375f"/><file name=".DS_Store" hash="194577a7e20bdcc7afbb718f502c134c"/></dir><file name=".DS_Store" hash="164f4d8848918d06a0b1de4041fdadd6"/></dir><file name=".DS_Store" hash="1a138f3b020c526173b9b06a9a2717df"/></dir><file name=".DS_Store" hash="c59d89c04035121099d9b012f5da3890"/></dir><dir name="controllers"><file name="MinematicController.php" hash="d579d4533a39629ede1549d15e728fa6"/><file name=".DS_Store" hash="a1ddf4e9ec2bec74d4ae1ce8b742675d"/></dir><dir name="etc"><file name="config.xml" hash="02c893b821f614e805a68a233cee6ad4"/><file name="system.xml" hash="4e6616f879f2826de2cd99e189faef4c"/><file name=".DS_Store" hash="d5c9ef4cc8915721d89f14aff358e204"/></dir><dir name="sql"><dir name="connector_setup"><file name="mysql4-install-0.1.0.php" hash="78df6c5b335e9c98a804eba5566a4108"/><file name=".DS_Store" hash="194577a7e20bdcc7afbb718f502c134c"/></dir><file name=".DS_Store" hash="e0ff3a55f14b180fe579834f1fd8d0e8"/></dir><file name=".DS_Store" hash="d9564ec8cafb44cb620aae2f6be1d711"/></dir><file name=".DS_Store" hash="cf6f6f942fad24bc822a04f8743b6e52"/></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="minematic_connector.xml" hash="ceae04cb1965c10562a4227be9eede40"/></dir><dir name="template"><dir name="minematic_connector"><file name="header_snippet.phtml" hash="1a972999363492611d3096aa1772cc44"/></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Minematic_Connector.xml" hash="78b1da5a65d9074dce12bc4d51fdb011"/></dir></target></contents>
16
  <compatible/>
17
  <dependencies><required><php><min>5.3.0</min><max>6.0.0</max></php></required></dependencies>
18
  </package>