Version Notes
Mage_Payone-3.3.9
Download this release
Release Info
Developer | PAYONE |
Extension | Mage_Payone |
Version | 3.3.9 |
Comparing to | |
See all releases |
Code changes from version 3.3.8 to 3.3.9
- app/code/community/Payone/Core/Block/Adminhtml/System/Config/Form/Field/CreditcardTemplate.php +157 -0
- app/code/community/Payone/Core/Block/Payment/Method/Form/Creditcard.php +395 -306
- app/code/community/Payone/Core/Model/Config/General/PaymentCreditcard.php +20 -0
- app/code/community/Payone/Core/Model/System/Config/CreditcardRequestType.php +38 -0
- app/code/community/Payone/Core/etc/config.xml +1 -1
- app/code/community/Payone/Core/etc/system.xml +18 -0
- app/design/adminhtml/default/default/template/payone/core/client_api.phtml +1 -0
- app/design/adminhtml/default/default/template/payone/core/payment/method/form/creditcard.phtml +204 -76
- app/design/adminhtml/default/default/template/payone/core/sales/order/create/init.phtml +4 -0
- app/design/adminhtml/default/default/template/payone/core/system/config/form/field/creditcard_template.phtml +317 -0
- app/design/frontend/base/default/template/payone/core/client_api.phtml +1 -0
- app/design/frontend/base/default/template/payone/core/payment/method/form/creditcard.phtml +270 -105
- app/locale/de_DE/Payone_Core.csv +48 -1
- app/locale/en_US/Payone_Core.csv +6 -1
- js/payone/core/creditcard.js +50 -1
- package.xml +5 -5
app/code/community/Payone/Core/Block/Adminhtml/System/Config/Form/Field/CreditcardTemplate.php
ADDED
@@ -0,0 +1,157 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
*
|
4 |
+
* NOTICE OF LICENSE
|
5 |
+
*
|
6 |
+
* This source file is subject to the GNU General Public License (GPL 3)
|
7 |
+
* that is bundled with this package in the file LICENSE.txt
|
8 |
+
*
|
9 |
+
* DISCLAIMER
|
10 |
+
*
|
11 |
+
* Do not edit or add to this file if you wish to upgrade Payone_Core to newer
|
12 |
+
* versions in the future. If you wish to customize Payone_Core for your
|
13 |
+
* needs please refer to http://www.payone.de for more information.
|
14 |
+
*
|
15 |
+
* @category Payone
|
16 |
+
* @package Payone_Core_Block
|
17 |
+
* @subpackage Adminhtml_System
|
18 |
+
* @copyright Copyright (c) 2015 <kontakt@fatchip.de> - www.fatchip.com
|
19 |
+
* @author Robert M�ller <robert.mueller@fatchip.de>
|
20 |
+
* @license <http://www.gnu.org/licenses/> GNU General Public License (GPL 3)
|
21 |
+
* @link http://www.fatchip.com
|
22 |
+
*/
|
23 |
+
class Payone_Core_Block_Adminhtml_System_Config_Form_Field_CreditcardTemplate
|
24 |
+
extends Payone_Core_Block_Adminhtml_System_Config_Form_Field_Abstract
|
25 |
+
{
|
26 |
+
|
27 |
+
protected $_aFcpoDefaultStringConf = array(
|
28 |
+
'Number_type' => 'tel',
|
29 |
+
'Number_count' => '30',
|
30 |
+
'Number_max' => '16',
|
31 |
+
'Number_iframe' => 'standard',
|
32 |
+
'Number_width' => '202px',
|
33 |
+
'Number_height' => '20px',
|
34 |
+
'Number_style' => 'standard',
|
35 |
+
'Number_css' => '',
|
36 |
+
'CVC_type' => 'tel',
|
37 |
+
'CVC_count' => '30',
|
38 |
+
'CVC_max' => '4',
|
39 |
+
'CVC_iframe' => 'standard',
|
40 |
+
'CVC_width' => '202px',
|
41 |
+
'CVC_height' => '20px',
|
42 |
+
'CVC_style' => 'standard',
|
43 |
+
'CVC_css' => '',
|
44 |
+
'Month_type' => 'select',
|
45 |
+
'Month_count' => '3',
|
46 |
+
'Month_max' => '2',
|
47 |
+
'Month_iframe' => 'custom',
|
48 |
+
'Month_width' => '120px',
|
49 |
+
'Month_height' => '20px',
|
50 |
+
'Month_style' => 'standard',
|
51 |
+
'Month_css' => '',
|
52 |
+
'Year_type' => 'select',
|
53 |
+
'Year_count' => '5',
|
54 |
+
'Year_max' => '4',
|
55 |
+
'Year_iframe' => 'custom',
|
56 |
+
'Year_width' => '120px',
|
57 |
+
'Year_height' => '20px',
|
58 |
+
'Year_style' => 'standard',
|
59 |
+
'Year_css' => '',
|
60 |
+
'Iframe_width' => '365px',
|
61 |
+
'Iframe_height' => '30px',
|
62 |
+
'Standard_input' => "width:365px;height:30px;padding: 0 8px;color:#636363;font-size:14px;font-family:'Helvetica Neue',Verdana,Arial,sans-serif;",
|
63 |
+
'Standard_selection' => 'width:100px;',
|
64 |
+
);
|
65 |
+
|
66 |
+
/**
|
67 |
+
*
|
68 |
+
*/
|
69 |
+
public function __construct()
|
70 |
+
{
|
71 |
+
parent::__construct();
|
72 |
+
$this->setTemplate('payone/core/system/config/form/field/creditcard_template.phtml');
|
73 |
+
}
|
74 |
+
|
75 |
+
/**
|
76 |
+
*
|
77 |
+
*/
|
78 |
+
protected function _prepareToRender()
|
79 |
+
{
|
80 |
+
$this->addColumn('Number_type', array(
|
81 |
+
'label' =>'',
|
82 |
+
'style' => '',
|
83 |
+
));
|
84 |
+
$this->addColumn('Number_count', array(
|
85 |
+
'label' =>'',
|
86 |
+
'style' => '',
|
87 |
+
));
|
88 |
+
$this->addColumn('Number_max', array(
|
89 |
+
'label' =>'',
|
90 |
+
'style' => '',
|
91 |
+
));
|
92 |
+
$this->_addAfter = false;
|
93 |
+
$this->_addButtonLabel = Mage::helper('payone_core')->__('Add');
|
94 |
+
parent::_prepareToRender();
|
95 |
+
}
|
96 |
+
|
97 |
+
/**
|
98 |
+
* @param $columnName
|
99 |
+
* @return string
|
100 |
+
* @throws Exception
|
101 |
+
*/
|
102 |
+
protected function _renderCellTemplate($columnName)
|
103 |
+
{
|
104 |
+
if ($columnName == 'txactions') {
|
105 |
+
$selectType = Payone_Core_Block_Adminhtml_System_Config_Form_Field_Abstract::PAYONE_CORE_FIELD_MULTISELECT;
|
106 |
+
|
107 |
+
$modelConfigCode = $this->getFactory()->getModelSystemConfigTransactionStatus();
|
108 |
+
$options = $modelConfigCode->toOptionArray();
|
109 |
+
|
110 |
+
$rendered = $this->prepareCellTemplate($columnName,$selectType,$options);
|
111 |
+
}
|
112 |
+
else
|
113 |
+
{
|
114 |
+
return parent::_renderCellTemplate($columnName);
|
115 |
+
}
|
116 |
+
|
117 |
+
return $rendered;
|
118 |
+
}
|
119 |
+
|
120 |
+
public function getCCFields() {
|
121 |
+
return array(
|
122 |
+
'Number',
|
123 |
+
'CVC',
|
124 |
+
'Month',
|
125 |
+
'Year',
|
126 |
+
);
|
127 |
+
}
|
128 |
+
|
129 |
+
public function getCCStyles() {
|
130 |
+
return array(
|
131 |
+
'standard' => Mage::helper('payone_core')->__('Standard'),
|
132 |
+
'custom' => Mage::helper('payone_core')->__('Custom'),
|
133 |
+
);
|
134 |
+
}
|
135 |
+
|
136 |
+
public function getCCTypes($sField) {
|
137 |
+
$aTypes = array();
|
138 |
+
if($sField == 'Month' || $sField == 'Year') {
|
139 |
+
$aTypes['select'] = Mage::helper('payone_core')->__('Select');
|
140 |
+
}
|
141 |
+
$aTypes['tel'] = Mage::helper('payone_core')->__('Numeric');
|
142 |
+
$aTypes['password'] = Mage::helper('payone_core')->__('Password');
|
143 |
+
$aTypes['text'] = Mage::helper('payone_core')->__('Text');
|
144 |
+
return $aTypes;
|
145 |
+
}
|
146 |
+
|
147 |
+
public function fcpoGetValue($sIdent) {
|
148 |
+
$aValues = $this->getElement()->getValue();
|
149 |
+
if(isset($aValues[$sIdent])) {
|
150 |
+
return $aValues[$sIdent];
|
151 |
+
} elseif(isset($this->_aFcpoDefaultStringConf[$sIdent])) {
|
152 |
+
return $this->_aFcpoDefaultStringConf[$sIdent];
|
153 |
+
}
|
154 |
+
return '';
|
155 |
+
}
|
156 |
+
|
157 |
+
}
|
app/code/community/Payone/Core/Block/Payment/Method/Form/Creditcard.php
CHANGED
@@ -1,307 +1,396 @@
|
|
1 |
-
<?php
|
2 |
-
/**
|
3 |
-
*
|
4 |
-
* NOTICE OF LICENSE
|
5 |
-
*
|
6 |
-
* This source file is subject to the GNU General Public License (GPL 3)
|
7 |
-
* that is bundled with this package in the file LICENSE.txt
|
8 |
-
*
|
9 |
-
* DISCLAIMER
|
10 |
-
*
|
11 |
-
* Do not edit or add to this file if you wish to upgrade Payone_Core to newer
|
12 |
-
* versions in the future. If you wish to customize Payone_Core for your
|
13 |
-
* needs please refer to http://www.payone.de for more information.
|
14 |
-
*
|
15 |
-
* @category Payone
|
16 |
-
* @package Payone_Core_Block
|
17 |
-
* @subpackage Payment
|
18 |
-
* @copyright Copyright (c) 2012 <info@noovias.com> - www.noovias.com
|
19 |
-
* @author Matthias Walter <info@noovias.com>
|
20 |
-
* @license <http://www.gnu.org/licenses/> GNU General Public License (GPL 3)
|
21 |
-
* @link http://www.noovias.com
|
22 |
-
*/
|
23 |
-
|
24 |
-
/**
|
25 |
-
*
|
26 |
-
* @category Payone
|
27 |
-
* @package Payone_Core_Block
|
28 |
-
* @subpackage Payment
|
29 |
-
* @copyright Copyright (c) 2012 <info@noovias.com> - www.noovias.com
|
30 |
-
* @license <http://www.gnu.org/licenses/> GNU General Public License (GPL 3)
|
31 |
-
* @link http://www.noovias.com
|
32 |
-
*/
|
33 |
-
class Payone_Core_Block_Payment_Method_Form_Creditcard
|
34 |
-
extends Payone_Core_Block_Payment_Method_Form_Abstract
|
35 |
-
{
|
36 |
-
|
37 |
-
|
38 |
-
protected
|
39 |
-
|
40 |
-
|
41 |
-
|
42 |
-
|
43 |
-
|
44 |
-
|
45 |
-
|
46 |
-
|
47 |
-
|
48 |
-
|
49 |
-
|
50 |
-
|
51 |
-
|
52 |
-
|
53 |
-
|
54 |
-
$
|
55 |
-
|
56 |
-
|
57 |
-
|
58 |
-
|
59 |
-
|
60 |
-
|
61 |
-
|
62 |
-
|
63 |
-
|
64 |
-
|
65 |
-
|
66 |
-
|
67 |
-
|
68 |
-
|
69 |
-
|
70 |
-
|
71 |
-
|
72 |
-
|
73 |
-
|
74 |
-
|
75 |
-
|
76 |
-
|
77 |
-
|
78 |
-
|
79 |
-
|
80 |
-
|
81 |
-
|
82 |
-
|
83 |
-
|
84 |
-
|
85 |
-
|
86 |
-
|
87 |
-
|
88 |
-
|
89 |
-
|
90 |
-
|
91 |
-
|
92 |
-
|
93 |
-
|
94 |
-
|
95 |
-
|
96 |
-
|
97 |
-
|
98 |
-
|
99 |
-
|
100 |
-
|
101 |
-
|
102 |
-
|
103 |
-
|
104 |
-
|
105 |
-
|
106 |
-
|
107 |
-
|
108 |
-
|
109 |
-
|
110 |
-
|
111 |
-
|
112 |
-
|
113 |
-
|
114 |
-
|
115 |
-
|
116 |
-
|
117 |
-
|
118 |
-
|
119 |
-
|
120 |
-
|
121 |
-
|
122 |
-
|
123 |
-
|
124 |
-
|
125 |
-
|
126 |
-
|
127 |
-
|
128 |
-
|
129 |
-
|
130 |
-
|
131 |
-
|
132 |
-
|
133 |
-
|
134 |
-
|
135 |
-
|
136 |
-
|
137 |
-
|
138 |
-
|
139 |
-
|
140 |
-
|
141 |
-
|
142 |
-
|
143 |
-
|
144 |
-
|
145 |
-
|
146 |
-
|
147 |
-
|
148 |
-
|
149 |
-
|
150 |
-
|
151 |
-
|
152 |
-
|
153 |
-
|
154 |
-
|
155 |
-
|
156 |
-
|
157 |
-
|
158 |
-
|
159 |
-
|
160 |
-
|
161 |
-
|
162 |
-
|
163 |
-
|
164 |
-
|
165 |
-
|
166 |
-
|
167 |
-
|
168 |
-
|
169 |
-
|
170 |
-
|
171 |
-
|
172 |
-
|
173 |
-
|
174 |
-
*
|
175 |
-
|
176 |
-
|
177 |
-
|
178 |
-
|
179 |
-
|
180 |
-
|
181 |
-
|
182 |
-
$this->
|
183 |
-
|
184 |
-
|
185 |
-
|
186 |
-
|
187 |
-
|
188 |
-
|
189 |
-
|
190 |
-
*
|
191 |
-
|
192 |
-
|
193 |
-
|
194 |
-
|
195 |
-
|
196 |
-
|
197 |
-
|
198 |
-
$this->
|
199 |
-
|
200 |
-
|
201 |
-
|
202 |
-
|
203 |
-
|
204 |
-
|
205 |
-
|
206 |
-
|
207 |
-
|
208 |
-
|
209 |
-
|
210 |
-
|
211 |
-
|
212 |
-
|
213 |
-
|
214 |
-
|
215 |
-
|
216 |
-
|
217 |
-
|
218 |
-
|
219 |
-
$
|
220 |
-
|
221 |
-
|
222 |
-
|
223 |
-
|
224 |
-
|
225 |
-
|
226 |
-
|
227 |
-
|
228 |
-
|
229 |
-
|
230 |
-
|
231 |
-
|
232 |
-
|
233 |
-
|
234 |
-
|
235 |
-
|
236 |
-
|
237 |
-
$
|
238 |
-
$
|
239 |
-
$
|
240 |
-
|
241 |
-
$
|
242 |
-
|
243 |
-
$
|
244 |
-
|
245 |
-
$
|
246 |
-
|
247 |
-
|
248 |
-
|
249 |
-
|
250 |
-
|
251 |
-
'
|
252 |
-
'
|
253 |
-
'
|
254 |
-
'
|
255 |
-
'
|
256 |
-
'
|
257 |
-
'
|
258 |
-
'
|
259 |
-
'
|
260 |
-
'
|
261 |
-
'
|
262 |
-
|
263 |
-
|
264 |
-
|
265 |
-
|
266 |
-
|
267 |
-
$
|
268 |
-
|
269 |
-
$request->
|
270 |
-
|
271 |
-
$
|
272 |
-
|
273 |
-
$
|
274 |
-
|
275 |
-
|
276 |
-
|
277 |
-
|
278 |
-
|
279 |
-
|
280 |
-
|
281 |
-
|
282 |
-
|
283 |
-
|
284 |
-
|
285 |
-
$
|
286 |
-
|
287 |
-
|
288 |
-
|
289 |
-
|
290 |
-
|
291 |
-
|
292 |
-
|
293 |
-
$
|
294 |
-
|
295 |
-
|
296 |
-
|
297 |
-
|
298 |
-
|
299 |
-
|
300 |
-
|
301 |
-
* @
|
302 |
-
|
303 |
-
|
304 |
-
|
305 |
-
|
306 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
307 |
}
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
*
|
4 |
+
* NOTICE OF LICENSE
|
5 |
+
*
|
6 |
+
* This source file is subject to the GNU General Public License (GPL 3)
|
7 |
+
* that is bundled with this package in the file LICENSE.txt
|
8 |
+
*
|
9 |
+
* DISCLAIMER
|
10 |
+
*
|
11 |
+
* Do not edit or add to this file if you wish to upgrade Payone_Core to newer
|
12 |
+
* versions in the future. If you wish to customize Payone_Core for your
|
13 |
+
* needs please refer to http://www.payone.de for more information.
|
14 |
+
*
|
15 |
+
* @category Payone
|
16 |
+
* @package Payone_Core_Block
|
17 |
+
* @subpackage Payment
|
18 |
+
* @copyright Copyright (c) 2012 <info@noovias.com> - www.noovias.com
|
19 |
+
* @author Matthias Walter <info@noovias.com>
|
20 |
+
* @license <http://www.gnu.org/licenses/> GNU General Public License (GPL 3)
|
21 |
+
* @link http://www.noovias.com
|
22 |
+
*/
|
23 |
+
|
24 |
+
/**
|
25 |
+
*
|
26 |
+
* @category Payone
|
27 |
+
* @package Payone_Core_Block
|
28 |
+
* @subpackage Payment
|
29 |
+
* @copyright Copyright (c) 2012 <info@noovias.com> - www.noovias.com
|
30 |
+
* @license <http://www.gnu.org/licenses/> GNU General Public License (GPL 3)
|
31 |
+
* @link http://www.noovias.com
|
32 |
+
*/
|
33 |
+
class Payone_Core_Block_Payment_Method_Form_Creditcard
|
34 |
+
extends Payone_Core_Block_Payment_Method_Form_Abstract
|
35 |
+
{
|
36 |
+
|
37 |
+
protected $_aHostedParams = null;
|
38 |
+
protected $hasTypes = true;
|
39 |
+
|
40 |
+
protected function _construct()
|
41 |
+
{
|
42 |
+
parent::_construct();
|
43 |
+
$this->setTemplate('payone/core/payment/method/form/creditcard.phtml');
|
44 |
+
}
|
45 |
+
|
46 |
+
/**
|
47 |
+
* Name from billing address in the format "Firstname Lastname".
|
48 |
+
* @return string
|
49 |
+
*/
|
50 |
+
public function getBillingName()
|
51 |
+
{
|
52 |
+
$billingName = $this->getSavedCustomerData('cc_owner');
|
53 |
+
if(empty($billingName)) {
|
54 |
+
$quote = $this->getQuote();
|
55 |
+
$address = $quote->getBillingAddress();
|
56 |
+
$billingName = $address->getFirstname() . ' ' . $address->getLastname();
|
57 |
+
}
|
58 |
+
return $billingName;
|
59 |
+
}
|
60 |
+
|
61 |
+
/**
|
62 |
+
* @return Mage_Payment_Model_Config
|
63 |
+
*/
|
64 |
+
protected function getMagentoPaymentConfig()
|
65 |
+
{
|
66 |
+
return $this->getFactory()->getSingletonPaymentConfig();
|
67 |
+
}
|
68 |
+
|
69 |
+
public function getCvcJson()
|
70 |
+
{
|
71 |
+
$return = array();
|
72 |
+
foreach ($this->getTypes() as $key => $type) {
|
73 |
+
$return[$key] = $type['check_cvc'];
|
74 |
+
}
|
75 |
+
return json_encode($return);
|
76 |
+
}
|
77 |
+
|
78 |
+
/**
|
79 |
+
* @return array
|
80 |
+
*/
|
81 |
+
protected function getSystemConfigMethodTypes()
|
82 |
+
{
|
83 |
+
return $this->getFactory()->getModelSystemConfigCreditCardType()->toSelectArray();
|
84 |
+
}
|
85 |
+
|
86 |
+
/**
|
87 |
+
* @return string
|
88 |
+
*/
|
89 |
+
public function getCreditCardType()
|
90 |
+
{
|
91 |
+
$creditCardType = $this->getSavedCustomerData('cc_type');
|
92 |
+
if(empty($creditCardType)) {
|
93 |
+
$creditCardType = $this->getInfoData('cc_type');
|
94 |
+
}
|
95 |
+
return $creditCardType;
|
96 |
+
}
|
97 |
+
|
98 |
+
/**
|
99 |
+
* @return string
|
100 |
+
*/
|
101 |
+
public function getPayoneConfigPaymentMethodId()
|
102 |
+
{
|
103 |
+
$payoneConfigPaymentMethodId = $this->getSavedCustomerData('payone_config_payment_method_id');
|
104 |
+
return $payoneConfigPaymentMethodId;
|
105 |
+
}
|
106 |
+
|
107 |
+
/**
|
108 |
+
* @return string
|
109 |
+
*/
|
110 |
+
public function getCreditCardNumberEnc()
|
111 |
+
{
|
112 |
+
$creditCardNumberEnc = $this->getSavedCustomerData('cc_number_enc');
|
113 |
+
return $creditCardNumberEnc;
|
114 |
+
}
|
115 |
+
|
116 |
+
/**
|
117 |
+
* @return string
|
118 |
+
*/
|
119 |
+
public function getCreditCardExpireYear()
|
120 |
+
{
|
121 |
+
$ccExpYear = $this->getSavedCustomerData('cc_exp_year');
|
122 |
+
if(empty($ccExpYear)) {
|
123 |
+
$ccExpYear = $this->getInfoData('cc_exp_year');
|
124 |
+
}
|
125 |
+
return $ccExpYear;
|
126 |
+
}
|
127 |
+
|
128 |
+
/**
|
129 |
+
* @return string
|
130 |
+
*/
|
131 |
+
public function getCreditCardExpireMonth()
|
132 |
+
{
|
133 |
+
$ccExpMonth = $this->getSavedCustomerData('cc_exp_month');
|
134 |
+
if(empty($ccExpMonth)) {
|
135 |
+
$ccExpMonth = $this->getInfoData('cc_exp_month');
|
136 |
+
}
|
137 |
+
return $ccExpMonth;
|
138 |
+
}
|
139 |
+
|
140 |
+
/**
|
141 |
+
* @return string
|
142 |
+
*/
|
143 |
+
public function getPayonePseudocardpan()
|
144 |
+
{
|
145 |
+
$payonePseudocardpan = $this->getSavedCustomerData('payone_pseudocardpan');
|
146 |
+
return $payonePseudocardpan;
|
147 |
+
}
|
148 |
+
|
149 |
+
/**
|
150 |
+
* @return string
|
151 |
+
*/
|
152 |
+
public function getCreditCardCid()
|
153 |
+
{
|
154 |
+
$creditCardNumberEnc = $this->getSavedCustomerData('cc_number_enc');
|
155 |
+
if(empty($creditCardNumberEnc)) {
|
156 |
+
return '';
|
157 |
+
}
|
158 |
+
return 'xxx';
|
159 |
+
}
|
160 |
+
|
161 |
+
/**
|
162 |
+
* @return integer
|
163 |
+
*/
|
164 |
+
public function getPayoneCreditCardCheckValidation()
|
165 |
+
{
|
166 |
+
$creditCardNumberEnc = $this->getSavedCustomerData('cc_number_enc');
|
167 |
+
if(empty($creditCardNumberEnc)) {
|
168 |
+
return 1;
|
169 |
+
}
|
170 |
+
return 0;
|
171 |
+
}
|
172 |
+
|
173 |
+
/**
|
174 |
+
* Retrieve credit card expire months
|
175 |
+
*
|
176 |
+
* @return array
|
177 |
+
*/
|
178 |
+
public function getCcMonths()
|
179 |
+
{
|
180 |
+
$months = $this->getData('cc_months');
|
181 |
+
if (is_null($months)) {
|
182 |
+
$months[0] = $this->__('Month');
|
183 |
+
$months = array_merge($months, $this->getMagentoPaymentConfig()->getMonths());
|
184 |
+
$this->setData('cc_months', $months);
|
185 |
+
}
|
186 |
+
return $months;
|
187 |
+
}
|
188 |
+
|
189 |
+
/**
|
190 |
+
* Retrieve credit card expire years
|
191 |
+
*
|
192 |
+
* @return array
|
193 |
+
*/
|
194 |
+
public function getCcYears()
|
195 |
+
{
|
196 |
+
$years = $this->getData('cc_years');
|
197 |
+
if (is_null($years)) {
|
198 |
+
$years = $this->getMagentoPaymentConfig()->getYears();
|
199 |
+
$years = array(0 => $this->__('Year')) + $years;
|
200 |
+
$this->setData('cc_years', $years);
|
201 |
+
}
|
202 |
+
return $years;
|
203 |
+
}
|
204 |
+
|
205 |
+
/**
|
206 |
+
* @return string
|
207 |
+
*/
|
208 |
+
public function getClientApiConfigAsJson()
|
209 |
+
{
|
210 |
+
return json_encode($this->getClientApiConfig());
|
211 |
+
}
|
212 |
+
|
213 |
+
/**
|
214 |
+
* @return array
|
215 |
+
*/
|
216 |
+
public function getClientApiConfig()
|
217 |
+
{
|
218 |
+
$creditcardcheck = $this->getCreditcardcheckParams();
|
219 |
+
$allowedValidity = $this->getAllowedValidityTimestamp();
|
220 |
+
|
221 |
+
$params = array(
|
222 |
+
'gateway' => $creditcardcheck,
|
223 |
+
'validation' => array(
|
224 |
+
'allowed_validity' => $allowedValidity
|
225 |
+
),
|
226 |
+
);
|
227 |
+
|
228 |
+
return $params;
|
229 |
+
}
|
230 |
+
|
231 |
+
/**
|
232 |
+
* Returns the gateways, one for each payment configuration
|
233 |
+
* @return array
|
234 |
+
*/
|
235 |
+
public function getCreditcardcheckParams()
|
236 |
+
{
|
237 |
+
$paymentConfigs = $this->getPaymentConfigs();
|
238 |
+
/** @var $helper Payone_Core_Helper_Data */
|
239 |
+
$helper = $this->helper('payone_core');
|
240 |
+
$factory = $this->getFactory();
|
241 |
+
$helperUrl = $this->getFactory()->helperUrl();
|
242 |
+
|
243 |
+
$serviceGenerateHash = $factory->getServiceClientApiGenerateHash();
|
244 |
+
|
245 |
+
$language = $helper->getDefaultLanguage();
|
246 |
+
|
247 |
+
$gateways = array();
|
248 |
+
foreach ($paymentConfigs as $paymentConfig) {
|
249 |
+
$request = $factory->getRequestClientApiCreditCardCheck();
|
250 |
+
$params = array(
|
251 |
+
'aid' => $paymentConfig->getAid(),
|
252 |
+
'mid' => $paymentConfig->getMid(),
|
253 |
+
'portalid' => $paymentConfig->getPortalid(),
|
254 |
+
'mode' => $paymentConfig->getMode(),
|
255 |
+
'encoding' => 'UTF-8',
|
256 |
+
'language' => $language,
|
257 |
+
'solution_version' => $helper->getPayoneVersion(),
|
258 |
+
'solution_name' => 'votum',
|
259 |
+
'integrator_version' => $helper->getMagentoVersion(),
|
260 |
+
'integrator_name' => 'Magento',
|
261 |
+
'storecarddata' => 'yes',
|
262 |
+
'successurl' => $helperUrl->getSuccessUrl(),
|
263 |
+
'errorurl' => $helperUrl->getErrorUrl()
|
264 |
+
|
265 |
+
);
|
266 |
+
$request->init($params);
|
267 |
+
$request->setResponsetype('JSON');
|
268 |
+
|
269 |
+
$hash = $serviceGenerateHash->generate($request, $paymentConfig->getKey());
|
270 |
+
|
271 |
+
$request->setHash($hash);
|
272 |
+
|
273 |
+
$params = $request->toArray();
|
274 |
+
|
275 |
+
$gateways[$paymentConfig->getId()] = $params;
|
276 |
+
}
|
277 |
+
return $gateways;
|
278 |
+
}
|
279 |
+
|
280 |
+
/**
|
281 |
+
* @return string
|
282 |
+
*/
|
283 |
+
public function getAllowedValidityTimestamp()
|
284 |
+
{
|
285 |
+
$config = $this->getConfigGeneral();
|
286 |
+
|
287 |
+
$days = $config->getPaymentCreditcard()->getMinValidityPeriod();
|
288 |
+
if (empty($days)) {
|
289 |
+
$days = 0;
|
290 |
+
}
|
291 |
+
|
292 |
+
$allowedDate = new DateTime(now());
|
293 |
+
$allowedDate->modify('+ ' . $days . ' days');
|
294 |
+
|
295 |
+
$timestamp = $allowedDate->format('U');
|
296 |
+
|
297 |
+
return $timestamp;
|
298 |
+
}
|
299 |
+
|
300 |
+
/**
|
301 |
+
* @override To prevent display of fee config on payment method, as there might be differen fees for each credit card type
|
302 |
+
*
|
303 |
+
* @return string
|
304 |
+
*/
|
305 |
+
public function getMethodLabelAfterHtml()
|
306 |
+
{
|
307 |
+
return '';
|
308 |
+
}
|
309 |
+
|
310 |
+
public function getCCRequestType() {
|
311 |
+
return $this->getConfigGeneral()->getPaymentCreditcard()->getCcRequestType();
|
312 |
+
}
|
313 |
+
|
314 |
+
protected function _getHostedParams() {
|
315 |
+
if($this->_aHostedParams === null) {
|
316 |
+
$aParams = array();
|
317 |
+
|
318 |
+
$sTemplate = $this->getConfigGeneral()->getPaymentCreditcard()->getCcTemplate();
|
319 |
+
if($sTemplate) {
|
320 |
+
$aParams = unserialize($sTemplate);
|
321 |
+
}
|
322 |
+
$this->_aHostedParams = $aParams;
|
323 |
+
}
|
324 |
+
return $this->_aHostedParams;
|
325 |
+
}
|
326 |
+
|
327 |
+
public function getHostedParam($sParam) {
|
328 |
+
$aParams = $this->_getHostedParams();
|
329 |
+
if(isset($aParams[$sParam])) {
|
330 |
+
return $aParams[$sParam];
|
331 |
+
}
|
332 |
+
return '';
|
333 |
+
}
|
334 |
+
|
335 |
+
/**
|
336 |
+
* @return string
|
337 |
+
*/
|
338 |
+
public function getHostedClientApiConfigAsJson()
|
339 |
+
{
|
340 |
+
return json_encode($this->getHostedClientApiConfig());
|
341 |
+
}
|
342 |
+
|
343 |
+
/**
|
344 |
+
* @return array
|
345 |
+
*/
|
346 |
+
public function getHostedClientApiConfig()
|
347 |
+
{
|
348 |
+
$params = array(
|
349 |
+
'gateway' => $this->getHostedCreditcardcheckParams(),
|
350 |
+
);
|
351 |
+
|
352 |
+
return $params;
|
353 |
+
}
|
354 |
+
|
355 |
+
/**
|
356 |
+
* Returns the gateways, one for each payment configuration
|
357 |
+
* @return array
|
358 |
+
*/
|
359 |
+
public function getHostedCreditcardcheckParams()
|
360 |
+
{
|
361 |
+
$paymentConfigs = $this->getPaymentConfigs();
|
362 |
+
/** @var $helper Payone_Core_Helper_Data */
|
363 |
+
$helper = $this->helper('payone_core');
|
364 |
+
$factory = $this->getFactory();
|
365 |
+
$helperUrl = $this->getFactory()->helperUrl();
|
366 |
+
|
367 |
+
$serviceGenerateHash = $factory->getServiceClientApiGenerateHash();
|
368 |
+
|
369 |
+
$language = $helper->getDefaultLanguage();
|
370 |
+
|
371 |
+
$gateways = array();
|
372 |
+
foreach ($paymentConfigs as $paymentConfig) {
|
373 |
+
$request = $factory->getRequestClientApiCreditCardCheck();
|
374 |
+
$params = array(
|
375 |
+
'aid' => $paymentConfig->getAid(),
|
376 |
+
'mid' => $paymentConfig->getMid(),
|
377 |
+
'portalid' => $paymentConfig->getPortalid(),
|
378 |
+
'mode' => $paymentConfig->getMode(),
|
379 |
+
'encoding' => 'UTF-8',
|
380 |
+
'storecarddata' => 'yes',
|
381 |
+
);
|
382 |
+
$request->init($params);
|
383 |
+
$request->setResponsetype('JSON');
|
384 |
+
|
385 |
+
$hash = $serviceGenerateHash->generate($request, $paymentConfig->getKey());
|
386 |
+
|
387 |
+
$request->setHash($hash);
|
388 |
+
|
389 |
+
$params = $request->toArray();
|
390 |
+
|
391 |
+
$gateways[$paymentConfig->getId()] = $params;
|
392 |
+
}
|
393 |
+
return $gateways;
|
394 |
+
}
|
395 |
+
|
396 |
}
|
app/code/community/Payone/Core/Model/Config/General/PaymentCreditcard.php
CHANGED
@@ -37,6 +37,9 @@ class Payone_Core_Model_Config_General_PaymentCreditcard extends Payone_Core_Mod
|
|
37 |
*/
|
38 |
protected $min_validity_period = 0;
|
39 |
|
|
|
|
|
|
|
40 |
/**
|
41 |
* @param int $min_validity_period
|
42 |
*/
|
@@ -52,4 +55,21 @@ class Payone_Core_Model_Config_General_PaymentCreditcard extends Payone_Core_Mod
|
|
52 |
{
|
53 |
return $this->min_validity_period;
|
54 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
55 |
}
|
37 |
*/
|
38 |
protected $min_validity_period = 0;
|
39 |
|
40 |
+
protected $sCCTemplate = '';
|
41 |
+
protected $sCCRequestType = 'AJAX';
|
42 |
+
|
43 |
/**
|
44 |
* @param int $min_validity_period
|
45 |
*/
|
55 |
{
|
56 |
return $this->min_validity_period;
|
57 |
}
|
58 |
+
|
59 |
+
public function setCcTemplate($sTemplate) {
|
60 |
+
$this->sCCTemplate = $sTemplate;
|
61 |
+
}
|
62 |
+
|
63 |
+
public function getCcTemplate() {
|
64 |
+
return $this->sCCTemplate;
|
65 |
+
}
|
66 |
+
|
67 |
+
public function setCcRequestType($sRequestType) {
|
68 |
+
$this->sCCRequestType = $sRequestType;
|
69 |
+
}
|
70 |
+
|
71 |
+
public function getCcRequestType() {
|
72 |
+
return $this->sCCRequestType;
|
73 |
+
}
|
74 |
+
|
75 |
}
|
app/code/community/Payone/Core/Model/System/Config/CreditcardRequestType.php
ADDED
@@ -0,0 +1,38 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
*
|
4 |
+
* NOTICE OF LICENSE
|
5 |
+
*
|
6 |
+
* This source file is subject to the GNU General Public License (GPL 3)
|
7 |
+
* that is bundled with this package in the file LICENSE.txt
|
8 |
+
*
|
9 |
+
* DISCLAIMER
|
10 |
+
*
|
11 |
+
* Do not edit or add to this file if you wish to upgrade Payone_Core to newer
|
12 |
+
* versions in the future. If you wish to customize Payone_Core for your
|
13 |
+
* needs please refer to http://www.payone.de for more information.
|
14 |
+
*
|
15 |
+
* @category Payone
|
16 |
+
* @package Payone_Core_Model
|
17 |
+
* @subpackage System
|
18 |
+
* @copyright Copyright (c) 2015 <kontakt@fatchip.de> - www.fatchip.com
|
19 |
+
* @author Robert M�ller <robert.mueller@fatchip.de>
|
20 |
+
* @license <http://www.gnu.org/licenses/> GNU General Public License (GPL 3)
|
21 |
+
* @link http://www.fatchip.com
|
22 |
+
*/
|
23 |
+
class Payone_Core_Model_System_Config_CreditcardRequestType extends Payone_Core_Model_System_Config_Abstract
|
24 |
+
{
|
25 |
+
const AJAX = 'AJAX';
|
26 |
+
const HOSTED_IFRAME = 'hosted-Iframe';
|
27 |
+
|
28 |
+
/**
|
29 |
+
* @return array
|
30 |
+
*/
|
31 |
+
public function toArray()
|
32 |
+
{
|
33 |
+
return array(
|
34 |
+
self::AJAX => 'AJAX',
|
35 |
+
self::HOSTED_IFRAME => 'hosted-Iframe'
|
36 |
+
);
|
37 |
+
}
|
38 |
+
}
|
app/code/community/Payone/Core/etc/config.xml
CHANGED
@@ -24,7 +24,7 @@
|
|
24 |
<config>
|
25 |
<modules>
|
26 |
<Payone_Core>
|
27 |
-
<version>3.3.
|
28 |
</Payone_Core>
|
29 |
</modules>
|
30 |
|
24 |
<config>
|
25 |
<modules>
|
26 |
<Payone_Core>
|
27 |
+
<version>3.3.9</version>
|
28 |
</Payone_Core>
|
29 |
</modules>
|
30 |
|
app/code/community/Payone/Core/etc/system.xml
CHANGED
@@ -358,6 +358,24 @@
|
|
358 |
<show_in_website>1</show_in_website>
|
359 |
<show_in_store>1</show_in_store>
|
360 |
</min_validity_period>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
361 |
</fields>
|
362 |
</payment_creditcard>
|
363 |
<payment_paypal_express_checkout>
|
358 |
<show_in_website>1</show_in_website>
|
359 |
<show_in_store>1</show_in_store>
|
360 |
</min_validity_period>
|
361 |
+
<cc_request_type translate="label">
|
362 |
+
<label>Request-type</label>
|
363 |
+
<frontend_type>select</frontend_type>
|
364 |
+
<source_model>payone_core/system_config_creditcardRequestType</source_model>
|
365 |
+
<sort_order>20</sort_order>
|
366 |
+
<show_in_default>1</show_in_default>
|
367 |
+
<show_in_website>1</show_in_website>
|
368 |
+
<show_in_store>1</show_in_store>
|
369 |
+
</cc_request_type>
|
370 |
+
<cc_template translate="label">
|
371 |
+
<label>Input-configuration</label>
|
372 |
+
<frontend_model>payone_core/adminhtml_system_config_form_field_creditcardTemplate</frontend_model>
|
373 |
+
<backend_model>adminhtml/system_config_backend_serialized_array</backend_model>
|
374 |
+
<sort_order>30</sort_order>
|
375 |
+
<show_in_default>1</show_in_default>
|
376 |
+
<show_in_website>1</show_in_website>
|
377 |
+
<show_in_store>1</show_in_store>
|
378 |
+
</cc_template>
|
379 |
</fields>
|
380 |
</payment_creditcard>
|
381 |
<payment_paypal_express_checkout>
|
app/design/adminhtml/default/default/template/payone/core/client_api.phtml
CHANGED
@@ -22,3 +22,4 @@
|
|
22 |
*/
|
23 |
?>
|
24 |
<script type="text/javascript" src="https://secure.pay1.de/client-api/js/ajax.js"></script>
|
|
22 |
*/
|
23 |
?>
|
24 |
<script type="text/javascript" src="https://secure.pay1.de/client-api/js/ajax.js"></script>
|
25 |
+
<script type="text/javascript" src="https://secure.pay1.de/client-api/js/v1/payone_hosted_min.js"></script>
|
app/design/adminhtml/default/default/template/payone/core/payment/method/form/creditcard.phtml
CHANGED
@@ -25,83 +25,211 @@
|
|
25 |
$code = $this->getMethodCode();
|
26 |
$displayCvc = null;
|
27 |
?>
|
28 |
-
<
|
29 |
-
|
30 |
-
|
31 |
-
|
32 |
-
|
33 |
-
|
34 |
-
<
|
35 |
-
|
36 |
-
|
37 |
-
|
38 |
-
|
39 |
-
|
40 |
-
|
41 |
-
|
42 |
-
|
43 |
-
|
44 |
-
|
45 |
-
|
46 |
-
|
47 |
-
<
|
48 |
-
|
49 |
-
|
50 |
-
|
51 |
-
|
52 |
-
|
53 |
-
|
54 |
-
|
55 |
-
|
56 |
-
|
57 |
-
|
58 |
-
|
59 |
-
|
60 |
-
|
61 |
-
|
62 |
-
<!-- Credit card number : -->
|
63 |
-
<li>
|
64 |
-
<div class="input-box">
|
65 |
-
<label for="<?php echo $code; ?>_cc_number">
|
66 |
-
<?php echo $this->__('Credit Card Number'); ?> <span class="required">*</span>
|
67 |
-
</label><br/>
|
68 |
-
<input type="text" id="<?php echo $code; ?>_cc_number" name="payment[cc_number]" value=""
|
69 |
-
title="<?php echo $this->__('Credit Card Number'); ?>"
|
70 |
-
class="input-text validate-cc-number validate-payone-cc-type no-submit"/>
|
71 |
-
</div>
|
72 |
-
</li>
|
73 |
-
<!-- Credit card expiration date : -->
|
74 |
-
<li>
|
75 |
-
<div class="input-box">
|
76 |
-
<label for="<?php echo $code ?>_expiration">
|
77 |
-
<?php echo $this->__('Expiration Date') ?> <span class="required">*</span>
|
78 |
-
</label><br/>
|
79 |
-
<div class="v-fix">
|
80 |
-
<select id="<?php echo $code ?>_cc_expiration_month" name="payment[cc_exp_month]" style="width:140px;"
|
81 |
-
class="required-entry no-submit month validate-payone-cc-validity-period">
|
82 |
-
<?php foreach ($this->getCcMonths() as $key => $month): ?>
|
83 |
-
<option value="<?php echo $key ? $key : '' ?>"<?php if ($key == $this->getCreditCardExpireMonth()): ?>
|
84 |
-
selected="selected"<?php endif ?>><?php echo $month ?></option>
|
85 |
-
<?php endforeach ?>
|
86 |
</select>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
87 |
</div>
|
88 |
-
|
89 |
-
|
90 |
-
|
91 |
-
|
92 |
-
|
93 |
-
|
94 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
95 |
</select>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
96 |
</div>
|
97 |
-
</
|
98 |
-
|
99 |
-
|
100 |
-
|
101 |
-
|
102 |
-
|
103 |
-
|
104 |
-
|
105 |
-
|
106 |
-
|
107 |
-
</
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
25 |
$code = $this->getMethodCode();
|
26 |
$displayCvc = null;
|
27 |
?>
|
28 |
+
<script>
|
29 |
+
var sCCRequestType = '<?php echo $this->getCCRequestType(); ?>'
|
30 |
+
</script>
|
31 |
+
<?php if($this->getCCRequestType() == 'AJAX') { ?>
|
32 |
+
<ul id="payment_form_<?php echo $code ?>" style="display:none">
|
33 |
+
<li>
|
34 |
+
<div class="input-box">
|
35 |
+
<label for="<?php echo $code ?>_cc_owner">
|
36 |
+
<?php echo $this->__('Name on Card') ?> <span class="required">*</span>
|
37 |
+
</label>
|
38 |
+
<br/>
|
39 |
+
<input type="text" id="<?php echo $code ?>_cc_owner" name="payment[cc_owner]"
|
40 |
+
value="<?php echo $this->getBillingName(); ?>"
|
41 |
+
title="<?php echo $this->__('Name on Card') ?>"
|
42 |
+
class="required-entry input-text no-submit" />
|
43 |
+
</div>
|
44 |
+
</li>
|
45 |
+
<!-- Credit card type : -->
|
46 |
+
<li>
|
47 |
+
<div class="input-box">
|
48 |
+
<label for="<?php echo $code; ?>_cc_type">
|
49 |
+
<?php echo $this->__('Credit Card Type'); ?> <span class="required">*</span>
|
50 |
+
</label><br/>
|
51 |
+
<select id="<?php echo $code ?>_cc_type_select" name="<?php echo $code ?>_cc_type_select"
|
52 |
+
class="no-submit required-entry">
|
53 |
+
<option value=""><?php echo $this->__('--Please Select--') ?></option>
|
54 |
+
<?php
|
55 |
+
foreach ($this->getTypes() as $key => $type):
|
56 |
+
$selected = $this->getCreditCardType() == $type['code'] ? 'selected="selected"' : '';
|
57 |
+
?>
|
58 |
+
<option value="<?php echo $key ?>"<?php echo $selected; ?>>
|
59 |
+
<?php echo $type['name'] ?><span><?php echo $type['fee']; ?></span>
|
60 |
+
</option>
|
61 |
+
<?php endforeach; ?>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
62 |
</select>
|
63 |
+
<input type="hidden" id="<?php echo $code ?>_cc_type" name="payment[cc_type]" value="" class=""/>
|
64 |
+
</div>
|
65 |
+
</li>
|
66 |
+
<!-- Credit card number : -->
|
67 |
+
<li>
|
68 |
+
<div class="input-box">
|
69 |
+
<label for="<?php echo $code; ?>_cc_number">
|
70 |
+
<?php echo $this->__('Credit Card Number'); ?> <span class="required">*</span>
|
71 |
+
</label><br/>
|
72 |
+
<input type="text" id="<?php echo $code; ?>_cc_number" name="payment[cc_number]" value=""
|
73 |
+
title="<?php echo $this->__('Credit Card Number'); ?>"
|
74 |
+
class="input-text validate-cc-number validate-payone-cc-type no-submit"/>
|
75 |
</div>
|
76 |
+
</li>
|
77 |
+
<!-- Credit card expiration date : -->
|
78 |
+
<li>
|
79 |
+
<div class="input-box">
|
80 |
+
<label for="<?php echo $code ?>_expiration">
|
81 |
+
<?php echo $this->__('Expiration Date') ?> <span class="required">*</span>
|
82 |
+
</label><br/>
|
83 |
+
<div class="v-fix">
|
84 |
+
<select id="<?php echo $code ?>_cc_expiration_month" name="payment[cc_exp_month]" style="width:140px;"
|
85 |
+
class="required-entry no-submit month validate-payone-cc-validity-period">
|
86 |
+
<?php foreach ($this->getCcMonths() as $key => $month): ?>
|
87 |
+
<option value="<?php echo $key ? $key : '' ?>"<?php if ($key == $this->getCreditCardExpireMonth()): ?>
|
88 |
+
selected="selected"<?php endif ?>><?php echo $month ?></option>
|
89 |
+
<?php endforeach ?>
|
90 |
+
</select>
|
91 |
+
</div>
|
92 |
+
<div class="v-fix" style="padding-left:5px;">
|
93 |
+
<select id="<?php echo $code ?>_cc_expiration_year" name="payment[cc_exp_year]"style="width:103px;"
|
94 |
+
class="year required-entry no-submit">
|
95 |
+
<?php foreach ($this->getCcYears() as $key => $year): ?>
|
96 |
+
<option value="<?php echo $key ? $key : '' ?>"<?php if ($key == $this->getCreditCardExpireYear()): ?>
|
97 |
+
selected="selected"<?php endif ?>><?php echo $year ?></option>
|
98 |
+
<?php endforeach ?>
|
99 |
+
</select>
|
100 |
+
</div>
|
101 |
+
</div>
|
102 |
+
</li>
|
103 |
+
<li>
|
104 |
+
<input type="hidden" id="payone_pseudocardpan" name="payment[payone_pseudocardpan]" value=""/>
|
105 |
+
<input type="hidden" id="payone_truncatedcardpan" name="payment[cc_number_enc]" value=""/>
|
106 |
+
<input type="hidden" id="<?php echo $code ?>_config_id" name="payment[payone_config_payment_method_id]" value=""/>
|
107 |
+
<input type="hidden" id="<?php echo $code ?>_config" name="payment[request_config]"
|
108 |
+
value="<?php echo $this->escapeHtml($this->getClientApiConfigAsJson()); ?>" class=""/>
|
109 |
+
<input type="hidden" id="payone_cc_check_validation" value="<?php echo $this->getPayoneCreditCardCheckValidation();?>"/>
|
110 |
+
</li>
|
111 |
+
</ul>
|
112 |
+
<?php } else { ?>
|
113 |
+
<ul id="payment_form_<?php echo $code ?>" style="display:none">
|
114 |
+
<li>
|
115 |
+
<div class="input-box">
|
116 |
+
<label for="<?php echo $code; ?>_cc_type"><?php echo $this->__('Credit Card Type'); ?>
|
117 |
+
<span class="required">*</span>
|
118 |
+
</label><br class="clear"/>
|
119 |
+
<select id="<?php echo $code ?>_cc_type_select" name="<?php echo $code ?>_cc_type_select"
|
120 |
+
class="no-submit required-entry">
|
121 |
+
<?php
|
122 |
+
foreach ($this->getTypes() as $key => $type) :
|
123 |
+
$selected = $this->getCreditCardType() == $type['code'] ? 'selected="selected"' : '';
|
124 |
+
if ($displayCvc === null) {
|
125 |
+
$displayCvc = $type['check_cvc'];
|
126 |
+
}
|
127 |
+
?>
|
128 |
+
<option value="<?php echo $key ?>" <?php echo $selected; ?>>
|
129 |
+
<?php echo $type['name'] ?><span><?php echo $type['fee']; ?></span>
|
130 |
+
</option>
|
131 |
+
<?php endforeach; ?>
|
132 |
</select>
|
133 |
+
<input type="hidden" id="<?php echo $code ?>_cc_type" name="payment[cc_type]" value="<?php echo $this->getCreditCardType();?>" class=""/>
|
134 |
+
</div>
|
135 |
+
</li>
|
136 |
+
<li>
|
137 |
+
<div class="input-box">
|
138 |
+
<label for="cardpanInput"><?php echo $this->__('Credit Card Number'); ?> <span class="required">*</span></label>
|
139 |
+
<br class="clear"/>
|
140 |
+
<span class="inputIframe" id="cardpan"></span>
|
141 |
</div>
|
142 |
+
</li>
|
143 |
+
<li>
|
144 |
+
<div class="input-box">
|
145 |
+
<label for="expireInput"><?php echo $this->__('Expiration Date') ?> <span class="required">*</span></label>
|
146 |
+
<br class="clear"/>
|
147 |
+
<span id="expireInput" class="inputIframe">
|
148 |
+
<span id="cardexpiremonth"></span>
|
149 |
+
<span id="cardexpireyear"></span>
|
150 |
+
</span>
|
151 |
+
</div>
|
152 |
+
</li>
|
153 |
+
<li>
|
154 |
+
<div class="input-box">
|
155 |
+
<label for="firstname"><?php echo $this->__('Firstname') ?><span class="required">*</span></label>
|
156 |
+
<br class="clear"/>
|
157 |
+
<input id="firstname" type="text" name="firstname" value="">
|
158 |
+
</div>
|
159 |
+
</li>
|
160 |
+
<li>
|
161 |
+
<div class="input-box">
|
162 |
+
<label for="lastname"><?php echo $this->__('Lastname') ?><span class="required">*</span></label>
|
163 |
+
<br class="clear"/>
|
164 |
+
<input id="lastname" type="text" name="lastname" value="">
|
165 |
+
</div>
|
166 |
+
</li>
|
167 |
+
<li>
|
168 |
+
<div id="errorOutput"></div>
|
169 |
+
<input type="hidden" id="<?php echo $code; ?>_cc_number" value=""/>
|
170 |
+
<input type="hidden" id="<?php echo $code ?>_cc_owner" name="payment[cc_owner]" value="" />
|
171 |
+
<input type="hidden" id="payone_pseudocardpan" name="payment[payone_pseudocardpan]" value="<?php echo $this->getPayonePseudocardpan();?>"/>
|
172 |
+
<input type="hidden" id="payone_truncatedcardpan" name="payment[cc_number_enc]" value="<?php echo $this->getCreditCardNumberEnc();?>"/>
|
173 |
+
<input type="hidden" id="<?php echo $code ?>_config_id" name="payment[payone_config_payment_method_id]"
|
174 |
+
value="<?php echo $this->getPayoneConfigPaymentMethodId();?>"/>
|
175 |
+
<input type="hidden" id="<?php echo $code ?>_config" name="payment[payone_config]"
|
176 |
+
value="<?php echo $this->escapeHtml($this->getHostedClientApiConfigAsJson()); ?>" class=""/>
|
177 |
+
<input type="hidden" id="<?php echo $code ?>_config_cvc" name="payment[payone_config_cvc]"
|
178 |
+
value="<?php echo $this->escapeHtml($this->getCvcJson()); ?>" class=""/>
|
179 |
+
<input type="hidden" id="payone_cc_check_validation" value="<?php echo $this->getPayoneCreditCardCheckValidation();?>"/>
|
180 |
+
</li>
|
181 |
+
</ul>
|
182 |
+
<script>
|
183 |
+
var request, fieldconfig;
|
184 |
+
fieldconfig = {
|
185 |
+
fields: {
|
186 |
+
cardpan: {
|
187 |
+
selector: "cardpan", // put name of your div-container here
|
188 |
+
type: "text", // text (default), password, tel
|
189 |
+
size: "30",
|
190 |
+
maxlength: "16",
|
191 |
+
},
|
192 |
+
cardexpiremonth: {
|
193 |
+
selector: "cardexpiremonth", // put name of your div-container here
|
194 |
+
type: "select",
|
195 |
+
size: "3",
|
196 |
+
maxlength: "2",
|
197 |
+
iframe: {
|
198 |
+
width: "50px",
|
199 |
+
}
|
200 |
+
},
|
201 |
+
cardexpireyear: {
|
202 |
+
selector: "cardexpireyear", // put name of your div-container here
|
203 |
+
type: "select",
|
204 |
+
size: "5",
|
205 |
+
maxlength: "4",
|
206 |
+
iframe: {
|
207 |
+
width: "80px",
|
208 |
+
}
|
209 |
+
}
|
210 |
+
},
|
211 |
+
defaultStyle: {
|
212 |
+
input: "",
|
213 |
+
select: "",
|
214 |
+
iframe: {
|
215 |
+
width: "202px",
|
216 |
+
height: "20px"
|
217 |
+
}
|
218 |
+
},
|
219 |
+
|
220 |
+
<?php if($this->getHostedParam('Errors_active') == "true") { ?>
|
221 |
+
error: "errorOutput", // area to display error-messages (optional)
|
222 |
+
<?php if($this->getHostedParam('Errors_lang') == "de") { ?>
|
223 |
+
language: Payone.ClientApi.Language.de // Language to display error-messages
|
224 |
+
<?php } else { ?>
|
225 |
+
language: Payone.ClientApi.Language.en
|
226 |
+
<?php } ?>
|
227 |
+
<?php } ?>
|
228 |
+
};
|
229 |
+
var sTypeIdSelector = '<?php echo $code ?>_cc_type_select'
|
230 |
+
if(typeof iframes == 'undefined') {
|
231 |
+
var iframes = payone.initHosted(fieldconfig, sTypeIdSelector);
|
232 |
+
}
|
233 |
+
|
234 |
+
</script>
|
235 |
+
<?php } ?>
|
app/design/adminhtml/default/default/template/payone/core/sales/order/create/init.phtml
CHANGED
@@ -41,6 +41,10 @@
|
|
41 |
return params;
|
42 |
}
|
43 |
);
|
|
|
|
|
|
|
|
|
44 |
});
|
45 |
//]]>
|
46 |
</script>
|
41 |
return params;
|
42 |
}
|
43 |
);
|
44 |
+
|
45 |
+
if(typeof sCCRequestType != 'undefined' && sCCRequestType == 'hosted-Iframe') {
|
46 |
+
var iframes = payone.initHosted(fieldconfig, sTypeIdSelector);
|
47 |
+
}
|
48 |
});
|
49 |
//]]>
|
50 |
</script>
|
app/design/adminhtml/default/default/template/payone/core/system/config/form/field/creditcard_template.phtml
ADDED
@@ -0,0 +1,317 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
*
|
4 |
+
* NOTICE OF LICENSE
|
5 |
+
*
|
6 |
+
* This source file is subject to the GNU General Public License (GPL 3)
|
7 |
+
* that is bundled with this package in the file LICENSE.txt
|
8 |
+
*
|
9 |
+
* DISCLAIMER
|
10 |
+
*
|
11 |
+
* Do not edit or add to this file if you wish to upgrade Payone_Core to newer
|
12 |
+
* versions in the future. If you wish to customize Payone_Core for your
|
13 |
+
* needs please refer to http://www.payone.de for more information.
|
14 |
+
*
|
15 |
+
* @category Payone
|
16 |
+
* @package design_adminhtml_default_default
|
17 |
+
* @subpackage template
|
18 |
+
* @copyright Copyright (c) 2012 <info@noovias.com> - www.noovias.com
|
19 |
+
* @author Matthias Walter <info@noovias.com>
|
20 |
+
* @license <http://www.gnu.org/licenses/> GNU General Public License (GPL 3)
|
21 |
+
* @link http://www.noovias.com
|
22 |
+
*/
|
23 |
+
?>
|
24 |
+
|
25 |
+
<script type="text/javascript">
|
26 |
+
|
27 |
+
function _groupExp(oElement) {
|
28 |
+
var _cur = oElement.parentNode;
|
29 |
+
|
30 |
+
if (_cur.className == "exp") {
|
31 |
+
_cur.className = "";
|
32 |
+
} else {
|
33 |
+
_cur.className = "exp";
|
34 |
+
}
|
35 |
+
}
|
36 |
+
|
37 |
+
function toggleHostedTemplate() {
|
38 |
+
if(document.getElementById('fcpoHostedCCTemplate').style.display != "") {
|
39 |
+
document.getElementById('fcpoHostedCCTemplate').style.display = "";
|
40 |
+
} else {
|
41 |
+
document.getElementById('fcpoHostedCCTemplate').style.display = "none";
|
42 |
+
}
|
43 |
+
}
|
44 |
+
|
45 |
+
function togglePreview() {
|
46 |
+
if(document.getElementById('fcpoHostedCCPreview').style.display != "") {
|
47 |
+
document.getElementById('fcpoHostedCCPreview').style.display = "";
|
48 |
+
} else {
|
49 |
+
document.getElementById('fcpoHostedCCPreview').style.display = "none";
|
50 |
+
}
|
51 |
+
}
|
52 |
+
|
53 |
+
function inputEnable(sInputId) {
|
54 |
+
document.getElementById(sInputId).disabled = false;
|
55 |
+
}
|
56 |
+
function inputDisable(sInputId) {
|
57 |
+
document.getElementById(sInputId).disabled = true;
|
58 |
+
}
|
59 |
+
|
60 |
+
function handleSizeFields(oSelect, sRowName) {
|
61 |
+
if(oSelect.options[oSelect.selectedIndex].value == 'custom') {
|
62 |
+
inputEnable('input_height_' + sRowName);
|
63 |
+
inputEnable('input_width_' + sRowName);
|
64 |
+
} else {
|
65 |
+
inputDisable('input_height_' + sRowName);
|
66 |
+
inputDisable('input_width_' + sRowName);
|
67 |
+
}
|
68 |
+
}
|
69 |
+
|
70 |
+
function handleCss(oSelect, sRowName) {
|
71 |
+
if(oSelect.options[oSelect.selectedIndex].value == 'custom') {
|
72 |
+
inputEnable('input_css_' + sRowName);
|
73 |
+
} else {
|
74 |
+
inputDisable('input_css_' + sRowName);
|
75 |
+
}
|
76 |
+
}
|
77 |
+
|
78 |
+
</script>
|
79 |
+
|
80 |
+
<a href="#" onclick="toggleHostedTemplate();return false;" style="text-decoration: underline;"><?php echo Mage::helper('payone_core')->__('Custom styling hosted-Iframe') ?></a>
|
81 |
+
<div id="fcpoHostedCCTemplate" style="display:none;padding-top:10px;">
|
82 |
+
<table>
|
83 |
+
<tr>
|
84 |
+
<th style="text-align:left;width:120px;"><?php echo Mage::helper('payone_core')->__('Field') ?></th>
|
85 |
+
<th><?php echo Mage::helper('payone_core')->__('Type') ?></th>
|
86 |
+
<th><?php echo Mage::helper('payone_core')->__('Digit-<br>count') ?></th>
|
87 |
+
<th><?php echo Mage::helper('payone_core')->__('Max-<br>digits') ?></th>
|
88 |
+
<th><?php echo Mage::helper('payone_core')->__('Iframe') ?></th>
|
89 |
+
<th><?php echo Mage::helper('payone_core')->__('Width') ?></th>
|
90 |
+
<th><?php echo Mage::helper('payone_core')->__('Height') ?></th>
|
91 |
+
<th><?php echo Mage::helper('payone_core')->__('Style') ?></th>
|
92 |
+
<th><?php echo Mage::helper('payone_core')->__('CSS') ?></th>
|
93 |
+
</tr>
|
94 |
+
<?php foreach ($this->getCCFields() as $sField) { ?>
|
95 |
+
<tr>
|
96 |
+
<td>
|
97 |
+
<?php echo Mage::helper('payone_core')->__('FCPO_CC_ROW_CC_'.$sField) ?>
|
98 |
+
</td>
|
99 |
+
<td>
|
100 |
+
<?php $sFieldIdent = $sField.'_type'; ?>
|
101 |
+
<select name="<?php echo $this->getElement()->getName().'['.$sFieldIdent.']'; ?>" style="width:inherit;">
|
102 |
+
<?php foreach ($this->getCCTypes($sField) as $sType => $sTitle) { ?>
|
103 |
+
<option value="<?php echo $sType; ?>" <?php if($sType == $this->fcpoGetValue($sFieldIdent)) echo 'selected'; ?>><?php echo $sTitle; ?></option>
|
104 |
+
<?php } ?>
|
105 |
+
</select>
|
106 |
+
</td>
|
107 |
+
<td>
|
108 |
+
<?php $sFieldIdent = $sField.'_count'; ?>
|
109 |
+
<input type="text" class="txt" size="4" name="<?php echo $this->getElement()->getName().'['.$sFieldIdent.']'; ?>" value="<?php echo $this->fcpoGetValue($sFieldIdent); ?>">
|
110 |
+
</td>
|
111 |
+
<td>
|
112 |
+
<?php $sFieldIdent = $sField.'_max'; ?>
|
113 |
+
<input type="text" class="txt" size="4" name="<?php echo $this->getElement()->getName().'['.$sFieldIdent.']'; ?>" value="<?php echo $this->fcpoGetValue($sFieldIdent); ?>">
|
114 |
+
</td>
|
115 |
+
<td>
|
116 |
+
<?php $sFieldIdentIframe = $sField.'_iframe'; ?>
|
117 |
+
<select name="<?php echo $this->getElement()->getName().'['.$sFieldIdentIframe.']'; ?>" onchange="handleSizeFields(this, '<?php echo $sField; ?>')" style="width:inherit;">
|
118 |
+
<?php foreach ($this->getCCStyles() as $sType => $sTitle) { ?>
|
119 |
+
<option value="<?php echo $sType; ?>" <?php if($sType == $this->fcpoGetValue($sFieldIdentIframe)) echo 'selected'; ?>><?php echo $sTitle; ?></option>
|
120 |
+
<?php } ?>
|
121 |
+
</select>
|
122 |
+
</td>
|
123 |
+
<td>
|
124 |
+
<?php $sFieldIdent = $sField.'_width'; ?>
|
125 |
+
<input id="input_width_<?php echo $sField; ?>" type="text" class="txt" size="4" name="<?php echo $this->getElement()->getName().'['.$sFieldIdent.']'; ?>" value="<?php echo $this->fcpoGetValue($sFieldIdent); ?>" <?php if($this->fcpoGetValue($sFieldIdentIframe) != "custom") echo 'disabled'; ?>>
|
126 |
+
</td>
|
127 |
+
<td>
|
128 |
+
<?php $sFieldIdent = $sField.'_height'; ?>
|
129 |
+
<input id="input_height_<?php echo $sField; ?>" type="text" class="txt" size="4" name="<?php echo $this->getElement()->getName().'['.$sFieldIdent.']'; ?>" value="<?php echo $this->fcpoGetValue($sFieldIdent); ?>" <?php if($this->fcpoGetValue($sFieldIdentIframe) != "custom") echo 'disabled'; ?>>
|
130 |
+
</td>
|
131 |
+
<td>
|
132 |
+
<?php $sFieldIdentCSS = $sField.'_style';# = "sFCPOCC".$sField."Style"; ?>
|
133 |
+
<select name="<?php echo $this->getElement()->getName().'['.$sFieldIdentCSS.']'; ?>" onchange="handleCss(this, '<?php echo $sField; ?>')" style="width:inherit;">
|
134 |
+
<?php foreach ($this->getCCStyles() as $sType => $sTitle) { ?>
|
135 |
+
<option value="<?php echo $sType; ?>" <?php if($sType == $this->fcpoGetValue($sFieldIdentCSS)) echo 'selected'; ?>><?php echo $sTitle; ?></option>
|
136 |
+
<?php } ?>
|
137 |
+
</select>
|
138 |
+
</td>
|
139 |
+
<td>
|
140 |
+
<?php $sFieldIdent = $sField.'_css';# = "sFCPOCC".$sField."CSS"; ?>
|
141 |
+
<input id="input_css_<?php echo $sField; ?>" type="text" class="txt" size="50" name="<?php echo $this->getElement()->getName().'['.$sFieldIdent.']'; ?>" value="<?php echo $this->fcpoGetValue($sFieldIdent); ?>" <?php if($this->fcpoGetValue($sFieldIdentCSS) != "custom") echo 'disabled'; ?>>
|
142 |
+
</td>
|
143 |
+
</tr>
|
144 |
+
<?php } ?>
|
145 |
+
</table>
|
146 |
+
<br>
|
147 |
+
<table>
|
148 |
+
<tr>
|
149 |
+
<th style="text-align:left;width:120px;"><?php echo Mage::helper('payone_core')->__('Standard-style'); ?></th>
|
150 |
+
<td><?php echo Mage::helper('payone_core')->__('Input'); ?></td>
|
151 |
+
<td><?php echo Mage::helper('payone_core')->__('Selection'); ?></td>
|
152 |
+
</tr>
|
153 |
+
<tr>
|
154 |
+
<td><?php echo Mage::helper('payone_core')->__('Input-fields'); ?></td>
|
155 |
+
<?php $sFieldIdent = 'Standard_input'; ?>
|
156 |
+
<td><input type="text" size="50" name="<?php echo $this->getElement()->getName().'['.$sFieldIdent.']'; ?>" value="<?php echo $this->fcpoGetValue($sFieldIdent); ?>"></td>
|
157 |
+
<?php $sFieldIdent = 'Standard_selection'; ?>
|
158 |
+
<td><input type="text" size="50" name="<?php echo $this->getElement()->getName().'['.$sFieldIdent.']'; ?>" value="<?php echo $this->fcpoGetValue($sFieldIdent); ?>"></td>
|
159 |
+
</tr>
|
160 |
+
<tr>
|
161 |
+
<td><?php echo Mage::helper('payone_core')->__('Iframe'); ?></td>
|
162 |
+
<td colspan="2">
|
163 |
+
<table>
|
164 |
+
<tr>
|
165 |
+
<td><?php echo Mage::helper('payone_core')->__('Width'); ?></td>
|
166 |
+
<td><?php echo Mage::helper('payone_core')->__('Height'); ?></td>
|
167 |
+
</tr>
|
168 |
+
<tr>
|
169 |
+
<?php $sFieldIdent = 'Iframe_width'; ?>
|
170 |
+
<td><input type="text" size="4" name="<?php echo $this->getElement()->getName().'['.$sFieldIdent.']'; ?>" value="<?php echo $this->fcpoGetValue($sFieldIdent); ?>"></td>
|
171 |
+
<?php $sFieldIdent = 'Iframe_height'; ?>
|
172 |
+
<td><input type="text" size="4" name="<?php echo $this->getElement()->getName().'['.$sFieldIdent.']'; ?>" value="<?php echo $this->fcpoGetValue($sFieldIdent); ?>"></td>
|
173 |
+
</tr>
|
174 |
+
</table>
|
175 |
+
</td>
|
176 |
+
</tr>
|
177 |
+
</table>
|
178 |
+
<br>
|
179 |
+
<table>
|
180 |
+
<tr>
|
181 |
+
<th style="text-align:left;width:120px;"><?php echo Mage::helper('payone_core')->__('Error-output'); ?></th>
|
182 |
+
<td></td>
|
183 |
+
</tr>
|
184 |
+
<tr>
|
185 |
+
<td><?php echo Mage::helper('payone_core')->__('Active'); ?></td>
|
186 |
+
<td>
|
187 |
+
<?php $sFieldIdent = 'Errors_active'; ?>
|
188 |
+
<input type="hidden" name="<?php echo $this->getElement()->getName().'['.$sFieldIdent.']'; ?>" value="false">
|
189 |
+
<input type="checkbox" name="<?php echo $this->getElement()->getName().'['.$sFieldIdent.']'; ?>" value="true" <?php if ($this->fcpoGetValue($sFieldIdent) == "true") echo 'checked'; ?>>
|
190 |
+
</td>
|
191 |
+
</tr>
|
192 |
+
<tr>
|
193 |
+
<td><?php echo Mage::helper('payone_core')->__('Language'); ?></td>
|
194 |
+
<td>
|
195 |
+
<?php $sFieldIdent = 'Errors_lang'; ?>
|
196 |
+
<select name="<?php echo $this->getElement()->getName().'['.$sFieldIdent.']'; ?>">
|
197 |
+
<option value="de" <?php if ($this->fcpoGetValue($sFieldIdent) == 'de') echo 'selected'; ?>><?php echo Mage::helper('payone_core')->__('German'); ?></option>
|
198 |
+
<option value="en" <?php if ($this->fcpoGetValue($sFieldIdent) == 'en') echo 'selected'; ?>><?php echo Mage::helper('payone_core')->__('English'); ?></option>
|
199 |
+
</select>
|
200 |
+
</td>
|
201 |
+
</tr>
|
202 |
+
</table>
|
203 |
+
<br>
|
204 |
+
<a href="#" onclick="togglePreview();return false;" style="text-decoration: underline;"><?php echo Mage::helper('payone_core')->__('Preview'); ?></a>
|
205 |
+
<div id="fcpoHostedCCPreview" style="display:none;padding-top:10px;">
|
206 |
+
|
207 |
+
<?php echo Mage::helper('payone_core')->__('You need to save before the changes are visible in the preview!'); ?>
|
208 |
+
<div style="border:1px solid #000;padding:10px;background-color: #fff;">
|
209 |
+
<script type="text/javascript" src="https://secure.pay1.de/client-api/js/v1/payone_hosted_min.js"></script>
|
210 |
+
<table>
|
211 |
+
<tr>
|
212 |
+
<td><label for="cardpanInput"><?php echo Mage::helper('payone_core')->__('Number:'); ?></label></td>
|
213 |
+
<td><span class="inputIframe" id="cardpan"></span></td>
|
214 |
+
</tr>
|
215 |
+
<tr>
|
216 |
+
<td><label for="cvcInput"><?php echo Mage::helper('payone_core')->__('CVV2 or CVC2 security code:'); ?></label></td>
|
217 |
+
<td><span id="cardcvc2" class="inputIframe"></span></td>
|
218 |
+
</tr>
|
219 |
+
<tr>
|
220 |
+
<td><label for="expireInput"><?php echo Mage::helper('payone_core')->__('Valid until:'); ?></label></td>
|
221 |
+
<td>
|
222 |
+
<span id="expireInput" class="inputIframe">
|
223 |
+
<span id="cardexpiremonth"></span>
|
224 |
+
<span id="cardexpireyear"></span>
|
225 |
+
</span>
|
226 |
+
</td>
|
227 |
+
</tr>
|
228 |
+
</table>
|
229 |
+
<script>
|
230 |
+
var request, config;
|
231 |
+
config = {
|
232 |
+
fields: {
|
233 |
+
cardpan: {
|
234 |
+
selector: "cardpan", // put name of your div-container here
|
235 |
+
type: "<?php echo $this->fcpoGetValue('Number_type'); ?>", // text (default), password, tel
|
236 |
+
size: "<?php echo $this->fcpoGetValue('Number_count'); ?>",
|
237 |
+
maxlength: "<?php echo $this->fcpoGetValue('Number_max'); ?>",
|
238 |
+
<?php if($this->fcpoGetValue('Number_style') == "custom") { ?>
|
239 |
+
style: "<?php echo $this->fcpoGetValue('Number_css'); ?>",
|
240 |
+
<?php } ?>
|
241 |
+
<?php if($this->fcpoGetValue('Number_iframe') == "custom") { ?>
|
242 |
+
iframe: {
|
243 |
+
width: "<?php echo $this->fcpoGetValue('Number_width'); ?>",
|
244 |
+
height: "<?php echo $this->fcpoGetValue('Number_height'); ?>"
|
245 |
+
}
|
246 |
+
<?php } ?>
|
247 |
+
},
|
248 |
+
cardcvc2: {
|
249 |
+
selector: "cardcvc2", // put name of your div-container here
|
250 |
+
type: "<?php echo $this->fcpoGetValue('CVC_type'); ?>", // text (default), password, tel
|
251 |
+
size: "<?php echo $this->fcpoGetValue('CVC_count'); ?>",
|
252 |
+
maxlength: "<?php echo $this->fcpoGetValue('CVC_max'); ?>",
|
253 |
+
<?php if($this->fcpoGetValue('CVC_style') == "custom") { ?>
|
254 |
+
style: "<?php echo $this->fcpoGetValue('CVC_css'); ?>",
|
255 |
+
<?php } ?>
|
256 |
+
<?php if($this->fcpoGetValue('CVC_iframe') == "custom") { ?>
|
257 |
+
iframe: {
|
258 |
+
width: "<?php echo $this->fcpoGetValue('CVC_width'); ?>",
|
259 |
+
height: "<?php echo $this->fcpoGetValue('CVC_height'); ?>"
|
260 |
+
}
|
261 |
+
<?php } ?>
|
262 |
+
},
|
263 |
+
cardexpiremonth: {
|
264 |
+
selector: "cardexpiremonth", // put name of your div-container here
|
265 |
+
type: "<?php echo $this->fcpoGetValue('Month_type'); ?>",
|
266 |
+
size: "<?php echo $this->fcpoGetValue('Month_count'); ?>",
|
267 |
+
maxlength: "<?php echo $this->fcpoGetValue('Month_max'); ?>",
|
268 |
+
<?php if($this->fcpoGetValue('Month_style') == "custom") { ?>
|
269 |
+
style: "<?php echo $this->fcpoGetValue('Month_css'); ?>",
|
270 |
+
<?php } ?>
|
271 |
+
<?php if($this->fcpoGetValue('Month_iframe') == "custom") { ?>
|
272 |
+
iframe: {
|
273 |
+
width: "<?php echo $this->fcpoGetValue('Month_width'); ?>",
|
274 |
+
height: "<?php echo $this->fcpoGetValue('Month_height'); ?>"
|
275 |
+
}
|
276 |
+
<?php } ?>
|
277 |
+
},
|
278 |
+
cardexpireyear: {
|
279 |
+
selector: "cardexpireyear", // put name of your div-container here
|
280 |
+
type: "<?php echo $this->fcpoGetValue('Year_type'); ?>",
|
281 |
+
size: "<?php echo $this->fcpoGetValue('Year_count'); ?>",
|
282 |
+
maxlength: "<?php echo $this->fcpoGetValue('Year_max'); ?>",
|
283 |
+
<?php if($this->fcpoGetValue('Year_style') == "custom") { ?>
|
284 |
+
style: "<?php echo $this->fcpoGetValue('Year_css'); ?>",
|
285 |
+
<?php } ?>
|
286 |
+
<?php if($this->fcpoGetValue('Year_iframe') == "custom") { ?>
|
287 |
+
iframe: {
|
288 |
+
width: "<?php echo $this->fcpoGetValue('Year_width'); ?>",
|
289 |
+
height: "<?php echo $this->fcpoGetValue('Year_height'); ?>"
|
290 |
+
}
|
291 |
+
<?php } ?>
|
292 |
+
}
|
293 |
+
},
|
294 |
+
defaultStyle: {
|
295 |
+
input: "<?php echo $this->fcpoGetValue('Standard_input'); ?>",
|
296 |
+
select: "<?php echo $this->fcpoGetValue('Standard_selection'); ?>",
|
297 |
+
iframe: {
|
298 |
+
width: "<?php echo $this->fcpoGetValue('Iframe_width'); ?>",
|
299 |
+
height: "<?php echo $this->fcpoGetValue('Iframe_height'); ?>"
|
300 |
+
}
|
301 |
+
},
|
302 |
+
|
303 |
+
<?php if($this->fcpoGetValue('Errors_active') == "true") { ?>
|
304 |
+
error: "errorOutput", // area to display error-messages (optional)
|
305 |
+
<?php if($this->fcpoGetValue('Errors_lang') == "de") { ?>
|
306 |
+
language: Payone.ClientApi.Language.de // Language to display error-messages
|
307 |
+
<?php } else { ?>
|
308 |
+
language: Payone.ClientApi.Language.en
|
309 |
+
<?php } ?>
|
310 |
+
<?php } ?>
|
311 |
+
};
|
312 |
+
var iframes = new Payone.ClientApi.HostedIFrames(config, request);
|
313 |
+
</script>
|
314 |
+
</div>
|
315 |
+
|
316 |
+
</div>
|
317 |
+
</div>
|
app/design/frontend/base/default/template/payone/core/client_api.phtml
CHANGED
@@ -22,3 +22,4 @@
|
|
22 |
*/
|
23 |
?>
|
24 |
<script type="text/javascript" src="https://secure.pay1.de/client-api/js/ajax.js"></script>
|
|
22 |
*/
|
23 |
?>
|
24 |
<script type="text/javascript" src="https://secure.pay1.de/client-api/js/ajax.js"></script>
|
25 |
+
<script type="text/javascript" src="https://secure.pay1.de/client-api/js/v1/payone_hosted_min.js"></script>
|
app/design/frontend/base/default/template/payone/core/payment/method/form/creditcard.phtml
CHANGED
@@ -26,114 +26,279 @@ $code = $this->getMethodCode();
|
|
26 |
$displayCvc = null;
|
27 |
?>
|
28 |
<fieldset class="form-list">
|
29 |
-
|
30 |
-
|
31 |
-
|
32 |
-
<
|
33 |
-
<
|
34 |
-
<
|
35 |
-
|
36 |
-
|
37 |
-
|
38 |
-
|
39 |
-
|
40 |
-
|
41 |
-
|
42 |
-
|
43 |
-
|
44 |
-
|
45 |
-
<
|
46 |
-
<
|
47 |
-
<
|
48 |
-
|
49 |
-
|
50 |
-
|
51 |
-
|
52 |
-
|
53 |
-
|
54 |
-
|
55 |
-
|
56 |
-
|
57 |
-
|
58 |
-
|
59 |
-
|
60 |
-
|
61 |
-
|
62 |
-
|
63 |
-
|
64 |
-
<input type="hidden" id="<?php echo $code ?>_cc_type" name="payment[cc_type]" value="<?php echo $this->getCreditCardType();?>" class=""/>
|
65 |
-
</div>
|
66 |
-
</li>
|
67 |
-
<!-- Credit card number : -->
|
68 |
-
<li>
|
69 |
-
<div class="input-box">
|
70 |
-
<label for="<?php echo $code; ?>_cc_number">
|
71 |
-
<?php echo $this->__('Credit Card Number'); ?> <span class="required">*</span>
|
72 |
-
</label><br class="clear"/>
|
73 |
-
<input type="text" id="<?php echo $code; ?>_cc_number"
|
74 |
-
value="<?php echo $this->getCreditCardNumberEnc();?>"
|
75 |
-
name="payment[cc_number]" title="<?php echo $this->__('Credit Card Number'); ?>"
|
76 |
-
class="input-text <?php echo ($this->getPayoneCreditCardCheckValidation() == 0)?'':'validate-cc-number'?> validate-payone-cc-type no-submit"
|
77 |
-
onchange="inputToNumbers(this); payoneChangedCreditCardNumber();"
|
78 |
-
oninput="inputToNumbers(this); payoneChangedCreditCardNumber();"/>
|
79 |
-
</div>
|
80 |
-
</li>
|
81 |
-
<!-- Credit card expiration date : -->
|
82 |
-
<li>
|
83 |
-
<div class="input-box">
|
84 |
-
<label for="<?php echo $code ?>_expiration">
|
85 |
-
<?php echo $this->__('Expiration Date') ?> <span class="required">*</span>
|
86 |
-
</label><br class="clear"/>
|
87 |
-
|
88 |
-
<div class="v-fix">
|
89 |
-
<select id="<?php echo $code ?>_cc_expiration_month" name="payment[cc_exp_month]"
|
90 |
-
style="width:140px;"
|
91 |
-
class="required-entry no-submit month validate-payone-cc-validity-period ">
|
92 |
-
<?php foreach ($this->getCcMonths() as $key => $month): ?>
|
93 |
-
<option value="<?php echo $key ? $key : '' ?>"<?php if ($key == $this->getCreditCardExpireMonth()): ?>
|
94 |
-
selected="selected"<?php endif ?>><?php echo $month ?></option>
|
95 |
-
<?php endforeach ?>
|
96 |
</select>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
97 |
</div>
|
98 |
-
|
99 |
-
|
100 |
-
|
101 |
-
|
102 |
-
|
103 |
-
|
104 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
105 |
</select>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
106 |
</div>
|
107 |
-
</
|
108 |
-
|
109 |
-
|
110 |
-
|
111 |
-
|
112 |
-
|
113 |
-
<
|
114 |
-
|
115 |
-
|
116 |
-
<input type="
|
117 |
-
|
118 |
-
|
119 |
-
value="<?php echo $this->
|
120 |
-
|
121 |
-
|
122 |
-
|
123 |
-
|
124 |
-
|
125 |
-
|
126 |
-
|
127 |
-
|
128 |
-
|
129 |
-
|
130 |
-
|
131 |
-
|
132 |
-
|
133 |
-
|
134 |
-
|
135 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
136 |
|
137 |
-
|
138 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
139 |
</fieldset>
|
26 |
$displayCvc = null;
|
27 |
?>
|
28 |
<fieldset class="form-list">
|
29 |
+
<?php if($this->getCCRequestType() == 'AJAX') { ?>
|
30 |
+
<ul id="payment_form_<?php echo $code ?>" style="display:none">
|
31 |
+
<!-- Creditcard owner : -->
|
32 |
+
<li>
|
33 |
+
<div class="input-box">
|
34 |
+
<label for="<?php echo $code ?>_cc_owner"><?php echo $this->__('Name on Card') ?>
|
35 |
+
<span class="required">*</span>
|
36 |
+
</label>
|
37 |
+
<br class="clear"/>
|
38 |
+
<input type="text" id="<?php echo $code ?>_cc_owner" name="payment[cc_owner]"
|
39 |
+
value="<?php echo $this->getBillingName(); ?>"
|
40 |
+
title="<?php echo $this->__('Name on Card') ?>"
|
41 |
+
class="required-entry input-text no-submit"/>
|
42 |
+
</div>
|
43 |
+
</li>
|
44 |
+
<!-- Credit card type : -->
|
45 |
+
<li>
|
46 |
+
<div class="input-box">
|
47 |
+
<label for="<?php echo $code; ?>_cc_type"><?php echo $this->__('Credit Card Type'); ?>
|
48 |
+
<span class="required">*</span>
|
49 |
+
</label><br class="clear"/>
|
50 |
+
<select id="<?php echo $code ?>_cc_type_select" name="<?php echo $code ?>_cc_type_select"
|
51 |
+
onchange="payone.displayCheckCvc(this);" class="no-submit required-entry">
|
52 |
+
<option value=""><?php echo $this->__('--Please Select--') ?></option>
|
53 |
+
<?php
|
54 |
+
foreach ($this->getTypes() as $key => $type) :
|
55 |
+
$selected = $this->getCreditCardType() == $type['code'] ? 'selected="selected"' : '';
|
56 |
+
if ($displayCvc === null) {
|
57 |
+
$displayCvc = $type['check_cvc'];
|
58 |
+
}
|
59 |
+
?>
|
60 |
+
<option value="<?php echo $key ?>" <?php echo $selected; ?>>
|
61 |
+
<?php echo $type['name'] ?><span><?php echo $type['fee']; ?></span>
|
62 |
+
</option>
|
63 |
+
<?php endforeach; ?>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
64 |
</select>
|
65 |
+
<input type="hidden" id="<?php echo $code ?>_cc_type" name="payment[cc_type]" value="<?php echo $this->getCreditCardType();?>" class=""/>
|
66 |
+
</div>
|
67 |
+
</li>
|
68 |
+
<!-- Credit card number : -->
|
69 |
+
<li>
|
70 |
+
<div class="input-box">
|
71 |
+
<label for="<?php echo $code; ?>_cc_number">
|
72 |
+
<?php echo $this->__('Credit Card Number'); ?> <span class="required">*</span>
|
73 |
+
</label><br class="clear"/>
|
74 |
+
<input type="text" id="<?php echo $code; ?>_cc_number"
|
75 |
+
value="<?php echo $this->getCreditCardNumberEnc();?>"
|
76 |
+
name="payment[cc_number]" title="<?php echo $this->__('Credit Card Number'); ?>"
|
77 |
+
class="input-text <?php echo ($this->getPayoneCreditCardCheckValidation() == 0)?'':'validate-cc-number'?> validate-payone-cc-type no-submit"
|
78 |
+
onchange="inputToNumbers(this); payoneChangedCreditCardNumber();"
|
79 |
+
oninput="inputToNumbers(this); payoneChangedCreditCardNumber();"/>
|
80 |
+
</div>
|
81 |
+
</li>
|
82 |
+
<!-- Credit card expiration date : -->
|
83 |
+
<li>
|
84 |
+
<div class="input-box">
|
85 |
+
<label for="<?php echo $code ?>_expiration">
|
86 |
+
<?php echo $this->__('Expiration Date') ?> <span class="required">*</span>
|
87 |
+
</label><br class="clear"/>
|
88 |
+
|
89 |
+
<div class="v-fix">
|
90 |
+
<select id="<?php echo $code ?>_cc_expiration_month" name="payment[cc_exp_month]"
|
91 |
+
style="width:140px;"
|
92 |
+
class="required-entry no-submit month validate-payone-cc-validity-period ">
|
93 |
+
<?php foreach ($this->getCcMonths() as $key => $month): ?>
|
94 |
+
<option value="<?php echo $key ? $key : '' ?>"<?php if ($key == $this->getCreditCardExpireMonth()): ?>
|
95 |
+
selected="selected"<?php endif ?>><?php echo $month ?></option>
|
96 |
+
<?php endforeach ?>
|
97 |
+
</select>
|
98 |
+
</div>
|
99 |
+
<div class="v-fix" style="padding-left:5px;">
|
100 |
+
<select id="<?php echo $code ?>_cc_expiration_year" name="payment[cc_exp_year]"
|
101 |
+
style="width:103px;" class="year required-entry no-submit">
|
102 |
+
<?php foreach ($this->getCcYears() as $key => $year): ?>
|
103 |
+
<option value="<?php echo $key ? $key : '' ?>"<?php if ($key == $this->getCreditCardExpireYear()): ?>
|
104 |
+
selected="selected"<?php endif ?>><?php echo $year ?></option>
|
105 |
+
<?php endforeach ?>
|
106 |
+
</select>
|
107 |
+
</div>
|
108 |
+
</div>
|
109 |
+
</li>
|
110 |
+
<!-- Credit card cvc : -->
|
111 |
+
<li style="clear:both;">
|
112 |
+
<div class="input-box" id="<?php echo $code ?>_cc_cid_div"
|
113 |
+
style="<?php echo $displayCvc == '0' ? 'display: none; ' : '';?>">
|
114 |
+
<label for="<?php echo $code ?>_cc_cid">
|
115 |
+
<?php echo $this->__('Card Verification Number') ?> <span class="required">*</span>
|
116 |
+
</label><br class="clear"/>
|
117 |
+
<input type="text" title="<?php echo $this->__('Card Verification Number') ?>"
|
118 |
+
class="required-entry input-text no-submit" id="<?php echo $code ?>_cc_cid"
|
119 |
+
name="payment[cc_cid]" style="width:3em;"
|
120 |
+
value="<?php echo $this->getCreditCardCid();?>" autocomplete="off" maxlength="4"
|
121 |
+
onchange="inputToNumbers(this)"
|
122 |
+
oninput="inputToNumbers(this)"/>
|
123 |
+
|
124 |
+
<a href="#" class="cvv-what-is-this"><?php echo $this->__('What is this?') ?></a>
|
125 |
</div>
|
126 |
+
</li>
|
127 |
+
<li>
|
128 |
+
<input type="hidden" id="payone_pseudocardpan" name="payment[payone_pseudocardpan]" value="<?php echo $this->getPayonePseudocardpan();?>"/>
|
129 |
+
<input type="hidden" id="payone_truncatedcardpan" name="payment[cc_number_enc]" value="<?php echo $this->getCreditCardNumberEnc();?>"/>
|
130 |
+
<input type="hidden" id="<?php echo $code ?>_config_id" name="payment[payone_config_payment_method_id]"
|
131 |
+
value="<?php echo $this->getPayoneConfigPaymentMethodId();?>"/>
|
132 |
+
<input type="hidden" id="<?php echo $code ?>_config" name="payment[payone_config]"
|
133 |
+
value="<?php echo $this->escapeHtml($this->getClientApiConfigAsJson()); ?>" class=""/>
|
134 |
+
<input type="hidden" id="<?php echo $code ?>_config_cvc" name="payment[payone_config_cvc]"
|
135 |
+
value="<?php echo $this->escapeHtml($this->getCvcJson()); ?>" class=""/>
|
136 |
+
<input type="hidden" id="payone_cc_check_validation" value="<?php echo $this->getPayoneCreditCardCheckValidation();?>"/>
|
137 |
+
|
138 |
+
</li>
|
139 |
+
</ul>
|
140 |
+
<?php } else { ?>
|
141 |
+
<ul id="payment_form_<?php echo $code ?>" style="display:none">
|
142 |
+
<li>
|
143 |
+
<div class="input-box">
|
144 |
+
<label for="<?php echo $code; ?>_cc_type"><?php echo $this->__('Credit Card Type'); ?>
|
145 |
+
<span class="required">*</span>
|
146 |
+
</label><br class="clear"/>
|
147 |
+
<select id="<?php echo $code ?>_cc_type_select" name="<?php echo $code ?>_cc_type_select"
|
148 |
+
class="no-submit required-entry">
|
149 |
+
<?php
|
150 |
+
foreach ($this->getTypes() as $key => $type) :
|
151 |
+
$selected = $this->getCreditCardType() == $type['code'] ? 'selected="selected"' : '';
|
152 |
+
if ($displayCvc === null) {
|
153 |
+
$displayCvc = $type['check_cvc'];
|
154 |
+
}
|
155 |
+
?>
|
156 |
+
<option value="<?php echo $key ?>" <?php echo $selected; ?>>
|
157 |
+
<?php echo $type['name'] ?><span><?php echo $type['fee']; ?></span>
|
158 |
+
</option>
|
159 |
+
<?php endforeach; ?>
|
160 |
</select>
|
161 |
+
<input type="hidden" id="<?php echo $code ?>_cc_type" name="payment[cc_type]" value="<?php echo $this->getCreditCardType();?>" class=""/>
|
162 |
+
</div>
|
163 |
+
</li>
|
164 |
+
<li>
|
165 |
+
<div class="input-box">
|
166 |
+
<label for="cardpanInput"><?php echo $this->__('Credit Card Number'); ?> <span class="required">*</span></label>
|
167 |
+
<br class="clear"/>
|
168 |
+
<span class="inputIframe" id="cardpan"></span>
|
169 |
+
</div>
|
170 |
+
</li>
|
171 |
+
<li>
|
172 |
+
<div class="input-box">
|
173 |
+
<label for="cvcInput"><?php echo $this->__('Card Verification Number') ?> <span class="required">*</span></label><br class="clear"/>
|
174 |
+
<span id="cardcvc2" class="inputIframe"></span>
|
175 |
+
<a href="#" class="cvv-what-is-this"><?php echo $this->__('What is this?') ?></a>
|
176 |
+
</div>
|
177 |
+
</li>
|
178 |
+
<li>
|
179 |
+
<div class="input-box">
|
180 |
+
<label for="expireInput"><?php echo $this->__('Expiration Date') ?> <span class="required">*</span></label>
|
181 |
+
<br class="clear"/>
|
182 |
+
<span id="expireInput" class="inputIframe">
|
183 |
+
<div class="v-fix"><span id="cardexpiremonth"></span></div>
|
184 |
+
<div class="v-fix" style="padding-left:5px;"><span id="cardexpireyear"></span></div>
|
185 |
+
</span>
|
186 |
+
</div>
|
187 |
+
</li>
|
188 |
+
<li>
|
189 |
+
<div class="input-box">
|
190 |
+
<label for="firstname"><?php echo $this->__('Firstname') ?><span class="required">*</span></label>
|
191 |
+
<br class="clear"/>
|
192 |
+
<input id="firstname" type="text" name="firstname" value="">
|
193 |
+
</div>
|
194 |
+
</li>
|
195 |
+
<li>
|
196 |
+
<div class="input-box">
|
197 |
+
<label for="lastname"><?php echo $this->__('Lastname') ?><span class="required">*</span></label>
|
198 |
+
<br class="clear"/>
|
199 |
+
<input id="lastname" type="text" name="lastname" value="">
|
200 |
</div>
|
201 |
+
</li>
|
202 |
+
<li>
|
203 |
+
<div id="errorOutput"></div>
|
204 |
+
<input type="hidden" id="<?php echo $code; ?>_cc_number" value=""/>
|
205 |
+
<input type="hidden" id="<?php echo $code ?>_cc_owner" name="payment[cc_owner]" value="" />
|
206 |
+
<input type="hidden" id="payone_pseudocardpan" name="payment[payone_pseudocardpan]" value="<?php echo $this->getPayonePseudocardpan();?>"/>
|
207 |
+
<input type="hidden" id="payone_truncatedcardpan" name="payment[cc_number_enc]" value="<?php echo $this->getCreditCardNumberEnc();?>"/>
|
208 |
+
<input type="hidden" id="<?php echo $code ?>_config_id" name="payment[payone_config_payment_method_id]"
|
209 |
+
value="<?php echo $this->getPayoneConfigPaymentMethodId();?>"/>
|
210 |
+
<input type="hidden" id="<?php echo $code ?>_config" name="payment[payone_config]"
|
211 |
+
value="<?php echo $this->escapeHtml($this->getHostedClientApiConfigAsJson()); ?>" class=""/>
|
212 |
+
<input type="hidden" id="<?php echo $code ?>_config_cvc" name="payment[payone_config_cvc]"
|
213 |
+
value="<?php echo $this->escapeHtml($this->getCvcJson()); ?>" class=""/>
|
214 |
+
<input type="hidden" id="payone_cc_check_validation" value="<?php echo $this->getPayoneCreditCardCheckValidation();?>"/>
|
215 |
+
</li>
|
216 |
+
</ul>
|
217 |
+
<script>
|
218 |
+
var request, fieldconfig;
|
219 |
+
fieldconfig = {
|
220 |
+
fields: {
|
221 |
+
cardpan: {
|
222 |
+
selector: "cardpan", // put name of your div-container here
|
223 |
+
type: "<?php echo $this->getHostedParam('Number_type'); ?>", // text (default), password, tel
|
224 |
+
size: "<?php echo $this->getHostedParam('Number_count'); ?>",
|
225 |
+
maxlength: "<?php echo $this->getHostedParam('Number_max'); ?>",
|
226 |
+
<?php if($this->getHostedParam('Number_style') == "custom") { ?>
|
227 |
+
style: "<?php echo $this->getHostedParam('Number_css'); ?>",
|
228 |
+
<?php } ?>
|
229 |
+
<?php if($this->getHostedParam('Number_iframe') == "custom") { ?>
|
230 |
+
iframe: {
|
231 |
+
width: "<?php echo $this->getHostedParam('Number_width'); ?>",
|
232 |
+
height: "<?php echo $this->getHostedParam('Number_height'); ?>"
|
233 |
+
}
|
234 |
+
<?php } ?>
|
235 |
+
},
|
236 |
+
cardcvc2: {
|
237 |
+
selector: "cardcvc2", // put name of your div-container here
|
238 |
+
type: "<?php echo $this->getHostedParam('CVC_type'); ?>", // text (default), password, tel
|
239 |
+
size: "<?php echo $this->getHostedParam('CVC_count'); ?>",
|
240 |
+
maxlength: "<?php echo $this->getHostedParam('CVC_max'); ?>",
|
241 |
+
<?php if($this->getHostedParam('CVC_style') == "custom") { ?>
|
242 |
+
style: "<?php echo $this->getHostedParam('CVC_css'); ?>",
|
243 |
+
<?php } ?>
|
244 |
+
<?php if($this->getHostedParam('CVC_iframe') == "custom") { ?>
|
245 |
+
iframe: {
|
246 |
+
width: "<?php echo $this->getHostedParam('CVC_width'); ?>",
|
247 |
+
height: "<?php echo $this->getHostedParam('CVC_height'); ?>"
|
248 |
+
}
|
249 |
+
<?php } ?>
|
250 |
+
},
|
251 |
+
cardexpiremonth: {
|
252 |
+
selector: "cardexpiremonth", // put name of your div-container here
|
253 |
+
type: "<?php echo $this->getHostedParam('Month_type'); ?>",
|
254 |
+
size: "<?php echo $this->getHostedParam('Month_count'); ?>",
|
255 |
+
maxlength: "<?php echo $this->getHostedParam('Month_max'); ?>",
|
256 |
+
<?php if($this->getHostedParam('Month_style') == "custom") { ?>
|
257 |
+
style: "<?php echo $this->getHostedParam('Month_css'); ?>",
|
258 |
+
<?php } ?>
|
259 |
+
<?php if($this->getHostedParam('Month_iframe') == "custom") { ?>
|
260 |
+
iframe: {
|
261 |
+
width: "<?php echo $this->getHostedParam('Month_width'); ?>",
|
262 |
+
height: "<?php echo $this->getHostedParam('Month_height'); ?>"
|
263 |
+
}
|
264 |
+
<?php } ?>
|
265 |
+
},
|
266 |
+
cardexpireyear: {
|
267 |
+
selector: "cardexpireyear", // put name of your div-container here
|
268 |
+
type: "<?php echo $this->getHostedParam('Year_type'); ?>",
|
269 |
+
size: "<?php echo $this->getHostedParam('Year_count'); ?>",
|
270 |
+
maxlength: "<?php echo $this->getHostedParam('Year_max'); ?>",
|
271 |
+
<?php if($this->getHostedParam('Year_style') == "custom") { ?>
|
272 |
+
style: "<?php echo $this->getHostedParam('Year_css'); ?>",
|
273 |
+
<?php } ?>
|
274 |
+
<?php if($this->getHostedParam('Year_iframe') == "custom") { ?>
|
275 |
+
iframe: {
|
276 |
+
width: "<?php echo $this->getHostedParam('Year_width'); ?>",
|
277 |
+
height: "<?php echo $this->getHostedParam('Year_height'); ?>"
|
278 |
+
}
|
279 |
+
<?php } ?>
|
280 |
+
}
|
281 |
+
},
|
282 |
+
defaultStyle: {
|
283 |
+
input: "<?php echo $this->getHostedParam('Standard_input'); ?>",
|
284 |
+
select: "<?php echo $this->getHostedParam('Standard_selection'); ?>",
|
285 |
+
iframe: {
|
286 |
+
width: "<?php echo $this->getHostedParam('Iframe_width'); ?>",
|
287 |
+
height: "<?php echo $this->getHostedParam('Iframe_height'); ?>"
|
288 |
+
}
|
289 |
+
},
|
290 |
|
291 |
+
<?php if($this->getHostedParam('Errors_active') == "true") { ?>
|
292 |
+
error: "errorOutput", // area to display error-messages (optional)
|
293 |
+
<?php if($this->getHostedParam('Errors_lang') == "de") { ?>
|
294 |
+
language: Payone.ClientApi.Language.de // Language to display error-messages
|
295 |
+
<?php } else { ?>
|
296 |
+
language: Payone.ClientApi.Language.en
|
297 |
+
<?php } ?>
|
298 |
+
<?php } ?>
|
299 |
+
};
|
300 |
+
|
301 |
+
var iframes = payone.initHosted(fieldconfig, '<?php echo $code ?>_cc_type_select');
|
302 |
+
</script>
|
303 |
+
<?php } ?>
|
304 |
</fieldset>
|
app/locale/de_DE/Payone_Core.csv
CHANGED
@@ -923,4 +923,51 @@
|
|
923 |
"There are 2 possibilities to pay with Yapital. Either you open the Yapital-app, select payment from the app-menu and scan the QR-code or you click the orange LOGIN button and log in on the next site, using your Yapital-login-data. After a successful transaction you will be redirected back to the shop.","Sie haben zwei Möglichkeiten mit Yapital zu bezahlen. Entweder öffnen Sie die Yapital-App, wählen Bezahlen aus dem App-Menü und scannen den unten aufgeführten QR-Code. Oder Sie loggen sich mit Ihren Yapital-Zugangsdaten über den orangen LOGIN Button auf dieser Seite ein. Nach erfolgreicher Transaktion gelangen Sie automatisch zurück in den Shop."
|
924 |
"Every transaction is handled in realtime with your Yapital-account. Your bankdata is not transmitted by Yapital, only the necessary transactiondata.","Alle Transaktionen werden in Echtzeit über Ihren Yapital-Account abgewickelt. Ihre Bankdaten werden nicht von Yapital weitergeleitet, sondern lediglich die erforderlichen Transaktionsdaten."
|
925 |
|
926 |
-
"Payment with creditcard","Bezahlung mit Kreditkarte"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
923 |
"There are 2 possibilities to pay with Yapital. Either you open the Yapital-app, select payment from the app-menu and scan the QR-code or you click the orange LOGIN button and log in on the next site, using your Yapital-login-data. After a successful transaction you will be redirected back to the shop.","Sie haben zwei Möglichkeiten mit Yapital zu bezahlen. Entweder öffnen Sie die Yapital-App, wählen Bezahlen aus dem App-Menü und scannen den unten aufgeführten QR-Code. Oder Sie loggen sich mit Ihren Yapital-Zugangsdaten über den orangen LOGIN Button auf dieser Seite ein. Nach erfolgreicher Transaktion gelangen Sie automatisch zurück in den Shop."
|
924 |
"Every transaction is handled in realtime with your Yapital-account. Your bankdata is not transmitted by Yapital, only the necessary transactiondata.","Alle Transaktionen werden in Echtzeit über Ihren Yapital-Account abgewickelt. Ihre Bankdaten werden nicht von Yapital weitergeleitet, sondern lediglich die erforderlichen Transaktionsdaten."
|
925 |
|
926 |
+
"Payment with creditcard","Bezahlung mit Kreditkarte"
|
927 |
+
|
928 |
+
"Request-type","Anfragetyp"
|
929 |
+
"Input-configuration","Feldkonfiguration"
|
930 |
+
|
931 |
+
"Custom styling hosted-Iframe","Benutzerdefinierte Anpassung hosted-Iframe"
|
932 |
+
|
933 |
+
"Field","Feld"
|
934 |
+
"Type","Typ"
|
935 |
+
"Digit-<br>count","Anzahl<br>Zeichen"
|
936 |
+
"Max-<br>digits","Zeichen<br>Max"
|
937 |
+
"Iframe","Iframe"
|
938 |
+
"Width","Breite"
|
939 |
+
"Height","Höhe"
|
940 |
+
"Style","Stil"
|
941 |
+
"CSS","CSS"
|
942 |
+
|
943 |
+
"FCPO_CC_ROW_CC_Number","Kreditkartennummer"
|
944 |
+
"FCPO_CC_ROW_CC_CVC","Kartenprüfziffer"
|
945 |
+
"FCPO_CC_ROW_CC_Month","Gültigkeitsmonat"
|
946 |
+
"FCPO_CC_ROW_CC_Year","Gültigkeitsjahr"
|
947 |
+
|
948 |
+
"Standard","Standard"
|
949 |
+
"Custom","Benutzerdefiniert"
|
950 |
+
|
951 |
+
"Select","Auswahl"
|
952 |
+
"Numeric","Numerisch"
|
953 |
+
"Password","Passwort"
|
954 |
+
"Text","Text"
|
955 |
+
|
956 |
+
"Standard-style","Standardstil"
|
957 |
+
"Input","Eingabe"
|
958 |
+
"Selection","Auswahl"
|
959 |
+
"Input-fields","Felder"
|
960 |
+
"Error-output","Fehlerausgabe"
|
961 |
+
"Active","Aktiv"
|
962 |
+
"Language","Language"
|
963 |
+
"German","Deutsch"
|
964 |
+
"English","Englisch"
|
965 |
+
"Preview","Vorschau"
|
966 |
+
"You need to save before the changes are visible in the preview!","Änderungen sind in der Vorschau erst nach dem Speichern sichtbar!"
|
967 |
+
"Number:","Nummer:"
|
968 |
+
"CVV2 or CVC2 security code:","Prüfziffer:"
|
969 |
+
"Valid until:","Gültig bis:"
|
970 |
+
"Card Verification Number","Prüfziffer:"
|
971 |
+
"Firstname","Vorname"
|
972 |
+
"Lastname","Nachname"
|
973 |
+
"What is this?","Was ist das?"
|
app/locale/en_US/Payone_Core.csv
CHANGED
@@ -21,4 +21,9 @@
|
|
21 |
"CFR","Commerz Finanz"
|
22 |
"BSV","BillSAFE"
|
23 |
"KLV","Klarna"
|
24 |
-
"KLS","Klarna"
|
|
|
|
|
|
|
|
|
|
21 |
"CFR","Commerz Finanz"
|
22 |
"BSV","BillSAFE"
|
23 |
"KLV","Klarna"
|
24 |
+
"KLS","Klarna"
|
25 |
+
|
26 |
+
"FCPO_CC_ROW_CC_Number","Creditcardnumber"
|
27 |
+
"FCPO_CC_ROW_CC_CVC","CVC security code"
|
28 |
+
"FCPO_CC_ROW_CC_Month","Validity-month"
|
29 |
+
"FCPO_CC_ROW_CC_Year","Validity-year"
|
js/payone/core/creditcard.js
CHANGED
@@ -31,6 +31,7 @@ PAYONE.Service.CreditCardCheck = function (handler, form, config) {
|
|
31 |
this.form = form;
|
32 |
this.config = config;
|
33 |
this.origMethod = '';
|
|
|
34 |
|
35 |
/**
|
36 |
* Enhances payment.save and runs Validate and CreditCardCheck for CreditCards
|
@@ -44,13 +45,47 @@ PAYONE.Service.CreditCardCheck = function (handler, form, config) {
|
|
44 |
this.handler.origMethod = origMethod;
|
45 |
// Payone credit card payment method is available, and selected, initiate credit card check:
|
46 |
if (this.validate(this.form)) {
|
47 |
-
this.
|
|
|
|
|
|
|
|
|
48 |
}
|
49 |
}
|
50 |
else {
|
51 |
origMethod();
|
52 |
}
|
53 |
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
54 |
|
55 |
/**
|
56 |
* Trigger CVC Code as configured
|
@@ -84,6 +119,7 @@ PAYONE.Service.CreditCardCheck = function (handler, form, config) {
|
|
84 |
var ccTypeConfigKey = elementCcType.value;
|
85 |
var ccTypeSplit = ccTypeConfigKey.split('_');
|
86 |
var configId = ccTypeSplit[0];
|
|
|
87 |
var ccType = ccTypeSplit[1];
|
88 |
$("payone_creditcard_config_id").setValue(configId);
|
89 |
$("payone_creditcard_cc_type").setValue(ccType);
|
@@ -114,6 +150,15 @@ PAYONE.Service.CreditCardCheck = function (handler, form, config) {
|
|
114 |
);
|
115 |
payoneGateway.call(data);
|
116 |
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
117 |
|
118 |
/**
|
119 |
* Collect PAYONE CreditCardCheck Request Parameters
|
@@ -373,3 +418,7 @@ function payoneChangedCreditCardNumber() {
|
|
373 |
$('payone_cc_check_validation').value = 1;
|
374 |
$('payone_creditcard_cc_number').addClassName('validate-cc-number');
|
375 |
}
|
|
|
|
|
|
|
|
31 |
this.form = form;
|
32 |
this.config = config;
|
33 |
this.origMethod = '';
|
34 |
+
this.iframes = false;
|
35 |
|
36 |
/**
|
37 |
* Enhances payment.save and runs Validate and CreditCardCheck for CreditCards
|
45 |
this.handler.origMethod = origMethod;
|
46 |
// Payone credit card payment method is available, and selected, initiate credit card check:
|
47 |
if (this.validate(this.form)) {
|
48 |
+
if(this.iframes == false) {
|
49 |
+
this.creditcardcheck();
|
50 |
+
} else {
|
51 |
+
this.creditcardcheckHosted();
|
52 |
+
}
|
53 |
}
|
54 |
}
|
55 |
else {
|
56 |
origMethod();
|
57 |
}
|
58 |
};
|
59 |
+
|
60 |
+
this.initHosted = function(fieldconfig, type_id) {
|
61 |
+
var configId = false;
|
62 |
+
var elementCcType = $('payone_creditcard_cc_type_select');
|
63 |
+
if (elementCcType != undefined) {
|
64 |
+
var ccTypeConfigKey = elementCcType.value;
|
65 |
+
var ccTypeSplit = ccTypeConfigKey.split('_');
|
66 |
+
configId = ccTypeSplit[0];
|
67 |
+
var ccType = ccTypeSplit[1];
|
68 |
+
$("payone_creditcard_cc_type").setValue(ccType);
|
69 |
+
}
|
70 |
+
|
71 |
+
aConfig = this.getConfig();
|
72 |
+
request = aConfig.gateway[configId];
|
73 |
+
|
74 |
+
var iframes = new Payone.ClientApi.HostedIFrames(fieldconfig, request);
|
75 |
+
iframes.setCardType(ccType);
|
76 |
+
|
77 |
+
document.getElementById(type_id).onchange = function () {
|
78 |
+
var elementCcType = $('payone_creditcard_cc_type_select');
|
79 |
+
if (elementCcType != undefined) {
|
80 |
+
var ccTypeConfigKey = elementCcType.value;
|
81 |
+
var ccTypeSplit = ccTypeConfigKey.split('_');
|
82 |
+
var ccType = ccTypeSplit[1];
|
83 |
+
iframes.setCardType(ccType); // on change: set new type of credit card to process
|
84 |
+
}
|
85 |
+
};
|
86 |
+
this.iframes = iframes;
|
87 |
+
return iframes;
|
88 |
+
}
|
89 |
|
90 |
/**
|
91 |
* Trigger CVC Code as configured
|
119 |
var ccTypeConfigKey = elementCcType.value;
|
120 |
var ccTypeSplit = ccTypeConfigKey.split('_');
|
121 |
var configId = ccTypeSplit[0];
|
122 |
+
|
123 |
var ccType = ccTypeSplit[1];
|
124 |
$("payone_creditcard_config_id").setValue(configId);
|
125 |
$("payone_creditcard_cc_type").setValue(ccType);
|
150 |
);
|
151 |
payoneGateway.call(data);
|
152 |
};
|
153 |
+
|
154 |
+
this.creditcardcheckHosted = function() {
|
155 |
+
if (this.iframes.isComplete()) {
|
156 |
+
$('payone_creditcard_cc_owner').value = $('firstname').value + ' ' + $('lastname').value;
|
157 |
+
this.iframes.creditCardCheck('processPayoneResponseCCHosted');
|
158 |
+
} else {
|
159 |
+
console.debug("not complete");
|
160 |
+
}
|
161 |
+
}
|
162 |
|
163 |
/**
|
164 |
* Collect PAYONE CreditCardCheck Request Parameters
|
418 |
$('payone_cc_check_validation').value = 1;
|
419 |
$('payone_creditcard_cc_number').addClassName('validate-cc-number');
|
420 |
}
|
421 |
+
|
422 |
+
function processPayoneResponseCCHosted(response) {
|
423 |
+
payone.handleResponseCreditcardCheck(response);
|
424 |
+
}
|
package.xml
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>Mage_Payone</name>
|
4 |
-
<version>3.3.
|
5 |
<stability>stable</stability>
|
6 |
<license>Open Software License (OSL)</license>
|
7 |
<channel>community</channel>
|
@@ -30,11 +30,11 @@
|
|
30 |
With FinanceGate Business even account receivable management, dunning and debt collection can be done by FinanceGate automatically.
|
31 |

|
32 |
Notice: Remember this extension is still beta. We recommend to test all transaction types in your application carefully before going live.</description>
|
33 |
-
<notes>Mage_Payone-3.3.
|
34 |
<authors><author><name>PAYONE</name><user>jgerle</user><email>tech.support@payone.de</email></author></authors>
|
35 |
-
<date>2015-
|
36 |
-
<time>
|
37 |
-
<contents><target name="mage"><dir name="lib"><dir name="Payone"><dir name="Api"><dir name="Adapter"><dir name="Http"><file name="Abstract.php" hash="50e5a129e9c406c82745288d35c869ee"/><file name="Curl.php" hash="09107f0d1fe82d4d3c58b73fd61c2481"/><file name="Socket.php" hash="76ff8d8ff010537d56f266acc47c7092"/></dir><file name="Interface.php" hash="12e6dcf75c76cf5a44fe92ea3f92dc8f"/></dir><file name="Config.php" hash="004c459ae31c87ba73419148bb236f09"/><dir name="Enum"><file name="AccessAction.php" hash="06f335b4a7915b38a39f65c15fb67852"/><file name="AddressCheckDivergence.php" hash="53c7accd75e2eb0c7f3a59e7c1d5c246"/><file name="AddressCheckPersonstatus.php" hash="834734b30c3f1979e84b487b44d20aef"/><file name="AddressCheckScore.php" hash="689d5042f08872c2e0f9cc7c839dd9e8"/><file name="AddressCheckSecstatus.php" hash="8fcf203cfb088a618ddf1436acfcd467"/><file name="AddressCheckType.php" hash="22c992dfd61bcbc66348b4d6f15c2101"/><file name="AvsResult.php" hash="b0386b93d4897ff9c425a64bc8440511"/><file name="BankaccountCheckType.php" hash="9e7bdb92cc66475ce71eb7cd4bfac903"/><file name="CaptureMode.php" hash="8063239d52293c4d681c0574e1d1ba18"/><file name="ConsumerscoreScore.php" hash="0698bad35ff8d2c777148038e6b881da"/><file name="ConsumerscoreType.php" hash="089cea7e978c2eaeb316726a78da1483"/><file name="CreditcardType.php" hash="e68edc3d4b9f5506239a037e0bc38473"/><file name="DebitTransactionType.php" hash="1aedd895d59618a5f1385001fd7291f4"/><file name="Ecommercemode.php" hash="7180d9c7c4b535d2b19e95ac740b9c60"/><file name="FileFormat.php" hash="23f747ea956c096bbbed4e7461e7fd2c"/><file name="FileType.php" hash="df5f5bb76244c8a81a59f8f4201b9986"/><file name="FinancingType.php" hash="7f18d69f522984f5bcd5ec169c346f09"/><file name="Gender.php" hash="d58bbf2a4019ec8c3b375f50ea2b3ffc"/><file name="GenericpaymentAction.php" hash="a784ca76d4a4a38f680530f565319902"/><file name="InvoiceDeliverymode.php" hash="b449ae8492973f1735746571fdc62153"/><file name="InvoicingItemType.php" hash="898ead3cd513b0156cda33035f5cefc2"/><file name="OnlinebanktransferType.php" hash="fc5b1a811e948aa75f27c3181f27a07f"/><file name="PayoutOpenBalance.php" hash="d263156eafb88ed7e74556b1b1924e94"/><file name="PeriodUnit.php" hash="08673a4c85ade8967011b05d34eef33b"/><file name="PeriodUnitRecurring.php" hash="3a665fa2bd8b15f0b2fc455dd2b58d7c"/><file name="RequestType.php" hash="0f46029990e12dee9e6a29e70eb4881b"/><file name="ResponseType.php" hash="092e28de767b844d119975e55c65d2b4"/><file name="Settleaccount.php" hash="a6a4c23be40837c9eec24f5342f69f80"/><file name="Shippingprovider.php" hash="cc47d7bb11f9633cb06ace20c1d3defc"/><file name="Storecarddata.php" hash="f5b8c68a66d61b788e4c068671858ff4"/><file name="UseCustomerdata.php" hash="1c6a5dd06e4447cb1f22cb819e9ebc5f"/><file name="WalletType.php" hash="64fa28a5d60a133d736d671b0d4f4100"/></dir><dir name="Exception"><file name="Abstract.php" hash="09266153140106c4177f1ec616e82b75"/><file name="InvalidParameters.php" hash="a7d9a56d5f1f1492e39f7bf128abd845"/><file name="InvalidResponse.php" hash="216f9e035f04fc0340f3960c92d2b209"/><file name="InvalidUrl.php" hash="61c4c388a90361e1de18d8b68fb914e7"/><file name="MappingNotFound.php" hash="e465bf155d207e86b420e20963113c97"/><file name="Payone.php" hash="63e447068676c3f62578f1392558e506"/><dir name="Request"><file name="InvalidKey.php" hash="45f6aea3a604026ea53732805c97998c"/><file name="InvalidMid.php" hash="8a215505065c1ad96d5ab24ce7bdb2c0"/><file name="InvalidMode.php" hash="97fd778214be1297e5a2639ac03edb17"/><file name="InvalidPortalid.php" hash="1346da51642cd24c3c8c49094a3760be"/></dir><file name="Timeout.php" hash="112670215f70139a4ab30a3a9d459fe3"/><file name="UnknownStatus.php" hash="767e935b0bca23c581db594cb71dcb88"/><file name="WritingRequestToServer.php" hash="16437699dd39c2307aca6aec944c3cb3"/></dir><file name="Factory.php" hash="d5b3aab8ad2f77303213e7d5e3a4b8a2"/><dir name="Mapper"><file name="Abstract.php" hash="cca8cbf754f938d0680c34d8dfb62581"/><dir name="Currency"><file name="Interface.php" hash="bf48bcda959ddea8ee3e32952e60949c"/></dir><file name="Currency.php" hash="d12f01a77c738e4f9807b5e75f5b3e1c"/><dir name="Request"><file name="Abstract.php" hash="b4161ceec23a7151d2bbc3c0fc95e71f"/><file name="Interface.php" hash="dfb550ad191f80669ccdeef763c7b59a"/><dir name="Management"><file name="UpdateAccess.php" hash="1c0454de087a657611578625cd4cbaba"/></dir><dir name="Payment"><file name="Abstract.php" hash="b3b1e2756395d8e08bed10cbcc9eab7e"/><file name="Authorization.php" hash="4314798721f70470e2c38a540c7146a8"/><file name="Capture.php" hash="dd8813205e0c3c512e589300a9e8a986"/><file name="CreateAccess.php" hash="2a8ff9db0d6a575eed3dde00a92c69c4"/><file name="Debit.php" hash="8cc7c0cea1d57afe566d1e0fe43ce46e"/><file name="Genericpayment.php" hash="b27ef61d7a7e784636a602a54140b0d0"/><file name="Preauthorization.php" hash="34b624ec8b2a2dac64febb900908ca05"/><file name="Refund.php" hash="7150d816db33148714233b83422c8162"/><file name="Vauthorization.php" hash="e7b128a72020208335864d76d675a902"/></dir></dir><dir name="Response"><file name="3dsCheck.php" hash="045096f3cb31429dc4d722ce2e519d9e"/><file name="Abstract.php" hash="c4a9c2972e67bc7d15e886eebb1ce5d6"/><file name="AddressCheck.php" hash="084b59a4216344eb13a5f3b21eb59f14"/><file name="Authorization.php" hash="9d19b05a3bdecd83cee8ea5a839f9453"/><file name="BankAccountCheck.php" hash="21b75a9386768830bfb230b06ada37b6"/><file name="Capture.php" hash="74df2833fecd483c81ebcfbc565a7533"/><file name="Consumerscore.php" hash="bb77021437781ae4c53af7b765226377"/><file name="CreateAccess.php" hash="1f55381b4c373debd047118728b590c9"/><file name="CreditCardCheck.php" hash="13b068754c45682ba531e606bd913fa2"/><file name="Debit.php" hash="c90741eaca2368f606b2563ac62883aa"/><file name="Genericpayment.php" hash="afa63b219ef83c9f9af6a58937dab5c6"/><file name="GetFile.php" hash="0656a7a3bbaf8731b603e933232c0eff"/><file name="GetInvoice.php" hash="f8f054ec2ac431b8b23ff35d812dddc0"/><file name="Interface.php" hash="3c036e02bb08de61eb26310138f738ae"/><file name="ManageMandate.php" hash="114676edb47ac6a20ca83be0c645ee4f"/><file name="Preauthorization.php" hash="7107262bb6ddd490d895be0a0db575a0"/><file name="Refund.php" hash="1b0f61f792c2e1afc6894d61793ab686"/><file name="UpdateAccess.php" hash="d37f044a3b21d10df368b9ec232897ad"/><file name="Vauthorization.php" hash="677a7fa3d73cd834fae60d2a9028af4c"/></dir><file name="currency.properties" hash="eef9fbec34f4f4a2602f6081fcfda371"/></dir><dir name="Persistence"><file name="Interface.php" hash="783670fa2ec0bb82977f1b4548d8d77b"/></dir><dir name="Request"><file name="3dsCheck.php" hash="94bba3316832ca7c88260eef39cfbb4c"/><file name="Abstract.php" hash="7cd7560fbab89bcbdd6334c4bc2e4766"/><file name="AddressCheck.php" hash="10740f6cdaffc9f78ed8bbae8fb6de63"/><dir name="Authorization"><file name="Abstract.php" hash="01f2911fc1978c4918c2fb44a4e5a3f4"/></dir><file name="Authorization.php" hash="5d3316d77bceedb62004632d16198b4a"/><file name="BankAccountCheck.php" hash="40ccd3f30fd53a31df0383185d060dd5"/><file name="Capture.php" hash="b33a01d76f1ed59cdfa40a0dcc024d53"/><file name="Consumerscore.php" hash="8dba5007ea234d999cbd8b0d02b154ce"/><file name="CreateAccess.php" hash="0fd67979ab701b54d568bcf5b39aef4e"/><file name="CreditCardCheck.php" hash="c6f35c53ef0e26796205abf2c6e81723"/><file name="Debit.php" hash="ce7deb0382877001222f4410be14a309"/><file name="Genericpayment.php" hash="aaa045479467cfee8ef681c87ba28462"/><file name="GetFile.php" hash="95f3f6b3cfaaf4cd83211dc90617f55b"/><file name="GetInvoice.php" hash="f83b623168d6fae921199b9859bb43ae"/><file name="Interface.php" hash="558d7665a4c3404e6d89ad13a122367a"/><file name="ManageMandate.php" hash="80b16691ad7360253ed1ccd264704ae0"/><dir name="Parameter"><file name="Abstract.php" hash="b193968a62a9eef3dfac086a891e85d1"/><dir name="Authorization"><file name="3dsecure.php" hash="c81ad086656fb07f173cb1c7006effcc"/><file name="Abstract.php" hash="8225edba0ff5e6a062361359f0b35a79"/><file name="Business.php" hash="becef5a6e46a7126eb4b07d3d4e2dabd"/><file name="DeliveryData.php" hash="62f5e16900673f02c7c86a6fe2d31da1"/><dir name="PaymentMethod"><file name="Abstract.php" hash="9a237eff832a99a6990b036a780e88ec"/><file name="Barzahlen.php" hash="fd8efe2cfc16a24948e7b0f164c7f1c0"/><file name="CashOnDelivery.php" hash="2e89d3baf895baef3b512acc36ea9831"/><file name="CreditCard.php" hash="c871f5e2c00492e2232bccdd0c60c4e7"/><file name="CreditCardIframe.php" hash="079c36332a2f43e6678e86bc5ab18302"/><file name="DebitPayment.php" hash="6c5bd3473b6edc5fc923bbb7718fc293"/><file name="Financing.php" hash="9bf3eabd7ff2e91b07905188ebec82e8"/><file name="OnlineBankTransfer.php" hash="f556ef8b1fa09eb5c216eb79fdbf9a9c"/><file name="Wallet.php" hash="3ff0949925f424d1737e27b9ea |