Class: Spree::Payments::Create
- Inherits:
-
Object
- Object
- Spree::Payments::Create
- Includes:
- ServiceModule::Base
- Defined in:
- app/services/spree/payments/create.rb
Instance Method Summary collapse
Methods included from ServiceModule::Base
Instance Method Details
#call(order:, params: {}) ⇒ Object
6 7 8 9 10 11 12 |
# File 'app/services/spree/payments/create.rb', line 6 def call(order:, params: {}) ApplicationRecord.transaction do run :prepare_payment_attributes run :find_or_create_payment_source run :save_payment end end |