Module: Przelewy24PaymentController::InstanceMethods
- Defined in:
- lib/przelewy24_payment/przelewy24_payment_controller.rb
Overview
ClassMethods
Instance Method Summary collapse
- #comeback ⇒ Object
- #payment_error(payment_params, code, description) ⇒ Object
- #payment_success(payment_params) ⇒ Object
- #payment_verify(response_params) ⇒ Object
Instance Method Details
#comeback ⇒ Object
25 26 27 28 29 30 31 32 33 |
# File 'lib/przelewy24_payment/przelewy24_payment_controller.rb', line 25 def comeback @response = przelewy24_verify(params) result = @response.split("\r\n") if result[1] == "TRUE" payment_success(params) else payment_error(params, :error_code => result[2], :error_descr => result[3]) end end |
#payment_error(payment_params, code, description) ⇒ Object
18 19 |
# File 'lib/przelewy24_payment/przelewy24_payment_controller.rb', line 18 def payment_error(payment_params, code, description) end |
#payment_success(payment_params) ⇒ Object
15 16 |
# File 'lib/przelewy24_payment/przelewy24_payment_controller.rb', line 15 def payment_success(payment_params) end |
#payment_verify(response_params) ⇒ Object
21 22 23 |
# File 'lib/przelewy24_payment/przelewy24_payment_controller.rb', line 21 def payment_verify(response_params) return data = { :amount => 100.0, :crc_key => '' } end |