Version Notes
Extension provides the ability for merchants to process through the CardConnect Gateway.
Download this release
Release Info
Developer | Team FireGento |
Extension | CardconnectCcgateway |
Version | 1.0.8 |
Comparing to | |
See all releases |
Code changes from version 1.0.7.1 to 1.0.8
- app/code/community/Cardconnect/Ccgateway/Model/.Standard.php.swp +0 -0
- app/code/community/Cardconnect/Ccgateway/Model/Standard.php +17 -43
- app/code/community/Cardconnect/Ccgateway/controllers/PaymentController.php +7 -1
- app/code/community/Cardconnect/Ccgateway/sql/cardconnect_ccgateway_setup/install-1.0.0.php +3 -3
- package.xml +4 -4
app/code/community/Cardconnect/Ccgateway/Model/.Standard.php.swp
ADDED
Binary file
|
app/code/community/Cardconnect/Ccgateway/Model/Standard.php
CHANGED
@@ -51,6 +51,8 @@ class Cardconnect_Ccgateway_Model_Standard extends Mage_Payment_Model_Method_Abs
|
|
51 |
protected $_order;
|
52 |
protected $_canCancelInvoice = true;
|
53 |
protected $_canSaveCc = true;
|
|
|
|
|
54 |
|
55 |
protected function _construct() {
|
56 |
parent::_construct();
|
@@ -76,45 +78,6 @@ class Cardconnect_Ccgateway_Model_Standard extends Mage_Payment_Model_Method_Abs
|
|
76 |
return $_url;
|
77 |
}
|
78 |
|
79 |
-
/**
|
80 |
-
* Return webservices url type string
|
81 |
-
*
|
82 |
-
* @return string
|
83 |
-
*/
|
84 |
-
public function getWebServicesUrl() {
|
85 |
-
|
86 |
-
$isTestMode = Mage::getModel('ccgateway/standard')->getConfigData('test_mode');
|
87 |
-
switch ($isTestMode) {
|
88 |
-
case 0:
|
89 |
-
$_webServicesUrl = 'https://fts.prinpay.com:8443/cardconnect/rest/';
|
90 |
-
break;
|
91 |
-
default:
|
92 |
-
$_webServicesUrl = 'https://fts.prinpay.com:6443/cardconnect/rest/';
|
93 |
-
break;
|
94 |
-
}
|
95 |
-
|
96 |
-
return $_webServicesUrl;
|
97 |
-
}
|
98 |
-
/**
|
99 |
-
* Return webservices url type string
|
100 |
-
*
|
101 |
-
* @return string
|
102 |
-
*/
|
103 |
-
public function getCardSecureApiUrl() {
|
104 |
-
|
105 |
-
$isTestMode = Mage::getModel('ccgateway/standard')->getConfigData('test_mode');
|
106 |
-
switch ($isTestMode) {
|
107 |
-
case 0:
|
108 |
-
$_cardSecureApiUrl = "https://fts.prinpay.com:8443/cardsecure/cs";
|
109 |
-
break;
|
110 |
-
default:
|
111 |
-
$_cardSecureApiUrl = 'https://fts.prinpay.com:6443/cardsecure/cs';
|
112 |
-
break;
|
113 |
-
}
|
114 |
-
|
115 |
-
return $_cardSecureApiUrl;
|
116 |
-
}
|
117 |
-
|
118 |
/**
|
119 |
* Return webservices keys location type string
|
120 |
*
|
@@ -282,7 +245,13 @@ class Cardconnect_Ccgateway_Model_Standard extends Mage_Payment_Model_Method_Abs
|
|
282 |
public function prepareSave() {
|
283 |
$info = $this->getInfoInstance();
|
284 |
if ($this->_canSaveCc) {
|
285 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
286 |
}
|
287 |
|
288 |
$info->setCcCidEnc($info->encrypt($info->getCcCid()));
|
@@ -313,9 +282,9 @@ class Cardconnect_Ccgateway_Model_Standard extends Mage_Payment_Model_Method_Abs
|
|
313 |
foreach ($collection as $data) {
|
314 |
$ccOwner = $data->getData("cc_owner");
|
315 |
$ccType = $data->getData("cc_type");
|
316 |
-
|
317 |
$ccExpiry = $data->getData("cc_exp_month") . substr($data->getData("cc_exp_year"), 2);
|
318 |
-
|
319 |
}
|
320 |
$price = $authAmount;
|
321 |
}
|
@@ -1027,7 +996,12 @@ class Cardconnect_Ccgateway_Model_Standard extends Mage_Payment_Model_Method_Abs
|
|
1027 |
} else {
|
1028 |
$retref = $response['retref'];
|
1029 |
// $ccToken = @$response['token'];
|
1030 |
-
|
|
|
|
|
|
|
|
|
|
|
1031 |
|
1032 |
$data = array('CC_ACTION' => $response['action'], /* Checkout Transaction Type */
|
1033 |
'CC_RETREF' => "$retref", /* Retrieval Reference Number */
|
51 |
protected $_order;
|
52 |
protected $_canCancelInvoice = true;
|
53 |
protected $_canSaveCc = true;
|
54 |
+
protected $_cclength = 0;
|
55 |
+
|
56 |
|
57 |
protected function _construct() {
|
58 |
parent::_construct();
|
78 |
return $_url;
|
79 |
}
|
80 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
81 |
/**
|
82 |
* Return webservices keys location type string
|
83 |
*
|
245 |
public function prepareSave() {
|
246 |
$info = $this->getInfoInstance();
|
247 |
if ($this->_canSaveCc) {
|
248 |
+
$_cclength = strlen($info->getCcNumber());
|
249 |
+
if (is_numeric($info->getCcNumber()) && $_cclength < 20) {
|
250 |
+
$info->setCcNumberEnc($info->encrypt($info->getCcNumber()));
|
251 |
+
} else {
|
252 |
+
$info->setCcCidEnc($info->encrypt($info->getCcCid()));
|
253 |
+
return $this;
|
254 |
+
}
|
255 |
}
|
256 |
|
257 |
$info->setCcCidEnc($info->encrypt($info->getCcCid()));
|
282 |
foreach ($collection as $data) {
|
283 |
$ccOwner = $data->getData("cc_owner");
|
284 |
$ccType = $data->getData("cc_type");
|
285 |
+
$ccNumber = Mage::helper('core')->decrypt($data->getData("cc_number_enc"));
|
286 |
$ccExpiry = $data->getData("cc_exp_month") . substr($data->getData("cc_exp_year"), 2);
|
287 |
+
$ccCvv2 = Mage::helper('core')->decrypt($data->getData("cc_cid_enc"));
|
288 |
}
|
289 |
$price = $authAmount;
|
290 |
}
|
996 |
} else {
|
997 |
$retref = $response['retref'];
|
998 |
// $ccToken = @$response['token'];
|
999 |
+
if (!empty($response['token'])){
|
1000 |
+
$ccToken = @$response['token'];
|
1001 |
+
} else {
|
1002 |
+
$ccToken ="";
|
1003 |
+
}
|
1004 |
+
|
1005 |
|
1006 |
$data = array('CC_ACTION' => $response['action'], /* Checkout Transaction Type */
|
1007 |
'CC_RETREF' => "$retref", /* Retrieval Reference Number */
|
app/code/community/Cardconnect/Ccgateway/controllers/PaymentController.php
CHANGED
@@ -101,7 +101,13 @@ class Cardconnect_Ccgateway_PaymentController extends Mage_Core_Controller_Front
|
|
101 |
$cc_action = Mage::getModel('ccgateway/standard')->getConfigData('checkout_trans' , $order->getStoreId());
|
102 |
$merchid = Mage::getModel('ccgateway/standard')->getConfigData('merchant' , $order->getStoreId());
|
103 |
|
104 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
105 |
|
106 |
if ($this->getRequest()->isPost()) {
|
107 |
$post = $this->getRequest()->getPost();
|
101 |
$cc_action = Mage::getModel('ccgateway/standard')->getConfigData('checkout_trans' , $order->getStoreId());
|
102 |
$merchid = Mage::getModel('ccgateway/standard')->getConfigData('merchant' , $order->getStoreId());
|
103 |
|
104 |
+
//$ccToken = "";
|
105 |
+
if (!empty($response['token'])){
|
106 |
+
$ccToken = $response['token'];
|
107 |
+
} else {
|
108 |
+
$ccToken ="";
|
109 |
+
}
|
110 |
+
|
111 |
|
112 |
if ($this->getRequest()->isPost()) {
|
113 |
$post = $this->getRequest()->getPost();
|
app/code/community/Cardconnect/Ccgateway/sql/cardconnect_ccgateway_setup/install-1.0.0.php
CHANGED
@@ -40,9 +40,9 @@ CREATE TABLE {$this->getTable('cardconnect_resp')} (
|
|
40 |
`CC_RETREF` VARCHAR(50),
|
41 |
`CC_AMT` DECIMAL(14,2),
|
42 |
`CC_AUTHCODE` VARCHAR(6),
|
43 |
-
`CC_ORDERID`
|
44 |
-
`CC_TOKEN`
|
45 |
-
`CC_MERCHID`
|
46 |
`CC_RESPSTAT` CHAR(1),
|
47 |
`CC_RESPCODE` CHAR(3),
|
48 |
`CC_RESPTEXT` VARCHAR(50),
|
40 |
`CC_RETREF` VARCHAR(50),
|
41 |
`CC_AMT` DECIMAL(14,2),
|
42 |
`CC_AUTHCODE` VARCHAR(6),
|
43 |
+
`CC_ORDERID` VARCHAR(50),
|
44 |
+
`CC_TOKEN` VARCHAR(50),
|
45 |
+
`CC_MERCHID` VARCHAR(50),
|
46 |
`CC_RESPSTAT` CHAR(1),
|
47 |
`CC_RESPCODE` CHAR(3),
|
48 |
`CC_RESPTEXT` VARCHAR(50),
|
package.xml
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>CardconnectCcgateway</name>
|
4 |
-
<version>1.0.
|
5 |
<stability>stable</stability>
|
6 |
<license uri="http://www.opensource.org/licenses/osl-3.0.php">OSL v3.0</license>
|
7 |
<channel>community</channel>
|
@@ -10,9 +10,9 @@
|
|
10 |
<description>The CardConnect solution is a powerful extension used for payment processing in eCommerce. We provide the option to process a payment through the Hosted Payment Page or Direct Post, in a safe and secure way. We also provide the ability of a wallet function which allows merchants to add/edit/delete card holder data for future payments. All Customer information is stored in a secured way; and allows Customers to make a secure payment as well. Please see the Integration Guide here for steps to install: http://cdn.cardconnect.com/docs/collateral/Magento-Integration_Guide_v1.2.pdf</description>
|
11 |
<notes>Extension provides the ability for merchants to process through the CardConnect Gateway.</notes>
|
12 |
<authors><author><name>AgileNova</name><user>Team</user><email>matt.wixson@agilenova.com</email></author></authors>
|
13 |
-
<date>2015-
|
14 |
-
<time>
|
15 |
-
<contents><target name="magecommunity"><dir name="Cardconnect"><dir name="Ccgateway"><dir name="Adminhtml"><dir name="Model"><dir name="System"><dir name="Config"><dir name="Source"><file name="Cardtype.php" hash="4c6fd9bc202c33e88f515349e1cd6905"/><file name="Checkouttype.php" hash="5468ed4e35f5aabf77ea65308b40d3a7"/><file name="Transaction.php" hash="6ba9e99fda4b19de82278800eb964bfb"/></dir></dir></dir></dir></dir><dir name="Block"><file name="Addcard.php" hash="def801e9a6c9351ffd488253c137c855"/><dir name="Adminhtml"><dir name="Customer"><file name="Data.php" hash="e401db541686c46a1f1f2db29aad7baf"/><dir name="Edit"><dir name="Tab"><file name="Account.php" hash="5ac21e8e4749605d36c5a47db115acca"/></dir></dir></dir><dir name="Sales"><dir name="Order"><dir name="Creditmemo"><dir name="Create"><file name="Form.php" hash="b856fbbd63401723571efaa76553a0aa"/><file name="Items.php" hash="696a59786bcf5f164f3bce6403cfc2ff"/></dir><dir name="View"><file name="Form.php" hash="2e3b0b6fbbfa159c27961b68b8420079"/></dir></dir><dir name="Invoice"><dir name="Create"><file name="Form.php" hash="0f7c57fa076ecd33e726337501d1d95b"/><file name="Items.php" hash="9b012dfb5fdbda0c20d4e163bd9ab662"/></dir><dir name="View"><file name="Form.php" hash="f25ee3483e04963f13c5e7fb82261408"/></dir></dir><dir name="Shipment"><dir name="Create"><file name="Form.php" hash="98ab8095084b6b21cdcd5cac5774987e"/></dir><dir name="View"><file name="Form.php" hash="e60bf6d244ea31ef68467c40d35bde98"/></dir></dir><dir name="View"><dir name="Tab"><file name="Info.php" hash="6e8ad75538f75f13fd483f2774d37621"/></dir></dir></dir></dir></dir><file name="Cardmanagement.php" hash="3d6ab227b63a89c5c3a7e5ebe5eddfad"/><file name="Form.php" hash="dc8294b3d1991476de13c9b20570605d"/><file name="Info.php" hash="5a30ffdd21b8fbb470fb0e9c07e9e82c"/><dir name="Onepage"><file name="Billing.php" hash="feca88ad00382cdb623921e004ada0f4"/></dir><file name="Redirect.php" hash="cfe86bec2d699ad474ee83f7bff118bb"/></dir><dir name="Helper"><file name="Data.php" hash="6ec07fb5ccc6ab30a0948da8941cb5bd"/></dir><dir name="Model"><dir name="Cardconnect"><file name="Resp.php" hash="b84483f77f4f5878be4ef5124e1cc9b4"/><file name="Wallet.php" hash="48fae16104d290466ce68bdb0091b4cd"/></dir><file name="Observer.php" hash="7e142307517c59a3b5b07dbbc4cae6e8"/><dir name="Resource"><dir name="Cardconnect"><dir name="Resp"><file name="Collection.php" hash="f91a8a542c331d96e9e0601a526bd1a2"/></dir><file name="Resp.php" hash="1689bf45552bf47bba76c595ce38618a"/><dir name="Wallet"><file name="Collection.php" hash="0e6c64693766cfb5e2ec56d01082eebd"/></dir><file name="Wallet.php" hash="0ffd67bd73177bb2ad32041cd32e4284"/></dir></dir><file name="Standard.php" hash="
|
16 |
<compatible/>
|
17 |
<dependencies><required><php><min>5.2.0</min><max>6.0.0</max></php></required></dependencies>
|
18 |
</package>
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>CardconnectCcgateway</name>
|
4 |
+
<version>1.0.8.2</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>
|
10 |
<description>The CardConnect solution is a powerful extension used for payment processing in eCommerce. We provide the option to process a payment through the Hosted Payment Page or Direct Post, in a safe and secure way. We also provide the ability of a wallet function which allows merchants to add/edit/delete card holder data for future payments. All Customer information is stored in a secured way; and allows Customers to make a secure payment as well. Please see the Integration Guide here for steps to install: http://cdn.cardconnect.com/docs/collateral/Magento-Integration_Guide_v1.2.pdf</description>
|
11 |
<notes>Extension provides the ability for merchants to process through the CardConnect Gateway.</notes>
|
12 |
<authors><author><name>AgileNova</name><user>Team</user><email>matt.wixson@agilenova.com</email></author></authors>
|
13 |
+
<date>2015-12-10</date>
|
14 |
+
<time>14:31:11</time>
|
15 |
+
<contents><target name="magecommunity"><dir name="Cardconnect"><dir name="Ccgateway"><dir name="Adminhtml"><dir name="Model"><dir name="System"><dir name="Config"><dir name="Source"><file name="Cardtype.php" hash="4c6fd9bc202c33e88f515349e1cd6905"/><file name="Checkouttype.php" hash="5468ed4e35f5aabf77ea65308b40d3a7"/><file name="Transaction.php" hash="6ba9e99fda4b19de82278800eb964bfb"/></dir></dir></dir></dir></dir><dir name="Block"><file name="Addcard.php" hash="def801e9a6c9351ffd488253c137c855"/><dir name="Adminhtml"><dir name="Customer"><file name="Data.php" hash="e401db541686c46a1f1f2db29aad7baf"/><dir name="Edit"><dir name="Tab"><file name="Account.php" hash="5ac21e8e4749605d36c5a47db115acca"/></dir></dir></dir><dir name="Sales"><dir name="Order"><dir name="Creditmemo"><dir name="Create"><file name="Form.php" hash="b856fbbd63401723571efaa76553a0aa"/><file name="Items.php" hash="696a59786bcf5f164f3bce6403cfc2ff"/></dir><dir name="View"><file name="Form.php" hash="2e3b0b6fbbfa159c27961b68b8420079"/></dir></dir><dir name="Invoice"><dir name="Create"><file name="Form.php" hash="0f7c57fa076ecd33e726337501d1d95b"/><file name="Items.php" hash="9b012dfb5fdbda0c20d4e163bd9ab662"/></dir><dir name="View"><file name="Form.php" hash="f25ee3483e04963f13c5e7fb82261408"/></dir></dir><dir name="Shipment"><dir name="Create"><file name="Form.php" hash="98ab8095084b6b21cdcd5cac5774987e"/></dir><dir name="View"><file name="Form.php" hash="e60bf6d244ea31ef68467c40d35bde98"/></dir></dir><dir name="View"><dir name="Tab"><file name="Info.php" hash="6e8ad75538f75f13fd483f2774d37621"/></dir></dir></dir></dir></dir><file name="Cardmanagement.php" hash="3d6ab227b63a89c5c3a7e5ebe5eddfad"/><file name="Form.php" hash="dc8294b3d1991476de13c9b20570605d"/><file name="Info.php" hash="5a30ffdd21b8fbb470fb0e9c07e9e82c"/><dir name="Onepage"><file name="Billing.php" hash="feca88ad00382cdb623921e004ada0f4"/></dir><file name="Redirect.php" hash="cfe86bec2d699ad474ee83f7bff118bb"/></dir><dir name="Helper"><file name="Data.php" hash="6ec07fb5ccc6ab30a0948da8941cb5bd"/></dir><dir name="Model"><dir name="Cardconnect"><file name="Resp.php" hash="b84483f77f4f5878be4ef5124e1cc9b4"/><file name="Wallet.php" hash="48fae16104d290466ce68bdb0091b4cd"/></dir><file name="Observer.php" hash="7e142307517c59a3b5b07dbbc4cae6e8"/><dir name="Resource"><dir name="Cardconnect"><dir name="Resp"><file name="Collection.php" hash="f91a8a542c331d96e9e0601a526bd1a2"/></dir><file name="Resp.php" hash="1689bf45552bf47bba76c595ce38618a"/><dir name="Wallet"><file name="Collection.php" hash="0e6c64693766cfb5e2ec56d01082eebd"/></dir><file name="Wallet.php" hash="0ffd67bd73177bb2ad32041cd32e4284"/></dir></dir><file name="Standard.php" hash="04878a67e253b70e5af6d79e63f89af7"/><file name="cardconnect_webservice.php" hash="baa5a5999739784325d0523a98a8b723"/><file name=".Standard.php.swp" hash="6845f8cc227a2aa6e4cb3bcd6c279e44"/></dir><dir name="blocks"><file name="billing.phtml" hash="24674ead62565508e2739cfda86669a8"/><dir name="creditmemo"><dir name="create"><file name="form.phtml" hash="1af2e3310737f3502ba26f4d3180e565"/></dir><dir name="view"><file name="form.phtml" hash="8754184850760738a00161b25d11d2c3"/></dir></dir><file name="info.phtml" hash="5d23267579d85f77d2038065619b998c"/><dir name="invoice"><dir name="create"><file name="form.phtml" hash="a7c52f4b0430a0a8be4fab9fd8e1462b"/><file name="items.phtml" hash="bc38033a2748716ee22eb200c8f29d4f"/></dir><dir name="view"><file name="form.phtml" hash="8bdf72eda5cc2b1170aa9b5f54728da0"/></dir></dir><dir name="shipment"><dir name="create"><file name="form.phtml" hash="ef541adc6774ec54cd0fd4f58d1c4cb6"/></dir><dir name="view"><file name="form.phtml" hash="1da4fa8006abee3517f1e18d3bf7e06c"/></dir></dir></dir><dir name="cc_keys"><file name="cacert.pem" hash="060fd410fecfc10d9c229b941868090c"/><file name=".htaccess" hash="d6a6f4184696bd7c56ae76973ec3489a"/></dir><dir name="controllers"><dir name="Adminhtml"><dir name="Sales"><dir name="Order"><file name="CreateController.php" hash="b0847bee66b63d057500a06d2102d034"/></dir><file name="OrderController.php" hash="d3a947e28c7dfaab5cbc5425fe5bc573"/></dir></dir><file name="CardmanagementController.php" hash="e1e0f5ad1df7f7c9e400b6c111a86124"/><file name="PaymentController.php" hash="a4b36228a9f94c8323f3aacc9d6fa4fa"/></dir><dir name="etc"><file name="config.xml" hash="444be1b3a9f3846ab4c760618dde5e20"/><file name="system.xml" hash="b931b80be0fac76b5adeb481e8bd6e3d"/></dir><dir name="sql"><dir name="cardconnect_ccgateway_setup"><file name="install-1.0.0.php" hash="c0d54dd38b639fb7577848d5c18a9b80"/></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Cardconnect_Ccgateway.xml" hash="eac8d5ee15ec6943fefc4dbbdef74671"/></dir></target><target name="mageskin"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="images"><dir name="cardconnect"><file name="cardconnect.gif" hash="b0ccf9c7446efd2bb6b65eadd98a3fde"/></dir></dir></dir></dir></dir><dir name="frontend"><dir name="base"><dir name="default"><dir name="css"><file name="cardconnect.css" hash="b58f299352d1bc2bebc47e3ed1ab3490"/></dir></dir></dir></dir></target><target name="magedesign"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="ccgateway.xml" hash="b84ef177b3e51da8203805b5ce094f19"/></dir><dir name="template"><dir name="ccgateway"><file name="form.phtml" hash="522f720341d93ed2b6da4c77bd94529b"/><file name="info.phtml" hash="9f608febdf1c537eb3f4c9933429c651"/></dir></dir></dir></dir></dir><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="ccgateway.xml" hash="55846fe0c9e2e2ec1ef96f196ae60843"/></dir><dir name="template"><dir name="ccgateway"><file name="blank.phtml" hash="d858f54e640d5b29bde38ed37ac3f8e8"/><dir name="cardmanagement"><file name="editcard.phtml" hash="4c3702b8459fb83f135efa2da6d89653"/><file name="index.phtml" hash="4917c72bd5cf1563957f2ad0c78ac84e"/><file name="new.phtml" hash="918fbb5c43137a1823ffee604570c561"/></dir><file name="form.phtml" hash="cfb468ebe4b5383a3d1d38dc4369cce1"/><file name="info.phtml" hash="de3d6b891ac68056b85db65c47a8f97f"/><file name="redirect.phtml" hash="4b3964b41e6e55bf54039f758e74560e"/></dir></dir></dir></dir></dir></target><target name="mage"><dir name="js"><dir name="cardconnect"><file name="ccgateway.js" hash="22b23a6677cf6b5c0a9c38e84accc9e1"/></dir></dir></target></contents>
|
16 |
<compatible/>
|
17 |
<dependencies><required><php><min>5.2.0</min><max>6.0.0</max></php></required></dependencies>
|
18 |
</package>
|