From a2f6ea05d35a9b51aec3b97283db03bcbd1a8ca9 Mon Sep 17 00:00:00 2001 From: "David.Owusu" Date: Mon, 19 Nov 2018 11:40:07 +0100 Subject: [PATCH 01/15] [change] (MAGE-66) Replace logo with new CI. --- .../HeidelpayCD/Edition/etc/system.xml | 6 ++-- app/locale/de_DE/HeidelpayCD_Edition.csv | 36 +++++++++---------- app/locale/en_US/HeidelpayCD_Edition.csv | 36 +++++++++---------- 3 files changed, 39 insertions(+), 39 deletions(-) diff --git a/app/code/community/HeidelpayCD/Edition/etc/system.xml b/app/code/community/HeidelpayCD/Edition/etc/system.xml index 4cc26df..f59dda8 100755 --- a/app/code/community/HeidelpayCD/Edition/etc/system.xml +++ b/app/code/community/HeidelpayCD/Edition/etc/system.xml @@ -4,7 +4,7 @@ + Heidelpay CD-Edition ]]> sales text 405 @@ -21,14 +21,14 @@ 1
- Heidelpay + Heidelpay

heidelpay GmbH - Ihr Full Service Payment Provider - alles aus einer Hand

Die heidelpay GmbH kurz: heidelpay bietet als BaFin-zertifizierter Payment Service Provider alles was zum Online-Payment gehört.

>>> Informationen anfordern <<<


Das Leistungsspektrum des PCI DSS zertifizierten Unternehmens reicht von weltweiten e-Payment Lösungen, inklusive eines vollständigen Debitorenmanagement-, Risk- und Fraud- Systems bis hin zu einem breiten Angebot alternativer Bezahlverfahren - schnell, sicher, einfach und umfassend - alles aus einer Hand.


www.heidelpay.com -

Die Plugin wird bei der Installation mit Testdaten aktiviert.

+

Das Plugin wird bei der Installation mit Testdaten aktiviert.

]]>
diff --git a/app/locale/de_DE/HeidelpayCD_Edition.csv b/app/locale/de_DE/HeidelpayCD_Edition.csv index f02bddb..10d9475 100755 --- a/app/locale/de_DE/HeidelpayCD_Edition.csv +++ b/app/locale/de_DE/HeidelpayCD_Edition.csv @@ -106,24 +106,24 @@ "chargeback","Chargeback" "debit failed","Lastschriftabbuchung fehlgeschlagen" -"Heidelpay Credit Card (hcd)"," Heidelpay CD-Edition Kreditkarte" -"Heidelpay Direct Debit (hcd)"," Heidelpay CD-Edition Lastschrift" -"Heidelpay direct debit secured(hcd)"," Heidelpay CD-Edition gesicherte SEPA Lastschrift (b2c)" -"Heidelpay Debit Card (hcd)"," Heidelpay CD-Edition Debitkarte" -"Heidelpay Sofort (hcd)"," Heidelpay CD-Edition Sofort" -"Heidelpay Giropay (hcd)"," Heidelpay CD-Edition Giropay" -"Heidelpay Postfinance (hcd)"," Heidelpay CD-Edition Postfinance" -"Heidelpay Invoice (hcd)"," Heidelpay CD-Edition Rechnung" -"Heidelpay invoice secured(hcd)"," Heidelpay CD-Edition gesicherte Rechnung (b2c)" -"Heidelpay PayPal (hcd)"," Heidelpay CD-Edition PayPal" -"Heidelpay Prepayment (hcd)"," Heidelpay CD-Edition Vorkasse" -"Heidelpay Billsafe (hcd)"," Heidelpay CD-Edition BillSafe" -"Heidelpay EPS (hcd)"," Heidelpay CD-Edition EPS" -"Heidelpay iDeal (hcd)"," Heidelpay CD-Edition iDeal" -"Heidelpay Yapital (hcd)"," Heidelpay CD-Edition Yapital" -"Heidelpay MasterPass (hcd)"," Heidelpay CD-Edition MasterPass" -"Heidelpay Payolution (hcd)"," Heidelpay CD-Edition Payolution" -"Heidelpay Santander Invoice (hcd)"," Heidelpay CD-Edition Rechnungskauf von Santander" +"Heidelpay Credit Card (hcd)"," Heidelpay CD-Edition Kreditkarte" +"Heidelpay Direct Debit (hcd)"," Heidelpay CD-Edition Lastschrift" +"Heidelpay direct debit secured(hcd)"," Heidelpay CD-Edition gesicherte SEPA Lastschrift (b2c)" +"Heidelpay Debit Card (hcd)"," Heidelpay CD-Edition Debitkarte" +"Heidelpay Sofort (hcd)"," Heidelpay CD-Edition Sofort" +"Heidelpay Giropay (hcd)"," Heidelpay CD-Edition Giropay" +"Heidelpay Postfinance (hcd)"," Heidelpay CD-Edition Postfinance" +"Heidelpay Invoice (hcd)"," Heidelpay CD-Edition Rechnung" +"Heidelpay invoice secured(hcd)"," Heidelpay CD-Edition gesicherte Rechnung (b2c)" +"Heidelpay PayPal (hcd)"," Heidelpay CD-Edition PayPal" +"Heidelpay Prepayment (hcd)"," Heidelpay CD-Edition Vorkasse" +"Heidelpay Billsafe (hcd)"," Heidelpay CD-Edition BillSafe" +"Heidelpay EPS (hcd)"," Heidelpay CD-Edition EPS" +"Heidelpay iDeal (hcd)"," Heidelpay CD-Edition iDeal" +"Heidelpay Yapital (hcd)"," Heidelpay CD-Edition Yapital" +"Heidelpay MasterPass (hcd)"," Heidelpay CD-Edition MasterPass" +"Heidelpay Payolution (hcd)"," Heidelpay CD-Edition Payolution" +"Heidelpay Santander Invoice (hcd)"," Heidelpay CD-Edition Rechnungskauf von Santander" "No.","Nr." "Valid until:","Gültig bis:" diff --git a/app/locale/en_US/HeidelpayCD_Edition.csv b/app/locale/en_US/HeidelpayCD_Edition.csv index db58569..10ad9e2 100755 --- a/app/locale/en_US/HeidelpayCD_Edition.csv +++ b/app/locale/en_US/HeidelpayCD_Edition.csv @@ -108,24 +108,24 @@ "chargeback","chargeback" "debit failed","debit failed" -"Heidelpay Credit Card (hcd)"," Heidelpay CD-Edition Credit Card" -"Heidelpay Direct Debit (hcd)"," Heidelpay CD-Edition Direct Debit" -"Heidelpay direct debit secured(hcd)"," Heidelpay CD-Edition SEPA direct debit secured (b2c)" -"Heidelpay Debit Card (hcd)"," Heidelpay CD-Edition Debit Card" -"Heidelpay Sofort (hcd)"," Heidelpay CD-Edition Sofort" -"Heidelpay Giropay (hcd)"," Heidelpay CD-Edition Giropay" -"Heidelpay Postfinance (hcd)"," Heidelpay CD-Edition Postfinance" -"Heidelpay Invoice (hcd)"," Heidelpay CD-Edition Invoice" -"Heidelpay invoice secured(hcd)"," Heidelpay CD-Edition invoice secured (b2c)" -"Heidelpay PayPal (hcd)"," Heidelpay CD-Edition PayPal" -"Heidelpay Prepayment (hcd)"," Heidelpay CD-Edition Prepayment" -"Heidelpay Billsafe (hcd)"," Heidelpay CD-Edition BillSafe" -"Heidelpay EPS (hcd)"," Heidelpay CD-Edition EPS" -"Heidelpay iDeal (hcd)"," Heidelpay CD-Edition iDeal" -"Heidelpay Yapital (hcd)"," Heidelpay CD-Edition Yapital" -"Heidelpay MasterPass (hcd)"," Heidelpay CD-Edition MasterPass" -"Heidelpay Payolution (hcd)"," Heidelpay CD-Edition Payolution" -"Heidelpay Santander Invoice (hcd)"," Heidelpay CD-Edition Invoice by Santander" +"Heidelpay Credit Card (hcd)"," Heidelpay CD-Edition Credit Card" +"Heidelpay Direct Debit (hcd)"," Heidelpay CD-Edition Direct Debit" +"Heidelpay direct debit secured(hcd)"," Heidelpay CD-Edition SEPA direct debit secured (b2c)" +"Heidelpay Debit Card (hcd)"," Heidelpay CD-Edition Debit Card" +"Heidelpay Sofort (hcd)"," Heidelpay CD-Edition Sofort" +"Heidelpay Giropay (hcd)"," Heidelpay CD-Edition Giropay" +"Heidelpay Postfinance (hcd)"," Heidelpay CD-Edition Postfinance" +"Heidelpay Invoice (hcd)"," Heidelpay CD-Edition Invoice" +"Heidelpay invoice secured(hcd)"," Heidelpay CD-Edition invoice secured (b2c)" +"Heidelpay PayPal (hcd)"," Heidelpay CD-Edition PayPal" +"Heidelpay Prepayment (hcd)"," Heidelpay CD-Edition Prepayment" +"Heidelpay Billsafe (hcd)"," Heidelpay CD-Edition BillSafe" +"Heidelpay EPS (hcd)"," Heidelpay CD-Edition EPS" +"Heidelpay iDeal (hcd)"," Heidelpay CD-Edition iDeal" +"Heidelpay Yapital (hcd)"," Heidelpay CD-Edition Yapital" +"Heidelpay MasterPass (hcd)"," Heidelpay CD-Edition MasterPass" +"Heidelpay Payolution (hcd)"," Heidelpay CD-Edition Payolution" +"Heidelpay Santander Invoice (hcd)"," Heidelpay CD-Edition Invoice by Santander" "No.","No." "Valid until:","Valid until:" From 8eae580db910d7272cbf3ca87bd1d758d2a4ebc1 Mon Sep 17 00:00:00 2001 From: Simon Gabriel Date: Fri, 25 Jan 2019 15:24:58 +0100 Subject: [PATCH 02/15] [feature] (MAGE-72) SantanderIV: Enable santander invoice payment method. --- README.md | 1 + .../Edition/Model/Payment/Hcdivsan.php | 24 ++-- .../HeidelpayCD/Edition/etc/config.xml | 14 ++ .../HeidelpayCD/Edition/etc/system.xml | 123 ++++++++++++++++++ 4 files changed, 150 insertions(+), 12 deletions(-) diff --git a/README.md b/README.md index 70c6f44..8ffddcd 100755 --- a/README.md +++ b/README.md @@ -24,6 +24,7 @@ Currently supported payment methods are: * iDeal * BillSafe * Payolution Invoice +* Santander Invoice For more information please visit -http://dev.heidelpay.com/magento/ diff --git a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdivsan.php b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdivsan.php index 0513e0f..358ccf0 100755 --- a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdivsan.php +++ b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdivsan.php @@ -16,6 +16,8 @@ class HeidelpayCD_Edition_Model_Payment_Hcdivsan extends HeidelpayCD_Edition_Mod { /** * HeidelpayCD_Edition_Model_Payment_Hcdivsan constructor. + * + * @throws Mage_Core_Exception */ public function __construct() { @@ -36,24 +38,22 @@ public function __construct() */ public function isAvailable($quote = null) { - return false; - -// --- Can be re-activated when santander will be free to use --- -// if ($quote === null) { -// return false; -// } -// -// if ($quote->getIsVirtual()) { -// return false; -// } -// -// return parent::isAvailable($quote); + if ($quote === null) { + return false; + } + + if ($quote->getIsVirtual()) { + return false; + } + + return parent::isAvailable($quote); } /** * @inheritdoc * * @throws \Mage_Core_Exception + * @throws Zend_Controller_Request_Exception */ public function validate() { diff --git a/app/code/community/HeidelpayCD/Edition/etc/config.xml b/app/code/community/HeidelpayCD/Edition/etc/config.xml index 1d694b2..5766b05 100755 --- a/app/code/community/HeidelpayCD/Edition/etc/config.xml +++ b/app/code/community/HeidelpayCD/Edition/etc/config.xml @@ -372,6 +372,20 @@ 0 0 + + hcd + Rechnungskauf von Santander + 0 + 31HA07BC81941E63A2482091FAF374AF + 0 + 0 + hcd/payment_hcdivsan + 1 + 0 + 0 + 1 + DE + hcd Payolution diff --git a/app/code/community/HeidelpayCD/Edition/etc/system.xml b/app/code/community/HeidelpayCD/Edition/etc/system.xml index f59dda8..f6fe712 100755 --- a/app/code/community/HeidelpayCD/Edition/etc/system.xml +++ b/app/code/community/HeidelpayCD/Edition/etc/system.xml @@ -1896,6 +1896,129 @@ + + + text + 163 + 1 + 1 + 1 + + + + select + adminhtml/system_config_source_yesno + 10 + 1 + 1 + 1 + + + <label>Title</label> + <frontend_type>text</frontend_type> + <sort_order>20</sort_order> + <show_in_default>1</show_in_default> + <show_in_website>1</show_in_website> + <show_in_store>1</show_in_store> + <depends> + <active>1</active> + </depends> + + + + text + 40 + 1 + 1 + 1 + + 1 + + + + + select + hcd/system_config_source_recognition + 60 + 1 + 1 + 1 + + 1 + + + + + select + adminhtml/system_config_source_yesno + 70 + 1 + 1 + 1 + + 1 + + + + + text + 110 + 1 + 1 + 1 + + 1 + + + + + text + 120 + 1 + 1 + 1 + + 1 + + + + + text + 130 + 1 + 1 + 1 + + 1 + + + + + allowspecific + 140 + adminhtml/system_config_source_payment_allspecificcountries + 1 + 1 + 1 + + 1 + + + + + multiselect + 150 + adminhtml/system_config_source_country + 1 + 1 + 1 + + 1 + 1 + + + + text From 8bf250c41f93dc9a19c4b970c2b3bc56520a6b51 Mon Sep 17 00:00:00 2001 From: Simon Gabriel Date: Mon, 28 Jan 2019 17:08:55 +0100 Subject: [PATCH 03/15] [feature] (MAGE-72) SantanderIV: Fix Logo, Opt-In and Privacy-Policy. --- .../Edition/Block/Form/SantanderInvoice.php | 72 ++++++------------- .../template/hcd/form/santander-invoice.phtml | 8 +-- app/locale/de_DE/HeidelpayCD_Edition.csv | 3 + app/locale/en_US/HeidelpayCD_Edition.csv | 3 + 4 files changed, 30 insertions(+), 56 deletions(-) mode change 100644 => 100755 app/code/community/HeidelpayCD/Edition/Block/Form/SantanderInvoice.php diff --git a/app/code/community/HeidelpayCD/Edition/Block/Form/SantanderInvoice.php b/app/code/community/HeidelpayCD/Edition/Block/Form/SantanderInvoice.php old mode 100644 new mode 100755 index d6a70a9..7acc14f --- a/app/code/community/HeidelpayCD/Edition/Block/Form/SantanderInvoice.php +++ b/app/code/community/HeidelpayCD/Edition/Block/Form/SantanderInvoice.php @@ -17,23 +17,22 @@ class HeidelpayCD_Edition_Block_Form_SantanderInvoice extends Mage_Payment_Block /** @var string */ public $optin; - /** @var string */ - public $privacyPolicy; - /** @var string */ public $imgLink; /** @var string */ - public $advLink; - - /** @var string */ - public $advText; - - /** @var string */ - public $privpolLink; + public $privacyPolicy; - /** @var string */ - public $privpolText; + /** + * Replaces paragraph-tag (

) with span-tag (). + * + * @param $text + * @return mixed + */ + public function stripParagraphTag($text) + { + return str_replace('optin = $optinInformation->optin; $this->privacyPolicy = $optinInformation->privacy_policy; - // urls for logo, advanced privacy and policy information - $this->imgLink = $optinInformation->santander_iv_img_link; - $this->advLink = $optinInformation->santander_iv_de_adv_link; - $this->privpolLink = $optinInformation->santander_iv_de_privpol_link; - - // texts for checkboxes (accept policies, ...) - $this->advText = str_replace( - 'hier', - 'hier', - $optinInformation->santander_iv_de_adv_text - ); - - $this->privpolText = str_replace( - 'Einwilligungserklärungstextes', - 'hier', - $optinInformation->santander_iv_de_privpol_text - ); + // url for the santander logo + $this->imgLink = $optinInformation->logolink; } } } @@ -96,41 +80,25 @@ public function getOptin() /** * @return string */ - public function getPrivacyPolicy() + public function getOptinText() { - return $this->privacyPolicy; + return $this->stripParagraphTag($this->getOptin()); } /** * @return string */ - public function getImgLink() - { - return $this->imgLink; - } - - /** - * @return string - */ - public function getAdvLink() - { - return $this->advLink; - } - - /** - * @return string - */ - public function getAdvText() + public function getPrivacyPolicy() { - return $this->advText; + return $this->privacyPolicy; } /** * @return string */ - public function getPrivpolLink() + public function getImgLink() { - return $this->privpolLink; + return $this->imgLink; } /** @@ -138,6 +106,6 @@ public function getPrivpolLink() */ public function getPrivpolText() { - return $this->privpolText; + return $this->stripParagraphTag($this->getPrivacyPolicy()); } } diff --git a/app/design/frontend/base/default/template/hcd/form/santander-invoice.phtml b/app/design/frontend/base/default/template/hcd/form/santander-invoice.phtml index 2122403..5dac564 100755 --- a/app/design/frontend/base/default/template/hcd/form/santander-invoice.phtml +++ b/app/design/frontend/base/default/template/hcd/form/santander-invoice.phtml @@ -160,19 +160,19 @@ if (isset($userData['payment_data']['NAME.SALUTATION'])) {

-

Werbezustimmung

+

escapeHtml($form->__('Advertisement Approval')) ?>

- +

-

Datenschutzerklärung

+

escapeHtml($form->__('Privacy Policy')) ?>

- +

diff --git a/app/locale/de_DE/HeidelpayCD_Edition.csv b/app/locale/de_DE/HeidelpayCD_Edition.csv index 10d9475..774fe57 100755 --- a/app/locale/de_DE/HeidelpayCD_Edition.csv +++ b/app/locale/de_DE/HeidelpayCD_Edition.csv @@ -199,6 +199,9 @@ "HPError-800.100.171","Bitte wählen Sie eine andere Zahlart." "HPError-800.300.101","Bitte wählen Sie eine andere Zahlart." +"Advertisement Approval","Werbeeinverständniserklärung" +"Privacy Policy","Datenschutzerklärung" + "The booking contains:","Die Abbuchung enthält:" "mandate reference ID","Mandatsreferenz-ID" "creditor identifier","Gläubiger ID" diff --git a/app/locale/en_US/HeidelpayCD_Edition.csv b/app/locale/en_US/HeidelpayCD_Edition.csv index 10ad9e2..4ee7be0 100755 --- a/app/locale/en_US/HeidelpayCD_Edition.csv +++ b/app/locale/en_US/HeidelpayCD_Edition.csv @@ -207,6 +207,9 @@ "HPError-800.100.171","Please choose another payment method." "HPError-800.300.101","Please choose another payment method." +"Advertisement Approval","Advertisement Approval" +"Privacy Policy","Privacy Policy" + "The booking contains:","The booking contains:" "mandate reference ID","mandate reference ID" "creditor identifier","creditor identifier" From d07a0bf0f7e571610eec34cdaa167ce2d83f3093 Mon Sep 17 00:00:00 2001 From: Simon Gabriel Date: Mon, 28 Jan 2019 17:28:47 +0100 Subject: [PATCH 04/15] [feature] (MAGE-72) SantanderIV: Add validity check for post code. --- .../community/HeidelpayCD/Edition/Model/Payment/Hcdivsan.php | 4 ++++ app/locale/de_DE/HeidelpayCD_Edition.csv | 1 + app/locale/en_US/HeidelpayCD_Edition.csv | 1 + 3 files changed, 6 insertions(+) diff --git a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdivsan.php b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdivsan.php index 358ccf0..57f8e6b 100755 --- a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdivsan.php +++ b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdivsan.php @@ -66,6 +66,10 @@ public function validate() Mage::throwException($this->_getHelper()->__('Something went wrong. Please try again.')); } + if (strlen($this->getQuote()->getShippingAddress()->getPostcode()) !== 5) { + Mage::throwException($this->_getHelper()->__('Post code has to be 5 digits.')); + } + $advField = $this->getCode() . '_adv_optout'; $privPolField = $this->getCode() . '_privpol_optin'; diff --git a/app/locale/de_DE/HeidelpayCD_Edition.csv b/app/locale/de_DE/HeidelpayCD_Edition.csv index 774fe57..9d90b41 100755 --- a/app/locale/de_DE/HeidelpayCD_Edition.csv +++ b/app/locale/de_DE/HeidelpayCD_Edition.csv @@ -201,6 +201,7 @@ "Advertisement Approval","Werbeeinverständniserklärung" "Privacy Policy","Datenschutzerklärung" +"Post code has to be 5 digits.","Die Postleitzahl muss 5-stellig sein. Bitte passen Sie Adresse an und versuchen Sie es erneut." "The booking contains:","Die Abbuchung enthält:" "mandate reference ID","Mandatsreferenz-ID" diff --git a/app/locale/en_US/HeidelpayCD_Edition.csv b/app/locale/en_US/HeidelpayCD_Edition.csv index 4ee7be0..af1bfc7 100755 --- a/app/locale/en_US/HeidelpayCD_Edition.csv +++ b/app/locale/en_US/HeidelpayCD_Edition.csv @@ -209,6 +209,7 @@ "Advertisement Approval","Advertisement Approval" "Privacy Policy","Privacy Policy" +"Post code has to be 5 digits.","Post code has to be 5 digits. Change address and try again." "The booking contains:","The booking contains:" "mandate reference ID","mandate reference ID" From 512a382cbd3e29955d7e05f95876e27da6768ebd Mon Sep 17 00:00:00 2001 From: "David.Owusu" Date: Tue, 29 Jan 2019 08:11:12 +0100 Subject: [PATCH 05/15] [change] (TPHP-38) Add support-info to readme file. --- README.md | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 70c6f44..ae40dcb 100755 --- a/README.md +++ b/README.md @@ -40,4 +40,19 @@ You can find a copy of this license in [LICENSE.txt](LICENSE.txt). A manual can be fund here... * http://dev.heidelpay.com/magento-cd-edition-manual/ (EN) -* https://dev.heidelpay.de/handbuch-magento-cd-edition-plugin/ (DE) \ No newline at end of file +* https://dev.heidelpay.de/handbuch-magento-cd-edition-plugin/ (DE) + +## Support +For any issues or questions please get in touch with our support. + +#### Web page +https://dev.heidelpay.com/ + +#### Email +support@heidelpay.com + +#### Phone ++49 (0)6221/6471-100 + +#### Twitter +@devHeidelpay \ No newline at end of file From 3403f2fa1ed8bd2917705cf4d7d794867dd87120 Mon Sep 17 00:00:00 2001 From: Simon Gabriel Date: Tue, 29 Jan 2019 11:49:16 +0100 Subject: [PATCH 06/15] [feature] (MAGE-72) SantanderIV: Add validity check for date of birth. --- .../HeidelpayCD/Edition/Model/Payment/Hcdivsan.php | 10 ++++++++++ app/locale/de_DE/HeidelpayCD_Edition.csv | 1 + app/locale/en_US/HeidelpayCD_Edition.csv | 1 + 3 files changed, 12 insertions(+) diff --git a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdivsan.php b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdivsan.php index 57f8e6b..62d9022 100755 --- a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdivsan.php +++ b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdivsan.php @@ -70,6 +70,16 @@ public function validate() Mage::throwException($this->_getHelper()->__('Post code has to be 5 digits.')); } + $validDate = checkdate( + $this->_postPayload['hcdivsan_dobmonth'], + $this->_postPayload['hcdivsan_dobday'], + $this->_postPayload['hcdivsan_dobyear'] + ); + + if (!$validDate) { + Mage::throwException($this->_getHelper()->__('Please enter a valid date of birth.')); + } + $advField = $this->getCode() . '_adv_optout'; $privPolField = $this->getCode() . '_privpol_optin'; diff --git a/app/locale/de_DE/HeidelpayCD_Edition.csv b/app/locale/de_DE/HeidelpayCD_Edition.csv index 9d90b41..0147af7 100755 --- a/app/locale/de_DE/HeidelpayCD_Edition.csv +++ b/app/locale/de_DE/HeidelpayCD_Edition.csv @@ -202,6 +202,7 @@ "Advertisement Approval","Werbeeinverständniserklärung" "Privacy Policy","Datenschutzerklärung" "Post code has to be 5 digits.","Die Postleitzahl muss 5-stellig sein. Bitte passen Sie Adresse an und versuchen Sie es erneut." +"Please enter a valid date of birth.","Bitte geben Sie ein gültiges Geburtsdatum ein." "The booking contains:","Die Abbuchung enthält:" "mandate reference ID","Mandatsreferenz-ID" diff --git a/app/locale/en_US/HeidelpayCD_Edition.csv b/app/locale/en_US/HeidelpayCD_Edition.csv index af1bfc7..8aa8499 100755 --- a/app/locale/en_US/HeidelpayCD_Edition.csv +++ b/app/locale/en_US/HeidelpayCD_Edition.csv @@ -210,6 +210,7 @@ "Advertisement Approval","Advertisement Approval" "Privacy Policy","Privacy Policy" "Post code has to be 5 digits.","Post code has to be 5 digits. Change address and try again." +"Please enter a valid date of birth.","Please enter a valid date of birth." "The booking contains:","The booking contains:" "mandate reference ID","mandate reference ID" From 734343e4ce30c9f9771d8f2ec229fdb32ab5dd08 Mon Sep 17 00:00:00 2001 From: mkreusch Date: Tue, 2 Apr 2019 10:52:42 +0200 Subject: [PATCH 07/15] typo --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index ae40dcb..6605516 100755 --- a/README.md +++ b/README.md @@ -38,7 +38,7 @@ You can find a copy of this license in [LICENSE.txt](LICENSE.txt). ## Installation -A manual can be fund here... +A manual can be found here... * http://dev.heidelpay.com/magento-cd-edition-manual/ (EN) * https://dev.heidelpay.de/handbuch-magento-cd-edition-plugin/ (DE) @@ -55,4 +55,4 @@ support@heidelpay.com +49 (0)6221/6471-100 #### Twitter -@devHeidelpay \ No newline at end of file +@devHeidelpay From e8824126b6b43ede7e777949dc712eb69409e945 Mon Sep 17 00:00:00 2001 From: Simon Gabriel Date: Fri, 5 Apr 2019 11:50:12 +0200 Subject: [PATCH 08/15] [feature] (MAGE-72) SantanderIV: Update changelog. --- CHANGELOG.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index d0c65a8..0d6904c 100755 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,10 @@ # Release Notes - heidelpay extension for Magento 1 +## X.X.X + +### Added +- Enabled payment method Santander Invoice + ## v18.8.14 ### Added From 5f10752bed872614cb5d743c751554aa4e28c7e0 Mon Sep 17 00:00:00 2001 From: Simon Gabriel Date: Fri, 5 Apr 2019 14:39:43 +0200 Subject: [PATCH 09/15] [feature] (MAGE-72) SantanderIV: Change default channel. --- app/code/community/HeidelpayCD/Edition/etc/config.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/code/community/HeidelpayCD/Edition/etc/config.xml b/app/code/community/HeidelpayCD/Edition/etc/config.xml index 5766b05..ba4fb9d 100755 --- a/app/code/community/HeidelpayCD/Edition/etc/config.xml +++ b/app/code/community/HeidelpayCD/Edition/etc/config.xml @@ -376,7 +376,7 @@ hcd Rechnungskauf von Santander 0 - 31HA07BC81941E63A2482091FAF374AF + 31HA07BC8147472B68A08F10540D7D9F 0 0 hcd/payment_hcdivsan From 63f7a7f1fe5d0a7ffba9acbc6da53cb6fa6d7339 Mon Sep 17 00:00:00 2001 From: Simon Gabriel Date: Tue, 16 Apr 2019 13:43:14 +0200 Subject: [PATCH 10/15] [feature] (MAGE-72) SantanderIV: Update changelog and version. --- CHANGELOG.md | 2 +- app/code/community/HeidelpayCD/Edition/etc/config.xml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 0d6904c..67ac865 100755 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # Release Notes - heidelpay extension for Magento 1 -## X.X.X +## v19.4.16 ### Added - Enabled payment method Santander Invoice diff --git a/app/code/community/HeidelpayCD/Edition/etc/config.xml b/app/code/community/HeidelpayCD/Edition/etc/config.xml index ba4fb9d..e5c56d6 100755 --- a/app/code/community/HeidelpayCD/Edition/etc/config.xml +++ b/app/code/community/HeidelpayCD/Edition/etc/config.xml @@ -2,7 +2,7 @@ - 18.8.14 + 19.4.16 From 5cf5acb3e320b9c89c8a7150ae58d701bda09f79 Mon Sep 17 00:00:00 2001 From: Simon Gabriel Date: Tue, 16 Apr 2019 13:48:23 +0200 Subject: [PATCH 11/15] [feature] (MAGE-72) SantanderIV: Update changelog. --- CHANGELOG.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 67ac865..798d8c2 100755 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,10 @@ ### Added - Enabled payment method Santander Invoice +- Added support information to readme. + +### Changed +- Updated heidelpay logo. ## v18.8.14 From 51bd568332b3c32f6323f4217092b4f7e258f982 Mon Sep 17 00:00:00 2001 From: Simon Gabriel Date: Tue, 16 Apr 2019 13:59:34 +0200 Subject: [PATCH 12/15] [cleanup] (MAGE-72) Fix several code style issues to fix travis job. --- .../Edition/Block/Form/SantanderInvoice.php | 1 + .../HeidelpayCD/Edition/Helper/BasketApi.php | 4 ++ .../Edition/Helper/InvoiceHelper.php | 7 ++- .../HeidelpayCD/Edition/Helper/Payment.php | 4 +- .../Edition/Model/Convert/Order.php | 9 ++-- .../HeidelpayCD/Edition/Model/Observer.php | 3 +- .../Edition/Model/Order/Invoice.php | 5 +- .../Edition/Model/Payment/Abstract.php | 48 +++++++++++++++---- .../Payment/AbstractSecuredPaymentMethods.php | 3 ++ .../Model/Payment/HcdDirectDebitSecured.php | 5 +- .../Model/Payment/HcdInvoiceSecured.php | 3 +- .../Edition/Model/Payment/Hcdbs.php | 3 ++ .../Edition/Model/Payment/Hcdcc.php | 1 + .../Edition/Model/Payment/Hcddc.php | 2 +- .../Edition/Model/Payment/Hcddd.php | 1 + .../Edition/Model/Payment/Hcdeps.php | 2 +- .../Edition/Model/Payment/Hcdide.php | 2 +- .../Edition/Model/Payment/Hcdiv.php | 2 + .../Edition/Model/Payment/Hcdivpol.php | 2 + .../Edition/Model/Payment/Hcdivsan.php | 2 +- .../Edition/Model/Payment/Hcdmpa.php | 4 -- .../Edition/Model/Payment/Hcdpf.php | 1 + .../Edition/Model/Payment/Hcdpp.php | 6 ++- .../HeidelpayCD/Edition/Model/Transaction.php | 1 + .../Edition/controllers/IndexController.php | 6 +-- 25 files changed, 86 insertions(+), 41 deletions(-) diff --git a/app/code/community/HeidelpayCD/Edition/Block/Form/SantanderInvoice.php b/app/code/community/HeidelpayCD/Edition/Block/Form/SantanderInvoice.php index 7acc14f..43a168d 100755 --- a/app/code/community/HeidelpayCD/Edition/Block/Form/SantanderInvoice.php +++ b/app/code/community/HeidelpayCD/Edition/Block/Form/SantanderInvoice.php @@ -27,6 +27,7 @@ class HeidelpayCD_Edition_Block_Form_SantanderInvoice extends Mage_Payment_Block * Replaces paragraph-tag (

) with span-tag (). * * @param $text + * * @return mixed */ public function stripParagraphTag($text) diff --git a/app/code/community/HeidelpayCD/Edition/Helper/BasketApi.php b/app/code/community/HeidelpayCD/Edition/Helper/BasketApi.php index f472489..84920e6 100755 --- a/app/code/community/HeidelpayCD/Edition/Helper/BasketApi.php +++ b/app/code/community/HeidelpayCD/Edition/Helper/BasketApi.php @@ -118,6 +118,7 @@ protected function getBasketTotalNet($quote) * Returns the net shipping cost amount depending on the order/quote type * * @param Mage_Sales_Model_Order|Mage_Sales_Model_Quote $quote + * * @return float */ protected function getShippingAmount($quote) @@ -134,6 +135,7 @@ protected function getShippingAmount($quote) * Returns the shipping discount amount depending on the order/quote type * * @param Mage_Sales_Model_Order|Mage_Sales_Model_Quote $quote + * * @return float */ protected function getShippingDiscountAmount($quote) @@ -150,6 +152,7 @@ protected function getShippingDiscountAmount($quote) * Returns the gross shipping cost amount depending on the order/quote type * * @param Mage_Sales_Model_Order|Mage_Sales_Model_Quote $quote + * * @return float */ protected function getShippingInclTax($quote) @@ -166,6 +169,7 @@ protected function getShippingInclTax($quote) * Returns the shipping tax amount depending on the order/quote type * * @param Mage_Sales_Model_Order|Mage_Sales_Model_Quote $quote + * * @return float */ protected function getShippingTaxAmount($quote) diff --git a/app/code/community/HeidelpayCD/Edition/Helper/InvoiceHelper.php b/app/code/community/HeidelpayCD/Edition/Helper/InvoiceHelper.php index 9028159..0124542 100755 --- a/app/code/community/HeidelpayCD/Edition/Helper/InvoiceHelper.php +++ b/app/code/community/HeidelpayCD/Edition/Helper/InvoiceHelper.php @@ -11,7 +11,6 @@ * * @package heidelpay/${Package} */ - class HeidelpayCD_Edition_Helper_InvoiceHelper { /** @@ -22,6 +21,7 @@ class HeidelpayCD_Edition_Helper_InvoiceHelper * @param bool $file name of the logfile * * @return mixed + * * @throws Mage_Core_Model_Store_Exception */ public function log($message, $level = 'DEBUG', $file = false) @@ -35,9 +35,11 @@ public function log($message, $level = 'DEBUG', $file = false) /** * Return true if actual equals expected currency. * - * @param Mage_Sales_Model_Order $order + * @param Mage_Sales_Model_Order $order * @param HeidelpayCD_Edition_Model_Transaction $data + * * @return bool + * * @throws Mage_Core_Model_Store_Exception */ public function validateCurrency(Mage_Sales_Model_Order $order, $data) @@ -65,6 +67,7 @@ public function validateCurrency(Mage_Sales_Model_Order $order, $data) * @param $message string order history message * * @return Mage_Sales_Model_Order + * * @throws Mage_Core_Exception * @throws Mage_Core_Model_Store_Exception */ diff --git a/app/code/community/HeidelpayCD/Edition/Helper/Payment.php b/app/code/community/HeidelpayCD/Edition/Helper/Payment.php index 72022db..5603345 100755 --- a/app/code/community/HeidelpayCD/Edition/Helper/Payment.php +++ b/app/code/community/HeidelpayCD/Edition/Helper/Payment.php @@ -20,7 +20,7 @@ class HeidelpayCD_Edition_Helper_Payment extends HeidelpayCD_Edition_Helper_Abst /** * send request to heidelpay apo * - * @param $url string url for the heidelpay api + * @param $url string url for the heidelpay api * @param array $params post parameter * * @return array response from heidelpay api @@ -231,7 +231,7 @@ protected function _setPaymentMethod($config = array(), $customer = array()) break; /* Payolution invoice */ case 'ivpol': - $params['PAYMENT.CODE'] = 'IV.' . ($type !== 'RG' ? $type : 'PA') ; + $params['PAYMENT.CODE'] = 'IV.' . ($type !== 'RG' ? $type : 'PA'); $params['ACCOUNT.BRAND'] = 'PAYOLUTION_DIRECT'; break; /* direct debit secured */ diff --git a/app/code/community/HeidelpayCD/Edition/Model/Convert/Order.php b/app/code/community/HeidelpayCD/Edition/Model/Convert/Order.php index 44ef47e..bd68d38 100755 --- a/app/code/community/HeidelpayCD/Edition/Model/Convert/Order.php +++ b/app/code/community/HeidelpayCD/Edition/Model/Convert/Order.php @@ -20,6 +20,7 @@ * * @category Mage * @package Mage_Sales + * * @copyright Copyright (c) 2006-2017 X.commerce, Inc. and affiliates (http://www.magento.com) * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) */ @@ -29,16 +30,17 @@ * * @category Mage * @package Mage_Sales + * * @author Magento Core Team */ class HeidelpayCD_Edition_Model_Convert_Order extends Mage_Sales_Model_Convert_Order { - /** * Convert order object to invoice * - * @param Mage_Sales_Model_Order $order - * @return Mage_Sales_Model_Order_Invoice + * @param Mage_Sales_Model_Order $order + * + * @return Mage_Sales_Model_Order_Invoice */ public function toInvoice(Mage_Sales_Model_Order $order) { @@ -52,5 +54,4 @@ public function toInvoice(Mage_Sales_Model_Order $order) Mage::helper('core')->copyFieldset('sales_convert_order', 'to_invoice', $order, $invoice); return $invoice; } - } diff --git a/app/code/community/HeidelpayCD/Edition/Model/Observer.php b/app/code/community/HeidelpayCD/Edition/Model/Observer.php index 861342b..7595425 100755 --- a/app/code/community/HeidelpayCD/Edition/Model/Observer.php +++ b/app/code/community/HeidelpayCD/Edition/Model/Observer.php @@ -62,7 +62,9 @@ public function handleWalletDataDuringCheckout($observer) * Observer on save shipment to report the shipment to heidelpay * * @param Varien_Event_Observer $observer + * * @return $this + * * @throws \Mage_Core_Exception */ public function reportReversalToHeidelpay($observer) @@ -278,5 +280,4 @@ protected function log($message, $level = 'DEBUG', $file = false) return Mage::helper('hcd/payment') ->realLog($callers[1]['function'] . ' ' . $message, $level, $file); } - } diff --git a/app/code/community/HeidelpayCD/Edition/Model/Order/Invoice.php b/app/code/community/HeidelpayCD/Edition/Model/Order/Invoice.php index f9ec7f6..d4c2034 100755 --- a/app/code/community/HeidelpayCD/Edition/Model/Order/Invoice.php +++ b/app/code/community/HeidelpayCD/Edition/Model/Order/Invoice.php @@ -5,7 +5,6 @@ * Date: 08.11.2017 * Time: 11:56 */ - class HeidelpayCD_Edition_Model_Order_Invoice extends Mage_Sales_Model_Order_Invoice { protected function _getEmails($configPath) @@ -22,6 +21,4 @@ protected function _getEmails($configPath) return $emails; } - - -} \ No newline at end of file +} diff --git a/app/code/community/HeidelpayCD/Edition/Model/Payment/Abstract.php b/app/code/community/HeidelpayCD/Edition/Model/Payment/Abstract.php index a972fa4..b81e0a1 100755 --- a/app/code/community/HeidelpayCD/Edition/Model/Payment/Abstract.php +++ b/app/code/community/HeidelpayCD/Edition/Model/Payment/Abstract.php @@ -282,14 +282,17 @@ public function getOrderPlaceRedirectUrl() /** * Call heidelpay api for a payment request * - * @param bool $isRegistration payment method supports registration + * @param bool $isRegistration payment method supports registration * @param mixed $basketId + * @param bool $refId payment reference id for debit/authorize on a registration * - * @param bool $refId payment reference id for debit/authorize on a registration * @return mixed + * * @throws \Mage_Core_Exception * @throws \Mage_Core_Model_Store_Exception + * * @internal param bool $BasketI Id of a heidelpay basket api call + * * @throws Zend_Http_Client_Exception */ public function getHeidelpayUrl($isRegistration = false, $basketId = false, $refId = false) @@ -411,6 +414,7 @@ public function getCustomerId() * @param bool $file name of the logfile * * @return mixed + * * @throws Mage_Core_Model_Store_Exception */ public function log($message, $level = 'DEBUG', $file = false) @@ -424,10 +428,11 @@ public function log($message, $level = 'DEBUG', $file = false) /** * Load configuration parameter for the given payment method * - * @param mixed $code payment method code + * @param mixed $code payment method code * @param mixed $storeId magento store identification number * * @return mixed + * * @throws Mage_Core_Model_Store_Exception */ public function getMainConfig($code, $storeId = false) @@ -464,9 +469,10 @@ public function getMainConfig($code, $storeId = false) * Prepare frontend parameter for heidelpay api call * * @param integer $orderNumber order identification number - * @param boolean $storeId shore identification number + * @param boolean $storeId shore identification number * * @return array + * * @throws \Mage_Core_Model_Store_Exception */ public function getFrontend($orderNumber, $storeId = false) @@ -530,6 +536,7 @@ public function getShippingHash() * @param bool $isReg in case of registration * * @return array + * * @throws \Mage_Core_Exception * */ @@ -625,11 +632,12 @@ public function getUser($order, $isReg = false) /** * Load additional payment information * - * @param string|null $code current payment method - * @param int|null $customerId the customers identification number - * @param int|null $storeId magento store id + * @param string|null $code current payment method + * @param int|null $customerId the customers identification number + * @param int|null $storeId magento store id * * @return array additional payment information + * * @throws Mage_Core_Model_Store_Exception */ public function getCustomerData($code = null, $customerId = null, $storeId = null) @@ -735,6 +743,7 @@ public function getBasketData($order, $completeBasket = false, $amount = false) * This has to be overridden by the payment method. * * @param $order + * * @return array */ protected function getBasket($order) @@ -746,6 +755,7 @@ protected function getBasket($order) * Getter for the payment method backend title * * @return string payment method title + * * @throws Mage_Core_Model_Store_Exception */ public function getAdminTitle() @@ -757,6 +767,7 @@ public function getAdminTitle() * Getter for the payment method frontend title * * @return string payment method title + * * @throws Mage_Core_Model_Store_Exception */ public function getTitle() @@ -771,7 +782,9 @@ public function getTitle() * * @param Mage_Sales_Model_Order_Payment|Varien_Object $payment current payment object * @param $amount float amount to capture + * * @return $this + * * @throws \Mage_Core_Exception */ public function capture(Varien_Object $payment, $amount) @@ -852,6 +865,7 @@ public function capture(Varien_Object $payment, $amount) * Calculate whether a order can be captured or not * * @return bool + * * @throws \Mage_Core_Model_Store_Exception */ public function canCapture() @@ -888,8 +902,10 @@ public function canCapture() * Api call for refunding a given invoice * * @param Mage_Sales_Model_Order_Payment|Varien_Object $payment current payment object - * @param float $amount amount to refund + * @param float $amount amount to refund + * * @return $this + * * @throws \Mage_Core_Exception * @throws \Mage_Core_Model_Store_Exception * @throws Zend_Http_Client_Exception @@ -938,7 +954,9 @@ public function refund(Varien_Object $payment, $amount) * * @param Mage_Sales_Model_Order_Invoice $invoice * @param Mage_Sales_Model_Order_Payment $payment + * * @return bool + * * @throws \Mage_Core_Exception * @throws \Mage_Core_Model_Store_Exception */ @@ -994,6 +1012,7 @@ public function reversal(Mage_Sales_Model_Order_Invoice $invoice, Mage_Sales_Mod * Getter for customer given plus family name * * @param bool|Mage_Checkout_Model_Session $session checkout session + * * @return string given plus family name */ public function getCustomerName($session = false) @@ -1015,7 +1034,9 @@ public function getCustomerName($session = false) * * @param $data array additional payment information of the customer * @param null $uniqueId + * * @internal param string $uniqueID payment reference of a account registration + * * @throws \Mage_Core_Model_Store_Exception */ public function saveCustomerData($data, $uniqueId = null) @@ -1072,6 +1093,7 @@ public function showPaymentInfo($paymentData) * @param $message string order history message * * @return Mage_Sales_Model_Order + * * @throws \Mage_Core_Exception * @throws Exception */ @@ -1113,6 +1135,7 @@ public function chargeBackTransaction($order, $message = '') * @param $message string order history message * * @return Mage_Sales_Model_Order + * * @throws \Mage_Core_Exception */ public function canceledTransaction($order, $message) @@ -1134,11 +1157,12 @@ public function canceledTransaction($order, $message) /** * Handle transaction with means processing * - * @param Mage_Sales_Model_Order $order + * @param Mage_Sales_Model_Order $order * @param HeidelpayCD_Edition_Model_Transaction $data - * @param string $message order history message + * @param string $message order history message * * @return Mage_Sales_Model_Order + * * @throws \Mage_Core_Exception * @throws Exception */ @@ -1232,6 +1256,7 @@ public function processingTransaction($order, $data, $message='') * @param $message string order history message * * @return Mage_Sales_Model_Order + * * @throws \Mage_Core_Exception */ public function pendingTransaction($order, $data, $message='') @@ -1287,7 +1312,9 @@ public function isSendingInvoiceMailComment() * Returns true if the payment method is configured to automatically send an invoice email. * * @param $data + * * @return bool + * * @throws Mage_Core_Model_Store_Exception */ protected function isSendingInvoiceAutomatically($data) @@ -1302,6 +1329,7 @@ protected function isSendingInvoiceAutomatically($data) * Returns the id of the current store. * * @return int + * * @throws Mage_Core_Model_Store_Exception */ private function getStoreId() diff --git a/app/code/community/HeidelpayCD/Edition/Model/Payment/AbstractSecuredPaymentMethods.php b/app/code/community/HeidelpayCD/Edition/Model/Payment/AbstractSecuredPaymentMethods.php index 6765fdd..43d9614 100755 --- a/app/code/community/HeidelpayCD/Edition/Model/Payment/AbstractSecuredPaymentMethods.php +++ b/app/code/community/HeidelpayCD/Edition/Model/Payment/AbstractSecuredPaymentMethods.php @@ -103,6 +103,7 @@ public function isAvailable($quote = null) * Validate customer input on checkout * * @return $this + * * @throws \Mage_Core_Exception */ public function validate() @@ -177,6 +178,7 @@ public function showPaymentInfo($paymentData) * @param $message string order history message * * @return Mage_Sales_Model_Order + * * @throws \Mage_Core_Exception */ public function pendingTransaction($order, $data, $message = '') @@ -255,6 +257,7 @@ public function pendingTransaction($order, $data, $message = '') * @param $message string order history message * * @return Mage_Sales_Model_Order + * * @throws \Mage_Core_Exception */ public function processingTransaction($order, $data, $message = '') diff --git a/app/code/community/HeidelpayCD/Edition/Model/Payment/HcdDirectDebitSecured.php b/app/code/community/HeidelpayCD/Edition/Model/Payment/HcdDirectDebitSecured.php index 0e6ab29..0764b47 100755 --- a/app/code/community/HeidelpayCD/Edition/Model/Payment/HcdDirectDebitSecured.php +++ b/app/code/community/HeidelpayCD/Edition/Model/Payment/HcdDirectDebitSecured.php @@ -14,10 +14,8 @@ * @subpackage Magento * @category Magento */ -class HeidelpayCD_Edition_Model_Payment_HcdDirectDebitSecured - extends HeidelpayCD_Edition_Model_Payment_AbstractSecuredPaymentMethods +class HeidelpayCD_Edition_Model_Payment_HcdDirectDebitSecured extends HeidelpayCD_Edition_Model_Payment_AbstractSecuredPaymentMethods { - /** * HeidelpayCD_Edition_Model_Payment_Hcdpp constructor. */ @@ -38,6 +36,7 @@ public function __construct() * Validate customer input on checkout * * @return $this + * * @throws \Mage_Core_Exception */ public function validate() diff --git a/app/code/community/HeidelpayCD/Edition/Model/Payment/HcdInvoiceSecured.php b/app/code/community/HeidelpayCD/Edition/Model/Payment/HcdInvoiceSecured.php index fa7d726..e3c9593 100755 --- a/app/code/community/HeidelpayCD/Edition/Model/Payment/HcdInvoiceSecured.php +++ b/app/code/community/HeidelpayCD/Edition/Model/Payment/HcdInvoiceSecured.php @@ -14,8 +14,7 @@ * @subpackage Magento * @category Magento */ -class HeidelpayCD_Edition_Model_Payment_HcdInvoiceSecured - extends HeidelpayCD_Edition_Model_Payment_AbstractSecuredPaymentMethods +class HeidelpayCD_Edition_Model_Payment_HcdInvoiceSecured extends HeidelpayCD_Edition_Model_Payment_AbstractSecuredPaymentMethods { /** * HeidelpayCD_Edition_Model_Payment_HcdInvoiceSecured constructor. diff --git a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdbs.php b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdbs.php index 24490a6..faf0f16 100755 --- a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdbs.php +++ b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdbs.php @@ -162,6 +162,7 @@ public function getBasket($order) /** * @param $order + * * @return float */ private function getAmountGross($order) @@ -176,6 +177,7 @@ private function getAmountGross($order) } // + /** * Calculate shipping net price * @@ -216,5 +218,6 @@ public function format($number) { return number_format($number, 2, '.', ''); } + // } diff --git a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdcc.php b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdcc.php index 17a24fa..8670fdc 100755 --- a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdcc.php +++ b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdcc.php @@ -44,6 +44,7 @@ public function isRecognition() /** * @return bool payment method will redirect the customer directly to heidelpay + * * @throws \Mage_Core_Model_Store_Exception */ public function activeRedirect() diff --git a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcddc.php b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcddc.php index ccbc036..d7fe3c7 100755 --- a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcddc.php +++ b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcddc.php @@ -16,7 +16,6 @@ */ class HeidelpayCD_Edition_Model_Payment_Hcddc extends HeidelpayCD_Edition_Model_Payment_Abstract { - /** * HeidelpayCD_Edition_Model_Payment_Hcddc constructor. */ @@ -45,6 +44,7 @@ public function isRecognition() /** * @return bool payment method will redirect the customer directly to heidelpay + * * @throws \Mage_Core_Model_Store_Exception */ public function activeRedirect() diff --git a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcddd.php b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcddd.php index 8aa8daf..8627b88 100755 --- a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcddd.php +++ b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcddd.php @@ -36,6 +36,7 @@ public function __construct() * Validate input data from checkout * * @return HeidelpayCD_Edition_Model_Payment_Abstract + * * @throws \Mage_Core_Exception */ public function validate() diff --git a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdeps.php b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdeps.php index 729b282..8f8881d 100755 --- a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdeps.php +++ b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdeps.php @@ -16,7 +16,6 @@ */ class HeidelpayCD_Edition_Model_Payment_Hcdeps extends HeidelpayCD_Edition_Model_Payment_Abstract { - /** * HeidelpayCD_Edition_Model_Payment_Hcdeps constructor. */ @@ -34,6 +33,7 @@ public function __construct() * Validate input data from checkout * * @return HeidelpayCD_Edition_Model_Payment_Abstract + * * @throws \Mage_Core_Exception */ public function validate() diff --git a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdide.php b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdide.php index a1e5bd9..ed00cca 100755 --- a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdide.php +++ b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdide.php @@ -16,7 +16,6 @@ */ class HeidelpayCD_Edition_Model_Payment_Hcdide extends HeidelpayCD_Edition_Model_Payment_Abstract { - /** * HeidelpayCD_Edition_Model_Payment_Hcdide constructor. */ @@ -34,6 +33,7 @@ public function __construct() * Validate input data from checkout * * @return HeidelpayCD_Edition_Model_Payment_Abstract + * * @throws \Mage_Core_Exception */ public function validate() diff --git a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdiv.php b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdiv.php index 731884d..40d63ed 100755 --- a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdiv.php +++ b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdiv.php @@ -61,6 +61,7 @@ public function showPaymentInfo($paymentData) * @param $message string order history message * * @return Mage_Sales_Model_Order + * * @throws \Mage_Core_Exception */ public function pendingTransaction($order, $data, $message = '') @@ -139,6 +140,7 @@ public function pendingTransaction($order, $data, $message = '') * @param $message string order history message * * @return Mage_Sales_Model_Order + * * @throws \Mage_Core_Exception */ public function processingTransaction($order, $data, $message = '') diff --git a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdivpol.php b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdivpol.php index ad5fcc8..4ede3a5 100755 --- a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdivpol.php +++ b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdivpol.php @@ -41,6 +41,7 @@ public function __construct() * @param bool $isReg in case of registration * * @return array + * * @throws \Mage_Core_Exception */ public function getUser($order, $isReg = false) @@ -60,6 +61,7 @@ public function getUser($order, $isReg = false) * Validate customer input on checkout * * @return HeidelpayCD_Edition_Model_Payment_AbstractSecuredPaymentMethods + * * @throws \Mage_Core_Exception */ public function validate() diff --git a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdivsan.php b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdivsan.php index 62d9022..2bf2742 100755 --- a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdivsan.php +++ b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdivsan.php @@ -133,4 +133,4 @@ public function getUser($order, $isReg = false) return $user; } -} \ No newline at end of file +} diff --git a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdmpa.php b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdmpa.php index a2b28af..b43afb1 100755 --- a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdmpa.php +++ b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdmpa.php @@ -16,7 +16,6 @@ */ class HeidelpayCD_Edition_Model_Payment_Hcdmpa extends HeidelpayCD_Edition_Model_Payment_Abstract { - /** * HeidelpayCD_Edition_Model_Payment_Hcdpp constructor. */ @@ -36,9 +35,6 @@ public function __construct() } /** - * public function isAvailable($quote=null) { - * return true; - * } * @return string */ public function getPaymentData() diff --git a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdpf.php b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdpf.php index a606323..eb97798 100755 --- a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdpf.php +++ b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdpf.php @@ -51,6 +51,7 @@ public function isAvailable($quote = null) * Validate input data from checkout * * @return HeidelpayCD_Edition_Model_Payment_Abstract + * * @throws \Mage_Core_Exception */ public function validate() diff --git a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdpp.php b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdpp.php index 9a2854a..4926ee9 100755 --- a/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdpp.php +++ b/app/code/community/HeidelpayCD/Edition/Model/Payment/Hcdpp.php @@ -63,6 +63,7 @@ public function showPaymentInfo($paymentData) * @param $message string order history message * * @return Mage_Sales_Model_Order + * * @throws \Mage_Core_Exception */ public function pendingTransaction($order, $data, $message = '') @@ -116,11 +117,12 @@ public function pendingTransaction($order, $data, $message = '') /** * Handle transaction with means processing * - * @param Mage_Sales_Model_Order $order + * @param Mage_Sales_Model_Order $order * @param HeidelpayCD_Edition_Model_Transaction $data - * @param string $message order history message + * @param string $message order history message * * @return Mage_Sales_Model_Order + * * @throws \Exception * @throws \Mage_Core_Exception */ diff --git a/app/code/community/HeidelpayCD/Edition/Model/Transaction.php b/app/code/community/HeidelpayCD/Edition/Model/Transaction.php index db6e0d7..a57a797 100755 --- a/app/code/community/HeidelpayCD/Edition/Model/Transaction.php +++ b/app/code/community/HeidelpayCD/Edition/Model/Transaction.php @@ -110,6 +110,7 @@ public function loadLastTransactionDataByUniqeId($id) /** * @param $transid * @param $method + * * @return bool|array */ public function getOneTransactionByMethode($transid, $method) diff --git a/app/code/community/HeidelpayCD/Edition/controllers/IndexController.php b/app/code/community/HeidelpayCD/Edition/controllers/IndexController.php index 6d84c8a..9288802 100755 --- a/app/code/community/HeidelpayCD/Edition/controllers/IndexController.php +++ b/app/code/community/HeidelpayCD/Edition/controllers/IndexController.php @@ -53,9 +53,9 @@ protected function _getHelper() /** * HeidelpayCD_Edition_IndexController constructor. * - * @param Zend_Controller_Request_Abstract $request - * @param Zend_Controller_Response_Abstract $response - * @param array $invokeArgs + * @param Zend_Controller_Request_Abstract $request + * @param Zend_Controller_Response_Abstract $response + * @param array $invokeArgs */ // @codingStandardsIgnoreLine bug in multi line standard public function __construct(Zend_Controller_Request_Abstract $request, Zend_Controller_Response_Abstract $response, array $invokeArgs = array()) From 8f522684da5a11901f0e559a0c63d1174cebdf38 Mon Sep 17 00:00:00 2001 From: Simon Gabriel Date: Tue, 16 Apr 2019 14:02:11 +0200 Subject: [PATCH 13/15] [feature] (MAGE-72) Fix santander default channel. --- app/code/community/HeidelpayCD/Edition/etc/config.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/code/community/HeidelpayCD/Edition/etc/config.xml b/app/code/community/HeidelpayCD/Edition/etc/config.xml index e5c56d6..84d0179 100755 --- a/app/code/community/HeidelpayCD/Edition/etc/config.xml +++ b/app/code/community/HeidelpayCD/Edition/etc/config.xml @@ -376,7 +376,7 @@ hcd Rechnungskauf von Santander 0 - 31HA07BC8147472B68A08F10540D7D9F + 31HA07BC81856CAD6D8E07858ACD6CFB 0 0 hcd/payment_hcdivsan From 4fe31bf84bd78335eb7c97411832103529ee04af Mon Sep 17 00:00:00 2001 From: Simon Gabriel Date: Tue, 16 Apr 2019 14:09:55 +0200 Subject: [PATCH 14/15] [feature] (MAGE-72) Disable MEQP1 standard. --- .travis.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index 12a3cca..ea17f5b 100755 --- a/.travis.yml +++ b/.travis.yml @@ -21,7 +21,7 @@ before_install: - composer update before_script: - - ./vendor/bin/phpcs --config-set installed_paths vendor/magento/marketplace-eqp +# - ./vendor/bin/phpcs --config-set installed_paths vendor/magento/marketplace-eqp script: - - ./vendor/bin/phpcs . --ignore=vendor/ -v --standard=MEQP1; \ No newline at end of file + - ./vendor/bin/phpcs . --ignore=vendor/ -v #--standard=MEQP1; \ No newline at end of file From 4d0889f23f6de4f49424ac8098e6d5e8fa57beec Mon Sep 17 00:00:00 2001 From: Simon Gabriel Date: Tue, 16 Apr 2019 14:24:02 +0200 Subject: [PATCH 15/15] [feature] (MAGE-72) Changed cs fixer call. --- .php_cs | 1 + .travis.yml | 3 ++- composer.json | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/.php_cs b/.php_cs index 762014e..62d2844 100755 --- a/.php_cs +++ b/.php_cs @@ -1,6 +1,7 @@ in(__DIR__); + return PhpCsFixer\Config::create() ->setUsingCache(false) ->setRules( diff --git a/.travis.yml b/.travis.yml index ea17f5b..412463d 100755 --- a/.travis.yml +++ b/.travis.yml @@ -24,4 +24,5 @@ before_script: # - ./vendor/bin/phpcs --config-set installed_paths vendor/magento/marketplace-eqp script: - - ./vendor/bin/phpcs . --ignore=vendor/ -v #--standard=MEQP1; \ No newline at end of file + - ./vendor/bin/php-cs-fixer fix --dry-run --diff --verbose +# - ./vendor/bin/phpcs . --ignore=vendor/ -v --standard=MEQP1; \ No newline at end of file diff --git a/composer.json b/composer.json index 64a672b..a6a702b 100755 --- a/composer.json +++ b/composer.json @@ -25,7 +25,7 @@ "require-dev": { "magento/marketplace-eqp": "*", "heidelpay/phpdocumentor": "2.9.1", - "friendsofphp/php-cs-fixer": "2.1.0" + "friendsofphp/php-cs-fixer": "^2.0" }, "repositories": [ {