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

PaymentMethods of type 'ideal' cannot be saved to customers. #298

Open
maartenheideman opened this issue Apr 8, 2024 · 1 comment
Open

Comments

@maartenheideman
Copy link

maartenheideman commented Apr 8, 2024

Description

I'm working on a project to let users subscribe to payed subscriptions featured by stripe. When I try to add a payment source of the type ideal or bancontact I'll recieve an error: PaymentMethods of type ideal cannot be saved to customers. How to solve that, what could be wrong? Creditcard and sepa work perfect. Ill get the message PaymentMethods of type 'ideal' cannot be saved to customer's. on url vendor/craftcms/commerce-stripe/src/gateways/PaymentIntents.php at line 380`

I'll use this form code:

<form method="post" class="form">
    {{ csrfInput() }}
    {{ actionInput('commerce/payment-sources/add') }}
    {{ hiddenInput('gatewayId', plan.gateway.id) }}
    {{ hiddenInput('successMessage', 'Betaalmethode succesvol toegevoegd.') }}
    {{ hiddenInput('cancelUrl', 'account/pay'|hash) }}
    {{ hiddenInput('isPrimaryPaymentSource', 1) }}
    {{ redirectInput('account/pay') }}

    <div class="cards-details__form__fields">
        {% namespace plan.gateway.handle|commercePaymentFormNamespace %}
            {{ plan.gateway.getPaymentFormHtml({
            paymentFormType: 'elements',
            appearance: {
                theme: 'stripe'
            },
            elementOptions: {
                layout: {
                    type: 'tabs',
                    defaultCollapsed: false,
                    radios: false,
                    spacedAccordionItems: false
                }
            },
            submitButtonClasses: 'cards-details__button button',
            submitButtonText: 'Betaalmethode opslaan',
            })|raw }}
        {% endnamespace %}
    </div>
</form>

Steps to reproduce

  1. After login try to add a payment source from the type ideal or bancontact to a user with the from described above.

Additional info

  • Craft CMS version: 4.4.16.1
  • Stripe for Craft Commerce version: 4.1.2.1
  • PHP version: 8.2
  • Database driver & version:
  • Plugins & versions:
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

1 participant