Version Notes
* fix OneStepCheckout bug
* log search using the global record search
* 1.8 compatibility
* make input id's and names in the payment templates unique
Download this release
Release Info
| Developer | PayIntelligent |
| Extension | Paymill_Paymill |
| Version | 3.3.0 |
| Comparing to | |
| See all releases | |
Code changes from version 3.2.0 to 3.3.0
- app/code/community/Paymill/Paymill/Model/Method/MethodModelAbstract.php +13 -3
- app/code/community/Paymill/Paymill/etc/config.xml +1 -1
- app/code/community/Paymill/Paymill/etc/system.xml +3 -3
- app/code/community/Paymill/Paymill/sql/paymill_setup/mysql4-install-3.0.0.php +7 -0
- app/design/adminhtml/base/default/template/paymill/log/view.phtml +31 -0
- app/design/adminhtml/base/default/template/paymill/payment/info/creditcard.phtml +14 -0
- app/design/adminhtml/base/default/template/paymill/payment/info/directdebit.phtml +14 -0
- app/design/frontend/base/default/layout/paymill.xml +30 -2
- app/design/frontend/base/default/template/paymill/payment/form/creditcard.phtml +69 -0
- app/design/frontend/base/default/template/paymill/payment/form/directdebit.phtml +49 -0
- app/design/frontend/base/default/template/paymill/payment/info/creditcard.phtml +6 -0
- app/design/frontend/base/default/template/paymill/payment/info/directdebit.phtml +6 -0
- app/etc/modules/Paymill_Paymill.xml +16 -0
- app/locale/en_US/Paymill_Paymill.csv +0 -56
- app/locale/es_ES/Paymill_Paymill.csv +0 -56
- js/paymill/paymentForm.js +30 -25
- package.xml +8 -8
app/code/community/Paymill/Paymill/Model/Method/MethodModelAbstract.php
CHANGED
|
@@ -154,10 +154,10 @@ abstract class Paymill_Paymill_Model_Method_MethodModelAbstract extends Mage_Pay
|
|
| 154 |
public function assignData($data)
|
| 155 |
{
|
| 156 |
$post = $data->getData();
|
| 157 |
-
if (array_key_exists('paymill-payment-token', $post)
|
| 158 |
-
&& !empty($post['paymill-payment-token'])) {
|
| 159 |
//Save Data into session
|
| 160 |
-
Mage::getSingleton('core/session')->setToken($post['paymill-payment-token']);
|
| 161 |
Mage::getSingleton('core/session')->setPaymentCode($this->getCode());
|
| 162 |
} else {
|
| 163 |
if (Mage::helper('paymill/fastCheckoutHelper')->hasData($this->_code)) {
|
|
@@ -253,5 +253,15 @@ abstract class Paymill_Paymill_Model_Method_MethodModelAbstract extends Mage_Pay
|
|
| 253 |
|
| 254 |
return false;
|
| 255 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 256 |
|
| 257 |
}
|
| 154 |
public function assignData($data)
|
| 155 |
{
|
| 156 |
$post = $data->getData();
|
| 157 |
+
if (array_key_exists('paymill-payment-token-' . $this->_getShortCode(), $post)
|
| 158 |
+
&& !empty($post['paymill-payment-token-' . $this->_getShortCode()])) {
|
| 159 |
//Save Data into session
|
| 160 |
+
Mage::getSingleton('core/session')->setToken($post['paymill-payment-token-' . $this->_getShortCode()]);
|
| 161 |
Mage::getSingleton('core/session')->setPaymentCode($this->getCode());
|
| 162 |
} else {
|
| 163 |
if (Mage::helper('paymill/fastCheckoutHelper')->hasData($this->_code)) {
|
| 253 |
|
| 254 |
return false;
|
| 255 |
}
|
| 256 |
+
|
| 257 |
+
protected function _getShortCode()
|
| 258 |
+
{
|
| 259 |
+
$methods = array(
|
| 260 |
+
'paymill_creditcard' => 'cc',
|
| 261 |
+
'paymill_directdebit' => 'elv'
|
| 262 |
+
);
|
| 263 |
+
|
| 264 |
+
return $methods[$this->_code];
|
| 265 |
+
}
|
| 266 |
|
| 267 |
}
|
app/code/community/Paymill/Paymill/etc/config.xml
CHANGED
|
@@ -2,7 +2,7 @@
|
|
| 2 |
<config>
|
| 3 |
<modules>
|
| 4 |
<Paymill_Paymill>
|
| 5 |
-
<version>3.
|
| 6 |
</Paymill_Paymill>
|
| 7 |
</modules>
|
| 8 |
|
| 2 |
<config>
|
| 3 |
<modules>
|
| 4 |
<Paymill_Paymill>
|
| 5 |
+
<version>3.3.0</version>
|
| 6 |
</Paymill_Paymill>
|
| 7 |
</modules>
|
| 8 |
|
app/code/community/Paymill/Paymill/etc/system.xml
CHANGED
|
@@ -11,7 +11,7 @@
|
|
| 11 |
<sort_order>700</sort_order>
|
| 12 |
<fields>
|
| 13 |
<version>
|
| 14 |
-
<label>v3.
|
| 15 |
<sort_order>1</sort_order>
|
| 16 |
<frontend_model>adminhtml/system_config_form_field_heading</frontend_model>
|
| 17 |
<frontend_type>label</frontend_type>
|
|
@@ -86,7 +86,7 @@
|
|
| 86 |
<sort_order>800</sort_order>
|
| 87 |
<fields>
|
| 88 |
<version>
|
| 89 |
-
<label>v3.
|
| 90 |
<sort_order>100</sort_order>
|
| 91 |
<frontend_model>adminhtml/system_config_form_field_heading</frontend_model>
|
| 92 |
<frontend_type>label</frontend_type>
|
|
@@ -171,7 +171,7 @@
|
|
| 171 |
<sort_order>800</sort_order>
|
| 172 |
<fields>
|
| 173 |
<version>
|
| 174 |
-
<label>v3.
|
| 175 |
<sort_order>100</sort_order>
|
| 176 |
<frontend_model>adminhtml/system_config_form_field_heading</frontend_model>
|
| 177 |
<frontend_type>label</frontend_type>
|
| 11 |
<sort_order>700</sort_order>
|
| 12 |
<fields>
|
| 13 |
<version>
|
| 14 |
+
<label>v3.3.0</label>
|
| 15 |
<sort_order>1</sort_order>
|
| 16 |
<frontend_model>adminhtml/system_config_form_field_heading</frontend_model>
|
| 17 |
<frontend_type>label</frontend_type>
|
| 86 |
<sort_order>800</sort_order>
|
| 87 |
<fields>
|
| 88 |
<version>
|
| 89 |
+
<label>v3.3.0</label>
|
| 90 |
<sort_order>100</sort_order>
|
| 91 |
<frontend_model>adminhtml/system_config_form_field_heading</frontend_model>
|
| 92 |
<frontend_type>label</frontend_type>
|
| 171 |
<sort_order>800</sort_order>
|
| 172 |
<fields>
|
| 173 |
<version>
|
| 174 |
+
<label>v3.3.0</label>
|
| 175 |
<sort_order>100</sort_order>
|
| 176 |
<frontend_model>adminhtml/system_config_form_field_heading</frontend_model>
|
| 177 |
<frontend_type>label</frontend_type>
|
app/code/community/Paymill/Paymill/sql/paymill_setup/mysql4-install-3.0.0.php
CHANGED
|
@@ -41,6 +41,13 @@ $installer->run("
|
|
| 41 |
PRIMARY KEY (`id`),
|
| 42 |
UNIQUE KEY `userId` (`user_id`)
|
| 43 |
) ENGINE = MYISAM CHARACTER SET utf8 COLLATE utf8_general_ci;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 44 |
");
|
|
|
|
| 45 |
|
| 46 |
$installer->endSetup();
|
| 41 |
PRIMARY KEY (`id`),
|
| 42 |
UNIQUE KEY `userId` (`user_id`)
|
| 43 |
) ENGINE = MYISAM CHARACTER SET utf8 COLLATE utf8_general_ci;
|
| 44 |
+
|
| 45 |
+
UPDATE sales_flat_quote_payment SET method = 'paymill_creditcard' WHERE method = 'paymillcc';
|
| 46 |
+
UPDATE sales_flat_order_payment SET method = 'paymill_creditcard' WHERE method = 'paymillcc';
|
| 47 |
+
|
| 48 |
+
UPDATE sales_flat_quote_payment SET method = 'paymill_directdebit' WHERE method = 'paymillelv';
|
| 49 |
+
UPDATE sales_flat_order_payment SET method = 'paymill_directdebit' WHERE method = 'paymillelv';
|
| 50 |
");
|
| 51 |
+
|
| 52 |
|
| 53 |
$installer->endSetup();
|
app/design/adminhtml/base/default/template/paymill/log/view.phtml
ADDED
|
@@ -0,0 +1,31 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* Magento
|
| 4 |
+
*
|
| 5 |
+
* NOTICE OF LICENSE
|
| 6 |
+
*
|
| 7 |
+
* This source file is subject to the Open Software License (OSL 3.0)
|
| 8 |
+
* that is bundled with this package in the file LICENSE.txt.
|
| 9 |
+
* It is also available through the world-wide-web at this URL:
|
| 10 |
+
* http://opensource.org/licenses/osl-3.0.php
|
| 11 |
+
* If you did not receive a copy of the license and are unable to
|
| 12 |
+
* obtain it through the world-wide-web, please send an email
|
| 13 |
+
* to license@magentocommerce.com so we can send you a copy immediately.
|
| 14 |
+
*
|
| 15 |
+
* @category PayIntelligent
|
| 16 |
+
* @package PayIntelligent_RatePAY
|
| 17 |
+
* @copyright Copyright (c) 2011 PayIntelligent GmbH (http://www.payintelligent.de)
|
| 18 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 19 |
+
*/
|
| 20 |
+
?>
|
| 21 |
+
|
| 22 |
+
<div style="border-bottom: 4px solid #DFDFDF;margin-bottom: 18px;padding-bottom: 0.25em;">
|
| 23 |
+
<h3>Developer Info</h3>
|
| 24 |
+
<pre><?php echo $this->getDevInfo(); ?></pre>
|
| 25 |
+
</div>
|
| 26 |
+
<?php if(strlen($this->getDevInfoAdditional()) > 0): ?>
|
| 27 |
+
<div style="border-bottom: 4px solid #DFDFDF;margin-bottom: 18px;padding-bottom: 0.25em;">
|
| 28 |
+
<h3>Extended Developer Info</h3>
|
| 29 |
+
<pre><?php echo $this->getDevInfoAdditional(); ?></pre>
|
| 30 |
+
</div>
|
| 31 |
+
<?php endif; ?>
|
app/design/adminhtml/base/default/template/paymill/payment/info/creditcard.phtml
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php if ($_specificInfo = $this->getSpecificInformation()): ?>
|
| 2 |
+
<table
|
| 3 |
+
<tr>
|
| 4 |
+
<td><img src="<?php echo $_specificInfo['imgUrl'] ?>" /></td>
|
| 5 |
+
</tr>
|
| 6 |
+
<tr>
|
| 7 |
+
<td><?php echo $this->htmlEscape($this->getMethod()->getTitle()) ?></td>
|
| 8 |
+
</tr>
|
| 9 |
+
<tr>
|
| 10 |
+
<td><?php echo $this->escapeHtml("Transaction Id: " . $_specificInfo['paymillTransactionId']); ?></td>
|
| 11 |
+
</tr>
|
| 12 |
+
</table>
|
| 13 |
+
<?php endif; ?>
|
| 14 |
+
<?php echo $this->getChildHtml() ?>
|
app/design/adminhtml/base/default/template/paymill/payment/info/directdebit.phtml
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php if ($_specificInfo = $this->getSpecificInformation()): ?>
|
| 2 |
+
<table
|
| 3 |
+
<tr>
|
| 4 |
+
<td><img src="<?php echo $_specificInfo['imgUrl'] ?>" /></td>
|
| 5 |
+
</tr>
|
| 6 |
+
<tr>
|
| 7 |
+
<td><?php echo $this->htmlEscape($this->getMethod()->getTitle()) ?></td>
|
| 8 |
+
</tr>
|
| 9 |
+
<tr>
|
| 10 |
+
<td><?php echo $this->escapeHtml("Transaction Id: " . $_specificInfo['paymillTransactionId']); ?></td>
|
| 11 |
+
</tr>
|
| 12 |
+
</table>
|
| 13 |
+
<?php endif; ?>
|
| 14 |
+
<?php echo $this->getChildHtml() ?>
|
app/design/frontend/base/default/layout/paymill.xml
CHANGED
|
@@ -12,10 +12,38 @@ and open the template in the editor.
|
|
| 12 |
<block type="core/text" name="google.cdn.jquery">
|
| 13 |
<action method="setText">
|
| 14 |
<text>
|
| 15 |
-
<![CDATA[
|
|
|
|
|
|
|
|
|
|
|
|
|
| 16 |
</text>
|
| 17 |
</action>
|
| 18 |
</block>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 19 |
</reference>
|
| 20 |
-
</
|
| 21 |
</layout>
|
| 12 |
<block type="core/text" name="google.cdn.jquery">
|
| 13 |
<action method="setText">
|
| 14 |
<text>
|
| 15 |
+
<![CDATA[
|
| 16 |
+
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script>
|
| 17 |
+
<script type="text/javascript" src="https://bridge.paymill.com/"></script></script>
|
| 18 |
+
<script type="text/javascript">pmQuery = jQuery.noConflict();</script>
|
| 19 |
+
]]>
|
| 20 |
</text>
|
| 21 |
</action>
|
| 22 |
</block>
|
| 23 |
+
<action method="addJs">
|
| 24 |
+
<script>paymill/paymentForm.js</script>
|
| 25 |
+
</action>
|
| 26 |
+
</reference>
|
| 27 |
+
</checkout_onepage_index>
|
| 28 |
+
<onestepcheckout_index_index>
|
| 29 |
+
<reference name="head">
|
| 30 |
+
<action method="addCss">
|
| 31 |
+
<stylesheet>css/paymill/logo.css</stylesheet>
|
| 32 |
+
</action>
|
| 33 |
+
<block type="core/text" name="google.cdn.jquery">
|
| 34 |
+
<action method="setText">
|
| 35 |
+
<text>
|
| 36 |
+
<![CDATA[
|
| 37 |
+
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script>
|
| 38 |
+
<script type="text/javascript" src="https://bridge.paymill.com/"></script></script>
|
| 39 |
+
<script type="text/javascript">pmQuery = jQuery.noConflict();</script>
|
| 40 |
+
]]>
|
| 41 |
+
</text>
|
| 42 |
+
</action>
|
| 43 |
+
</block>
|
| 44 |
+
<action method="addJs">
|
| 45 |
+
<script>paymill/paymentForm.js</script>
|
| 46 |
+
</action>
|
| 47 |
</reference>
|
| 48 |
+
</onestepcheckout_index_index>
|
| 49 |
</layout>
|
app/design/frontend/base/default/template/paymill/payment/form/creditcard.phtml
ADDED
|
@@ -0,0 +1,69 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php $_code = $this->getMethodCode() ?>
|
| 2 |
+
<ul class="form-list" id="payment_form_<?php echo $_code ?>" style="display:none;">
|
| 3 |
+
<li>
|
| 4 |
+
<label for="<?php echo $_code ?>_holdername" class="required"><em>*</em><?php echo $this->__("paymill_Holder") ?></label>
|
| 5 |
+
<div class="input-box">
|
| 6 |
+
<input value="<?php echo $this->getPaymentEntry($_code, 'card_holder'); ?>" type="text" id="<?php echo $_code ?>_holdername" class="input-text paymill-validate-cc-holder required-entry"/>
|
| 7 |
+
</div>
|
| 8 |
+
</li>
|
| 9 |
+
<li>
|
| 10 |
+
<label for="<?php echo $_code ?>_number" class="required"><em>*</em><?php echo $this->__("paymill_Number") ?></label>
|
| 11 |
+
<div class="input-box">
|
| 12 |
+
<input value="<?php echo $this->getPaymentEntry($_code, 'cc_number'); ?>" type="text" id="<?php echo $_code ?>_number" class="input-text paymill-validate-cc-number required-entry"/>
|
| 13 |
+
</div>
|
| 14 |
+
</li>
|
| 15 |
+
<li>
|
| 16 |
+
<label for="<?php echo $_code ?>_expiry_month" class="required"><em>*</em><?php echo $this->__("paymill_Date") ?></label>
|
| 17 |
+
<div class="input-box">
|
| 18 |
+
<div class="v-fix">
|
| 19 |
+
<select id="<?php echo $_code ?>_expiry_month" class="month paymill-validate-cc-expdate-month required-entry">
|
| 20 |
+
<?php foreach ($this->getPaymillCcMonths() as $k => $v): ?>
|
| 21 |
+
<option value="<?php echo $k ? $k : '' ?>"<?php if($this->isPaymentDataAvailable($_code) && $this->getPaymentEntry($_code, 'expire_month') == $k): ?> selected="selected"<?php else: ?><?php if ($k == $this->getInfoData($_code . '_expiry_month')): ?> selected="selected"<?php endif ?><?php endif ?>><?php echo $v ?></option>
|
| 22 |
+
<?php endforeach ?>
|
| 23 |
+
</select>
|
| 24 |
+
</div>
|
| 25 |
+
<div class="v-fix">
|
| 26 |
+
<select id="<?php echo $_code ?>_expiry_year" class="year paymill-validate-cc-expdate-year required-entry">
|
| 27 |
+
<?php foreach ($this->getPaymillCcYears() as $k => $v): ?>
|
| 28 |
+
<option value="<?php echo $k ? $k : '' ?>"<?php if($this->isPaymentDataAvailable($_code) && $this->getPaymentEntry($_code, 'expire_year') == $k): ?> selected="selected"<?php if ($k == $this->getInfoData($_code . '_expiry_year')): ?> selected="selected"<?php endif ?><?php endif ?>><?php echo $v ?></option>
|
| 29 |
+
<?php endforeach ?>
|
| 30 |
+
</select>
|
| 31 |
+
</div>
|
| 32 |
+
</div>
|
| 33 |
+
</li>
|
| 34 |
+
<li>
|
| 35 |
+
<label for="<?php echo $_code ?>_cvc"><?php echo $this->__("paymill_Cvc") ?></label><span class="tooltip" title="<?php echo $this->__('paymill_cvc_tooltip'); ?>">?</span>
|
| 36 |
+
<div class="input-box">
|
| 37 |
+
<input value="<?php echo $this->getPaymentEntry($_code, 'cvc'); ?>" type="text" id="<?php echo $_code ?>_cvc" class="input-text paymill-validate-cc-cvc"/>
|
| 38 |
+
</div>
|
| 39 |
+
</li>
|
| 40 |
+
<?php if (Mage::helper('paymill/optionHelper')->isShowingLabels()) : ?>
|
| 41 |
+
<li>
|
| 42 |
+
<div class='paymill_powered'>
|
| 43 |
+
<div class='paymill_credits'>
|
| 44 |
+
<?php echo $this->__("paymill_slogan"); ?><a href='http://www.paymill.de' target='_blank'>PAYMILL</a>
|
| 45 |
+
</div>
|
| 46 |
+
</div>
|
| 47 |
+
</li>
|
| 48 |
+
<?php endif; ?>
|
| 49 |
+
<li>
|
| 50 |
+
<input class="paymill-payment-token-cc" name="payment[paymill-payment-token-cc]" id="payment[paymill-payment-token-cc]" type="hidden" />
|
| 51 |
+
<input class="paymill_3ds_cancel" name="payment[paymill_3ds_cancel]" id="payment[paymill_3ds_cancel]" type="hidden" value="<?php echo $this->__("paymill_3ds_cancel") ?>"/>
|
| 52 |
+
<input class="paymill-payment-amount-cc" name="payment[paymill-payment-amount-cc]" id="payment[paymill-payment-amount-cc]" type="hidden" value="<?php echo Mage::helper('paymill/paymentHelper')->getPreAuthAmount($_code) ?>"/>
|
| 53 |
+
<input class="paymill-payment-currency-cc" name="payment[paymill-payment-currency-cc]" id="payment[paymill-payment-currency-cc]" type="hidden" value="<?php echo Mage::helper('paymill/paymentHelper')->getCurrency() ?>"/>
|
| 54 |
+
<input class="paymill-option-debug-cc" name="payment[paymill-option-debug]" id="payment[paymill-option-debug]" type="hidden" value="<?php echo Mage::helper('paymill/optionHelper')->isInDebugMode() ?>"/>
|
| 55 |
+
<input class="paymill-info-public_key-cc" name="payment[paymill-info-public_key-cc]" id="payment[paymill-info-public_key-cc]" type="hidden" value="<?php echo Mage::helper('paymill/optionHelper')->getPublicKey() ?>"/>
|
| 56 |
+
<input class="paymill-info-fastCheckout-cc" name="payment[paymill-info-fastCheckout-cc]" id="payment[paymill-info-fastCheckout-cc]" type="hidden" value="<?php echo $this->isNormalCheckout($_code) ?>"/>
|
| 57 |
+
<input class="paymill-payment-error-number" name="payment[paymill-payment-error-number]" id="payment[paymill-payment-error-number]" type="hidden" value="<?php echo $this->__("paymill_error_text_invalid_number_cc") . "<br/>\n" ?>"/>
|
| 58 |
+
<input class="paymill-payment-error-holder" name="payment[paymill-payment-error-holder]" id="payment[paymill-payment-error-holder]" type="hidden" value="<?php echo $this->__("paymill_error_text_invalid_holder_cc") . "<br/>\n" ?>"/>
|
| 59 |
+
<input class="paymill-payment-error-expdate" name="payment[paymill-payment-error-expdate]" id="payment[paymill-payment-error-expdate]" type="hidden" value="<?php echo $this->__("paymill_error_text_invalid_expdate") . "<br/>\n" ?>"/>
|
| 60 |
+
<input class="paymill-payment-error-cvc" name="payment[paymill-payment-error-cvc]" id="payment[paymill-payment-error--cvc]" type="hidden" value="<?php echo $this->__("paymill_error_text_invalid_cvc") . "<br/>\n" ?>"/>
|
| 61 |
+
</li>
|
| 62 |
+
</ul>
|
| 63 |
+
<script type="text/javascript">
|
| 64 |
+
//<![CDATA[
|
| 65 |
+
if (!eventsSetted) {
|
| 66 |
+
addPaymillEvents();
|
| 67 |
+
}
|
| 68 |
+
//]]>
|
| 69 |
+
</script>
|
app/design/frontend/base/default/template/paymill/payment/form/directdebit.phtml
ADDED
|
@@ -0,0 +1,49 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php $_code = $this->getMethodCode() ?>
|
| 2 |
+
<ul class="form-list" id="payment_form_<?php echo $_code ?>" style="display:none;">
|
| 3 |
+
<li>
|
| 4 |
+
<p class="paymill-payment-errors alert-error" style="display:none;"></p>
|
| 5 |
+
</li>
|
| 6 |
+
<li>
|
| 7 |
+
<label for="<?php echo $_code ?>_holdername" class="required"><em>*</em><?php echo $this->__("paymill_Holder") ?></label>
|
| 8 |
+
<div class="input-box">
|
| 9 |
+
<input value="<?php echo $this->getPaymentEntry($_code, 'holder'); ?>" type="text" id="<?php echo $_code ?>_holdername" class="input-text paymill-validate-dd-holdername required-entry"/>
|
| 10 |
+
</div>
|
| 11 |
+
</li>
|
| 12 |
+
<li>
|
| 13 |
+
<label for="<?php echo $_code ?>_account" class="required"><em>*</em><?php echo $this->__("paymill_account") ?></label>
|
| 14 |
+
<div class="input-box">
|
| 15 |
+
<input value="<?php echo $this->getPaymentEntry($_code, 'account'); ?>" type="text" id="<?php echo $_code ?>_account" class="input-text paymill-validate-dd-account required-entry"/>
|
| 16 |
+
</div>
|
| 17 |
+
</li>
|
| 18 |
+
<li>
|
| 19 |
+
<label for="<?php echo $_code ?>_bankcode" class="required"><em>*</em><?php echo $this->__("paymill_bankcode") ?></label>
|
| 20 |
+
<div class="input-box">
|
| 21 |
+
<input value="<?php echo $this->getPaymentEntry($_code, 'code'); ?>" type="text" id="<?php echo $_code ?>_bankcode" class="input-text paymill-validate-dd-bankcode required-entry"/>
|
| 22 |
+
</div>
|
| 23 |
+
</li>
|
| 24 |
+
<?php if (Mage::helper('paymill/optionHelper')->isShowingLabels()) : ?>
|
| 25 |
+
<li>
|
| 26 |
+
<div class='paymill_powered'><div class='paymill_credits'>
|
| 27 |
+
<?php echo $this->__("paymill_slogan_elv"); ?>
|
| 28 |
+
<a href='http://www.paymill.de' target='_blank'>PAYMILL</a>
|
| 29 |
+
</div>
|
| 30 |
+
</div>
|
| 31 |
+
</li>
|
| 32 |
+
<?php endif; ?>
|
| 33 |
+
<li>
|
| 34 |
+
<input class="paymill-payment-token-elv" name="payment[paymill-payment-token-elv]" id="payment[paymill-payment-token-elv]" type="hidden" />
|
| 35 |
+
<input class="paymill-option-debug-elv" name="payment[paymill-option-debug-elv]" id="payment[paymill-option-debug-elv]" type="hidden" value="<?php echo Mage::helper('paymill/optionHelper')->isInDebugMode() ?>" />
|
| 36 |
+
<input class="paymill-info-public_key-elv" name="payment[paymill-info-public_key-elv]" id="payment[paymill-info-public_key-elv]" type="hidden" value="<?php echo Mage::helper('paymill/optionHelper')->getPublicKey() ?>" />
|
| 37 |
+
<input class="paymill-info-fastCheckout-elv" name="payment[paymill-info-fastCheckout-elv]" id="payment[paymill-info-fastCheckout-elv]" type="hidden" value="<?php echo $this->isNormalCheckout($_code) ?>" />
|
| 38 |
+
<input class="paymill-payment-error-number-elv" name="payment[paymill-payment-error-number-elv]" id="payment[paymill-payment-error-number-elv]" type="hidden" value="<?php echo $this->__("paymill_error_text_invalid_number_elv") . "<br/>\n" ?>" />
|
| 39 |
+
<input class="paymill-payment-error-holder-elv" name="payment[paymill-payment-error-holder-elv]" id="payment[paymill-payment-error-holder-elv]" type="hidden" value="<?php echo $this->__("paymill_error_text_invalid_holder_elv") . "<br/>\n" ?>" />
|
| 40 |
+
<input class="paymill-payment-error-bankcode" name="payment[paymill-payment-error-bankcode]" id="payment[paymill-payment-error-bankcode]" type="hidden" value="<?php echo $this->__("paymill_error_text_invalid_bankcode") . "<br/>\n" ?>" />
|
| 41 |
+
</li>
|
| 42 |
+
</ul>
|
| 43 |
+
<script type="text/javascript">
|
| 44 |
+
//<![CDATA[
|
| 45 |
+
if (!eventsSetted) {
|
| 46 |
+
addPaymillEvents();
|
| 47 |
+
}
|
| 48 |
+
//]]>
|
| 49 |
+
</script>
|
app/design/frontend/base/default/template/paymill/payment/info/creditcard.phtml
ADDED
|
@@ -0,0 +1,6 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<table>
|
| 2 |
+
<tr>
|
| 3 |
+
<td><?php echo $this->htmlEscape($this->getMethod()->getTitle()) ?></td>
|
| 4 |
+
</tr>
|
| 5 |
+
</table>
|
| 6 |
+
<?php echo $this->getChildHtml() ?>
|
app/design/frontend/base/default/template/paymill/payment/info/directdebit.phtml
ADDED
|
@@ -0,0 +1,6 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<table>
|
| 2 |
+
<tr>
|
| 3 |
+
<td><?php echo $this->htmlEscape($this->getMethod()->getTitle()) ?></td>
|
| 4 |
+
</tr>
|
| 5 |
+
</table>
|
| 6 |
+
<?php echo $this->getChildHtml() ?>
|
app/etc/modules/Paymill_Paymill.xml
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0" encoding="UTF-8"?>
|
| 2 |
+
<config>
|
| 3 |
+
<modules>
|
| 4 |
+
<!-- declare CompanyName_NewModule module -->
|
| 5 |
+
<Paymill_Paymill>
|
| 6 |
+
<!-- this is an active module -->
|
| 7 |
+
<active>true</active>
|
| 8 |
+
<!-- this module will be located in app/code/local code pool -->
|
| 9 |
+
<codePool>community</codePool>
|
| 10 |
+
<!-- specify dependencies for correct module loading order -->
|
| 11 |
+
<depends>
|
| 12 |
+
<Mage_Payment />
|
| 13 |
+
</depends>
|
| 14 |
+
</Paymill_Paymill>
|
| 15 |
+
</modules>
|
| 16 |
+
</config>
|
app/locale/en_US/Paymill_Paymill.csv
DELETED
|
@@ -1,56 +0,0 @@
|
|
| 1 |
-
"paymill_credit_card","Credit Card"
|
| 2 |
-
"paymill_direct_debit","Direct Debit"
|
| 3 |
-
"paymill_creditcard","Credit Card"
|
| 4 |
-
"paymill_directdebit","Direct Debit"
|
| 5 |
-
"paymill_Basic_Setting","Paymill Basic Settings"
|
| 6 |
-
"paymill_Public_Key","Public Key"
|
| 7 |
-
"paymill_Private_Key","Private Key"
|
| 8 |
-
"paymill_Activate_Debugging","Activate Debugging"
|
| 9 |
-
"paymill_fc_active","Enable Fast Checkout"
|
| 10 |
-
"paymill_Activate_Logging","Enable Logging"
|
| 11 |
-
"paymill_Show_Label","show Paymill label during checkout"
|
| 12 |
-
"paymill_credit_card_label","Paymill Credit Card"
|
| 13 |
-
"paymill_direct_debit_label","Paymill Direct Debit"
|
| 14 |
-
"paymill_opt_Enabled","Enable"
|
| 15 |
-
"paymill_opt_Countries","Countries"
|
| 16 |
-
"paymill_opt_Sort","Sort Order"
|
| 17 |
-
"paymill_Number","Number"
|
| 18 |
-
"paymill_Cvc","CVC"
|
| 19 |
-
"paymill_Holder","Accountowner"
|
| 20 |
-
"paymill_Date","Valid until (MM/YYYY)"
|
| 21 |
-
"paymill_Amount","Amount"
|
| 22 |
-
"paymill_Currency","Currency"
|
| 23 |
-
"paymill_public_key_tooltip","Please enter your Public Key."
|
| 24 |
-
"paymill_public_key_comment","You can find your Public Key in the Paymill cockpit by clicking: MY ACCOUNT->Settings->API keys"
|
| 25 |
-
"paymill_private_key_tooltip","Please enter your Private Key."
|
| 26 |
-
"paymill_private_key_comment","You can find your Private Key in the Paymill cockpit by clicking: MY ACCOUNT->Settings->API keys"
|
| 27 |
-
"paymill_error_text_invalid_number_cc","Please enter a valid Credit Card number."
|
| 28 |
-
"paymill_error_text_invalid_number_elv","Please enter a valid Accountnumber"
|
| 29 |
-
"paymill_error_text_invalid_expdate","Invalid Expiry Date"
|
| 30 |
-
"paymill_error_text_invalid_holder_cc","Please enter a card holder."
|
| 31 |
-
"paymill_error_text_invalid_holder_elv","Please enter an account holder."
|
| 32 |
-
"paymill_error_text_invalid_bankcode","Invalid Bankcode"
|
| 33 |
-
"paymill_error_text_invalid_payment","The payment you chose could not be identified. Please contact the support"
|
| 34 |
-
"paymill_account","Accountnumber"
|
| 35 |
-
"paymill_bankcode","Bankcode"
|
| 36 |
-
"paymill_log","Paymill Log"
|
| 37 |
-
"paymill_error_text_no_entry_selected","Please select an entry"
|
| 38 |
-
"paymill_action_delete", "Delete selection"
|
| 39 |
-
"paymill_dialog_confirm", "Are you sure?"
|
| 40 |
-
"paymill_backend_log_id","ID"
|
| 41 |
-
"paymill_backend_log_entry_date","Entry date"
|
| 42 |
-
"paymill_backend_log_version","Version"
|
| 43 |
-
"paymill_backend_log_merchant_info","Merchant Information"
|
| 44 |
-
"paymill_backend_log_dev_info","Developer Information"
|
| 45 |
-
"paymill_backend_log_dev_info_additional","Additional Developer Information"
|
| 46 |
-
"paymill_checkout_generating_invoice","Invoice is beeing generated"
|
| 47 |
-
"paymill_preAuth_active","Authorize Credit Card payments during Checkout and capture manually by generating the invoice."
|
| 48 |
-
"paymill_token_tolerace","Token Tolerance Value"
|
| 49 |
-
"paymill_token_tolerace_tooltip","Sum of all additional charges used to avoid 3D secure variations"
|
| 50 |
-
"paymill_token_tolerace_comment", "Sum of all additional charges used to avoid 3D secure variations"
|
| 51 |
-
"paymill_log_action_success", "Action Successful"
|
| 52 |
-
"paymill_accepted_currency", "Accepted Currencies"
|
| 53 |
-
"paymill_slogan","Secure credit card payments powered by "
|
| 54 |
-
"paymill_slogan_elv","Direct debit payments powered by "
|
| 55 |
-
"paymill_error_text_invalid_cvc", "Invalid cvc"
|
| 56 |
-
"paymill_cvc_tooltip", "What is a CVV/CVC number? Prospective credit cards will have a 3 to 4-digit number, usually on the back of the card. It ascertains that the payment is carried out by the credit card holder and the card account is legitimate. On Visa the CVV (Card Verification Value) appears after and to the right of your card number. Same goes for Mastercard’s CVC (Card Verfication Code), which also appears after and to the right of your card number, and has 3-digits. Diners Club, Discover, and JCB credit and debit cards have a three-digit card security code which also appears after and to the right of your card number. The American Express CID (Card Identification Number) is a 4-digit number printed on the front of your card. It appears above and to the right of your card number. On Maestro the CVV appears after and to the right of your number. If you don’t have a CVV for your Maestro card you can use 000."
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
app/locale/es_ES/Paymill_Paymill.csv
DELETED
|
@@ -1,56 +0,0 @@
|
|
| 1 |
-
"paymill_credit_card","Tarjeta de crédito"
|
| 2 |
-
"paymill_direct_debit","Débito directo"
|
| 3 |
-
"paymill_creditcard","Tarjeta de crédito"
|
| 4 |
-
"paymill_directdebit","Débito directo"
|
| 5 |
-
"paymill_Basic_Setting","Paymill: Configuración básica"
|
| 6 |
-
"paymill_Public_Key","Clave pública"
|
| 7 |
-
"paymill_Private_Key","Clave privada"
|
| 8 |
-
"paymill_Activate_Debugging","Activar Depuración"
|
| 9 |
-
"paymill_fc_active","Activar Pago rápido"
|
| 10 |
-
"paymill_Activate_Logging","Activar Registro"
|
| 11 |
-
"paymill_Show_Label","Mostrar etiqueta de Paymill durante el Pago"
|
| 12 |
-
"paymill_credit_card_label","Paymill: Tarjeta de crédito"
|
| 13 |
-
"paymill_direct_debit_label","Paymill: Débito directo"
|
| 14 |
-
"paymill_opt_Enabled","Activar"
|
| 15 |
-
"paymill_opt_Countries","Países"
|
| 16 |
-
"paymill_opt_Sort","Ordenar por"
|
| 17 |
-
"paymill_Number","Número"
|
| 18 |
-
"paymill_Cvc","CVC"
|
| 19 |
-
"paymill_Holder","Nombre del titular"
|
| 20 |
-
"paymill_Date","Válida hasta (MM/YYYY)"
|
| 21 |
-
"paymill_Amount","Cantidad"
|
| 22 |
-
"paymill_Currency","Moneda"
|
| 23 |
-
"paymill_public_key_tooltip","Introduce tu clave pública"
|
| 24 |
-
"paymill_public_key_comment","Puedes encontrar tu clave pública en el sitio web de Paymill pulsando : MY ACCOUNT->Settings->API Keys"
|
| 25 |
-
"paymill_private_key_tooltip","Introduce tu clave privada."
|
| 26 |
-
"paymill_private_key_comment","Puedes encontrar tu clave pública en el sitio web de Paymill pulsando : MY ACCOUNT->Settings->API Keys"
|
| 27 |
-
"paymill_error_text_invalid_number_cc","Por favor, introduce un número de Tarjeta de Crédito válido."
|
| 28 |
-
"paymill_error_text_invalid_number_elv","Por favor, introduce un número de cuenta válido."
|
| 29 |
-
"paymill_error_text_invalid_expdate","Fecha de expiración inválida"
|
| 30 |
-
"paymill_error_text_invalid_holder_cc","Por favor, introduce el nombre del titular de la tarjeta."
|
| 31 |
-
"paymill_error_text_invalid_holder_elv","Por favor, introduce el nombre del titular de la cuenta."
|
| 32 |
-
"paymill_error_text_invalid_bankcode","Código de banco inválido."
|
| 33 |
-
"paymill_error_text_invalid_payment","No se ha podido indentificar el método de pago escogido. Por favor, contáctese con nuestro equipo de soporte al cliente."
|
| 34 |
-
"paymill_account","Número de cuenta"
|
| 35 |
-
"paymill_bankcode","Código del Banco"
|
| 36 |
-
"paymill_log","Registro de Paymill"
|
| 37 |
-
"paymill_error_text_no_entry_selected","Por favor, selecione una entrada"
|
| 38 |
-
"paymill_action_delete", "Eliminar selección"
|
| 39 |
-
"paymill_dialog_confirm", "Estás seguro?"
|
| 40 |
-
"paymill_backend_log_id","ID"
|
| 41 |
-
"paymill_backend_log_entry_date","Fecha"
|
| 42 |
-
"paymill_backend_log_version","Versión"
|
| 43 |
-
"paymill_backend_log_merchant_info","Información para el Comerciante"
|
| 44 |
-
"paymill_backend_log_dev_info","Información para los desarrolladores"
|
| 45 |
-
"paymill_backend_log_dev_info_additional","Información adicional para desarrolladores"
|
| 46 |
-
"paymill_checkout_generating_invoice","Se está generando la factura"
|
| 47 |
-
"paymill_preAuth_active","Autorizar pagos por Tarjeta de Crédito durante el pago y capturar manualmente al generar la factura."
|
| 48 |
-
"paymill_token_tolerace","Valor del Token de tolerancia"
|
| 49 |
-
"paymill_token_tolerace_tooltip","Suma de todos los cargos adicionales usados para evitar variaciones seguras en 3D"
|
| 50 |
-
"paymill_token_tolerace_comment", "Suma de todos los cargos adicionales usados para evitar variaciones seguras en 3D"
|
| 51 |
-
"paymill_log_action_success", "Acción realizada con éxito"
|
| 52 |
-
"paymill_accepted_currency", "Monedas aceptadas"
|
| 53 |
-
"paymill_slogan","Pago seguro con Tarjeta de crédito por "
|
| 54 |
-
"paymill_slogan_elv","Pagos con Débito directo por "
|
| 55 |
-
"paymill_error_text_invalid_cvc", "cvc incorrecto"
|
| 56 |
-
"paymill_cvc_tooltip", "What is a CVV/CVC number? Prospective credit cards will have a 3 to 4-digit number, usually on the back of the card. It ascertains that the payment is carried out by the credit card holder and the card account is legitimate. On Visa the CVV (Card Verification Value) appears after and to the right of your card number. Same goes for Mastercard’s CVC (Card Verfication Code), which also appears after and to the right of your card number, and has 3-digits. Diners Club, Discover, and JCB credit and debit cards have a three-digit card security code which also appears after and to the right of your card number. The American Express CID (Card Identification Number) is a 4-digit number printed on the front of your card. It appears above and to the right of your card number. On Maestro the CVV appears after and to the right of your number. If you don’t have a CVV for your Maestro card you can use 000."
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
js/paymill/paymentForm.js
CHANGED
|
@@ -15,13 +15,28 @@ var PAYMILL_ERROR_TEXT_IVALID_HOLDER = null;
|
|
| 15 |
var PAYMILL_ERROR_TEXT_IVALID_BANKCODE = null;
|
| 16 |
var PAYMILL_ERROR_TEXT_IVALID_PAYMENT = null;
|
| 17 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 18 |
/**
|
| 19 |
* prints debug messages in the log if debug mode is active
|
| 20 |
* @param {String} message
|
| 21 |
*/
|
| 22 |
function debug(message)
|
| 23 |
{
|
| 24 |
-
debug_state = pmQuery('.paymill-option-debug').val();
|
| 25 |
if (debug_state === 1) {
|
| 26 |
var displayName = "";
|
| 27 |
if (PAYMILL_PAYMENT_NAME === 'paymill_creditcard') {
|
|
@@ -95,7 +110,7 @@ function paymillResponseHandler(error, result)
|
|
| 95 |
} else {
|
| 96 |
// Appending Token to form
|
| 97 |
debug("Saving Token in Form: " + result.token);
|
| 98 |
-
pmQuery('.paymill-payment-token').val(result.token);
|
| 99 |
}
|
| 100 |
}
|
| 101 |
/**
|
|
@@ -104,6 +119,7 @@ function paymillResponseHandler(error, result)
|
|
| 104 |
*/
|
| 105 |
function paymillSubmitForm()
|
| 106 |
{
|
|
|
|
| 107 |
PAYMILL_PAYMENT_NAME = pmQuery("input[name='payment[method]']:checked").val();
|
| 108 |
|
| 109 |
if (PAYMILL_PAYMENT_NAME === "paymill_creditcard") {
|
|
@@ -120,10 +136,12 @@ function paymillSubmitForm()
|
|
| 120 |
PAYMILL_ERROR_TEXT_IVALID_BANKCODE = pmQuery('.paymill-payment-error-bankcode').val();
|
| 121 |
}
|
| 122 |
|
| 123 |
-
|
| 124 |
-
if (pmQuery("
|
| 125 |
-
|
| 126 |
}
|
|
|
|
|
|
|
| 127 |
|
| 128 |
switch (PAYMILL_PAYMENT_NAME) {
|
| 129 |
case "paymill_creditcard":
|
|
@@ -182,16 +200,16 @@ function paymillSubmitForm()
|
|
| 182 |
return false;
|
| 183 |
}
|
| 184 |
|
| 185 |
-
var cvc = 000;
|
| 186 |
|
| 187 |
-
if (
|
| 188 |
cvc = pmQuery('#paymill_creditcard_cvc').val();
|
| 189 |
}
|
| 190 |
|
| 191 |
debug("Generating Token");
|
| 192 |
paymill.createToken({
|
| 193 |
-
amount_int: parseInt(pmQuery('.paymill-payment-amount').val()), // E.g. "15" for 0.15 Eur
|
| 194 |
-
currency: pmQuery('.paymill-payment-currency').val(), // ISO 4217 e.g. "EUR"
|
| 195 |
number: pmQuery('#paymill_creditcard_number').val(),
|
| 196 |
exp_month: pmQuery('#paymill_creditcard_expiry_month').val(),
|
| 197 |
exp_year: pmQuery('#paymill_creditcard_expiry_year').val(),
|
|
@@ -238,11 +256,9 @@ function paymillSubmitForm()
|
|
| 238 |
|
| 239 |
debug("Generating Token");
|
| 240 |
paymill.createToken({
|
| 241 |
-
amount_int: pmQuery('.paymill-payment-amount').val(), // E.g. "15" for 0.15 Eur
|
| 242 |
-
currency: pmQuery('.paymill-payment-currency').val(), // ISO 4217 e.g. "EUR"
|
| 243 |
number: pmQuery('#paymill_directdebit_account').val(),
|
| 244 |
bank: pmQuery('#paymill_directdebit_bankcode').val(),
|
| 245 |
-
|
| 246 |
}, paymillResponseHandler);
|
| 247 |
}
|
| 248 |
break;
|
|
@@ -291,22 +307,11 @@ function addPaymillEvents()
|
|
| 291 |
pmQuery('.paymill-info-fastCheckout-cc').val('false');
|
| 292 |
});
|
| 293 |
|
| 294 |
-
//Gather Data
|
| 295 |
-
PAYMILL_PUBLIC_KEY = pmQuery('.paymill-info-public_key').val();
|
| 296 |
-
pmQuery('#paymill_creditcard_number').live('input', paymillShowCardIcon);
|
| 297 |
pmQuery('#paymill_creditcard_number').live('input', paymillSubmitForm);
|
| 298 |
pmQuery('#paymill_creditcard_cvc').live('input', paymillSubmitForm);
|
| 299 |
pmQuery('#paymill_creditcard_expiry_month').live('change', paymillSubmitForm);
|
| 300 |
pmQuery('#paymill_creditcard_expiry_year').live('change', paymillSubmitForm);
|
| 301 |
-
|
| 302 |
pmQuery('#paymill_directdebit_bankcode').live('input', paymillSubmitForm);
|
|
|
|
| 303 |
eventsSetted = true;
|
| 304 |
-
|
| 305 |
-
}
|
| 306 |
-
|
| 307 |
-
pmQuery(document).ready(function()
|
| 308 |
-
{
|
| 309 |
-
if (!eventsSetted) {
|
| 310 |
-
addPaymillEvents();
|
| 311 |
-
}
|
| 312 |
-
});
|
| 15 |
var PAYMILL_ERROR_TEXT_IVALID_BANKCODE = null;
|
| 16 |
var PAYMILL_ERROR_TEXT_IVALID_PAYMENT = null;
|
| 17 |
|
| 18 |
+
|
| 19 |
+
function getPaymillCode()
|
| 20 |
+
{
|
| 21 |
+
var methods = {
|
| 22 |
+
paymill_creditcard: "cc",
|
| 23 |
+
paymill_directdebit: 'elv'
|
| 24 |
+
};
|
| 25 |
+
|
| 26 |
+
if (methods.hasOwnProperty(pmQuery("input[name='payment[method]']:checked").val())) {
|
| 27 |
+
return methods[pmQuery("input[name='payment[method]']:checked").val()];
|
| 28 |
+
}
|
| 29 |
+
|
| 30 |
+
return 'other';
|
| 31 |
+
}
|
| 32 |
+
|
| 33 |
/**
|
| 34 |
* prints debug messages in the log if debug mode is active
|
| 35 |
* @param {String} message
|
| 36 |
*/
|
| 37 |
function debug(message)
|
| 38 |
{
|
| 39 |
+
debug_state = pmQuery('.paymill-option-debug-' + getPaymillCode()).val();
|
| 40 |
if (debug_state === 1) {
|
| 41 |
var displayName = "";
|
| 42 |
if (PAYMILL_PAYMENT_NAME === 'paymill_creditcard') {
|
| 110 |
} else {
|
| 111 |
// Appending Token to form
|
| 112 |
debug("Saving Token in Form: " + result.token);
|
| 113 |
+
pmQuery('.paymill-payment-token-' + getPaymillCode()).val(result.token);
|
| 114 |
}
|
| 115 |
}
|
| 116 |
/**
|
| 119 |
*/
|
| 120 |
function paymillSubmitForm()
|
| 121 |
{
|
| 122 |
+
PAYMILL_PUBLIC_KEY = pmQuery('.paymill-info-public_key-' + getPaymillCode()).val();
|
| 123 |
PAYMILL_PAYMENT_NAME = pmQuery("input[name='payment[method]']:checked").val();
|
| 124 |
|
| 125 |
if (PAYMILL_PAYMENT_NAME === "paymill_creditcard") {
|
| 136 |
PAYMILL_ERROR_TEXT_IVALID_BANKCODE = pmQuery('.paymill-payment-error-bankcode').val();
|
| 137 |
}
|
| 138 |
|
| 139 |
+
|
| 140 |
+
if (pmQuery('#paymill_creditcard_number').closest("form").attr("id") === undefined) {
|
| 141 |
+
pmQuery('#paymill_creditcard_number').closest("form").attr("id", 'paymill-checkout-form')
|
| 142 |
}
|
| 143 |
+
|
| 144 |
+
var form = pmQuery('#paymill_creditcard_number').closest("form").attr("id");
|
| 145 |
|
| 146 |
switch (PAYMILL_PAYMENT_NAME) {
|
| 147 |
case "paymill_creditcard":
|
| 200 |
return false;
|
| 201 |
}
|
| 202 |
|
| 203 |
+
var cvc = '000';
|
| 204 |
|
| 205 |
+
if (pmQuery('#paymill_creditcard_cvc').val() !== '') {
|
| 206 |
cvc = pmQuery('#paymill_creditcard_cvc').val();
|
| 207 |
}
|
| 208 |
|
| 209 |
debug("Generating Token");
|
| 210 |
paymill.createToken({
|
| 211 |
+
amount_int: parseInt(pmQuery('.paymill-payment-amount-' + getPaymillCode()).val()), // E.g. "15" for 0.15 Eur
|
| 212 |
+
currency: pmQuery('.paymill-payment-currency-' + getPaymillCode()).val(), // ISO 4217 e.g. "EUR"
|
| 213 |
number: pmQuery('#paymill_creditcard_number').val(),
|
| 214 |
exp_month: pmQuery('#paymill_creditcard_expiry_month').val(),
|
| 215 |
exp_year: pmQuery('#paymill_creditcard_expiry_year').val(),
|
| 256 |
|
| 257 |
debug("Generating Token");
|
| 258 |
paymill.createToken({
|
|
|
|
|
|
|
| 259 |
number: pmQuery('#paymill_directdebit_account').val(),
|
| 260 |
bank: pmQuery('#paymill_directdebit_bankcode').val(),
|
| 261 |
+
accountholder: pmQuery('#paymill_directdebit_holdername').val()
|
| 262 |
}, paymillResponseHandler);
|
| 263 |
}
|
| 264 |
break;
|
| 307 |
pmQuery('.paymill-info-fastCheckout-cc').val('false');
|
| 308 |
});
|
| 309 |
|
|
|
|
|
|
|
|
|
|
| 310 |
pmQuery('#paymill_creditcard_number').live('input', paymillSubmitForm);
|
| 311 |
pmQuery('#paymill_creditcard_cvc').live('input', paymillSubmitForm);
|
| 312 |
pmQuery('#paymill_creditcard_expiry_month').live('change', paymillSubmitForm);
|
| 313 |
pmQuery('#paymill_creditcard_expiry_year').live('change', paymillSubmitForm);
|
|
|
|
| 314 |
pmQuery('#paymill_directdebit_bankcode').live('input', paymillSubmitForm);
|
| 315 |
+
pmQuery('#paymill_creditcard_number').live('input', paymillShowCardIcon);
|
| 316 |
eventsSetted = true;
|
| 317 |
+
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
package.xml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
| 1 |
<?xml version="1.0"?>
|
| 2 |
<package>
|
| 3 |
<name>Paymill_Paymill</name>
|
| 4 |
-
<version>3.
|
| 5 |
<stability>stable</stability>
|
| 6 |
<license>Open Software License</license>
|
| 7 |
<channel>community</channel>
|
|
@@ -13,14 +13,14 @@ The Paymill Magento extension provides a credit card form and a direct debit for
|
|
| 13 |
<br /><br />
|
| 14 |
IMPORTANT: Only use the latest version.
|
| 15 |
</description>
|
| 16 |
-
<notes>* OneStepCheckout
|
| 17 |
-
*
|
| 18 |
-
*
|
| 19 |
-
*
|
| 20 |
<authors><author><name>PayIntelligent</name><user>Paymill</user><email>community@paymill.de</email></author></authors>
|
| 21 |
-
<date>2013-10-
|
| 22 |
-
<time>13:
|
| 23 |
-
<contents><target name="magecommunity"><dir
|
| 24 |
<compatible/>
|
| 25 |
<dependencies><required><php><min>5.2.0</min><max>6.0.0</max></php></required></dependencies>
|
| 26 |
</package>
|
| 1 |
<?xml version="1.0"?>
|
| 2 |
<package>
|
| 3 |
<name>Paymill_Paymill</name>
|
| 4 |
+
<version>3.3.0</version>
|
| 5 |
<stability>stable</stability>
|
| 6 |
<license>Open Software License</license>
|
| 7 |
<channel>community</channel>
|
| 13 |
<br /><br />
|
| 14 |
IMPORTANT: Only use the latest version.
|
| 15 |
</description>
|
| 16 |
+
<notes>* fix OneStepCheckout bug
|
| 17 |
+
* log search using the global record search
|
| 18 |
+
* 1.8 compatibility
|
| 19 |
+
* make input id's and names in the payment templates unique</notes>
|
| 20 |
<authors><author><name>PayIntelligent</name><user>Paymill</user><email>community@paymill.de</email></author></authors>
|
| 21 |
+
<date>2013-10-16</date>
|
| 22 |
+
<time>13:05:55</time>
|
| 23 |
+
<contents><target name="magecommunity"><dir name="Paymill"><dir><dir name="Paymill"><dir name="Block"><dir name="Adminhtml"><dir name="Log"><file name="Grid.php" hash="7d74f94403297eeb551272ad5c94513f"/><dir name="View"><file name="Plane.php" hash="87b7707dba28fa4357ab7fb2d12b19e4"/><file name="Tabs.php" hash="d16d9748921a34067242eaf92d6f299e"/></dir><file name="View.php" hash="af850dd16c3e7505a69a6cb3ca3fbc27"/></dir><file name="Log.php" hash="02930fb46a2a4569176ceb29c45037e8"/></dir><dir name="Payment"><dir name="Form"><file name="PaymentFormAbstract.php" hash="3b7c3c02a50d24def79485a7d2d47dd5"/><file name="PaymentFormCreditcard.php" hash="5351fa41246fb107bd3e62fdd274f715"/><file name="PaymentFormDirectdebit.php" hash="526991e3ed3c25b6c242fdd21e7aba25"/></dir><dir name="Info"><file name="PaymentFormCreditcard.php" hash="3e7a3d2b84878bc22f6ac9e2a0ac5c76"/><file name="PaymentFormDirectdebit.php" hash="bbc8f0cae5dff57df9ec1975650fe5e0"/></dir></dir></dir><dir name="Helper"><file name="CustomerHelper.php" hash="2970725a233e835e8c24d47d6a650c6a"/><file name="Data.php" hash="65371da937bd0aa1ba57aa4b9d27d989"/><file name="FastCheckoutHelper.php" hash="48058398d9af8d92f69e0a0566b0b040"/><file name="LoggingHelper.php" hash="53ea7f4d5c3af8de149a06dbe37ac061"/><file name="OptionHelper.php" hash="f0fae6bb8f67fc2e27f6957925e8168e"/><file name="PaymentHelper.php" hash="192be10925ef842da606bcad3f652375"/><file name="RefundHelper.php" hash="b936d48e6f9022acb0370ec755cf5850"/><file name="TransactionHelper.php" hash="7cce355230eee2f1c617df1bd18f8752"/></dir><dir name="Model"><file name="Fastcheckout.php" hash="94565a600a12f880edeabc941bd35ded"/><dir name="Log"><file name="Search.php" hash="4338b3876e745405bfcc5a32cfe42527"/></dir><file name="Log.php" hash="476c497495b92c3cf49e0c7b470854d4"/><dir name="Method"><file name="MethodModelAbstract.php" hash="055ce0ef74200646cfaaff5b6a15bc30"/><file name="MethodModelCreditcard.php" hash="972c52004e7f8f9be24a9037bd93be29"/><file name="MethodModelDirectdebit.php" hash="bc7bc9b40760ca488e48a257dccc768d"/></dir><dir name="Mysql4"><dir name="Fastcheckout"><file name="Collection.php" hash="14d4aa413ec952fd2452f08ab2a208f6"/></dir><file name="Fastcheckout.php" hash="56b09daa390ba1f4f5116f1d701833e4"/><dir name="Log"><file name="Collection.php" hash="cf4d8fec68a4cc44b2e47bf69e014cf3"/></dir><file name="Log.php" hash="9bd80dc9300cc189b6b3ebd921b4e3e6"/></dir><file name="Observer.php" hash="1f4a97d901810157228fd9224f319827"/><file name="TransactionData.php" hash="6f2bfd7a7ecde8dc4f21e03d33fdd7e4"/></dir><dir name="controllers"><dir name="Adminhtml"><file name="LogController.php" hash="fe634fc07d161f160ae060600561a0b1"/></dir></dir><dir name="etc"><file name="adminhtml.xml" hash="402c36431d690ffa9b7eae074cadfb4e"/><file name="config.xml" hash="9dbae26f56c55920323c20c879183635"/><file name="system.xml" hash="8a821f12386481d62899fd8159c8ea4e"/></dir><dir name="sql"><dir name="paymill_setup"><file name="mysql4-install-3.0.0.php" hash="46a31a1699b06185dea919edf6e07c74"/></dir></dir></dir></dir></dir></target><target name="magedesign"><dir name="adminhtml"><dir name="base"><dir name="default"><dir name="template"><dir name="paymill"><dir><dir name="log"><file name="view.phtml" hash="2d4df28de6e1cb4701963db3d0c0545c"/></dir><dir name="payment"><dir name="info"><file name="creditcard.phtml" hash="1c604ec666d9a3028a04c0d9a4257e4a"/><file name="directdebit.phtml" hash="1c604ec666d9a3028a04c0d9a4257e4a"/></dir></dir></dir></dir></dir><dir name="layout"><file name="paymill.xml" hash="fcc95f6e7c375fee779178a0f9f1a1d8"/></dir></dir></dir></dir><dir name="frontend"><dir name="base"><dir name="default"><dir name="template"><dir name="paymill"><dir><dir name="payment"><dir name="form"><file name="creditcard.phtml" hash="108686f598b1944108c7ba101768a9c1"/><file name="directdebit.phtml" hash="fb82ffcdc17e0d2c0a4415e0c34a5807"/></dir><dir name="info"><file name="creditcard.phtml" hash="42f875eb1b6e3e6151ddf152ef0bf13a"/><file name="directdebit.phtml" hash="42f875eb1b6e3e6151ddf152ef0bf13a"/></dir></dir></dir></dir></dir><dir name="layout"><file name="paymill.xml" hash="693c79248b355e3d35218f6a71e46f43"/></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Paymill_Paymill.xml" hash="d36d3af5f5752dcf87517272ddb9af53"/></dir></target><target name="magelocale"><dir name="de_DE"><file name="Paymill_Paymill.csv" hash="39f32cc2babac62a1796971aca3a97b8"/></dir><dir name="en_GB"><file name="Paymill_Paymill.csv" hash="3945f929635b1e2e556915b1017f6634"/></dir></target><target name="magelocal"><dir name="en_US"><file name="Paymill_Paymill.csv" hash=""/></dir><dir name="es_ES"><file name="Paymill_Paymill.csv" hash=""/></dir></target><target name="mage"><dir name="js"><dir name="paymill"><file name="paymentForm.js" hash="3029815f95863ac11e0ebbf7fa0c77e6"/></dir></dir></target><target name="magelib"><dir name="Services"><dir><dir name="Paymill"><dir name="Apiclient"><file name="Curl.php" hash="62457ead798a8bf62ccddb0bc7e8f449"/><file name="Interface.php" hash="349309458455e550c562fb17cf23f4a6"/><file name="paymill.crt" hash="51e14b4c734e450402ea2cf73f2aee0f"/></dir><file name="Base.php" hash="9f583d1613257b20a7d325131d545fae"/><file name="Clients.php" hash="f9bc9034a6f3b88a842f35efd6524ab6"/><file name="Exception.php" hash="9beffb75d92c0de3c1c7ea5b33930fff"/><file name="LoggingInterface.php" hash="46ebeede1da14b761c54a18aff6c3b79"/><file name="Offers.php" hash="28b2d420c87531ffa1f193ec3934fc5b"/><file name="PaymentProcessor.php" hash="e16fb85db7fa34a17f98f3e1ecac5f91"/><file name="Payments.php" hash="dd8e18548fb149956fff93fd55f68029"/><file name="Preauthorizations.php" hash="af4c8ab19444eee76951e9fe9f0e8fdd"/><file name="Refunds.php" hash="e15a2dfb3df362cb9cd45c8e5382b77b"/><file name="Subscriptions.php" hash="e8f55fcfd1065439d49bc5f734294be6"/><file name="Transactions.php" hash="fb6d248c88285105a426bf4491cbfc6b"/><file name="Webhooks.php" hash="06be5e57b81b3052a56371933e0674e9"/></dir></dir></dir></target><target name="mageskin"><dir name="frontend"><dir name="base"><dir name="default"><dir name="css"><dir name="paymill"><file name="logo.css" hash="6c09811ecd11d36b9e41b4a616481769"/></dir></dir><dir name="images"><dir name="paymill"><file name="icon_32x20_amex.png" hash="42c5fb43b4b603804b50da9761927d40"/><file name="icon_32x20_dinersclub.png" hash="0a7a8fc8f679ccf05d91298c9968629c"/><file name="icon_32x20_discover.png" hash="4fe8ef419087bed97cddbdeb251b847c"/><file name="icon_32x20_jcb.png" hash="774a040f938c5566fa3fddfa840d4743"/><file name="icon_32x20_maestro.png" hash="a6ffd22c9bbedb603449e2aa6136dbd1"/><file name="icon_32x20_mastercard.png" hash="09aef6dcbc50038605b7c0e5a38eb76e"/><file name="icon_32x20_visa.png" hash="e6d54e5c0120202eb5757bcfe499d73b"/><file name="icon_paymill.png" hash="303983a288b45cc7ddc5b88ad2eedd51"/></dir></dir></dir></dir></dir></target></contents>
|
| 24 |
<compatible/>
|
| 25 |
<dependencies><required><php><min>5.2.0</min><max>6.0.0</max></php></required></dependencies>
|
| 26 |
</package>
|
