Version Notes
MineWhat magento plugin
Download this release
Release Info
Developer | MineWhat Inc. |
Extension | minewhat |
Version | 1.0.9 |
Comparing to | |
See all releases |
Code changes from version 1.0.8 to 1.0.9
- app/code/community/MineWhat/Insights/Block/Event/Checkout/Onepage/Success.php +4 -0
- app/design/frontend/base/default/template/minewhat/insights/event/catalog/product/view.phtml +1 -1
- app/design/frontend/base/default/template/minewhat/insights/event/checkout/cart/index.phtml +1 -1
- app/design/frontend/base/default/template/minewhat/insights/event/checkout/onepage/success.phtml +3 -3
- app/design/frontend/default/default/template/minewhat/insights/event/catalog/product/view.phtml +1 -1
- app/design/frontend/default/default/template/minewhat/insights/event/checkout/cart/index.phtml +1 -1
- app/design/frontend/default/default/template/minewhat/insights/event/checkout/onepage/success.phtml +3 -3
- package.xml +3 -3
app/code/community/MineWhat/Insights/Block/Event/Checkout/Onepage/Success.php
CHANGED
@@ -75,6 +75,10 @@ class MineWhat_Insights_Block_Event_Checkout_Onepage_Success extends Mage_Core_B
|
|
75 |
|
76 |
}
|
77 |
|
|
|
|
|
|
|
|
|
78 |
return $orderInfo;
|
79 |
}
|
80 |
|
75 |
|
76 |
}
|
77 |
|
78 |
+
$orderInfo['orderId'] = $lastOrderId;
|
79 |
+
$orderInfo['email'] = $order->getCustomerEmail();
|
80 |
+
$orderInfo['createdAt'] = $order->getCreatedAt();
|
81 |
+
|
82 |
return $orderInfo;
|
83 |
}
|
84 |
|
app/design/frontend/base/default/template/minewhat/insights/event/catalog/product/view.phtml
CHANGED
@@ -55,7 +55,7 @@
|
|
55 |
<script type="text/javascript">
|
56 |
//<![CDATA[
|
57 |
var _mwapi = _mwapi || [];
|
58 |
-
_mwapi.push(['trackEvent', 'product', '<?php echo $_product->getId() ?>', '<?php echo json_encode($associated_ids) ?>']);
|
59 |
//]]>
|
60 |
</script>
|
61 |
<?php } ?>
|
55 |
<script type="text/javascript">
|
56 |
//<![CDATA[
|
57 |
var _mwapi = _mwapi || [];
|
58 |
+
_mwapi.push(['trackEvent', 'product', {pid: '<?php echo $_product->getId() ?>', associated_ids: '<?php echo json_encode($associated_ids) ?>'}]);
|
59 |
//]]>
|
60 |
</script>
|
61 |
<?php } ?>
|
app/design/frontend/base/default/template/minewhat/insights/event/checkout/cart/index.phtml
CHANGED
@@ -11,7 +11,7 @@
|
|
11 |
<script type="text/javascript">
|
12 |
//<![CDATA[
|
13 |
var _mwapi = _mwapi || [];
|
14 |
-
_mwapi.push(['trackEvent', 'addtocart', '<?php echo $_product["id"] ?>', '<?php echo $_product["sku"] ?>', '<?php echo $_product["parentId"] ?>', '<?php echo $_product["qty"] ?>', '<?php echo json_encode($_product["bundle"]) ?>']);
|
15 |
//]]>
|
16 |
</script>
|
17 |
<?php } ?>
|
11 |
<script type="text/javascript">
|
12 |
//<![CDATA[
|
13 |
var _mwapi = _mwapi || [];
|
14 |
+
_mwapi.push(['trackEvent', 'addtocart', {pid: '<?php echo $_product["id"] ?>', sku: '<?php echo $_product["sku"] ?>', parent_pid: '<?php echo $_product["parentId"] ?>', qty: '<?php echo $_product["qty"] ?>', bundle: '<?php echo json_encode($_product["bundle"]) ?>'}]);
|
15 |
//]]>
|
16 |
</script>
|
17 |
<?php } ?>
|
app/design/frontend/base/default/template/minewhat/insights/event/checkout/onepage/success.phtml
CHANGED
@@ -10,11 +10,11 @@
|
|
10 |
<script type="text/javascript">
|
11 |
//<![CDATA[
|
12 |
var _mwapi = _mwapi || [];
|
13 |
-
var
|
14 |
<?php foreach ($orderInfo['items'] as $product) { ?>
|
15 |
-
|
16 |
<?php } ?>
|
17 |
-
_mwapi.push(['trackEvent', 'buy', '
|
18 |
//]]>
|
19 |
</script>
|
20 |
<?php } ?>
|
10 |
<script type="text/javascript">
|
11 |
//<![CDATA[
|
12 |
var _mwapi = _mwapi || [];
|
13 |
+
var products = [];
|
14 |
<?php foreach ($orderInfo['items'] as $product) { ?>
|
15 |
+
products.push({pid: '<?php echo $product["id"] ?>', qty: '<?php echo intval($product["qty"]) ?>', sku: '<?php echo $product["sku"] ?>', price: '<?php echo $product["price"] ?>', parent_pid: '<?php echo $product["parentId"] ?>', bundle: '<?php echo json_encode($product["bundle"]) ?>'});
|
16 |
<?php } ?>
|
17 |
+
_mwapi.push(['trackEvent', 'buy', {products: products, order: {order_number: '<?php echo $orderInfo["orderId"] ?>', created_at: '<?php echo $orderInfo["createdAt"] ?>', email: '<?php echo $orderInfo["email"] ?>'}, platform: "magento"}]);
|
18 |
//]]>
|
19 |
</script>
|
20 |
<?php } ?>
|
app/design/frontend/default/default/template/minewhat/insights/event/catalog/product/view.phtml
CHANGED
@@ -55,7 +55,7 @@
|
|
55 |
<script type="text/javascript">
|
56 |
//<![CDATA[
|
57 |
var _mwapi = _mwapi || [];
|
58 |
-
_mwapi.push(['trackEvent', 'product', '<?php echo $_product->getId() ?>', '<?php echo json_encode($associated_ids) ?>']);
|
59 |
//]]>
|
60 |
</script>
|
61 |
<?php } ?>
|
55 |
<script type="text/javascript">
|
56 |
//<![CDATA[
|
57 |
var _mwapi = _mwapi || [];
|
58 |
+
_mwapi.push(['trackEvent', 'product', {pid: '<?php echo $_product->getId() ?>', associated_ids: '<?php echo json_encode($associated_ids) ?>'}]);
|
59 |
//]]>
|
60 |
</script>
|
61 |
<?php } ?>
|
app/design/frontend/default/default/template/minewhat/insights/event/checkout/cart/index.phtml
CHANGED
@@ -11,7 +11,7 @@
|
|
11 |
<script type="text/javascript">
|
12 |
//<![CDATA[
|
13 |
var _mwapi = _mwapi || [];
|
14 |
-
_mwapi.push(['trackEvent', 'addtocart', '<?php echo $_product["id"] ?>', '<?php echo $_product["sku"] ?>', '<?php echo $_product["parentId"] ?>', '<?php echo $_product["qty"] ?>', '<?php echo json_encode($_product["bundle"]) ?>']);
|
15 |
//]]>
|
16 |
</script>
|
17 |
<?php } ?>
|
11 |
<script type="text/javascript">
|
12 |
//<![CDATA[
|
13 |
var _mwapi = _mwapi || [];
|
14 |
+
_mwapi.push(['trackEvent', 'addtocart', {pid: '<?php echo $_product["id"] ?>', sku: '<?php echo $_product["sku"] ?>', parent_pid: '<?php echo $_product["parentId"] ?>', qty: '<?php echo $_product["qty"] ?>', bundle: '<?php echo json_encode($_product["bundle"]) ?>'}]);
|
15 |
//]]>
|
16 |
</script>
|
17 |
<?php } ?>
|
app/design/frontend/default/default/template/minewhat/insights/event/checkout/onepage/success.phtml
CHANGED
@@ -10,11 +10,11 @@
|
|
10 |
<script type="text/javascript">
|
11 |
//<![CDATA[
|
12 |
var _mwapi = _mwapi || [];
|
13 |
-
var
|
14 |
<?php foreach ($orderInfo['items'] as $product) { ?>
|
15 |
-
|
16 |
<?php } ?>
|
17 |
-
_mwapi.push(['trackEvent', 'buy', '
|
18 |
//]]>
|
19 |
</script>
|
20 |
<?php } ?>
|
10 |
<script type="text/javascript">
|
11 |
//<![CDATA[
|
12 |
var _mwapi = _mwapi || [];
|
13 |
+
var products = [];
|
14 |
<?php foreach ($orderInfo['items'] as $product) { ?>
|
15 |
+
products.push({pid: '<?php echo $product["id"] ?>', qty: '<?php echo intval($product["qty"]) ?>', sku: '<?php echo $product["sku"] ?>', price: '<?php echo $product["price"] ?>', parent_pid: '<?php echo $product["parentId"] ?>', bundle: '<?php echo json_encode($product["bundle"]) ?>'});
|
16 |
<?php } ?>
|
17 |
+
_mwapi.push(['trackEvent', 'buy', {products: products, order: {order_number: '<?php echo $orderInfo["orderId"] ?>', created_at: '<?php echo $orderInfo["createdAt"] ?>', email: '<?php echo $orderInfo["email"] ?>'}, platform: "magento"}]);
|
18 |
//]]>
|
19 |
</script>
|
20 |
<?php } ?>
|
package.xml
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>minewhat</name>
|
4 |
-
<version>1.0.
|
5 |
<stability>stable</stability>
|
6 |
<license uri="http://opensource.org/licenses/osl-3.0.php">osl</license>
|
7 |
<channel>community</channel>
|
@@ -10,8 +10,8 @@
|
|
10 |
<description>MineWhat Insights</description>
|
11 |
<notes>MineWhat magento plugin</notes>
|
12 |
<authors><author><name>MineWhat Inc.</name><user>MineWhat</user><email>plugins@minewhat.com</email></author></authors>
|
13 |
-
<date>2014-06-
|
14 |
-
<time>
|
15 |
<contents><target name="magecommunity"><dir name="MineWhat"><dir name="Insights"><dir name="Block"><dir name="Base"><file name="Script.php" hash="4af0a2e100d9d33f99125a0a6e64421b"/></dir><dir name="Event"><dir name="Catalog"><dir name="Product"><file name="View.php" hash="e1f3e3e9172a1c42d520f4dd870b54b2"/></dir></dir><dir name="Checkout"><dir name="Cart"><file name="Index.php" hash="fafaf6953262ea2b0bc3092d538c30d1"/></dir><dir name="Onepage"><file name="Success.php" hash="0c314455071a35d765f8447ac7df6a44"/></dir></dir></dir></dir><dir name="Helper"><file name="Data.php" hash="f55be36b0f6e46f0fccd3a2dee670ec3"/></dir><dir name="Model"><file name="Observer.php" hash="509eb21a74d2693e0aa24d7acd039aae"/></dir><dir name="etc"><file name="adminhtml.xml" hash="f1fb655aac4dc7f71cadb6c7a7e816f8"/><file name="config.xml" hash="dfb8144831b6cee45bba4167076eb266"/><file name="system.xml" hash="75d5165628b2b748a985db0aef1e505d"/></dir></dir></dir></target><target name="magedesign"><dir name="frontend"><dir name="default"><dir name="default"><dir name="layout"><file name="minewhat_insights.xml" hash="81061e0839af5d4f44ca0e4ae5383ab2"/></dir><dir name="template"><dir name="minewhat"><dir name="insights"><dir name="base"><file name="script.phtml" hash="a6b4ecb06d6c40b402ad619425d4493d"/></dir><dir name="event"><dir name="catalog"><dir name="product"><file name="view.phtml" hash="4f4f45eb87b55cf2de64188fcac7f13b"/></dir></dir><dir name="checkout"><dir name="cart"><file name="index.phtml" hash="63393e384b3e8b8f76ccc74fc4db5dec"/></dir><dir name="onepage"><file name="success.phtml" hash="4614dfe802afe6e73b8707b536071912"/></dir></dir></dir></dir></dir></dir></dir></dir><dir name="base"><dir name="default"><dir name="layout"><file name="minewhat_insights.xml" hash="81061e0839af5d4f44ca0e4ae5383ab2"/></dir><dir name="template"><dir name="minewhat"><dir name="insights"><dir name="base"><file name="script.phtml" hash="a6b4ecb06d6c40b402ad619425d4493d"/></dir><dir name="event"><dir name="catalog"><dir name="product"><file name="view.phtml" hash="4f4f45eb87b55cf2de64188fcac7f13b"/></dir></dir><dir name="checkout"><dir name="cart"><file name="index.phtml" hash="63393e384b3e8b8f76ccc74fc4db5dec"/></dir><dir name="onepage"><file name="success.phtml" hash="4614dfe802afe6e73b8707b536071912"/></dir></dir></dir></dir></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="MineWhat_Insights.xml" hash="8d2f076cbfcc14688ed800f622869d4b"/></dir></target></contents>
|
16 |
<compatible/>
|
17 |
<dependencies><required><php><min>5.2.5</min><max>6.0.0</max></php></required></dependencies>
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>minewhat</name>
|
4 |
+
<version>1.0.9</version>
|
5 |
<stability>stable</stability>
|
6 |
<license uri="http://opensource.org/licenses/osl-3.0.php">osl</license>
|
7 |
<channel>community</channel>
|
10 |
<description>MineWhat Insights</description>
|
11 |
<notes>MineWhat magento plugin</notes>
|
12 |
<authors><author><name>MineWhat Inc.</name><user>MineWhat</user><email>plugins@minewhat.com</email></author></authors>
|
13 |
+
<date>2014-06-24</date>
|
14 |
+
<time>20:10:38</time>
|
15 |
<contents><target name="magecommunity"><dir name="MineWhat"><dir name="Insights"><dir name="Block"><dir name="Base"><file name="Script.php" hash="4af0a2e100d9d33f99125a0a6e64421b"/></dir><dir name="Event"><dir name="Catalog"><dir name="Product"><file name="View.php" hash="e1f3e3e9172a1c42d520f4dd870b54b2"/></dir></dir><dir name="Checkout"><dir name="Cart"><file name="Index.php" hash="fafaf6953262ea2b0bc3092d538c30d1"/></dir><dir name="Onepage"><file name="Success.php" hash="0c314455071a35d765f8447ac7df6a44"/></dir></dir></dir></dir><dir name="Helper"><file name="Data.php" hash="f55be36b0f6e46f0fccd3a2dee670ec3"/></dir><dir name="Model"><file name="Observer.php" hash="509eb21a74d2693e0aa24d7acd039aae"/></dir><dir name="etc"><file name="adminhtml.xml" hash="f1fb655aac4dc7f71cadb6c7a7e816f8"/><file name="config.xml" hash="dfb8144831b6cee45bba4167076eb266"/><file name="system.xml" hash="75d5165628b2b748a985db0aef1e505d"/></dir></dir></dir></target><target name="magedesign"><dir name="frontend"><dir name="default"><dir name="default"><dir name="layout"><file name="minewhat_insights.xml" hash="81061e0839af5d4f44ca0e4ae5383ab2"/></dir><dir name="template"><dir name="minewhat"><dir name="insights"><dir name="base"><file name="script.phtml" hash="a6b4ecb06d6c40b402ad619425d4493d"/></dir><dir name="event"><dir name="catalog"><dir name="product"><file name="view.phtml" hash="4f4f45eb87b55cf2de64188fcac7f13b"/></dir></dir><dir name="checkout"><dir name="cart"><file name="index.phtml" hash="63393e384b3e8b8f76ccc74fc4db5dec"/></dir><dir name="onepage"><file name="success.phtml" hash="4614dfe802afe6e73b8707b536071912"/></dir></dir></dir></dir></dir></dir></dir></dir><dir name="base"><dir name="default"><dir name="layout"><file name="minewhat_insights.xml" hash="81061e0839af5d4f44ca0e4ae5383ab2"/></dir><dir name="template"><dir name="minewhat"><dir name="insights"><dir name="base"><file name="script.phtml" hash="a6b4ecb06d6c40b402ad619425d4493d"/></dir><dir name="event"><dir name="catalog"><dir name="product"><file name="view.phtml" hash="4f4f45eb87b55cf2de64188fcac7f13b"/></dir></dir><dir name="checkout"><dir name="cart"><file name="index.phtml" hash="63393e384b3e8b8f76ccc74fc4db5dec"/></dir><dir name="onepage"><file name="success.phtml" hash="4614dfe802afe6e73b8707b536071912"/></dir></dir></dir></dir></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="MineWhat_Insights.xml" hash="8d2f076cbfcc14688ed800f622869d4b"/></dir></target></contents>
|
16 |
<compatible/>
|
17 |
<dependencies><required><php><min>5.2.5</min><max>6.0.0</max></php></required></dependencies>
|