Class: MC2P::RefundCaptureVoidObjectItemMixin
- Inherits:
-
ObjectItemMixin
- Object
- ObjectItemMixin
- MC2P::RefundCaptureVoidObjectItemMixin
- Defined in:
- lib/mixins.rb
Overview
Allows make refund, capture and void an object item
Instance Attribute Summary
Attributes inherited from ObjectItemMixin
#_deleted, #json_dict, #resource
Instance Method Summary collapse
-
#capture(data = nil) ⇒ Object
- Capture the object item Params:
data
-
data to send Returns: response dictionary.
- Capture the object item Params:
-
#refund(data = nil) ⇒ Object
- Refund the object item Params:
data
-
data to send Returns: response dictionary.
- Refund the object item Params:
-
#void(data = nil) ⇒ Object
- Void the object item Params:
data
-
data to send Returns: response dictionary.
- Void the object item Params:
Methods inherited from ObjectItemMixin
#id_required_and_not_deleted, #initialize, #to_s
Constructor Details
This class inherits a constructor from MC2P::ObjectItemMixin
Instance Method Details
#capture(data = nil) ⇒ Object
Capture the object item Params:
data
-
data to send
Returns: response dictionary
109 110 111 112 113 114 115 |
# File 'lib/mixins.rb', line 109 def capture(data = nil) id_required_and_not_deleted @resource.capture( @json_dict[@id_property], data ) end |
#refund(data = nil) ⇒ Object
Refund the object item Params:
data
-
data to send
Returns: response dictionary
97 98 99 100 101 102 103 |
# File 'lib/mixins.rb', line 97 def refund(data = nil) id_required_and_not_deleted @resource.refund( @json_dict[@id_property], data ) end |
#void(data = nil) ⇒ Object
Void the object item Params:
data
-
data to send
Returns: response dictionary
121 122 123 124 125 126 127 |
# File 'lib/mixins.rb', line 121 def void(data = nil) id_required_and_not_deleted @resource.void( @json_dict[@id_property], data ) end |