First generartion of final js
This commit is contained in:
parent
360282dce4
commit
01fbebb42e
|
|
@ -83,7 +83,6 @@ class BACS
|
|||
'payment_hash' => $this->stripe->payment_hash->hash,
|
||||
'gateway_type_id' => GatewayType::BACS,
|
||||
],
|
||||
'confirm' => true,
|
||||
];
|
||||
|
||||
$data['intent'] = $this->stripe->createPaymentIntent($payment_intent_data);
|
||||
|
|
|
|||
|
|
@ -48,6 +48,17 @@ class ProcessBACS {
|
|||
this.payNowButton.disabled = true;
|
||||
this.payNowButton.querySelector('svg').classList.remove('hidden');
|
||||
this.payNowButton.querySelector('span').classList.add('hidden');
|
||||
|
||||
this.stripe.confirmBecsDebitPayment(
|
||||
document.querySelector('meta[name=pi-client-secret').content,
|
||||
{}
|
||||
).then((result) => {
|
||||
if (result.error) {
|
||||
return this.handleFailure(result.error.message);
|
||||
}
|
||||
|
||||
return this.handleSuccess(result);
|
||||
});
|
||||
}
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -48,6 +48,17 @@ class ProcessBACS {
|
|||
this.payNowButton.disabled = true;
|
||||
this.payNowButton.querySelector('svg').classList.remove('hidden');
|
||||
this.payNowButton.querySelector('span').classList.add('hidden');
|
||||
|
||||
this.stripe.confirmBecsDebitPayment(
|
||||
document.querySelector('meta[name=pi-client-secret').content,
|
||||
{}
|
||||
).then((result) => {
|
||||
if (result.error) {
|
||||
return this.handleFailure(result.error.message);
|
||||
}
|
||||
|
||||
return this.handleSuccess(result);
|
||||
});
|
||||
}
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue