mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2024-11-10 05:02:36 +01:00
Fixes for js
This commit is contained in:
parent
33764a4828
commit
aab55a9346
21
public/js/clients/payments/stripe-bacs.js
vendored
21
public/js/clients/payments/stripe-bacs.js
vendored
@ -50,15 +50,20 @@ class ProcessBACS {
|
||||
this.payNowButton.disabled = true;
|
||||
this.payNowButton.querySelector('svg').classList.remove('hidden');
|
||||
this.payNowButton.querySelector('span').classList.add('hidden');
|
||||
this.stripe.confirmBacsDebitPayment(
|
||||
document.querySelector('meta[name=pi-client-secret]').content, {
|
||||
payment_method: token}).then((result) => {
|
||||
if (result.error) {
|
||||
return this.handleFailure(result.error.message);
|
||||
}
|
||||
this.stripe
|
||||
.confirmBacsDebitPayment(
|
||||
document.querySelector('meta[name=pi-client-secret')
|
||||
.content, {
|
||||
payment_method: document.querySelector('input[name=token]').value
|
||||
}
|
||||
)
|
||||
.then((result) => {
|
||||
if (result.error) {
|
||||
return this.handleFailure(result.error.message);
|
||||
}
|
||||
|
||||
return this.handleSuccess(result);
|
||||
});
|
||||
return this.handleSuccess(result);
|
||||
});
|
||||
});
|
||||
}
|
||||
};
|
||||
|
21
resources/js/clients/payments/stripe-bacs.js
vendored
21
resources/js/clients/payments/stripe-bacs.js
vendored
@ -50,15 +50,20 @@ class ProcessBACS {
|
||||
this.payNowButton.disabled = true;
|
||||
this.payNowButton.querySelector('svg').classList.remove('hidden');
|
||||
this.payNowButton.querySelector('span').classList.add('hidden');
|
||||
this.stripe.confirmBacsDebitPayment(
|
||||
document.querySelector('meta[name=pi-client-secret]').content, {
|
||||
payment_method: token}).then((result) => {
|
||||
if (result.error) {
|
||||
return this.handleFailure(result.error.message);
|
||||
}
|
||||
this.stripe
|
||||
.confirmBacsDebitPayment(
|
||||
document.querySelector('meta[name=pi-client-secret')
|
||||
.content, {
|
||||
payment_method: document.querySelector('input[name=token]').value
|
||||
}
|
||||
)
|
||||
.then((result) => {
|
||||
if (result.error) {
|
||||
return this.handleFailure(result.error.message);
|
||||
}
|
||||
|
||||
return this.handleSuccess(result);
|
||||
});
|
||||
return this.handleSuccess(result);
|
||||
});
|
||||
});
|
||||
}
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user