Template:2012FR/Form-section/Processing/Default: Difference between revisions
Jump to navigation
Jump to search
Content deleted Content added
No edit summary |
remove paypal_ec override for Japan, it's default everywhere now |
||
(9 intermediate revisions by the same user not shown) | |||
Line 9: | Line 9: | ||
donationForm.redirectPayment = function(paymentMethod, paymentSubMethod, skipValidation) { |
donationForm.redirectPayment = function(paymentMethod, paymentSubMethod, skipValidation) { |
||
⚫ | |||
⚫ | |||
⚫ | |||
var form = document.paypalcontribution; // we should really change this some day |
var form = document.paypalcontribution; // we should really change this some day |
||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
form.currency_code.value = '</html>{{{currency|USD}}}<html>'; |
|||
⚫ | |||
⚫ | |||
form.currency_code.value = '</html>{{{currency|USD}}}<html>'; |
|||
} |
|||
⚫ | |||
⚫ | |||
paymentSubMethod = ''; |
|||
⚫ | |||
} |
|||
⚫ | |||
⚫ | |||
⚫ | |||
} |
|||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
// Astropay overrides |
|||
⚫ | |||
if ( country === 'AR' || country === 'CL' || country === 'CO' || country === 'MX' || country === 'UY' ) { |
|||
paymentMethod = 'cc'; |
|||
form. |
form.payment_method.value = 'cc'; |
||
⚫ | |||
⚫ | |||
} |
} |
||
⚫ | |||
⚫ | |||
⚫ | |||
frequency = 'onetime'; |
|||
⚫ | |||
⚫ | |||
} |
|||
form.payment_method.value = paymentMethod; |
|||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
if( frequency !== 'monthly' ){ |
|||
⚫ | |||
⚫ | |||
⚫ | |||
} |
|||
} else { |
|||
form.recurring.value = 'true'; |
|||
} |
} |
||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
if ( form.recurring.value == 'true' ) { |
|||
⚫ | |||
⚫ | |||
if ( paymentSubMethod ) { |
|||
full_dotted_payment_method = form.payment_method.value + '.' + paymentSubMethod; |
|||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
form.method = "GET"; |
form.method = "GET"; |
||
form.submit(); |
form.submit(); |
Revision as of 18:19, 8 March 2018