Class: Moneytree::Oauth::StripeController
- Inherits:
-
ApplicationController
- Object
- ApplicationController
- ApplicationController
- Moneytree::Oauth::StripeController
- Defined in:
- app/controllers/moneytree/oauth/stripe_controller.rb
Instance Method Summary collapse
Instance Method Details
#callback ⇒ Object
8 9 10 11 12 13 |
# File 'app/controllers/moneytree/oauth/stripe_controller.rb', line 8 def callback # TODO: Remove this module prefix once we figure out how to properly autoload this. payment_gateway = Moneytree::PaymentGateway.create!(psp: 'stripe', account: current_account) payment_gateway.oauth_callback(payment_gateway_params) redirect_to Moneytree.oauth_redirect, notice: 'Connected to Stripe' end |
#new ⇒ Object
4 5 6 |
# File 'app/controllers/moneytree/oauth/stripe_controller.rb', line 4 def new redirect_to stripe_oauth_url end |