Craig_Tco - Version 2.3.1

Version Notes

Updating return logic to handle multiple currencies

Download this release

Release Info

Developer Magento Core Team
Extension Craig_Tco
Version 2.3.1
Comparing to
See all releases


Code changes from version 2.3.0 to 2.3.1

app/code/local/Craig/Tco/controllers/NotificationController.php CHANGED
@@ -47,7 +47,7 @@ class Craig_Tco_NotificationController extends Mage_Core_Controller_Front_Action
47
  $hashInvoice = $insMessage['invoice_id'];
48
  $StringToHash = strtoupper(md5($hashOrder . $hashSid . $hashInvoice . $hashSecretWord));
49
 
50
- if ($StringToHash != $insMessage['md5_hash'] && number_format($order->getBaseGrandTotal(), 2, '.', '') != $insMessage['invoice_list_amount']) {
51
  $order->addStatusHistoryComment('Hash or total did not match!');
52
  $order->save();
53
  die('Hash Incorrect');
47
  $hashInvoice = $insMessage['invoice_id'];
48
  $StringToHash = strtoupper(md5($hashOrder . $hashSid . $hashInvoice . $hashSecretWord));
49
 
50
+ if ($StringToHash != $insMessage['md5_hash'] && number_format($order->getGrandTotal(), 2, '.', '') != $insMessage['invoice_list_amount']) {
51
  $order->addStatusHistoryComment('Hash or total did not match!');
52
  $order->save();
53
  die('Hash Incorrect');
app/code/local/Craig/Tco/controllers/RedirectController.php CHANGED
@@ -56,7 +56,7 @@ class Craig_Tco_RedirectController extends Mage_Core_Controller_Front_Action {
56
  $order->loadByIncrementId($session->getLastRealOrderId());
57
  $hashSecretWord = Mage::getStoreConfig('payment/tco/secret_word');
58
  $hashSid = Mage::getStoreConfig('payment/tco/sid');
59
- $hashTotal = number_format($order->getBaseGrandTotal(), 2, '.', '');
60
 
61
  if (Mage::getStoreConfig('payment/tco/demo') == '1') {
62
  $hashOrder = '1';
@@ -80,4 +80,4 @@ class Craig_Tco_RedirectController extends Mage_Core_Controller_Front_Action {
80
  }
81
  }
82
 
83
- }
56
  $order->loadByIncrementId($session->getLastRealOrderId());
57
  $hashSecretWord = Mage::getStoreConfig('payment/tco/secret_word');
58
  $hashSid = Mage::getStoreConfig('payment/tco/sid');
59
+ $hashTotal = number_format($order->getGrandTotal(), 2, '.', '');
60
 
61
  if (Mage::getStoreConfig('payment/tco/demo') == '1') {
62
  $hashOrder = '1';
80
  }
81
  }
82
 
83
+ }
app/code/local/Craig/Tco/etc/config.xml CHANGED
@@ -24,7 +24,7 @@
24
  <config>
25
  <modules>
26
  <Craig_Tco>
27
- <version>2.2.1</version>
28
  </Craig_Tco>
29
  </modules>
30
  <global>
24
  <config>
25
  <modules>
26
  <Craig_Tco>
27
+ <version>2.3.1</version>
28
  </Craig_Tco>
29
  </modules>
30
  <global>
package.xml CHANGED
@@ -1,19 +1,18 @@
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>Craig_Tco</name>
4
- <version>2.3.0</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>2Checkout Payment Extension</summary>
10
- <description>2Checkout Payment Extension</description>
11
- <notes>Adding support for Direct Checkout&#xD;
12
- Updating Refund logic to support 1.7+</notes>
13
  <authors><author><name>Craig Christenson</name><user>auto-converted</user><email>cchristenson@2checkout.com</email></author></authors>
14
- <date>2013-04-22</date>
15
- <time>14:23:59</time>
16
- <contents><target name="mageetc"><dir name="modules"><file name="Craig_Tco.xml" hash="4a6e92678d9b2a310af880d35a4c355f"/></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="template"><dir name="tco"><file name="form.phtml" hash="08ae585e158550d0a5dccbed3d37758d"/><file name="info.phtml" hash="b714a7398773adc71ea086024dfc96b1"/></dir></dir></dir></dir></dir></target><target name="magelocal"><dir name="Craig"><dir name="Tco"><dir name="Block"><file name="Form.php" hash="b552018543f57090c42784d939004dd4"/><file name="Info.php" hash="ceb4ec03e4de3e4f1dafaf5d7da9b982"/><file name="Redirect.php" hash="d8a2e7a91476f2c0acf1de0b11bb2316"/></dir><dir name="controllers"><file name="NotificationController.php" hash="24237131f9fd8d537a1b400fbce272f0"/><file name="RedirectController.php" hash="e3ec6f4e46f22b9a2de916d463447ae8"/></dir><dir name="etc"><file name="config.xml" hash="ec868c128af27ef62506b78ea885221b"/><file name="system.xml" hash="8b8a49a75cd220f0ae7597d70c55f156"/></dir><dir name="Helper"><file name="Data.php" hash="de7680011db7d6821c1f68d70a8fa684"/></dir><dir name="Model"><file name="Checkout.php" hash="abc306412071808aaa015f0198efc4fb"/><file name="Observer.php" hash="c24b10be82be173a91cd6b53a0cbbd18"/></dir></dir></dir></target></contents>
17
  <compatible/>
18
  <dependencies/>
19
  </package>
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>Craig_Tco</name>
4
+ <version>2.3.1</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>2Checkout Payment Extension</summary>
10
+ <description>2Checkout Payment Module - Tested on 1.4.x, 1.5.x, 1.6.x, 1.7.x</description>
11
+ <notes>Updating return logic to handle multiple currencies</notes>
 
12
  <authors><author><name>Craig Christenson</name><user>auto-converted</user><email>cchristenson@2checkout.com</email></author></authors>
13
+ <date>2013-05-02</date>
14
+ <time>20:48:24</time>
15
+ <contents><target name="mageetc"><dir name="modules"><file name="Craig_Tco.xml" hash="4a6e92678d9b2a310af880d35a4c355f"/></dir></target><target name="magelocal"><dir name="Craig"><dir name="Tco"><dir name="Block"><file name="Form.php" hash="b552018543f57090c42784d939004dd4"/><file name="Redirect.php" hash="d8a2e7a91476f2c0acf1de0b11bb2316"/><file name="Info.php" hash="ceb4ec03e4de3e4f1dafaf5d7da9b982"/></dir><dir name="controllers"><file name="NotificationController.php" hash="5bf12db9cfc0719deea1f82dfe3fe1a2"/><file name="RedirectController.php" hash="234c09971716a837f84e459a7d15199f"/></dir><dir name="Model"><file name="Checkout.php" hash="abc306412071808aaa015f0198efc4fb"/><file name="Observer.php" hash="c24b10be82be173a91cd6b53a0cbbd18"/></dir><dir name="Helper"><file name="Data.php" hash="de7680011db7d6821c1f68d70a8fa684"/></dir><dir name="etc"><file name="config.xml" hash="9eb772f0d3b59f9f4cc431291eb99800"/><file name="system.xml" hash="8b8a49a75cd220f0ae7597d70c55f156"/></dir></dir></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="template"><dir name="tco"><file name="form.phtml" hash="08ae585e158550d0a5dccbed3d37758d"/><file name="info.phtml" hash="b714a7398773adc71ea086024dfc96b1"/></dir></dir></dir></dir></dir></target></contents>
16
  <compatible/>
17
  <dependencies/>
18
  </package>