Skip to content

Instantly share code, notes, and snippets.

@vernondegoede
Created March 20, 2018 10:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save vernondegoede/503870a82acd947d2fea420853518de8 to your computer and use it in GitHub Desktop.
Save vernondegoede/503870a82acd947d2fea420853518de8 to your computer and use it in GitHub Desktop.
Create a new Mollie payment
Spree::Payment::Processing.module_eval do
def process!(amount = nil)
amount ||= money.money.cents
started_processing!
response = payment_method.create_transaction(
amount,
source,
gateway_options
)
handle_response(response, :pend, :failure)
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment