Version Notes
Added ability to append coupon code to cart regeneration link
Download this release
Release Info
Developer | Magento Core Team |
Extension | Rejoiner |
Version | 1.1.20 |
Comparing to | |
See all releases |
Code changes from version 1.1.19 to 1.1.20
app/code/community/Rejoiner/Acr/controllers/AddbyskuController.php
CHANGED
@@ -16,7 +16,14 @@ class Rejoiner_Acr_AddbyskuController extends Mage_Core_Controller_Front_Action
|
|
16 |
$successMessage = '';
|
17 |
foreach ($params as $key => $product) {
|
18 |
if ($product && is_array($product)) {
|
19 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
20 |
$productId = $productBySKU->getId();
|
21 |
if ($productId) {
|
22 |
$qty = Mage::getModel('cataloginventory/stock_item')->loadByProduct($productId)->getQty();
|
16 |
$successMessage = '';
|
17 |
foreach ($params as $key => $product) {
|
18 |
if ($product && is_array($product)) {
|
19 |
+
if (!isset($product['sku'])) {
|
20 |
+
continue;
|
21 |
+
}
|
22 |
+
$productModel = Mage::getModel('catalog/product');
|
23 |
+
$productBySKU = $productModel->loadByAttribute('sku', $product['sku']);
|
24 |
+
if (!$productBySKU->getId()) {
|
25 |
+
continue;
|
26 |
+
}
|
27 |
$productId = $productBySKU->getId();
|
28 |
if ($productId) {
|
29 |
$qty = Mage::getModel('cataloginventory/stock_item')->loadByProduct($productId)->getQty();
|
app/code/community/Rejoiner/Acr/controllers/AddtocartController.php
CHANGED
@@ -11,6 +11,9 @@ class Rejoiner_Acr_AddtocartController extends Mage_Core_Controller_Front_Action
|
|
11 |
foreach ($params as $key => $product) {
|
12 |
if ($product && is_array($product)) {
|
13 |
$prodModel = Mage::getModel('catalog/product')->load((int)$product['product']);
|
|
|
|
|
|
|
14 |
try {
|
15 |
$cart->addProduct($prodModel, $product);
|
16 |
unset($params[$key]);
|
@@ -19,6 +22,9 @@ class Rejoiner_Acr_AddtocartController extends Mage_Core_Controller_Front_Action
|
|
19 |
}
|
20 |
}
|
21 |
}
|
|
|
|
|
|
|
22 |
$cart->save();
|
23 |
Mage::getSingleton('checkout/session')->setCartWasUpdated(true);
|
24 |
$this->getResponse()->setRedirect(Mage::getUrl('checkout/cart/', array('_query' => $params)));
|
11 |
foreach ($params as $key => $product) {
|
12 |
if ($product && is_array($product)) {
|
13 |
$prodModel = Mage::getModel('catalog/product')->load((int)$product['product']);
|
14 |
+
if (!$prodModel->getId()) {
|
15 |
+
continue;
|
16 |
+
}
|
17 |
try {
|
18 |
$cart->addProduct($prodModel, $product);
|
19 |
unset($params[$key]);
|
22 |
}
|
23 |
}
|
24 |
}
|
25 |
+
if ($params['coupon_code']) {
|
26 |
+
$cart->getQuote()->setCouponCode($params['coupon_code'])->collectTotals()->save();;
|
27 |
+
}
|
28 |
$cart->save();
|
29 |
Mage::getSingleton('checkout/session')->setCartWasUpdated(true);
|
30 |
$this->getResponse()->setRedirect(Mage::getUrl('checkout/cart/', array('_query' => $params)));
|
package.xml
CHANGED
@@ -1,18 +1,18 @@
|
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>Rejoiner</name>
|
4 |
-
<version>1.1.
|
5 |
<stability>stable</stability>
|
6 |
<license uri="http://www.opensource.org/licenses/osl-3.0.php">OSL v3.0</license>
|
7 |
<channel>community</channel>
|
8 |
<extends/>
|
9 |
<summary>Rejoiner Cart Abandonment Remarketing</summary>
|
10 |
<description>Turn abandoned carts into 15% more sales with Rejoiner</description>
|
11 |
-
<notes>Added
|
12 |
<authors><author><name>Mike</name><user>auto-converted</user><email>mike@rejoiner.com</email></author></authors>
|
13 |
-
<date>2016-01-
|
14 |
-
<time>13:
|
15 |
-
<contents><target name="mageetc"><dir name="modules"><file name="Rejoiner_Acr.xml" hash="1aad3601804cead81b6e687dfcb5b83f"/></dir></target><target name="magecommunity"><dir name="Rejoiner"><dir name="Acr"><dir name="Block"><dir name="Adminhtml"><dir name="Custom"><file name="Form.php" hash="88c8a6fa07de1c1f9ea12b79a791c370"/></dir><dir name="Form"><dir name="Field"><file name="Source.php" hash="87fca4bcce28c32b51d1ab0be864a11d"/></dir></dir><file name="Notification.php" hash="4b4837b59ab85fa886e65be49d511490"/><dir name="Preinstalled"><file name="Form.php" hash="04f5b18db325c2e630c103779c704ebe"/></dir></dir><file name="Snippets.php" hash="560ff9092b1083eaa45edf8e893cb890"/></dir><dir name="Helper"><file name="Data.php" hash="1533241a5b0dd30b987464a719c0c25a"/></dir><dir name="Model"><dir name="Api"><file name="Client.php" hash="d41d8cd98f00b204e9800998ecf8427e"/></dir><file name="Notification.php" hash="a03d68e9bbaa820ce87557fca9f8f811"/><file name="Observer.php" hash="6a90f25f0a4378f9b5dad032b0a975a5"/><dir name="Resource"><file name="Setup.php" hash="48f66ad159e3d10a21cc04a980ca923e"/></dir><dir name="System"><dir name="Config"><dir name="Source"><file name="Salesrule.php" hash="1b6a8d728b5fa308b18a222c5981ed52"/></dir></dir></dir></dir><dir name="controllers"><file name="AddbyskuController.php" hash="
|
16 |
<compatible/>
|
17 |
<dependencies><required><php><min>5.3.0</min><max>7.0.0</max></php></required></dependencies>
|
18 |
</package>
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>Rejoiner</name>
|
4 |
+
<version>1.1.20</version>
|
5 |
<stability>stable</stability>
|
6 |
<license uri="http://www.opensource.org/licenses/osl-3.0.php">OSL v3.0</license>
|
7 |
<channel>community</channel>
|
8 |
<extends/>
|
9 |
<summary>Rejoiner Cart Abandonment Remarketing</summary>
|
10 |
<description>Turn abandoned carts into 15% more sales with Rejoiner</description>
|
11 |
+
<notes>Added ability to append coupon code to cart regeneration link</notes>
|
12 |
<authors><author><name>Mike</name><user>auto-converted</user><email>mike@rejoiner.com</email></author></authors>
|
13 |
+
<date>2016-01-25</date>
|
14 |
+
<time>13:10:42</time>
|
15 |
+
<contents><target name="mageetc"><dir name="modules"><file name="Rejoiner_Acr.xml" hash="1aad3601804cead81b6e687dfcb5b83f"/></dir></target><target name="magecommunity"><dir name="Rejoiner"><dir name="Acr"><dir name="Block"><dir name="Adminhtml"><dir name="Custom"><file name="Form.php" hash="88c8a6fa07de1c1f9ea12b79a791c370"/></dir><dir name="Form"><dir name="Field"><file name="Source.php" hash="87fca4bcce28c32b51d1ab0be864a11d"/></dir></dir><file name="Notification.php" hash="4b4837b59ab85fa886e65be49d511490"/><dir name="Preinstalled"><file name="Form.php" hash="04f5b18db325c2e630c103779c704ebe"/></dir></dir><file name="Snippets.php" hash="560ff9092b1083eaa45edf8e893cb890"/></dir><dir name="Helper"><file name="Data.php" hash="1533241a5b0dd30b987464a719c0c25a"/></dir><dir name="Model"><dir name="Api"><file name="Client.php" hash="d41d8cd98f00b204e9800998ecf8427e"/></dir><file name="Notification.php" hash="a03d68e9bbaa820ce87557fca9f8f811"/><file name="Observer.php" hash="6a90f25f0a4378f9b5dad032b0a975a5"/><dir name="Resource"><file name="Setup.php" hash="48f66ad159e3d10a21cc04a980ca923e"/></dir><dir name="System"><dir name="Config"><dir name="Source"><file name="Salesrule.php" hash="1b6a8d728b5fa308b18a222c5981ed52"/></dir></dir></dir></dir><dir name="controllers"><file name="AddbyskuController.php" hash="2a09648d5550ab0c9b8f934615c2e8bf"/><file name="AddtocartController.php" hash="3449e820f5f46fc4aa12a5b989ddae89"/><dir name="Adminhtml"><file name="RejoinerController.php" hash="c2e5fea12a2fc23905d86f119c2baa39"/></dir></dir><dir name="etc"><file name="config.xml" hash="525db600c2c3572bc4fdfb3bb01121fb"/><file name="system.xml" hash="13cdcf93f5638abf82c1499db974dec5"/></dir><dir name="sql"><dir name="rejoiner_setup"><file name="mysql4-install-1.0.0.0.php" hash="8d9a21c9c09fe44c6fe51ddd2106e3e0"/><file name="mysql4-upgrade-1.0.0.0-1.0.1.0.php" hash="36cc70cc6dd37aab7f3c460e0af58d59"/></dir></dir></dir></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="rejoiner_acr.xml" hash="538d7561470c2cc1c7f822e7fe1ffef8"/></dir><dir name="template"><dir name="rejoiner_acr"><file name="conversion.phtml" hash="13a53b2f28e5f5fa6e0644ea9cf5a6a4"/><file name="email.phtml" hash="05e54d0999953acf865b6a439c4bb6b5"/><file name="tracking.phtml" hash="87e4d3e22c3b4876cca8ccb9cb3744c6"/></dir></dir></dir></dir></dir><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="rejoiner_acr.xml" hash="3181cf1ca63813a9ce633ed3268659f4"/></dir><dir name="template"><dir name="rejoiner_acr"><file name="notification.phtml" hash="3a3872e6434bf7d2ca7fa0edfe6f9726"/></dir></dir></dir></dir></dir></target><target name="magelocale"><dir name="en_US"><file name="Rejoiner_Acr.csv" hash="9015e31d97b9bc4746bc0a5241f8013b"/></dir></target></contents>
|
16 |
<compatible/>
|
17 |
<dependencies><required><php><min>5.3.0</min><max>7.0.0</max></php></required></dependencies>
|
18 |
</package>
|