Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

disabled form represents a problem #408

Closed
proseLA opened this issue Mar 25, 2024 · 0 comments
Closed

disabled form represents a problem #408

proseLA opened this issue Mar 25, 2024 · 0 comments

Comments

@proseLA
Copy link
Contributor

proseLA commented Mar 25, 2024

square_webPay really has no control over the square javascript.

if there is an error in the square fields, and the user submits the form, square will notify the user and do it all in javascript.

i am also throwing an error in the console.

however, at this point, you have created an overlay and disabled all other fields. (line 435)

if (flagOnSubmit) {
var formPassed = check_form();
zcLog2Console('Form checked, passed ('+formPassed+')');
if (formPassed) {
// -----
// If we're submitting based on a "Confirm Order" button-click,
// activate the OPC overlay, disable that button and set the document's
// cursor to the 'wait' state.
//
if (submit_type === 'confirm') {
jQuery('*').css('cursor', 'wait');
jQuery('#checkoutPayment > .opc-overlay').addClass('active');
jQuery('#opc-order-confirm').attr('disabled', true);
}
jQuery('#confirm-the-order').attr('disabled', false);
// -----
// If the currently-selected payment method handles the submission of the
// payment-form, defer the submission to its handling.
//
if (paymentMethodHandlesSubmit == true) {
zcLog2Console('Deferring form submittal to the currently-selected payment method.');
} else {
jQuery('form[name="checkout_payment"]').submit();
}
}
}

i am not sure how we can get the 2 javascripts to talk nice to each other, so that the overlay does not happen and once can continue on.

perhaps a screencast will help demonstrate the problem.

@lat9 lat9 added the bug label Mar 28, 2024
@lat9 lat9 added this to the v2.5.1 milestone Mar 28, 2024
@lat9 lat9 closed this as completed in b87bdc7 Apr 4, 2024
lat9 added a commit that referenced this issue Apr 4, 2024
2 bugs in squareWebPay interoperation; fixes #408
@lat9 lat9 reopened this Apr 4, 2024
@lat9 lat9 closed this as completed Apr 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants