Hi,
Problem
Currently, when there is only one payment gateway available, the checkout pane Payment information become empty. This is a little disturbing for users, who can't see the payment gateway. And because this empty fieldset. The first reaction is "hey what's the problem ? Why this empty pane" :-)
Proposal
Add a configuration option on the checkout pane payment_information, option which permit to always display payment gateway / method even if there is only a single gateway available for the current user.
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | 2907504-2.patch | 3.09 KB | flocondetoile |
Issue fork commerce-2907504
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
flocondetoileThe patch to review.
Thanks
Comment #3
flocondetoileComment #4
grimreaperThanks for the patch.
Works for me! ;)
Here is my review.
Why this check? On the submitConfigurationForm method, the form has already been validated, no?
Comment #5
flocondetoileIn fact I wonder even if this need to be configurable. I don't understand why we should hide the payment method if there is only one method available. The customer should see what is the payment method available even if there is only one. Thoughts ?
Comment #6
bojanz commentedIn general it doesn't make a lot of sense to show a single radio button to users. The assumption was this can happen only in specific circumstances:
1) You have a single off-site gateway.
2) You have a single on-site gateway, and you have no payment methods (so your only option is "Add credit card")
You appear to have a situation that wasn't considered: An on-site gateway where there are payment methods, but no option to add new. How does that happen? Gift cards?
I agree that if the single radio is a payment method, it's not a good idea to hide it, cause we're missing vital information, and such a thing doesn't need to be configurable.
Comment #7
flocondetoileThe use case was a single off-site gateway (Paypal to be more precise) for a DrupalCamp site.
But you display an information to users about the gateway which will be used. It's a information which can have sens (Have I a paypal acocunt for example, before going to the payment step).
Comment #8
flocondetoileFixing issue summary / title (about payment gateway vs method)
Comment #9
flocondetoileComment #10
bojanz commentedI think that what you want is this issue: #2858179: Allow gateways to show text at checkout (in PaymentInformation). Gateway provided help text would be shown even if the radio selection is hidden.
I would need more community feedback before changing the current radio logic. It was made as a direct response to the 1.x community requests, such as #2505101: If only one (required) payment option, hide the selector. I'll ask people at DrupalCon Nashville.
Comment #11
init90Thanks, @flocondetoile!
I have payment methods filtering based on product types added to the cart. In some cases may leave only one payment method and it looks quite confusing when the place, where early were shown payment methods, is empty.
Comment #12
odizle commentedI agree that having a single radion button does not make sense, but having an empty "Payment information" pane is confusing.
From a UX perspective, I think it's better to show the customer the payment option even is not selected and only one is available.
In my case, the website only accepts PayPal and since there is no need for a billing address, the "payment information" pane is empty which makes the page looks like something is missing.
Comment #13
no sssweat commentedTotally agree!
Better yet, if there is nothing to fill or select, how about skipping the step altogether?
Assuming you only have 1 payment gateway then simply disable the "Payment information" pane in the checkout flow.
But if you have multiple payment gateways that may appear based on conditionals, then the previous paragraph wouldn't do. But perhaps if there is a way to programmatically skip the step if only 1 payment gateway shows up, that would be the desirable solution IMO.
Comment #14
rongok commentedIf "Payment information" pane is disable in the checkout flow, orders are completed without processing any payments.
Comment #15
pslcbs commentedIn my opinion it makes more than sense to show all the critical information to a customer, and payment gateway is in that club.
I think the solution on patch is the best way to, at least, have the option to display your single payment gateway to your customer.
Patch #2 works perfect for me, thanks!! ;-)
Comment #16
lukasss commented+ 1 for this
Comment #17
littlepixiez commentedI definitely think we need to have a radio button appear for just one payment gateway. It looks like the checkout is broken if it is empty... And we don't necessarily want a description for our payment gateways either.
We need "PayPal" to appear so they can continue to the review step and know what they're committing to on the next step. They may not want to use PayPal, or may not even have it. I think it's crucial we display the payment gateway on this pane regardless of count.
Many ++++s for #2 being committed! :)
Comment #18
poker10 commented+1 for this patch and the configuration option. It is important to display such information to the Customer, otherwise it can cause confusion (why are payment methods missing?, what I have selected?, etc..).
Comment #19
kopeboyYep, seconding this as well.
In my case with bank transfer payment the user has no instructions before having completed the checkout, which is very confusing.
Comment #20
aasarava commented+1 for the patch. This makes a lot of sense, especially if you're using something like PayPal as a gateway, which takes care of accepting payment via PayPal, Venmo, credit card, etc. Those aren't set up as multiple gateways -- it's all a single gateway as far as Commerce is concerned.
Comment #21
joe huggansTested this and it works well for me. Thanks
Comment #22
xperd commentedComment #23
xperd commentedWhat needs to be done with the patch?
Customer must see available payment gateway, even if there is only one.
Comment #24
jsacksick commentedComment #26
jsacksick commentedOpened an MR against 3.0.x, patch had to be rerolled and made a few adjusments to it. If the tests are green, I'll commit the change.
Comment #28
jsacksick commented@flocondetoile: Committed the rerolled patch, thank you! 🎉
Comment #29
flocondetoileYouhou ! My older issue I believe :-) Thanks !
Comment #30
ramlev commentedThe patch also merges in 2.x branch. Thank you.