Posixtech_NetworkMerchants - Version 1.0.0.3

Version Notes

Fix: Turn OFF response text checking for successful transaction.

Download this release

Release Info

Developer Posixtech Ltd.
Extension Posixtech_NetworkMerchants
Version 1.0.0.3
Comparing to
See all releases


Code changes from version 1.0.0.2 to 1.0.0.3

app/code/community/Posixtech/.DS_Store CHANGED
Binary file
app/code/community/Posixtech/NetworkMerchants/Model/PaymentMethod.php CHANGED
@@ -103,18 +103,14 @@ class Posixtech_NetworkMerchants_Model_PaymentMethod extends Mage_Payment_Model_
103
  $r = $this->doSale($request);
104
 
105
  if (isset($r['response']) && ($r['response'] == 1)) {
106
- if(isset($r['responsetext']) && (($r['responsetext'] == 'SUCCESS') || ($r['responsetext']=='Approved or completed successfully')) ) {
107
- $payment->setTransactionId($r['transactionid'])
108
- ->setCcApproval($r['authcode'])
109
- ->setCcTransId($r['transactionid'])
110
- ->setIsTransactionClosed(0)
111
- ->setParentTransactionId(null)
112
- ->setCcAvsStatus($r['avsresponse'])
113
- ->setCcCidStatus($r['cvvresponse']);
114
- return $this;
115
- } else {
116
- Mage::throwException('Transaction Declined: ' . $r['responsetext']);
117
- }
118
  } else {
119
  Mage::throwException('Transaction Declined: ' . $r['responsetext']);
120
  }
@@ -275,11 +271,10 @@ class Posixtech_NetworkMerchants_Model_PaymentMethod extends Mage_Payment_Model_
275
  $this->_preauthorizeCapture($payment,$amount);
276
 
277
  $transactionid = $payment->getTransactionId();
278
- $order = $payment->getOrder();
279
-
280
  $testMode = $this->getConfigData('test_mode');
281
- $username = '';
282
- $password = '';
283
  if($testMode) {
284
  $username = 'demo';
285
  $password = 'password';
@@ -303,16 +298,12 @@ class Posixtech_NetworkMerchants_Model_PaymentMethod extends Mage_Payment_Model_
303
  $result = $this->_doPost($query);
304
 
305
  if (isset($result['response']) && ($result['response'] == 1)) {
306
- if(isset($result['responsetext']) && (($result['responsetext'] == 'SUCCESS') || ($result['responsetext']=='Approved or completed successfully')) ) {
307
- $payment->setStatus(self::STATUS_APPROVED);
308
- $payment->setLastTransId($result['transactionid']);
309
- if (!$payment->getParentTransactionId() || $result['transactionid'] != $payment->getParentTransactionId()) {
310
- $payment->setTransactionId($result['transactionid']);
311
- }
312
- return $this;
313
- } else {
314
- Mage::throwException('Transaction Declined: ' . $result['transactionid']);
315
  }
 
316
  } else {
317
  Mage::throwException('Transaction Declined: ' . $result['transactionid']);
318
  }
@@ -334,18 +325,14 @@ class Posixtech_NetworkMerchants_Model_PaymentMethod extends Mage_Payment_Model_
334
  $r = $this->doSale($request);
335
 
336
  if (isset($r['response']) && ($r['response'] == 1)) {
337
- if(isset($r['responsetext']) && (($r['responsetext'] == 'SUCCESS') || ($r['responsetext']=='Approved or completed successfully')) ) {
338
- $payment->setTransactionId($r['transactionid'])
339
- ->setCcApproval($r['authcode'])
340
- ->setCcTransId($r['transactionid'])
341
- ->setIsTransactionClosed(0)
342
- ->setParentTransactionId(null)
343
- ->setCcAvsStatus($r['avsresponse'])
344
- ->setCcCidStatus($r['cvvresponse']);
345
- return $this;
346
- } else {
347
- Mage::throwException('Transaction Declined: ' . $r['responsetext']);
348
- }
349
  } else {
350
  Mage::throwException('Transaction Declined: ' . $r['responsetext']);
351
  }
103
  $r = $this->doSale($request);
104
 
105
  if (isset($r['response']) && ($r['response'] == 1)) {
106
+ $payment->setTransactionId($r['transactionid'])
107
+ ->setCcApproval($r['authcode'])
108
+ ->setCcTransId($r['transactionid'])
109
+ ->setIsTransactionClosed(0)
110
+ ->setParentTransactionId(null)
111
+ ->setCcAvsStatus($r['avsresponse'])
112
+ ->setCcCidStatus($r['cvvresponse']);
113
+ return $this;
 
 
 
 
114
  } else {
115
  Mage::throwException('Transaction Declined: ' . $r['responsetext']);
116
  }
271
  $this->_preauthorizeCapture($payment,$amount);
272
 
273
  $transactionid = $payment->getTransactionId();
274
+
 
275
  $testMode = $this->getConfigData('test_mode');
276
+ $username = null;
277
+ $password = null;
278
  if($testMode) {
279
  $username = 'demo';
280
  $password = 'password';
298
  $result = $this->_doPost($query);
299
 
300
  if (isset($result['response']) && ($result['response'] == 1)) {
301
+ $payment->setStatus(self::STATUS_APPROVED);
302
+ $payment->setLastTransId($result['transactionid']);
303
+ if (!$payment->getParentTransactionId() || $result['transactionid'] != $payment->getParentTransactionId()) {
304
+ $payment->setTransactionId($result['transactionid']);
 
 
 
 
 
305
  }
306
+ return $this;
307
  } else {
308
  Mage::throwException('Transaction Declined: ' . $result['transactionid']);
309
  }
325
  $r = $this->doSale($request);
326
 
327
  if (isset($r['response']) && ($r['response'] == 1)) {
328
+ $payment->setTransactionId($r['transactionid'])
329
+ ->setCcApproval($r['authcode'])
330
+ ->setCcTransId($r['transactionid'])
331
+ ->setIsTransactionClosed(0)
332
+ ->setParentTransactionId(null)
333
+ ->setCcAvsStatus($r['avsresponse'])
334
+ ->setCcCidStatus($r['cvvresponse']);
335
+ return $this;
 
 
 
 
336
  } else {
337
  Mage::throwException('Transaction Declined: ' . $r['responsetext']);
338
  }
app/code/community/Posixtech/NetworkMerchants/etc/config.xml CHANGED
@@ -36,7 +36,7 @@
36
  <config>
37
  <modules>
38
  <Posixtech_NetworkMerchants>
39
- <version>1.0.0.1</version>
40
  </Posixtech_NetworkMerchants>
41
  </modules>
42
  <global>
36
  <config>
37
  <modules>
38
  <Posixtech_NetworkMerchants>
39
+ <version>1.0.0.3</version>
40
  </Posixtech_NetworkMerchants>
41
  </modules>
42
  <global>
package.xml CHANGED
@@ -1,59 +1,45 @@
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>Posixtech_NetworkMerchants</name>
4
- <version>1.0.0.2</version>
5
- <stability>devel</stability>
6
  <license uri="http://www.posixtech.com/POSIXTECH_LTD_LICENSE.txt">POSIXTECH_LTD_LICENSE</license>
7
  <channel>community</channel>
8
  <extends/>
9
- <summary>What is 'NMI Direct Post API'?&#xD;
10
- The Direct Post method is the simplest integration method for both web-based and non web-based payment applications; however, merchants using this integration method should have passed a PCI vulnerability scans before use. For detail regarding this payment method, you can browse https://www.nmi.com/&#xD;
11
- Network Merchants Inc (NMI) provide solution regarding payment gateways for companies that want to process online transactions in real-time anywhere in the world through unique distribution channel and power of control. The 'First Call Resolution', 'Proprietary, Innovative &amp; Secure Products' and 'Non-Compete Guarantee' are key feature of NMI</summary>
12
- <description>Overview: &#xD;
13
- Network Merchants Inc. Payment Gateway Integration (Direct Post API)&#xD;
14
- &#xD;
15
- &#xD;
16
- What is &#x201C;NMI Direct Post API&#x201D;? The Direct Post method is the simplest integration method for both web-based and non web-based payment applications; however, merchants using this integration method should have passed a PCI vulnerability scans before use. For detail regarding this payment method, you can browse https://www.nmi.com/&#xD;
17
- &#xD;
18
- Network Merchants Inc (NMI) provide solution regarding payment gateways for companies that want to process online transactions in real-time anywhere in the world through unique distribution channel and power of control. The &#x2018;First Call Resolution&#x2019;, &#x2018;Proprietary, Innovative &amp; Secure Products&#x2019; and &#x2018;Non-Compete Guarantee&#x2019; are key feature of NMI&#xD;
19
- &#xD;
20
- This module is based on &#x2018;Transaction Request APIs&#x2019; and has following option &#xD;
21
- a. Authorize, &#xD;
22
- b. Authorize &amp; capture, &#xD;
23
- c. Void&#xD;
24
- d. Refund.&#xD;
25
- &#xD;
26
- &#xD;
27
- Customer Experience&#xD;
28
- 1. Free customer support.&#xD;
29
- 2. Free extension updates.&#xD;
30
- 3. Free bug fixing.&#xD;
31
- 4. PE compatibility&#xD;
32
- 5. Easy 2-minute installation&#xD;
33
- 6. All our extensions come open source&#xD;
34
- 7. Free upgrades during support period&#xD;
35
- 8. Our excellent support team is waiting to hear from you each business day from 9:00 am to 5:00 pm GMT&#xD;
36
- Visit Extension Page: http://store.posixtech.com/nmi-direct-post-api.html &#xD;
37
- User Guide: http://store.posixtech.com/nmi-direct-post-api.html &#xD;
38
  Please note you must already have a Network Merchants Inc account to use this module.&#xD;
39
- Please, check Magento versions compatibility on the product page!&#xD;
40
- &#xD;
41
- Questions? Require customization?&#xD;
42
- For any kind of question or feedback, feel free to contact us directly at info@posixtech.com&#xD;
43
- &#xD;
44
- Themes and extensions releases, updates &amp; promotions &#x2014; follow Posixtech on Twitter and Facebook!&#xD;
45
- </description>
46
- <notes>A payment method build from scratch to work seamlessly in Magento&#xD;
47
- &#xD;
48
- &#x2022; Version number: 1.0.0.1 &#xD;
49
- &#x2022; Stability: Stable &#xD;
50
- &#x2022; Compatibility: 1.5, 1.6, 1.7, 1.8 &#xD;
51
- &#xD;
52
- NMI Direct Post API payment method for Magento. Admin will able to configure payment method related option from System &gt; Configuration &gt; Payment Method plus much more.</notes>
53
- <authors><author><name>Posixtech Ltd.</name><user>posixtech</user><email>bank@posixtech.com</email></author></authors>
54
- <date>2013-11-22</date>
55
- <time>07:52:52</time>
56
- <contents><target name="magecommunity"><dir name="Posixtech"><dir name="NetworkMerchants"><dir name="Block"><dir name="Direct"><dir name="Form"><file name="Cc.php" hash="cc849c46ec15b74d9ccc67d503dced90"/><file name=".DS_Store" hash="5fee2b876e4438ab4b88b25b0cedd4e6"/></dir><dir name="Info"><file name="Cc.php" hash="1f65aaf483320075531780db1f65b1ea"/><file name=".DS_Store" hash="5fee2b876e4438ab4b88b25b0cedd4e6"/></dir><file name=".DS_Store" hash="1b57af7fedd28f88710e11d4342f43eb"/></dir><file name=".DS_Store" hash="2209c4ebeb79dd90152514adb95102bc"/></dir><dir name="Helper"><file name="Data.php" hash="921d622c9f7d889d93ee42216efdf8ce"/><file name=".DS_Store" hash="5cc9b356b8566590d84d1a846226a1e1"/></dir><dir name="Model"><dir name="Direct"><file name="Request.php" hash="bae335e36c9042dfc41d8c474ff8da71"/><file name=".DS_Store" hash="70d24aa344419921e5d1ec1fe72cc082"/></dir><file name="PaymentMethod.php" hash="5497092a3a8922837b890d7a6f3ec0d3"/><file name=".DS_Store" hash="807fb538f6177b96f9d87b07e0e99560"/></dir><dir name="etc"><file name="config.xml" hash="711c1181116bba1266884db4a354a4fa"/><file name="system.xml" hash="32c758ef339e07d89ed8393310cd38bc"/><file name=".DS_Store" hash="3cf7327b7340b7db7c031327cb542a62"/></dir><file name=".DS_Store" hash="7c43533d587efe5cf71deecbd962d309"/></dir><file name=".DS_Store" hash="6ad8c67a0c53cf2a589d82d057229899"/></dir></target><target name="magedesign"><dir name="frontend"><dir name="default"><dir name="default"><dir name="template"><dir name="networkmerchants"><dir name="form"><file name="cc.phtml" hash="4234692fc2a7bb37365255d07b4575c3"/><file name=".DS_Store" hash="860327bc9800f32ef30c2b37a9bec056"/></dir><file name=".DS_Store" hash="5d6ac7fcc92eca27e410fa88ac6df707"/></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Posixtech_NetworkMerchants.xml" hash="9742774cfc7565a93c52edb1206fdce3"/></dir></target></contents>
57
  <compatible/>
58
  <dependencies><required><php><min>5.1.0</min><max>6.0.0</max></php></required></dependencies>
59
  </package>
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>Posixtech_NetworkMerchants</name>
4
+ <version>1.0.0.3</version>
5
+ <stability>stable</stability>
6
  <license uri="http://www.posixtech.com/POSIXTECH_LTD_LICENSE.txt">POSIXTECH_LTD_LICENSE</license>
7
  <channel>community</channel>
8
  <extends/>
9
+ <summary>The Direct Post method is the simplest integration method for both web-based and non web-based payment.</summary>
10
+ <description>What is &#x201C;NMI Direct Post API&#x201D;? The Direct Post method is the simplest integration method for both web-based and non web-based payment applications; however, merchants using this integration method should have passed a PCI vulnerability scans before use. For detail regarding this payment method, you can browse &lt;a href="https://www.nmi.com/"&gt;https://www.nmi.com/&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&#xD;
11
+ &#xD;
12
+ Network Merchants Inc (NMI) provide solution regarding payment gateways for companies that want to process online transactions in real-time anywhere in the world through unique distribution channel and power of control. The &#x2018;First Call Resolution&#x2019;, &#x2018;Proprietary, Innovative &amp; Secure Products&#x2019; and &#x2018;Non-Compete Guarantee&#x2019; are key feature of NMI&lt;br /&gt;&lt;br /&gt;&#xD;
13
+ &#xD;
14
+ This module is based on &#x2018;Transaction Request APIs&#x2019; and has following options &lt;br /&gt;&#xD;
15
+ a. Authorize, &lt;br /&gt;&#xD;
16
+ b. Authorize &amp; capture, &lt;br /&gt;&#xD;
17
+ c. Void&lt;br /&gt;&#xD;
18
+ d. Refund.&lt;br /&gt;&#xD;
19
+ &lt;br /&gt;&#xD;
20
+ &lt;img src="http://store.posixtech.com/media/magento_extension_service/posixtech_guarantee.jpg" /&gt;&lt;br /&gt;&lt;br /&gt;&#xD;
21
+ &lt;b&gt;Customer Experience&lt;/b&gt;&lt;br /&gt;&#xD;
22
+ 1. Free customer support.&lt;br /&gt;&#xD;
23
+ 2. Free extension updates.&lt;br /&gt;&#xD;
24
+ 3. Free bug fixing.&lt;br /&gt;&#xD;
25
+ 4. PE compatibility&lt;br /&gt;&#xD;
26
+ 5. Easy 2-minute installation&lt;br /&gt;&#xD;
27
+ 6. All our extensions come open source&lt;br /&gt;&#xD;
28
+ 7. Free upgrades during support period&lt;br /&gt;&#xD;
29
+ 8. Our excellent support team is waiting to hear from you each business day from 9:00 am to 5:00 pm GMT&lt;br /&gt;&lt;br /&gt;&#xD;
30
+ &#xD;
31
+ Visit Extension Page: &lt;a href="http://store.posixtech.com/nmi-direct-post-api.html"&gt;http://store.posixtech.com/nmi-direct-post-api.html&lt;/a&gt;&#xD;
32
+ &lt;br /&gt;&lt;br /&gt;&#xD;
33
+ User Guide: &lt;a href="http://store.posixtech.com/nmi-direct-post-api.html"&gt;http://store.posixtech.com/nmi-direct-post-api.html&lt;/a&gt; &#xD;
34
+ &lt;br /&gt;&lt;br /&gt;&#xD;
 
 
 
35
  Please note you must already have a Network Merchants Inc account to use this module.&#xD;
36
+ &lt;br /&gt;&lt;br /&gt;&#xD;
37
+ Please, check Magento versions compatibility on the product page!</description>
38
+ <notes>Fix: Turn OFF response text checking for successful transaction.</notes>
39
+ <authors><author><name>Posixtech Ltd.</name><user>posixtech</user><email>info@posixtech.com</email></author></authors>
40
+ <date>2014-02-03</date>
41
+ <time>11:23:40</time>
42
+ <contents><target name="magecommunity"><dir name="Posixtech"><dir name="NetworkMerchants"><dir name="Block"><dir name="Direct"><dir name="Form"><file name="Cc.php" hash="cc849c46ec15b74d9ccc67d503dced90"/><file name=".DS_Store" hash="5fee2b876e4438ab4b88b25b0cedd4e6"/></dir><dir name="Info"><file name="Cc.php" hash="1f65aaf483320075531780db1f65b1ea"/><file name=".DS_Store" hash="5fee2b876e4438ab4b88b25b0cedd4e6"/></dir><file name=".DS_Store" hash="1b57af7fedd28f88710e11d4342f43eb"/></dir><file name=".DS_Store" hash="2209c4ebeb79dd90152514adb95102bc"/></dir><dir name="Helper"><file name="Data.php" hash="921d622c9f7d889d93ee42216efdf8ce"/><file name=".DS_Store" hash="5cc9b356b8566590d84d1a846226a1e1"/></dir><dir name="Model"><dir name="Direct"><file name="Request.php" hash="bae335e36c9042dfc41d8c474ff8da71"/><file name=".DS_Store" hash="70d24aa344419921e5d1ec1fe72cc082"/></dir><file name="PaymentMethod.php" hash="e662afc92cde387842d1681fb4d4858c"/><file name=".DS_Store" hash="807fb538f6177b96f9d87b07e0e99560"/></dir><dir name="etc"><file name="config.xml" hash="d359c4c1a978b7e9c8e4c7c427f78078"/><file name="system.xml" hash="32c758ef339e07d89ed8393310cd38bc"/><file name=".DS_Store" hash="3cf7327b7340b7db7c031327cb542a62"/></dir><file name=".DS_Store" hash="7c43533d587efe5cf71deecbd962d309"/></dir><file name=".DS_Store" hash="67263079577f97adc3e509bbc452593c"/></dir></target><target name="mageetc"><dir name="modules"><file name="Posixtech_NetworkMerchants.xml" hash="9742774cfc7565a93c52edb1206fdce3"/></dir></target><target name="magedesign"><dir name="frontend"><dir name="default"><dir name="default"><dir name="template"><dir name="networkmerchants"><dir name="form"><file name="cc.phtml" hash="4234692fc2a7bb37365255d07b4575c3"/><file name=".DS_Store" hash="860327bc9800f32ef30c2b37a9bec056"/></dir><file name=".DS_Store" hash="5d6ac7fcc92eca27e410fa88ac6df707"/></dir></dir></dir></dir></dir></target></contents>
 
 
 
 
 
 
 
 
 
 
 
43
  <compatible/>
44
  <dependencies><required><php><min>5.1.0</min><max>6.0.0</max></php></required></dependencies>
45
  </package>