mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-09 03:14:30 -04:00
Merge pull request #6149 from beganovich/v5-2806-wepay-ach
(v5) Preselect the first token on WePay ACH payment page
This commit is contained in:
commit
1915a15ee1
@ -53,5 +53,14 @@
|
|||||||
document.getElementById('pay-now').addEventListener('click', function () {
|
document.getElementById('pay-now').addEventListener('click', function () {
|
||||||
document.getElementById('server-response').submit();
|
document.getElementById('server-response').submit();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
document.addEventListener('DOMContentLoaded', () => {
|
||||||
|
let firstAccount = document
|
||||||
|
.querySelector('.toggle-payment-with-token')
|
||||||
|
|
||||||
|
firstAccount.checked = true;
|
||||||
|
|
||||||
|
document.querySelector('input[name=source]').value = firstAccount.dataset.token;
|
||||||
|
});
|
||||||
</script>
|
</script>
|
||||||
@endpush
|
@endpush
|
||||||
|
Loading…
x
Reference in New Issue
Block a user