Index: trunk/extensions/DonationInterface/globalcollect_gateway/globalcollect.adapter.php |
— | — | @@ -1710,12 +1710,12 @@ |
1711 | 1711 | } |
1712 | 1712 | |
1713 | 1713 | /** |
1714 | | - * Stage: setup_stage_payment_method_for_direct_debit |
| 1714 | + * Stage: setupStagePaymentMethodForDirectDebit |
1715 | 1715 | * |
1716 | 1716 | * @param string $payment_submethod |
1717 | 1717 | * @param string $type request|response |
1718 | 1718 | */ |
1719 | | - protected function setup_stage_payment_method_for_direct_debit( $payment_submethod, $type = 'request' ) { |
| 1719 | + protected function setupStagePaymentMethodForDirectDebit( $payment_submethod, $type = 'request' ) { |
1720 | 1720 | |
1721 | 1721 | // DATECOLLECT is required on all Direct Debit |
1722 | 1722 | $this->addKeyToTransaction('DATECOLLECT'); |
— | — | @@ -1724,10 +1724,11 @@ |
1725 | 1725 | $this->staged_data['direct_debit_text'] = 'Wikimedia Foundation'; |
1726 | 1726 | |
1727 | 1727 | $this->staged_data['payment_product'] = $this->payment_submethods[ $payment_submethod ]['paymentproductid']; |
1728 | | - $this->data_constraints['IBAN']['length'] = 21; |
1729 | 1728 | $this->var_map['PAYMENTPRODUCTID'] = 'payment_product'; |
1730 | 1729 | $this->var_map['COUNTRYCODEBANK'] = 'country'; |
1731 | 1730 | |
| 1731 | + $this->data_constraints['iban']['length'] = 21; |
| 1732 | + |
1732 | 1733 | // Direct debit has different required fields for each paymentproductid. |
1733 | 1734 | $this->addKeysToTransactionForSubmethod( $payment_submethod ); |
1734 | 1735 | } |
— | — | @@ -1760,47 +1761,47 @@ |
1761 | 1762 | |
1762 | 1763 | /* Direct Debit */ |
1763 | 1764 | case 'dd_nl': |
1764 | | - $this->data_constraints['DIRECTDEBITTEXT']['length'] = 32; |
| 1765 | + $this->data_constraints['direct_debit_text']['length'] = 32; |
1765 | 1766 | |
1766 | | - $this->setup_stage_payment_method_for_direct_debit( $payment_submethod, $type); |
| 1767 | + $this->setupStagePaymentMethodForDirectDebit( $payment_submethod, $type); |
1767 | 1768 | break; |
1768 | 1769 | case 'dd_gb': |
1769 | 1770 | $this->staged_data['transaction_type'] = '01'; |
1770 | 1771 | |
1771 | | - $this->setup_stage_payment_method_for_direct_debit( $payment_submethod, $type); |
| 1772 | + $this->setupStagePaymentMethodForDirectDebit( $payment_submethod, $type); |
1772 | 1773 | break; |
1773 | 1774 | case 'dd_at': |
1774 | | - $this->data_constraints['DIRECTDEBITTEXT']['length'] = 28; |
| 1775 | + $this->data_constraints['direct_debit_text']['length'] = 28; |
1775 | 1776 | |
1776 | | - $this->setup_stage_payment_method_for_direct_debit( $payment_submethod, $type); |
| 1777 | + $this->setupStagePaymentMethodForDirectDebit( $payment_submethod, $type); |
1777 | 1778 | break; |
1778 | 1779 | case 'dd_be': |
1779 | 1780 | |
1780 | | - $this->setup_stage_payment_method_for_direct_debit( $payment_submethod, $type); |
| 1781 | + $this->setupStagePaymentMethodForDirectDebit( $payment_submethod, $type); |
1781 | 1782 | break; |
1782 | 1783 | case 'dd_ch': |
1783 | 1784 | |
1784 | | - $this->setup_stage_payment_method_for_direct_debit( $payment_submethod, $type); |
| 1785 | + $this->setupStagePaymentMethodForDirectDebit( $payment_submethod, $type); |
1785 | 1786 | break; |
1786 | 1787 | case 'dd_de': |
1787 | 1788 | |
1788 | | - $this->setup_stage_payment_method_for_direct_debit( $payment_submethod, $type); |
| 1789 | + $this->setupStagePaymentMethodForDirectDebit( $payment_submethod, $type); |
1789 | 1790 | break; |
1790 | 1791 | case 'dd_es': |
1791 | | - $this->data_constraints['DIRECTDEBITTEXT']['length'] = 40; |
| 1792 | + $this->data_constraints['direct_debit_text']['length'] = 40; |
1792 | 1793 | |
1793 | | - $this->setup_stage_payment_method_for_direct_debit( $payment_submethod, $type); |
| 1794 | + $this->setupStagePaymentMethodForDirectDebit( $payment_submethod, $type); |
1794 | 1795 | break; |
1795 | 1796 | case 'dd_fr': |
1796 | | - $this->data_constraints['DIRECTDEBITTEXT']['length'] = 18; |
| 1797 | + $this->data_constraints['direct_debit_text']['length'] = 18; |
1797 | 1798 | |
1798 | | - $this->setup_stage_payment_method_for_direct_debit( $payment_submethod, $type); |
| 1799 | + $this->setupStagePaymentMethodForDirectDebit( $payment_submethod, $type); |
1799 | 1800 | break; |
1800 | 1801 | case 'dd_it': |
1801 | | - $this->data_constraints['BANKCHECKDIGIT']['length'] = 1; |
1802 | | - $this->data_constraints['DIRECTDEBITTEXT']['length'] = 32; |
| 1802 | + $this->data_constraints['bank_check_digit']['length'] = 1; |
| 1803 | + $this->data_constraints['direct_debit_text']['length'] = 32; |
1803 | 1804 | |
1804 | | - $this->setup_stage_payment_method_for_direct_debit( $payment_submethod, $type); |
| 1805 | + $this->setupStagePaymentMethodForDirectDebit( $payment_submethod, $type); |
1805 | 1806 | break; |
1806 | 1807 | |
1807 | 1808 | /* Online bank transfer */ |