Class: ShopifyAPI::Payout
- Inherits:
-
Rest::Base
- Object
- Rest::Base
- ShopifyAPI::Payout
- Extended by:
- T::Sig
- Defined in:
- lib/shopify_api/rest/resources/2022_04/payout.rb,
lib/shopify_api/rest/resources/2022_07/payout.rb,
lib/shopify_api/rest/resources/2022_10/payout.rb,
lib/shopify_api/rest/resources/2023_01/payout.rb,
lib/shopify_api/rest/resources/2023_04/payout.rb,
lib/shopify_api/rest/resources/2023_07/payout.rb
Instance Attribute Summary collapse
-
#amount ⇒ Object
readonly
Returns the value of attribute amount.
-
#currency ⇒ Object
readonly
Returns the value of attribute currency.
-
#date ⇒ Object
readonly
Returns the value of attribute date.
-
#id ⇒ Object
readonly
Returns the value of attribute id.
-
#status ⇒ Object
readonly
Returns the value of attribute status.
Attributes inherited from Rest::Base
Class Method Summary collapse
- .all(since_id: nil, last_id: nil, date_min: nil, date_max: nil, date: nil, status: nil, session: ShopifyAPI::Context.active_session, **kwargs) ⇒ Object
- .find(id:, session: ShopifyAPI::Context.active_session) ⇒ Object
Instance Method Summary collapse
-
#initialize(session: ShopifyAPI::Context.active_session) ⇒ Payout
constructor
A new instance of Payout.
Methods inherited from Rest::Base
base_find, class_name, create_instance, create_instances_from_response, #delete, get_path, has_many?, has_one?, json_body_name, json_response_body_names, #method_missing, next_page?, next_page_info, prev_page?, prev_page_info, primary_key, read_only_attributes, request, #respond_to_missing?, #save, #save!, #to_hash
Constructor Details
#initialize(session: ShopifyAPI::Context.active_session) ⇒ Payout
Returns a new instance of Payout.
16 17 18 19 20 21 22 23 24 |
# File 'lib/shopify_api/rest/resources/2022_04/payout.rb', line 16 def initialize(session: ShopifyAPI::Context.active_session) super(session: session) @amount = T.let(nil, T.nilable(String)) @currency = T.let(nil, T.nilable(String)) @date = T.let(nil, T.nilable(String)) @id = T.let(nil, T.nilable(Integer)) @status = T.let(nil, T.nilable(String)) end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class ShopifyAPI::Rest::Base
Instance Attribute Details
#amount ⇒ Object (readonly)
Returns the value of attribute amount.
34 35 36 |
# File 'lib/shopify_api/rest/resources/2022_04/payout.rb', line 34 def amount @amount end |
#currency ⇒ Object (readonly)
Returns the value of attribute currency.
36 37 38 |
# File 'lib/shopify_api/rest/resources/2022_04/payout.rb', line 36 def currency @currency end |
#date ⇒ Object (readonly)
Returns the value of attribute date.
38 39 40 |
# File 'lib/shopify_api/rest/resources/2022_04/payout.rb', line 38 def date @date end |
#id ⇒ Object (readonly)
Returns the value of attribute id.
40 41 42 |
# File 'lib/shopify_api/rest/resources/2022_04/payout.rb', line 40 def id @id end |
#status ⇒ Object (readonly)
Returns the value of attribute status.
42 43 44 |
# File 'lib/shopify_api/rest/resources/2022_04/payout.rb', line 42 def status @status end |
Class Method Details
.all(since_id: nil, last_id: nil, date_min: nil, date_max: nil, date: nil, status: nil, session: ShopifyAPI::Context.active_session, **kwargs) ⇒ Object
75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 |
# File 'lib/shopify_api/rest/resources/2022_04/payout.rb', line 75 def all( since_id: nil, last_id: nil, date_min: nil, date_max: nil, date: nil, status: nil, session: ShopifyAPI::Context.active_session, **kwargs ) response = base_find( session: session, ids: {}, params: {since_id: since_id, last_id: last_id, date_min: date_min, date_max: date_max, date: date, status: status}.merge(kwargs).compact, ) T.cast(response, T::Array[Payout]) end |
.find(id:, session: ShopifyAPI::Context.active_session) ⇒ Object
51 52 53 54 55 56 57 58 59 60 61 |
# File 'lib/shopify_api/rest/resources/2022_04/payout.rb', line 51 def find( id:, session: ShopifyAPI::Context.active_session ) result = base_find( session: session, ids: {id: id}, params: {}, ) T.cast(result[0], T.nilable(Payout)) end |