Class: LockstepSdk::PayablesSummaryReportModel
- Inherits:
-
Object
- Object
- LockstepSdk::PayablesSummaryReportModel
- Defined in:
- lib/lockstep_sdk/models/payables_summary_report_model.rb
Overview
Represents the payables summary report based on a timeframe
Instance Attribute Summary collapse
-
#base_currency_code ⇒ String
The base currency code of the group.
-
#group_key ⇒ Uuid
The GroupKey uniquely identifies a single Lockstep Platform account.
-
#timeframe ⇒ Int32
Timeframe in days the payables summary report is generated on.
-
#total_amount_billed ⇒ Double
Amount of bills received based in the timeframe in the group’s base currency.
-
#total_bills_count ⇒ Int32
Number of bills received in the timeframe.
-
#total_payments_amount ⇒ Double
Amount of payments made based in the timeframe in the group’s base currency.
-
#total_payments_count ⇒ Int32
Number of payments made based in the timeframe.
Instance Method Summary collapse
-
#as_json(options = {}) ⇒ object
This object as a JSON key-value structure.
-
#initialize(params = {}) ⇒ PayablesSummaryReportModel
constructor
Initialize the PayablesSummaryReportModel using the provided prototype.
-
#to_json(*options) ⇒ String
This object converted to a JSON string.
Constructor Details
#initialize(params = {}) ⇒ PayablesSummaryReportModel
Initialize the PayablesSummaryReportModel using the provided prototype
25 26 27 28 29 30 31 32 33 |
# File 'lib/lockstep_sdk/models/payables_summary_report_model.rb', line 25 def initialize(params = {}) @group_key = params.dig(:group_key) @timeframe = params.dig(:timeframe) @base_currency_code = params.dig(:base_currency_code) @total_payments_amount = params.dig(:total_payments_amount) @total_payments_count = params.dig(:total_payments_count) @total_amount_billed = params.dig(:total_amount_billed) @total_bills_count = params.dig(:total_bills_count) end |
Instance Attribute Details
#base_currency_code ⇒ String
Returns The base currency code of the group.
45 46 47 |
# File 'lib/lockstep_sdk/models/payables_summary_report_model.rb', line 45 def base_currency_code @base_currency_code end |
#group_key ⇒ Uuid
Returns The GroupKey uniquely identifies a single Lockstep Platform account. All records for this account will share the same GroupKey value. GroupKey values cannot be changed once created. For more information, see [Accounts and GroupKeys](developer.lockstep.io/docs/accounts-and-groupkeys).
37 38 39 |
# File 'lib/lockstep_sdk/models/payables_summary_report_model.rb', line 37 def group_key @group_key end |
#timeframe ⇒ Int32
Returns Timeframe in days the payables summary report is generated on.
41 42 43 |
# File 'lib/lockstep_sdk/models/payables_summary_report_model.rb', line 41 def timeframe @timeframe end |
#total_amount_billed ⇒ Double
Returns Amount of bills received based in the timeframe in the group’s base currency.
57 58 59 |
# File 'lib/lockstep_sdk/models/payables_summary_report_model.rb', line 57 def total_amount_billed @total_amount_billed end |
#total_bills_count ⇒ Int32
Returns Number of bills received in the timeframe.
61 62 63 |
# File 'lib/lockstep_sdk/models/payables_summary_report_model.rb', line 61 def total_bills_count @total_bills_count end |
#total_payments_amount ⇒ Double
Returns Amount of payments made based in the timeframe in the group’s base currency.
49 50 51 |
# File 'lib/lockstep_sdk/models/payables_summary_report_model.rb', line 49 def total_payments_amount @total_payments_amount end |
#total_payments_count ⇒ Int32
Returns Number of payments made based in the timeframe.
53 54 55 |
# File 'lib/lockstep_sdk/models/payables_summary_report_model.rb', line 53 def total_payments_count @total_payments_count end |
Instance Method Details
#as_json(options = {}) ⇒ object
Returns This object as a JSON key-value structure.
65 66 67 68 69 70 71 72 73 74 75 |
# File 'lib/lockstep_sdk/models/payables_summary_report_model.rb', line 65 def as_json(={}) { 'groupKey' => @group_key, 'timeframe' => @timeframe, 'baseCurrencyCode' => @base_currency_code, 'totalPaymentsAmount' => @total_payments_amount, 'totalPaymentsCount' => @total_payments_count, 'totalAmountBilled' => @total_amount_billed, 'totalBillsCount' => @total_bills_count, } end |
#to_json(*options) ⇒ String
Returns This object converted to a JSON string.
79 80 81 |
# File 'lib/lockstep_sdk/models/payables_summary_report_model.rb', line 79 def to_json(*) "[#{as_json(*).to_json(*)}]" end |