Closed rain2o closed 5 years ago
Ok thanks for looking into this. I suggest we include the method code in the modules vsf config, that way it can be updated as required.
To enable it per store based on the Backend enabled payment methods we can implement some logic for checking if it should be included inside of the component here https://github.com/develodesign/vsf-payment-stripe/blob/master/index.ts
We'll be working on this over the next 4 weeks for another project, please let us know if you can look at it or need any advice on anything.
I will push updates.
@rain2o Ready, you can check on v2.5.0
tag.
Now we use https://stripe.com/docs/plugins/magento/install#download as base backend.
I understand that this module handles the payment side directly with Stripe and simply passes the token to the back-end platform of Vue Storefront on place order. But I'm curious what platforms this module currently supports? In order for it to support a back-end platform it would need to send the payment method code and data according to the platform's requirements.
I notice that the payment method "Stripe" (code
stripe
) is hard-coded to be injected as a payment method with this module. Shouldn't this be coming from the back-end platform's allowed payment methods? There are a few concerns with this approach.stripe
isn't what Stripe's official Magento 2 module uses as the payment method code. They usestripe_payments
for the Credit Card method, and they have a series of other methods available as well.This does add some level of complexity to this if the methods are to be handled dynamically. For starters, the method code might be different for Magento 2 Stripe module vs some other e-commerce platform with Stripe support. I'm not sure if they make this consistent across all platforms or not. Additionally this means the module would need to have some way of ensuring only supported methods via Stripe are utilized. This could be as simple as a disclaimer in the README I suppose, stating which methods are currently supported. But then the logic in the module would need to check the method codes and know what to expect for each one that is supported based on what the platform uses.
I don't have a clear question in this issue (other than what back-end platforms are currently supported if any), and there is no clear answer to all my rambling. But I think this is a good start to a conversation and potential roadmap for this module.