Closed (fixed)
Project:
Commerce Authorize.Net
Version:
8.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
10 Nov 2017 at 02:09 UTC
Updated:
20 Dec 2017 at 18:14 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
nikathoneAnd here is the patch.
Comment #3
nikathoneTo be accurate this patch also will enable the submit button back. Otherwise the user is forced to reload the form in order to submit again in case there is an error.
Comment #4
nikathoneAdding parent issue.
Comment #5
bradjones1Here's a similar, but different, approach which more closely follows the example in Stripe. Same idea though... perhaps Matt/maintainers have a preference.
Comment #6
nikathone@bradjones1 noticed that you did removed the
This will cause the form to submit though and we don't want that cause of the error.
Comment #7
bradjones1eventisn't in scope, so it was erroring, at least in Firefox. The default submit functionality is short-circuited already by the library.Comment #8
mglamanGiving this a look over.
Comment #9
mglamanFirst realization:
Braintree, Square, Authorize.net, and Stripe are having to rethink the way to display errors. We need an error handling library in Commerce itself which renders the display message.
I think this is really important, making sure that the screen scrolls to errors.
I think both solutions are viable for people to use. They're pretty close in implementation. I'd like to talk to bojanz to see if we could make a core fix in Commerce that could be part of 2.2, which is slated to release December 6th.
Comment #10
bradjones1Most of this was lifted from Stripe, apparently, so abstracting this to something in payments core would probably make sense.
Glad you agree on the scrolling piece; I wondered if that was too bespoke but there's nothing else to indicate to the user that the submission a) did anything and b) resulted in an error.
Comment #11
mglamanI like #9. I'd like to get feedback from some others. I do not have the time to manually test right now.
Comment #12
mglamanNeither patch applied nor provided same error response handling for eCheck. Rerolled. Testing
Comment #13
nikathoneFirst argument is suppose to be the error code but we are sending error text message.
Comment #14
mglamanLooks good! Thanks for catching that. Addressed.
Comment #16
mglamanFixed! Thank you both.