File tree Expand file tree Collapse file tree 4 files changed +14
-18
lines changed Expand file tree Collapse file tree 4 files changed +14
-18
lines changed Original file line number Diff line number Diff line change @@ -57,8 +57,11 @@ public function performPayment(array $initial_response)
57
57
return $ this ->processPaymentCaptureResponse ($ payment );
58
58
}
59
59
catch (Exception $ e ) {
60
+ Mage::logException ($ e );
60
61
Mage::getSingleton ('checkout/session ' )->addError ($ e ->getMessage ());
61
- return Mage::app ()->getResponse ()->setRedirect ('cancel ' , array ('_secure ' =>true ));
62
+
63
+ $ this ->cancel ();
64
+ return Mage::app ()->getResponse ()->setRedirect ('failure ' , array ('_secure ' =>true ));
62
65
}
63
66
}
64
67
@@ -196,12 +199,11 @@ public function processPaymentCaptureResponse(array $request)
196
199
197
200
/**
198
201
* Cancel the order
199
- *
200
- * @param Mage_Sales_Model_Order $order
201
202
*/
202
- public function cancel (Mage_Sales_Model_Order $ order )
203
+ public function cancel ()
203
204
{
204
- $ order ->cancel ()->save ();
205
+ Mage::helper ('sign2pay ' )->setStatusOnOrder ($ this ->_order , 'Canceled ' );
206
+ $ this ->_order ->cancel ()->save ();
205
207
206
208
return $ this ;
207
209
}
Original file line number Diff line number Diff line change @@ -85,13 +85,7 @@ public function cancelAction()
85
85
$ session = Mage::getSingleton ('checkout/session ' );
86
86
$ session ->setQuoteId ($ session ->getSign2payQuoteId (true ));
87
87
if ($ session ->getLastRealOrderId ()) {
88
- $ order = Mage::getModel ('sales/order ' )->loadByIncrementId ($ session ->getLastRealOrderId ());
89
- if ($ order ->getId ()) {
90
- Mage::getModel ('sign2pay/processor ' )->cancel ($ order );
91
- }
92
88
Mage::helper ('sign2pay/checkout ' )->restoreQuote ();
93
- Mage::getSingleton ('checkout/session ' )->addError ("The payment has been cancelled. " );
94
-
95
89
}
96
90
$ this ->_redirect ('checkout/cart ' );
97
91
}
Original file line number Diff line number Diff line change 2
2
<config >
3
3
<modules >
4
4
<Sign2pay_Payment >
5
- <version >0.7.4 </version >
5
+ <version >0.7.5 </version >
6
6
</Sign2pay_Payment >
7
7
</modules >
8
8
Original file line number Diff line number Diff line change 1
1
<?xml version =" 1.0" ?>
2
2
<package >
3
3
<name >Sign2Pay_Mobile_Payments</name >
4
- <version >0.7.4 </version >
4
+ <version >0.7.5 </version >
5
5
<stability >beta</stability >
6
6
<license >Sign2Pay Commercial License</license >
7
7
<channel >community</channel >
@@ -13,13 +13,13 @@ Analysing hundreds of data points in a single signature, Sign2Pay provides the s
13
13

14
14
Compatible with: 1.7, 1.8, 1.9</description >
15
15
<notes >Changes:
16
- - Add dynamic bank logo to payment method label 
17
- - Add mobile phone number to authorize request 
16
+ - Simplify order cancelation workflow during payment
17
+ - Change logo url in admin section 
18
18
</notes >
19
19
<
authors ><
author ><
name >Sign2Pay</
name ><
user >Sign2Pay</
user ><
email >
[email protected] </
email ></
author ></
authors >
20
- <date >2015-11-24 </date >
21
- <time >15:36:47 </time >
22
- <contents><target name="magecommunity"><dir name="Sign2pay"><dir name="Payment"><dir name="Block"><dir name="Adminhtml"><file name="Notifications.php" hash="80a5205a24d830664b7f0a75c649c3ca"/></dir><dir name="Form"><file name="Sign2pay.php" hash="d32961e2b98a40b2e836ba080ece7b13"/></dir><dir name="Info"><file name="Sign2pay.php" hash="f24dfc1137275bb5963ac3ce115c9702"/></dir><file name="Redirect.php" hash="6541b32748997daa49f163fbc073692a"/><file name="RiskAssessment.php" hash="2404631636842acb48d0faa17bdaa0c0"/></dir><dir name="Helper"><file name="Checkout.php" hash="8dc4a28893064a1be1652eeb3e8092bb"/><file name="CountryCodes.php" hash="06142eb49e0d3290a78036e58fcc8d26"/><file name="Data.php" hash="a9cc9a7671f29b6e4685bb42b7694857"/></dir><dir name="Model"><dir name="Model"><dir name="System"><dir name="Config"><dir name="Source"><file name="OnepageTypes.php" hash="ef9973c103caa53d5dee6ff8bf13a547"/></dir></dir></dir></dir><file name="Observer.php" hash="b1c40e839b5a316dccc46ff25a691390"/><file name="Processor.php" hash="ac3799cd66646cf764337ecb1b9731d5"/><file name="Sign2pay.php" hash="d32ef2a9d5b9af7213fec934256effcd"/></dir><dir name="controllers"><file name="PaymentController.php" hash="aef7e5cdd64aac71793a4b2fb062b0b9"/></dir><dir name="etc"><file name="config.xml" hash="440f8b3b379381ec9458033fe54f5a87"/><file name="system.xml" hash="3b53e87a3157590c06f8370d5867320e"/></dir></dir></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="sign2pay.xml" hash="953d1389f9c540f790ffefc1541f2695"/></dir><dir name="template"><dir name="sign2pay"><dir name="form"><file name="sign2pay.phtml" hash="127ad19fb075adf3b1dea937fed82052"/></dir><file name="redirect.phtml" hash="f9fa638723240bd8e3f84ae3835a499c"/><file name="riskassessment.phtml" hash="9d15a0924c0ebe7516a4f2cf23b0be17"/><file name="success.phtml" hash="8670cd6c98497a862f1e134082c9f45c"/></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Sign2pay_Payment.xml" hash="62959f5fdbe4e43aee1ac6c3bffc0978"/></dir></target><target name="mageweb"><dir name="js"><dir name="sign2pay"><file name="jquery.min.js" hash="e0e0559014b222245deb26b6ae8bd940"/><file name="payment.js" hash="6d4bfd7bce9ef29ad133796cb280b488"/></dir></dir></target></contents>
20
+ <date >2015-11-27 </date >
21
+ <time >11:26:56 </time >
22
+ <contents><target name="magecommunity"><dir name="Sign2pay"><dir name="Payment"><dir name="Block"><dir name="Adminhtml"><file name="Notifications.php" hash="80a5205a24d830664b7f0a75c649c3ca"/></dir><dir name="Form"><file name="Sign2pay.php" hash="d32961e2b98a40b2e836ba080ece7b13"/></dir><dir name="Info"><file name="Sign2pay.php" hash="f24dfc1137275bb5963ac3ce115c9702"/></dir><file name="Redirect.php" hash="6541b32748997daa49f163fbc073692a"/><file name="RiskAssessment.php" hash="2404631636842acb48d0faa17bdaa0c0"/></dir><dir name="Helper"><file name="Checkout.php" hash="8dc4a28893064a1be1652eeb3e8092bb"/><file name="CountryCodes.php" hash="06142eb49e0d3290a78036e58fcc8d26"/><file name="Data.php" hash="a9cc9a7671f29b6e4685bb42b7694857"/></dir><dir name="Model"><dir name="Model"><dir name="System"><dir name="Config"><dir name="Source"><file name="OnepageTypes.php" hash="ef9973c103caa53d5dee6ff8bf13a547"/></dir></dir></dir></dir><file name="Observer.php" hash="b1c40e839b5a316dccc46ff25a691390"/><file name="Processor.php" hash="0a0124b4bbf7dcf8f3bf9d86c635db99"/><file name="Sign2pay.php" hash="d32ef2a9d5b9af7213fec934256effcd"/></dir><dir name="controllers"><file name="PaymentController.php" hash="0b49d4a50bf2301c6d45d271f602ddca"/></dir><dir name="etc"><file name="config.xml" hash="5d61019032214bfd5f7d8231e6b9b923"/><file name="system.xml" hash="327ceb144bc52677cfecf141ad9a3cdd"/></dir></dir></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="sign2pay.xml" hash="953d1389f9c540f790ffefc1541f2695"/></dir><dir name="template"><dir name="sign2pay"><dir name="form"><file name="sign2pay.phtml" hash="127ad19fb075adf3b1dea937fed82052"/></dir><file name="redirect.phtml" hash="f9fa638723240bd8e3f84ae3835a499c"/><file name="riskassessment.phtml" hash="9d15a0924c0ebe7516a4f2cf23b0be17"/><file name="success.phtml" hash="8670cd6c98497a862f1e134082c9f45c"/></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Sign2pay_Payment.xml" hash="62959f5fdbe4e43aee1ac6c3bffc0978"/></dir></target><target name="mageweb"><dir name="js"><dir name="sign2pay"><file name="jquery.min.js" hash="e0e0559014b222245deb26b6ae8bd940"/><file name="payment.js" hash="6d4bfd7bce9ef29ad133796cb280b488"/></dir></dir></target></contents>
23
23
<compatible />
24
24
<dependencies ><required ><php ><min >5.3.0</min ><max >6.0.0</max ></php ></required ></dependencies >
25
25
</package >
You can’t perform that action at this time.
0 commit comments