Class: PaymentMethod::Pagseguro
- Inherits:
-
PaymentMethod
- Object
- PaymentMethod
- PaymentMethod::Pagseguro
- Defined in:
- app/models/spree/payment_method/pagseguro.rb
Instance Method Summary collapse
- #actions ⇒ Object
- #auto_capture? ⇒ Boolean
-
#can_void?(payment) ⇒ Boolean
Indicates whether its possible to void the payment.
- #cancel(response) ⇒ Object
- #capture(*args) ⇒ Object
- #method_type ⇒ Object
- #payment_profiles_supported? ⇒ Boolean
- #provider ⇒ Object
- #provider_class ⇒ Object
- #source_required? ⇒ Boolean
- #supports?(source) ⇒ Boolean
- #void(*args) ⇒ Object
Instance Method Details
#actions ⇒ Object
49 50 51 |
# File 'app/models/spree/payment_method/pagseguro.rb', line 49 def actions %w(capture void) end |
#auto_capture? ⇒ Boolean
26 27 28 |
# File 'app/models/spree/payment_method/pagseguro.rb', line 26 def auto_capture? false end |
#can_void?(payment) ⇒ Boolean
Indicates whether its possible to void the payment.
35 36 37 |
# File 'app/models/spree/payment_method/pagseguro.rb', line 35 def can_void?(payment) payment.state != 'void' end |
#cancel(response) ⇒ Object
43 |
# File 'app/models/spree/payment_method/pagseguro.rb', line 43 def cancel(response); end |
#capture(*args) ⇒ Object
39 40 41 |
# File 'app/models/spree/payment_method/pagseguro.rb', line 39 def capture(*args) ActiveMerchant::Billing::Response.new(true, "", {}, {}) end |
#method_type ⇒ Object
30 31 32 |
# File 'app/models/spree/payment_method/pagseguro.rb', line 30 def method_type 'pag_seguro' end |
#payment_profiles_supported? ⇒ Boolean
6 7 8 |
# File 'app/models/spree/payment_method/pagseguro.rb', line 6 def payment_profiles_supported? false end |
#provider ⇒ Object
18 19 20 |
# File 'app/models/spree/payment_method/pagseguro.rb', line 18 def provider provider_class.new end |
#provider_class ⇒ Object
14 15 16 |
# File 'app/models/spree/payment_method/pagseguro.rb', line 14 def provider_class Billing::Pagseguro end |
#source_required? ⇒ Boolean
22 23 24 |
# File 'app/models/spree/payment_method/pagseguro.rb', line 22 def source_required? false end |
#supports?(source) ⇒ Boolean
10 11 12 |
# File 'app/models/spree/payment_method/pagseguro.rb', line 10 def supports?(source) true end |
#void(*args) ⇒ Object
45 46 47 |
# File 'app/models/spree/payment_method/pagseguro.rb', line 45 def void(*args) ActiveMerchant::Billing::Response.new(true, "", {}, {}) end |