Version Notes
New Payson module
Download this release
Release Info
Developer | Oscar Villegas |
Extension | Payson |
Version | 1.8.2 |
Comparing to | |
See all releases |
Code changes from version 1.8.1 to 1.8.2
- app/code/community/Payson/Payson/Helper/Api.php +11 -4
- app/code/community/Payson/Payson/Model/Method/Invoice.php +54 -0
- app/code/community/Payson/Payson/Model/Order/Creditmemo/Total/Invoice.php +1 -1
- app/code/community/Payson/Payson/Model/Order/Invoice/Total/Invoice.php +1 -1
- app/code/community/Payson/Payson/Model/Quote/Address/Total/Invoice.php +1 -1
- app/code/community/Payson/Payson/controllers/Adminhtml/Sales/Order/ShipmentController.php +2 -1
- app/code/community/Payson/Payson/controllers/CheckoutController.php +24 -12
- app/code/community/Payson/Payson/etc/config.xml +1 -1
- app/code/community/Payson/Payson/etc/system.xml +2 -40
- app/code/community/Payson/Payson/etc/system.xml.bak +0 -185
- package.xml +4 -4
app/code/community/Payson/Payson/Helper/Api.php
CHANGED
@@ -16,8 +16,8 @@ class Payson_Payson_Helper_Api {
|
|
16 |
const API_CALL_PAYMENT_UPDATE = '%s://%sapi.payson.%s/%s/%sUpdate/';
|
17 |
const PAY_FORWARD_URL = '%s://%s%s.payson.%s/paySecure/';
|
18 |
const APPLICATION_ID = 'Magento';
|
19 |
-
const MODULE_NAME = '
|
20 |
-
const MODULE_VERSION = '1.0';
|
21 |
const DEBUG_MODE_MAIL = 'testagent-1@payson.se';
|
22 |
const DEBUG_MODE_AGENT_ID = '4';
|
23 |
const DEBUG_MODE_MD5 = '2acab30d-fe50-426f-90d7-8c60a7eb31d4';
|
@@ -28,6 +28,9 @@ class Payson_Payson_Helper_Api {
|
|
28 |
const STATUS_CREDITED = 'CREDITED';
|
29 |
const STATUS_INCOMPLETE = 'INCOMPLETE';
|
30 |
const STATUS_ERROR = 'ERROR';
|
|
|
|
|
|
|
31 |
const STATUS_EXPIRED = 'EXPIRED';
|
32 |
const STATUS_REVERSALERROR = 'REVERSALERROR';
|
33 |
const PAYMENT_METHOD_BANK = 'BANK';
|
@@ -78,7 +81,6 @@ class Payson_Payson_Helper_Api {
|
|
78 |
public function __construct() {
|
79 |
$this->_config = Mage::getModel('payson/config');
|
80 |
$this->_helper = Mage::helper('payson');
|
81 |
-
$this->_invoice = Mage::getModel('payson/method/invoice');
|
82 |
}
|
83 |
|
84 |
private function getHttpClient($url) {
|
@@ -933,6 +935,7 @@ LIMIT
|
|
933 |
}
|
934 |
|
935 |
case self::STATUS_ERROR:
|
|
|
936 |
|
937 |
$order->cancel();
|
938 |
|
@@ -943,9 +946,13 @@ LIMIT
|
|
943 |
|
944 |
case self::STATUS_INCOMPLETE:
|
945 |
case self::STATUS_EXPIRED:
|
|
|
|
|
946 |
$order->cancel();
|
947 |
|
948 |
-
$order->addStatusHistoryComment($this->_helper->__('The order was not completed within allocated time'));
|
|
|
|
|
949 |
case self::STATUS_REVERSALERROR:
|
950 |
default: {
|
951 |
$order->cancel();
|
16 |
const API_CALL_PAYMENT_UPDATE = '%s://%sapi.payson.%s/%s/%sUpdate/';
|
17 |
const PAY_FORWARD_URL = '%s://%s%s.payson.%s/paySecure/';
|
18 |
const APPLICATION_ID = 'Magento';
|
19 |
+
const MODULE_NAME = 'Payson_AllinOne';
|
20 |
+
const MODULE_VERSION = '1.0.2';
|
21 |
const DEBUG_MODE_MAIL = 'testagent-1@payson.se';
|
22 |
const DEBUG_MODE_AGENT_ID = '4';
|
23 |
const DEBUG_MODE_MD5 = '2acab30d-fe50-426f-90d7-8c60a7eb31d4';
|
28 |
const STATUS_CREDITED = 'CREDITED';
|
29 |
const STATUS_INCOMPLETE = 'INCOMPLETE';
|
30 |
const STATUS_ERROR = 'ERROR';
|
31 |
+
const STATUS_DENIED = 'DENIED';
|
32 |
+
const STATUS_ABORTED ='ABORTED';
|
33 |
+
const STATUS_CANCELED = 'CANCELED';
|
34 |
const STATUS_EXPIRED = 'EXPIRED';
|
35 |
const STATUS_REVERSALERROR = 'REVERSALERROR';
|
36 |
const PAYMENT_METHOD_BANK = 'BANK';
|
81 |
public function __construct() {
|
82 |
$this->_config = Mage::getModel('payson/config');
|
83 |
$this->_helper = Mage::helper('payson');
|
|
|
84 |
}
|
85 |
|
86 |
private function getHttpClient($url) {
|
935 |
}
|
936 |
|
937 |
case self::STATUS_ERROR:
|
938 |
+
case self::STATUS_DENIED:
|
939 |
|
940 |
$order->cancel();
|
941 |
|
946 |
|
947 |
case self::STATUS_INCOMPLETE:
|
948 |
case self::STATUS_EXPIRED:
|
949 |
+
case self::STATUS_CANCELED:
|
950 |
+
case self::STATUS_ABORTED:
|
951 |
$order->cancel();
|
952 |
|
953 |
+
$order->addStatusHistoryComment($this->_helper->__('The order was canceled or not completed within allocated time'));
|
954 |
+
break;
|
955 |
+
|
956 |
case self::STATUS_REVERSALERROR:
|
957 |
default: {
|
958 |
$order->cancel();
|
app/code/community/Payson/Payson/Model/Method/Invoice.php
ADDED
@@ -0,0 +1,54 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
class Payson_Payson_Model_Method_Invoice extends Payson_Payson_Model_Method_Abstract {
|
4 |
+
/*
|
5 |
+
* Protected properties
|
6 |
+
*/
|
7 |
+
|
8 |
+
/**
|
9 |
+
* @inheritDoc
|
10 |
+
*/
|
11 |
+
protected $_code = 'payson_invoice';
|
12 |
+
|
13 |
+
/**
|
14 |
+
* @inheritDoc
|
15 |
+
*/
|
16 |
+
protected $_canCapture = true;
|
17 |
+
protected $_canRefund = true;
|
18 |
+
protected $_canVoid = true;
|
19 |
+
protected $_canUseCheckout = false;
|
20 |
+
|
21 |
+
/*
|
22 |
+
* Public methods
|
23 |
+
*/
|
24 |
+
|
25 |
+
/**
|
26 |
+
* @inheritDoc
|
27 |
+
*/
|
28 |
+
|
29 |
+
public function capture(Varien_Object $payment, $amount) {
|
30 |
+
|
31 |
+
$order = $payment->getOrder();
|
32 |
+
|
33 |
+
$order_id = $order->getData('increment_id');
|
34 |
+
|
35 |
+
$api = Mage::helper('payson/api');
|
36 |
+
$helper = Mage::helper('payson');
|
37 |
+
$api->PaymentDetails($order_id);
|
38 |
+
$details = $api->GetResponse();
|
39 |
+
|
40 |
+
if (($details->type ===
|
41 |
+
Payson_Payson_Helper_Api::PAYMENT_METHOD_INVOICE) ||
|
42 |
+
($details->invoiceStatus ===
|
43 |
+
Payson_Payson_Helper_Api::INVOICE_STATUS_ORDERCREATED)) {
|
44 |
+
$api->PaymentUpdate($order_id, Payson_Payson_Helper_Api::UPDATE_ACTION_SHIPORDER);
|
45 |
+
|
46 |
+
$order->addStatusHistoryComment($helper->__(
|
47 |
+
'Order was activated at Payson'));
|
48 |
+
} else {
|
49 |
+
Mage::throwException($helper->__('Payson is not ready to create an invoice. Please try again later.'));
|
50 |
+
}
|
51 |
+
|
52 |
+
return $this;
|
53 |
+
}
|
54 |
+
}
|
app/code/community/Payson/Payson/Model/Order/Creditmemo/Total/Invoice.php
CHANGED
@@ -12,7 +12,7 @@ Mage_Sales_Model_Order_Creditmemo_Total_Abstract {
|
|
12 |
if(!$this->_config->CanInvoicePayment()){
|
13 |
return $this;
|
14 |
}
|
15 |
-
if ($method !== 'payson_standard') {
|
16 |
return $this;
|
17 |
}
|
18 |
|
12 |
if(!$this->_config->CanInvoicePayment()){
|
13 |
return $this;
|
14 |
}
|
15 |
+
if (($method !== 'payson_standard')||($method == "payson_invoice")) {
|
16 |
return $this;
|
17 |
}
|
18 |
|
app/code/community/Payson/Payson/Model/Order/Invoice/Total/Invoice.php
CHANGED
@@ -11,7 +11,7 @@ Mage_Sales_Model_Order_Invoice_Total_Abstract {
|
|
11 |
return $this;
|
12 |
}
|
13 |
$method = $order->getPayment()->getMethodInstance()->getCode();
|
14 |
-
if ($method !== 'payson_standard') {
|
15 |
return $this;
|
16 |
}
|
17 |
if ($order->hasInvoices() == 0) {
|
11 |
return $this;
|
12 |
}
|
13 |
$method = $order->getPayment()->getMethodInstance()->getCode();
|
14 |
+
if (($method !== 'payson_standard')||($method == "payson_invoice")) {
|
15 |
return $this;
|
16 |
}
|
17 |
if ($order->hasInvoices() == 0) {
|
app/code/community/Payson/Payson/Model/Quote/Address/Total/Invoice.php
CHANGED
@@ -20,7 +20,7 @@ class Payson_Payson_Model_Quote_Address_Total_Invoice extends Mage_Sales_Model_Q
|
|
20 |
if (!$this->_config->CanInvoicePayment()) {
|
21 |
return $this;
|
22 |
}
|
23 |
-
if ($method !== 'payson_standard') {
|
24 |
return $this;
|
25 |
}
|
26 |
|
20 |
if (!$this->_config->CanInvoicePayment()) {
|
21 |
return $this;
|
22 |
}
|
23 |
+
if (($method !== 'payson_standard')||($method == "payson_invoice")) {
|
24 |
return $this;
|
25 |
}
|
26 |
|
app/code/community/Payson/Payson/controllers/Adminhtml/Sales/Order/ShipmentController.php
CHANGED
@@ -8,7 +8,7 @@ class Payson_Payson_Adminhtml_Sales_Order_ShipmentController extends Mage_Adminh
|
|
8 |
|
9 |
$order = Mage::getModel('sales/order')->load($this->getRequest()->getParam('order_id'));
|
10 |
|
11 |
-
if ($order->getPayment()->getMethodInstance()->getCode() == "payson_standard") {
|
12 |
$invoice = Mage::getModel('sales/service_order', $order)->prepareInvoice();
|
13 |
$invoice->setRequestedCaptureCase(Mage_Sales_Model_Order_Invoice::CAPTURE_ONLINE);
|
14 |
$invoice->register();
|
@@ -20,6 +20,7 @@ class Payson_Payson_Adminhtml_Sales_Order_ShipmentController extends Mage_Adminh
|
|
20 |
|
21 |
parent::saveAction();
|
22 |
}
|
|
|
23 |
}
|
24 |
|
25 |
}
|
8 |
|
9 |
$order = Mage::getModel('sales/order')->load($this->getRequest()->getParam('order_id'));
|
10 |
|
11 |
+
if (($order->getPayment()->getMethodInstance()->getCode() == "payson_standard")||($order->getPayment()->getMethodInstance()->getCode() == "payson_invoice")) {
|
12 |
$invoice = Mage::getModel('sales/service_order', $order)->prepareInvoice();
|
13 |
$invoice->setRequestedCaptureCase(Mage_Sales_Model_Order_Invoice::CAPTURE_ONLINE);
|
14 |
$invoice->register();
|
20 |
|
21 |
parent::saveAction();
|
22 |
}
|
23 |
+
|
24 |
}
|
25 |
|
26 |
}
|
app/code/community/Payson/Payson/controllers/CheckoutController.php
CHANGED
@@ -69,8 +69,6 @@ class Payson_Payson_CheckoutController extends Mage_Core_Controller_Front_Action
|
|
69 |
return $this;
|
70 |
}
|
71 |
|
72 |
-
|
73 |
-
|
74 |
public function redirectAction() {
|
75 |
|
76 |
$order = $this->getOrder();
|
@@ -102,12 +100,13 @@ class Payson_Payson_CheckoutController extends Mage_Core_Controller_Front_Action
|
|
102 |
$this->_redirect('checkout/cart');
|
103 |
}
|
104 |
}
|
|
|
105 |
public function returnAction() {
|
106 |
$order = $this->getOrder();
|
107 |
|
108 |
$paymentDetailsResponse = Mage::helper('payson/api')->PaymentDetails(Mage::getSingleton('checkout/session')->getLastRealOrderId())->getResponse();
|
109 |
$paymentStatus = $paymentDetailsResponse->status;
|
110 |
-
$paymentDetails
|
111 |
$new_paymentDetails = array();
|
112 |
foreach ($paymentDetails as $item) {
|
113 |
foreach ($item as $key => $value) {
|
@@ -123,13 +122,13 @@ class Payson_Payson_CheckoutController extends Mage_Core_Controller_Front_Action
|
|
123 |
case 'PENDING':
|
124 |
case 'PROCESSING':
|
125 |
case 'CREDITED': {
|
126 |
-
|
127 |
|
128 |
if ($paymentDetailsResponse->type !== 'INVOICE' && $paymentDetailsResponse->status === 'COMPLETED') {
|
129 |
$order->setState(Mage_Sales_Model_Order::STATE_PROCESSING, true);
|
130 |
$order->sendNewOrderEmail()->save();
|
131 |
-
$order['payson_invoice_fee']= 0;
|
132 |
-
$order['base_payson_invoice_fee']=0;
|
133 |
|
134 |
$invoice = Mage::getModel('sales/service_order', $order)->prepareInvoice();
|
135 |
$invoice->setRequestedCaptureCase(Mage_Sales_Model_Order_Invoice::CAPTURE_ONLINE);
|
@@ -145,19 +144,19 @@ class Payson_Payson_CheckoutController extends Mage_Core_Controller_Front_Action
|
|
145 |
if ($paymentDetailsResponse->type !== 'INVOICE' && $paymentDetailsResponse->status === 'PROCESSING') {
|
146 |
$order->setState(Mage_Sales_Model_Order::STATE_PENDING_PAYMENT, true);
|
147 |
Mage::getSingleton('core/session')->addError(sprintf(Mage::helper('payson')->__('Your payment is being processed by Payson')));
|
148 |
-
$order['payson_invoice_fee']= 0;
|
149 |
-
$order['base_payson_invoice_fee']=0;
|
150 |
$this->_redirect('checkout/onepage/success');
|
151 |
break;
|
152 |
}
|
153 |
if ($paymentDetailsResponse->type !== 'INVOICE' && $paymentDetailsResponse->status === 'PENDING') {
|
154 |
Mage::getSingleton('core/session')->addError(sprintf(Mage::helper('payson')->__('Something went wrong with the payment. Please, try a different payment method')));
|
155 |
-
$order['payson_invoice_fee']= 0;
|
156 |
-
$order['base_payson_invoice_fee']=0;
|
157 |
$this->_redirect('checkout/onepage/failure');
|
158 |
break;
|
159 |
}
|
160 |
-
|
161 |
if ($paymentDetailsResponse->type === 'INVOICE' && $paymentDetailsResponse->type !== 'TRANSFER') {
|
162 |
$order->setState(Mage_Sales_Model_Order::STATE_PROCESSING, true);
|
163 |
$order->sendNewOrderEmail()->save();
|
@@ -169,13 +168,26 @@ class Payson_Payson_CheckoutController extends Mage_Core_Controller_Front_Action
|
|
169 |
break;
|
170 |
}
|
171 |
}
|
172 |
-
case 'ERROR':
|
|
|
173 |
$errorMessage = Mage::helper('payson')->__('The payment was denied by Payson. Please, try a different payment method');
|
174 |
Mage::getSingleton('core/session')->addError($errorMessage);
|
175 |
$this->cancelOrder($errorMessage);
|
176 |
$this->_redirect('checkout');
|
177 |
break;
|
178 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
179 |
default: {
|
180 |
Mage::getSingleton('core/session')->addError(sprintf(Mage::helper('payson')->__('Something went wrong with the payment. Please, try a different payment method')));
|
181 |
$this->_redirect('checkout');
|
69 |
return $this;
|
70 |
}
|
71 |
|
|
|
|
|
72 |
public function redirectAction() {
|
73 |
|
74 |
$order = $this->getOrder();
|
100 |
$this->_redirect('checkout/cart');
|
101 |
}
|
102 |
}
|
103 |
+
|
104 |
public function returnAction() {
|
105 |
$order = $this->getOrder();
|
106 |
|
107 |
$paymentDetailsResponse = Mage::helper('payson/api')->PaymentDetails(Mage::getSingleton('checkout/session')->getLastRealOrderId())->getResponse();
|
108 |
$paymentStatus = $paymentDetailsResponse->status;
|
109 |
+
$paymentDetails = $paymentDetailsResponse->receiverList->receiver->ToArray();
|
110 |
$new_paymentDetails = array();
|
111 |
foreach ($paymentDetails as $item) {
|
112 |
foreach ($item as $key => $value) {
|
122 |
case 'PENDING':
|
123 |
case 'PROCESSING':
|
124 |
case 'CREDITED': {
|
125 |
+
|
126 |
|
127 |
if ($paymentDetailsResponse->type !== 'INVOICE' && $paymentDetailsResponse->status === 'COMPLETED') {
|
128 |
$order->setState(Mage_Sales_Model_Order::STATE_PROCESSING, true);
|
129 |
$order->sendNewOrderEmail()->save();
|
130 |
+
$order['payson_invoice_fee'] = 0;
|
131 |
+
$order['base_payson_invoice_fee'] = 0;
|
132 |
|
133 |
$invoice = Mage::getModel('sales/service_order', $order)->prepareInvoice();
|
134 |
$invoice->setRequestedCaptureCase(Mage_Sales_Model_Order_Invoice::CAPTURE_ONLINE);
|
144 |
if ($paymentDetailsResponse->type !== 'INVOICE' && $paymentDetailsResponse->status === 'PROCESSING') {
|
145 |
$order->setState(Mage_Sales_Model_Order::STATE_PENDING_PAYMENT, true);
|
146 |
Mage::getSingleton('core/session')->addError(sprintf(Mage::helper('payson')->__('Your payment is being processed by Payson')));
|
147 |
+
$order['payson_invoice_fee'] = 0;
|
148 |
+
$order['base_payson_invoice_fee'] = 0;
|
149 |
$this->_redirect('checkout/onepage/success');
|
150 |
break;
|
151 |
}
|
152 |
if ($paymentDetailsResponse->type !== 'INVOICE' && $paymentDetailsResponse->status === 'PENDING') {
|
153 |
Mage::getSingleton('core/session')->addError(sprintf(Mage::helper('payson')->__('Something went wrong with the payment. Please, try a different payment method')));
|
154 |
+
$order['payson_invoice_fee'] = 0;
|
155 |
+
$order['base_payson_invoice_fee'] = 0;
|
156 |
$this->_redirect('checkout/onepage/failure');
|
157 |
break;
|
158 |
}
|
159 |
+
//Update the order with the true amount
|
160 |
if ($paymentDetailsResponse->type === 'INVOICE' && $paymentDetailsResponse->type !== 'TRANSFER') {
|
161 |
$order->setState(Mage_Sales_Model_Order::STATE_PROCESSING, true);
|
162 |
$order->sendNewOrderEmail()->save();
|
168 |
break;
|
169 |
}
|
170 |
}
|
171 |
+
case 'ERROR':
|
172 |
+
case 'DENIED': {
|
173 |
$errorMessage = Mage::helper('payson')->__('The payment was denied by Payson. Please, try a different payment method');
|
174 |
Mage::getSingleton('core/session')->addError($errorMessage);
|
175 |
$this->cancelOrder($errorMessage);
|
176 |
$this->_redirect('checkout');
|
177 |
break;
|
178 |
}
|
179 |
+
case 'ABORTED':
|
180 |
+
case 'CANCELED': {
|
181 |
+
$order->setState(Mage_Sales_Model_Order::STATE_CANCELED, true);
|
182 |
+
$cancelMessage = Mage::helper('payson')->__('Order was canceled at Payson');
|
183 |
+
$this->cancelOrder($cancelMessage);
|
184 |
+
if ($this->_config->restoreCartOnCancel()) {
|
185 |
+
$this->restoreCart();
|
186 |
+
}
|
187 |
+
$this->_redirect('checkout');
|
188 |
+
}
|
189 |
+
|
190 |
+
|
191 |
default: {
|
192 |
Mage::getSingleton('core/session')->addError(sprintf(Mage::helper('payson')->__('Something went wrong with the payment. Please, try a different payment method')));
|
193 |
$this->_redirect('checkout');
|
app/code/community/Payson/Payson/etc/config.xml
CHANGED
@@ -2,7 +2,7 @@
|
|
2 |
<config>
|
3 |
<modules>
|
4 |
<Payson_Payson>
|
5 |
-
<version>1.
|
6 |
</Payson_Payson>
|
7 |
</modules>
|
8 |
<admin>
|
2 |
<config>
|
3 |
<modules>
|
4 |
<Payson_Payson>
|
5 |
+
<version>1.8.2</version>
|
6 |
</Payson_Payson>
|
7 |
</modules>
|
8 |
<admin>
|
app/code/community/Payson/Payson/etc/system.xml
CHANGED
@@ -51,8 +51,8 @@
|
|
51 |
<show_in_store>0</show_in_store>
|
52 |
</agent_id>
|
53 |
<md5_key translate="label,comment">
|
54 |
-
<label>
|
55 |
-
<comment>
|
56 |
<frontend_type>text</frontend_type>
|
57 |
<sort_order>40</sort_order>
|
58 |
<show_in_default>1</show_in_default>
|
@@ -79,44 +79,6 @@
|
|
79 |
<show_in_website>0</show_in_website>
|
80 |
<show_in_store>0</show_in_store>
|
81 |
</payment_guarantee>
|
82 |
-
<!--<active_invoice translate="label,comment">
|
83 |
-
<label>Enable Invoice</label>
|
84 |
-
<comment>Enable/disable invoice payment with Payson.</comment>
|
85 |
-
<frontend_type>select</frontend_type>
|
86 |
-
<source_model>adminhtml/system_config_source_yesno</source_model>
|
87 |
-
<sort_order>43</sort_order>
|
88 |
-
<show_in_default>1</show_in_default>
|
89 |
-
<show_in_website>1</show_in_website>
|
90 |
-
<show_in_store>1</show_in_store>
|
91 |
-
</active_invoice>
|
92 |
-
<invoice_fee_tax translate="label,comment">
|
93 |
-
<label>Invoice fee tax</label>
|
94 |
-
<comment>Tax class for invoice fees.</comment>
|
95 |
-
<frontend_type>select</frontend_type>
|
96 |
-
<source_model>adminhtml/system_config_source_shipping_taxclass</source_model>
|
97 |
-
<sort_order>50</sort_order>
|
98 |
-
<show_in_default>1</show_in_default>
|
99 |
-
<show_in_website>1</show_in_website>
|
100 |
-
<show_in_store>1</show_in_store>
|
101 |
-
</invoice_fee_tax>
|
102 |
-
<invoice_fee_sek translate="label,comment">
|
103 |
-
<label>Invoice fee (SEK)</label>
|
104 |
-
<comment>Invoice fee for SEK excluding tax.</comment>
|
105 |
-
<frontend_type>text</frontend_type>
|
106 |
-
<sort_order>55</sort_order>
|
107 |
-
<show_in_default>1</show_in_default>
|
108 |
-
<show_in_website>1</show_in_website>
|
109 |
-
<show_in_store>1</show_in_store>
|
110 |
-
</invoice_fee_sek>
|
111 |
-
<invoice_fee_eur translate="label,comment">
|
112 |
-
<label>Invoice fee (EUR)</label>
|
113 |
-
<comment>Invoice fee for EUR excluding tax.</comment>
|
114 |
-
<frontend_type>text</frontend_type>
|
115 |
-
<sort_order>60</sort_order>
|
116 |
-
<show_in_default>1</show_in_default>
|
117 |
-
<show_in_website>1</show_in_website>
|
118 |
-
<show_in_store>1</show_in_store>
|
119 |
-
</invoice_fee_eur>-->
|
120 |
<restore_on_cancel translate="label,comment">
|
121 |
<label>Restore cart on cancel</label>
|
122 |
<comment>Restore cart when customer cancel the payment</comment>
|
51 |
<show_in_store>0</show_in_store>
|
52 |
</agent_id>
|
53 |
<md5_key translate="label,comment">
|
54 |
+
<label>API key</label>
|
55 |
+
<comment>API key is found on your Payson profile page.</comment>
|
56 |
<frontend_type>text</frontend_type>
|
57 |
<sort_order>40</sort_order>
|
58 |
<show_in_default>1</show_in_default>
|
79 |
<show_in_website>0</show_in_website>
|
80 |
<show_in_store>0</show_in_store>
|
81 |
</payment_guarantee>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
82 |
<restore_on_cancel translate="label,comment">
|
83 |
<label>Restore cart on cancel</label>
|
84 |
<comment>Restore cart when customer cancel the payment</comment>
|
app/code/community/Payson/Payson/etc/system.xml.bak
DELETED
@@ -1,185 +0,0 @@
|
|
1 |
-
<?xml version="1.0" encoding="UTF-8"?>
|
2 |
-
<config>
|
3 |
-
<sections>
|
4 |
-
<payment>
|
5 |
-
<groups>
|
6 |
-
<payson_standard translate="label" module="payson">
|
7 |
-
<label>Payson All in one Payment</label>
|
8 |
-
<comment><![CDATA[Payson Invoice requires a separate contract. Please contact Payson for more information<a href="http://payson.se" target="_blank">Click here</a>]]></comment>
|
9 |
-
<sort_order>-100</sort_order>
|
10 |
-
<show_in_default>1</show_in_default>
|
11 |
-
<show_in_website>1</show_in_website>
|
12 |
-
<show_in_store>1</show_in_store>
|
13 |
-
<fields>
|
14 |
-
<test_mode translate="label,comment">
|
15 |
-
<label>Test mode</label>
|
16 |
-
<comment>Enable/disable test mode.</comment>
|
17 |
-
<frontend_type>select</frontend_type>
|
18 |
-
<source_model>adminhtml/system_config_source_yesno</source_model>
|
19 |
-
<sort_order>5</sort_order>
|
20 |
-
<show_in_default>1</show_in_default>
|
21 |
-
<show_in_website>1</show_in_website>
|
22 |
-
<show_in_store>1</show_in_store>
|
23 |
-
</test_mode>
|
24 |
-
<active translate="label,comment">
|
25 |
-
<label>Enabled</label>
|
26 |
-
<comment>Enable/disable payment with Payson.</comment>
|
27 |
-
<frontend_type>select</frontend_type>
|
28 |
-
<source_model>adminhtml/system_config_source_yesno</source_model>
|
29 |
-
<sort_order>10</sort_order>
|
30 |
-
<show_in_default>1</show_in_default>
|
31 |
-
<show_in_website>1</show_in_website>
|
32 |
-
<show_in_store>1</show_in_store>
|
33 |
-
</active>
|
34 |
-
<email translate="label,comment">
|
35 |
-
<label>Email</label>
|
36 |
-
<comment>Email address bound to your Payson account.</comment>
|
37 |
-
<frontend_type>text</frontend_type>
|
38 |
-
<validate>validate-email</validate>
|
39 |
-
<sort_order>20</sort_order>
|
40 |
-
<show_in_default>1</show_in_default>
|
41 |
-
<show_in_website>0</show_in_website>
|
42 |
-
<show_in_store>0</show_in_store>
|
43 |
-
</email>
|
44 |
-
<agent_id translate="label,comment">
|
45 |
-
<label>Agent ID</label>
|
46 |
-
<comment>Agent ID is found on your Payson profile page.</comment>
|
47 |
-
<frontend_type>text</frontend_type>
|
48 |
-
<sort_order>30</sort_order>
|
49 |
-
<show_in_default>1</show_in_default>
|
50 |
-
<show_in_website>0</show_in_website>
|
51 |
-
<show_in_store>0</show_in_store>
|
52 |
-
</agent_id>
|
53 |
-
<md5_key translate="label,comment">
|
54 |
-
<label>MD5 key</label>
|
55 |
-
<comment>MD5 key is found on your Payson profile page.</comment>
|
56 |
-
<frontend_type>text</frontend_type>
|
57 |
-
<sort_order>40</sort_order>
|
58 |
-
<show_in_default>1</show_in_default>
|
59 |
-
<show_in_website>0</show_in_website>
|
60 |
-
<show_in_store>0</show_in_store>
|
61 |
-
</md5_key>
|
62 |
-
<payson_All_in_one translate="label">
|
63 |
-
<label>Please select the payment method</label>
|
64 |
-
<comment>Choose your prefered Payson payment</comment>
|
65 |
-
<frontend_type>select</frontend_type>
|
66 |
-
<source_model>payson/system_config_source_paysondirectmethod</source_model>
|
67 |
-
<sort_order>45</sort_order>
|
68 |
-
<show_in_default>1</show_in_default>
|
69 |
-
<show_in_website>1</show_in_website>
|
70 |
-
<show_in_store>1</show_in_store>
|
71 |
-
</payson_All_in_one>
|
72 |
-
<payment_guarantee translate="label,comment">
|
73 |
-
<label>Enable payment guarantee</label>
|
74 |
-
<comment>Enable/disable payment guarantee.</comment>
|
75 |
-
<frontend_type>select</frontend_type>
|
76 |
-
<source_model>adminhtml/system_config_source_yesno</source_model>
|
77 |
-
<sort_order>50</sort_order>
|
78 |
-
<show_in_default>0</show_in_default>
|
79 |
-
<show_in_website>0</show_in_website>
|
80 |
-
<show_in_store>0</show_in_store>
|
81 |
-
</payment_guarantee>
|
82 |
-
<!--<active_invoice translate="label,comment">
|
83 |
-
<label>Enable Invoice</label>
|
84 |
-
<comment>Enable/disable invoice payment with Payson.</comment>
|
85 |
-
<frontend_type>select</frontend_type>
|
86 |
-
<source_model>adminhtml/system_config_source_yesno</source_model>
|
87 |
-
<sort_order>43</sort_order>
|
88 |
-
<show_in_default>1</show_in_default>
|
89 |
-
<show_in_website>1</show_in_website>
|
90 |
-
<show_in_store>1</show_in_store>
|
91 |
-
</active_invoice>
|
92 |
-
<invoice_fee_tax translate="label,comment">
|
93 |
-
<label>Invoice fee tax</label>
|
94 |
-
<comment>Tax class for invoice fees.</comment>
|
95 |
-
<frontend_type>select</frontend_type>
|
96 |
-
<source_model>adminhtml/system_config_source_shipping_taxclass</source_model>
|
97 |
-
<sort_order>50</sort_order>
|
98 |
-
<show_in_default>1</show_in_default>
|
99 |
-
<show_in_website>1</show_in_website>
|
100 |
-
<show_in_store>1</show_in_store>
|
101 |
-
</invoice_fee_tax>
|
102 |
-
<invoice_fee_sek translate="label,comment">
|
103 |
-
<label>Invoice fee (SEK)</label>
|
104 |
-
<comment>Invoice fee for SEK excluding tax.</comment>
|
105 |
-
<frontend_type>text</frontend_type>
|
106 |
-
<sort_order>55</sort_order>
|
107 |
-
<show_in_default>1</show_in_default>
|
108 |
-
<show_in_website>1</show_in_website>
|
109 |
-
<show_in_store>1</show_in_store>
|
110 |
-
</invoice_fee_sek>-->
|
111 |
-
<restore_on_cancel translate="label,comment">
|
112 |
-
<label>Restore cart on cancel</label>
|
113 |
-
<comment>Restore cart when customer cancel the payment</comment>
|
114 |
-
<frontend_type>select</frontend_type>
|
115 |
-
<source_model>adminhtml/system_config_source_yesno</source_model>
|
116 |
-
<sort_order>100</sort_order>
|
117 |
-
<show_in_default>1</show_in_default>
|
118 |
-
<show_in_website>1</show_in_website>
|
119 |
-
<show_in_store>1</show_in_store>
|
120 |
-
</restore_on_cancel>
|
121 |
-
<restore_on_error translate="label,comment">
|
122 |
-
<label>Restore cart on error</label>
|
123 |
-
<comment>Restore cart when status from Payson is error</comment>
|
124 |
-
<frontend_type>select</frontend_type>
|
125 |
-
<source_model>adminhtml/system_config_source_yesno</source_model>
|
126 |
-
<sort_order>150</sort_order>
|
127 |
-
<show_in_default>1</show_in_default>
|
128 |
-
<show_in_website>1</show_in_website>
|
129 |
-
<show_in_store>1</show_in_store>
|
130 |
-
</restore_on_error>
|
131 |
-
<show_receipt_page translate="label,comment">
|
132 |
-
<label>Show receipt page</label>
|
133 |
-
<comment>Here you can enable or disable our receipt page</comment>
|
134 |
-
<frontend_type>select</frontend_type>
|
135 |
-
<source_model>adminhtml/system_config_source_yesno</source_model>
|
136 |
-
<sort_order>200</sort_order>
|
137 |
-
<show_in_default>1</show_in_default>
|
138 |
-
<show_in_website>0</show_in_website>
|
139 |
-
<show_in_store>0</show_in_store>
|
140 |
-
</show_receipt_page>
|
141 |
-
</fields>
|
142 |
-
</payson_standard>
|
143 |
-
<payson_invoice translate="label" module="payson">
|
144 |
-
<label>Payson_invoice_setup</label>
|
145 |
-
<sort_order>-99</sort_order>
|
146 |
-
<show_in_default>1</show_in_default>
|
147 |
-
<show_in_website>1</show_in_website>
|
148 |
-
<show_in_store>1</show_in_store>
|
149 |
-
<comment><![CDATA[Payson Invoice requires a separate contract. Please contact Payson for more information<a href="http://payson.se" target="_blank">Click here</a>]]></comment>
|
150 |
-
<fields>
|
151 |
-
<active_invoice translate="label,comment">
|
152 |
-
<label>Enabled</label>
|
153 |
-
<comment>Enable/disable invoice payment with Payson.</comment>
|
154 |
-
<frontend_type>select</frontend_type>
|
155 |
-
<source_model>adminhtml/system_config_source_yesno</source_model>
|
156 |
-
<sort_order>10</sort_order>
|
157 |
-
<show_in_default>1</show_in_default>
|
158 |
-
<show_in_website>1</show_in_website>
|
159 |
-
<show_in_store>1</show_in_store>
|
160 |
-
</active_invoice>
|
161 |
-
<invoice_fee_tax translate="label,comment">
|
162 |
-
<label>Invoice fee tax</label>
|
163 |
-
<comment>Tax class for invoice fees.</comment>
|
164 |
-
<frontend_type>select</frontend_type>
|
165 |
-
<source_model>adminhtml/system_config_source_shipping_taxclass</source_model>
|
166 |
-
<sort_order>20</sort_order>
|
167 |
-
<show_in_default>1</show_in_default>
|
168 |
-
<show_in_website>1</show_in_website>
|
169 |
-
<show_in_store>1</show_in_store>
|
170 |
-
</invoice_fee_tax>
|
171 |
-
<invoice_fee_sek translate="label,comment">
|
172 |
-
<label>Invoice fee (SEK)</label>
|
173 |
-
<comment>Invoice fee for SEK excluding tax.</comment>
|
174 |
-
<frontend_type>text</frontend_type>
|
175 |
-
<sort_order>30</sort_order>
|
176 |
-
<show_in_default>1</show_in_default>
|
177 |
-
<show_in_website>1</show_in_website>
|
178 |
-
<show_in_store>1</show_in_store>
|
179 |
-
</invoice_fee_sek>
|
180 |
-
</fields>
|
181 |
-
</payson_invoice>
|
182 |
-
</groups>
|
183 |
-
</payment>
|
184 |
-
</sections>
|
185 |
-
</config>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
package.xml
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>Payson</name>
|
4 |
-
<version>1.8.
|
5 |
<stability>stable</stability>
|
6 |
<license uri="http://opensource.org/licenses/bsd-license.php">BSD licence</license>
|
7 |
<channel>community</channel>
|
@@ -10,9 +10,9 @@
|
|
10 |
<description>This module integrates with Payson and allows you to charge your customers via Invoice, Card and direct bank transfers.</description>
|
11 |
<notes>New Payson module </notes>
|
12 |
<authors><author><name>Karl Brundin</name><user>PaysonAB</user><email>integration@payson.se</email></author><author><name>Oscar Villegas</name><user>PaysonAB</user><email>integration@payson.se</email></author></authors>
|
13 |
-
<date>2015-
|
14 |
-
<time>
|
15 |
-
<contents><target name="magecommunity"><dir name="Payson"><dir name="Payson"><dir name="Block"><file name="Form.php" hash="74a8967879fbb6af999f0e513bc91323"/><dir name="Invoice"><file name="Form.php" hash="88a008948e1231b135ba8a798eeb1c66"/></dir><dir name="Order"><dir name="Totals"><file name="Fee.php" hash="3e8566e634d68d8df9bb70f597916980"/></dir></dir><dir name="Standard"><file name="Form.php" hash="c715cbec95494a9a26d261992429dff0"/></dir></dir><dir name="Helper"><dir name="Api"><dir name="Response"><file name="Interface.php" hash="51d0ffe7eefaa12eb9b4f2551e9f4259"/><dir name="Standard"><file name="Parameters.php" hash="6965b8259867c23a5e1e682e14491eb2"/></dir><file name="Standard.php" hash="cef827896629364fee49671af879adc3"/><file name="Validate.php" hash="34fb6626af3a6ac06e987c9e10a95796"/></dir></dir><file name="Api.php" hash="
|
16 |
<compatible/>
|
17 |
<dependencies><required><php><min>5.3.0</min><max>6.0.0</max></php><package><name>Mage_Core_modules</name><channel>community</channel><min>1.8.0</min><max></max></package></required></dependencies>
|
18 |
</package>
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>Payson</name>
|
4 |
+
<version>1.8.2</version>
|
5 |
<stability>stable</stability>
|
6 |
<license uri="http://opensource.org/licenses/bsd-license.php">BSD licence</license>
|
7 |
<channel>community</channel>
|
10 |
<description>This module integrates with Payson and allows you to charge your customers via Invoice, Card and direct bank transfers.</description>
|
11 |
<notes>New Payson module </notes>
|
12 |
<authors><author><name>Karl Brundin</name><user>PaysonAB</user><email>integration@payson.se</email></author><author><name>Oscar Villegas</name><user>PaysonAB</user><email>integration@payson.se</email></author></authors>
|
13 |
+
<date>2015-04-08</date>
|
14 |
+
<time>13:55:00</time>
|
15 |
+
<contents><target name="magecommunity"><dir name="Payson"><dir name="Payson"><dir name="Block"><file name="Form.php" hash="74a8967879fbb6af999f0e513bc91323"/><dir name="Invoice"><file name="Form.php" hash="88a008948e1231b135ba8a798eeb1c66"/></dir><dir name="Order"><dir name="Totals"><file name="Fee.php" hash="3e8566e634d68d8df9bb70f597916980"/></dir></dir><dir name="Standard"><file name="Form.php" hash="c715cbec95494a9a26d261992429dff0"/></dir></dir><dir name="Helper"><dir name="Api"><dir name="Response"><file name="Interface.php" hash="51d0ffe7eefaa12eb9b4f2551e9f4259"/><dir name="Standard"><file name="Parameters.php" hash="6965b8259867c23a5e1e682e14491eb2"/></dir><file name="Standard.php" hash="cef827896629364fee49671af879adc3"/><file name="Validate.php" hash="34fb6626af3a6ac06e987c9e10a95796"/></dir></dir><file name="Api.php" hash="3925df6dceb6670b8b07ccb94a5d94cf"/><file name="Data.php" hash="83ff59b1588c0b0ff8d2f7341589ea59"/><file name="FundingConstraint.php" hash="7acf2b5d8c045237aeff6566cd55cca1"/></dir><dir name="Model"><file name="Config.php" hash="7de7a2257df64a5e039de977edbc5492"/><dir name="Method"><file name="Abstract.php" hash="ecb3334750970e08c0580c0d5f384467"/><file name="Invoice.php" hash="9d041fdca8625cbe095232701f1409c5"/><file name="Standard.php" hash="53ebf0a98fe2b7ee8f1a18c057e10b02"/></dir><dir name="Mysql4"><file name="Setup.php" hash="3075fa047af3d56d6eac609004e6e1cc"/></dir><dir name="Order"><dir name="Creditmemo"><dir name="Total"><file name="Invoice.php" hash="19fadd6df40cd03528fb9c211c34a8bc"/></dir></dir><dir name="Invoice"><dir name="Total"><file name="Invoice.php" hash="87899d88d04362bc148eb51a0a9a076e"/></dir></dir></dir><dir name="Quote"><dir name="Address"><dir name="Total"><file name="Invoice.php" hash="44eef552e2dd3869c3181f3f939ac355"/></dir></dir></dir><file name="Standard.php" hash="5dc2e3fa79eab14c384144e71f7e653c"/><dir name="System"><dir name="Config"><dir name="Source"><file name="Paysondirectmethod.php" hash="5f0a8584217204a638d11dbf61891779"/></dir></dir></dir></dir><dir name="controllers"><dir name="Adminhtml"><dir name="Sales"><dir name="Order"><file name="ShipmentController.php" hash="14d87cc2d4cf99b36411349271f8975a"/></dir></dir></dir><file name="CheckoutController.php" hash="77a22d4cc2493a4c9964503011ba6b1e"/><file name="IpnController.php" hash="e7b092cdd0011a3a1359a084bbaf14ad"/></dir><dir name="etc"><file name="config.xml" hash="320aa741c272c8c13df85159f2f00f6d"/><file name="system.xml" hash="052f75f1e334256de3b6bc473376ebe0"/></dir><dir name="sql"><dir name="payson_setup"><file name="mysql4-install-0.1.0.php" hash="21cd9fd3436ba1eb2fc20eaaadb42106"/><file name="mysql4-upgrade-0.1.0-0.1.2.php" hash="5bbcb930748e3a87a220c0e9f8448a15"/></dir></dir></dir></dir></target><target name="magedesign"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="Payson.xml" hash="1ace2a646cd9a33521e7b392b6c5f3f1"/></dir><dir name="template"><dir name="Payson"><dir name="Payson"><file name="total.phtml" hash="73984e3bd27f5cd1d67550471e4e3da2"/></dir></dir></dir><dir name="Payson"><dir name="Payson"><file name="total.phtml" hash="e05160dad39cd2cbf86decc34fb8d225"/></dir></dir></dir></dir></dir><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="Payson.xml" hash="22b9b9ae0cc9b1c70f79d690fbb4db41"/></dir><dir name="template"><dir name="Payson"><dir name="Payson"><file name="standard_form.phtml" hash="23c387ef94322de355e00f1a49e243d4"/></dir></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Payson_Payson.xml" hash="9118f2a12f9a78438b37b4c9bc5c5198"/></dir></target><target name="magelocale"><dir name="sv_SE"><file name="Payson_Payson.csv" hash="f926728c834ad53fb53d098ef61c23a9"/></dir></target><target name="mageskin"><dir name="frontend"><dir name="base"><dir name="default"><dir name="Payson"><dir name="Payson"><file name="Allinone.png" hash="98f586ec9a3e706d86662796bd776685"/><file name="Allinone3.png" hash="f9a4240a702838136584dc1256104ce5"/><file name="payson.gif" hash="638d0055cbc1a4bdc32e9fa1156b722a"/><file name="payson.png" hash="308916345711a4520313c94218c5bda7"/><file name="payson_faktura.png" hash="fa218c9949c05c6f3452d9f4c541da2c"/></dir></dir></dir></dir></dir></target></contents>
|
16 |
<compatible/>
|
17 |
<dependencies><required><php><min>5.3.0</min><max>6.0.0</max></php><package><name>Mage_Core_modules</name><channel>community</channel><min>1.8.0</min><max></max></package></required></dependencies>
|
18 |
</package>
|