mirror of
https://github.com/woocommerce/woocommerce-paypal-payments.git
synced 2025-09-06 10:55:00 +08:00
Add "No 3DS" option
This commit is contained in:
parent
0553ea62bf
commit
b988e08c66
2 changed files with 10 additions and 5 deletions
|
@ -103,10 +103,14 @@ class CreditCardRenderer {
|
|||
const save_card = this.defaultConfig.save_card ? true : false;
|
||||
const vault = document.getElementById('ppcp-credit-card-vault') ?
|
||||
document.getElementById('ppcp-credit-card-vault').checked : save_card;
|
||||
hostedFields.submit({
|
||||
contingencies: [this.defaultConfig.hosted_fields.contingency],
|
||||
const contingency = this.defaultConfig.hosted_fields.contingency;
|
||||
const hostedFieldsData = {
|
||||
vault: vault
|
||||
}).then((payload) => {
|
||||
};
|
||||
if (contingency !== 'NO_3D_SECURE') {
|
||||
hostedFieldsData.contingencies = [contingency];
|
||||
}
|
||||
hostedFields.submit(hostedFieldsData).then((payload) => {
|
||||
payload.orderID = payload.orderId;
|
||||
this.spinner.unblock();
|
||||
return contextConfig.onApprove(payload);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue