Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Warren Harding 132 posts 275 karma points
    Sep 23, 2021 @ 02:47
    Warren Harding
    0

    Skip payment method step

    Hi there - is there a way to skip the Payment Method page if we are only offering credit card payment?

    Thank you

  • Matt Brailsford 4124 posts 22215 karma points MVP 9x c-trib
    Sep 23, 2021 @ 13:57
    Matt Brailsford
    0

    Is this a custom integration? or are you meaning with Vendr Checkout package?

  • Warren Harding 132 posts 275 karma points
    Sep 23, 2021 @ 23:30
    Warren Harding
    0

    Ah yes sorry - I forget it's a seperate package Can that stage be skipped if I've set credit card as the default?

  • Matt Brailsford 4124 posts 22215 karma points MVP 9x c-trib
    Sep 24, 2021 @ 08:15
    Matt Brailsford
    0

    Hey Warren

    Unfortunately it's not quite built to do that I don't think.

    You might be able to just unpublished the Payment Method page, but you'll also need to disable some event handlers we have in place https://github.com/vendrhub/vendr-checkout/blob/dev/src/Vendr.Checkout/Events/ResetPaymentAndShippingMethods.cs

    We use those to clear the payment / shipping methods at different stages throughout the checkout flow as changes in the billing / shipping location could affect previously selected options, so we just clear them.

    You'll have to try disabling them via code in a composer

    composition.WithNotificationEvent<OrderPaymentCountryRegionChangingNotification>()
        .RemoveHandler<OrderPaymentCountryRegionChangingHandler>();
    

    You'll need to do this for every event that needs removing though, and you may need to add your own so that the shipping methods continue to be cleared.

    Matt

Please Sign in or register to post replies

Write your reply to:

Draft