Class: NimbleshopPaypalwp::Processor
- Inherits:
-
Processor::Base
- Object
- Processor::Base
- NimbleshopPaypalwp::Processor
- Defined in:
- lib/nimbleshop_paypalwp/processor.rb
Instance Attribute Summary collapse
-
#notify ⇒ Object
readonly
Returns the value of attribute notify.
-
#order ⇒ Object
readonly
Returns the value of attribute order.
-
#payment_method ⇒ Object
readonly
Returns the value of attribute payment_method.
Instance Method Summary collapse
-
#initialize(options = {}) ⇒ Processor
constructor
A new instance of Processor.
Constructor Details
#initialize(options = {}) ⇒ Processor
Returns a new instance of Processor.
6 7 8 9 10 11 12 13 14 |
# File 'lib/nimbleshop_paypalwp/processor.rb', line 6 def initialize( = {}) .symbolize_keys! .assert_valid_keys :raw_post raw_post = .fetch :raw_post @notify = ActiveMerchant::Billing::Integrations::Paypal::Notification.new raw_post @order = Order.find_by_number! notify.invoice @payment_method = NimbleshopPaypalwp::Paypalwp.first end |
Instance Attribute Details
#notify ⇒ Object (readonly)
Returns the value of attribute notify.
4 5 6 |
# File 'lib/nimbleshop_paypalwp/processor.rb', line 4 def notify @notify end |
#order ⇒ Object (readonly)
Returns the value of attribute order.
4 5 6 |
# File 'lib/nimbleshop_paypalwp/processor.rb', line 4 def order @order end |
#payment_method ⇒ Object (readonly)
Returns the value of attribute payment_method.
4 5 6 |
# File 'lib/nimbleshop_paypalwp/processor.rb', line 4 def payment_method @payment_method end |