Class: LockstepSdk::ApHeaderInfoModel
- Inherits:
-
Object
- Object
- LockstepSdk::ApHeaderInfoModel
- Defined in:
- lib/lockstep_sdk/models/ap_header_info_model.rb
Overview
Aggregated Accounts Payable information.
Instance Attribute Summary collapse
-
#advance_payment_amount_past_thirty_days ⇒ Double
The amount in advance from the payments made over the past thirty days.
-
#amount_billed_past_thirty_days ⇒ Double
The total amount billed over the past thirty days.
-
#amount_due_past_thirty_days ⇒ Double
The amount outstanding on the bills received over the past thirty days.
-
#amount_paid_past_thirty_days ⇒ Double
The total amount paid over the past thirty days.
-
#billing_vendors_past_thirty_days ⇒ Int32
The number of vendors that sent bills over the the past thirty days.
-
#bills_paid_past_thirty_days ⇒ Int32
The number of bills paid over the past thirty days.
-
#bills_past_thirty_days ⇒ Int32
The number of bills received over the past thirty days.
-
#group_key ⇒ Uuid
The GroupKey uniquely identifies a single Lockstep Platform account.
-
#percentage_of_total_ap ⇒ Double
Portion of Total AP that is Past due.
-
#percentage_of_total_ap90_days_past_due ⇒ Double
Portion of Total AP that is 90+ days Past due.
-
#report_period ⇒ Date-time
The date of the report.
-
#total_advance_payments ⇒ Double
The total number of advance payments.
-
#total_ap_amount ⇒ Double
The total accounts payable amount.
-
#total_billed_amount ⇒ Double
The total amount billed.
-
#total_billed_amount_current_year ⇒ Double
The total amount billed, due this year.
-
#total_billed_amount_previous_year ⇒ Double
The total amount billed, due last year.
-
#total_bills ⇒ Int32
The total number of bills.
-
#total_bills90_days_past_due ⇒ Int32
The number of bills 90+ days past due.
-
#total_bills_paid ⇒ Int32
The number of paid bills.
-
#total_bills_past_due ⇒ Int32
The number of past due bills.
-
#total_paid ⇒ Double
The total amount paid.
-
#total_paid_amount_current_year ⇒ Double
The total of all payments made this year.
-
#total_past_due_amount ⇒ Double
The total amount past due.
-
#total_past_due_amount90_days ⇒ Double
The total amount for bills 90+ days past due.
-
#total_vendors ⇒ Int32
The total number of vendors.
-
#vendors_paid_past_thirty_days ⇒ Int32
The number of vendors who were paid within the past thirty days.
Instance Method Summary collapse
-
#as_json(options = {}) ⇒ object
This object as a JSON key-value structure.
-
#initialize(params = {}) ⇒ ApHeaderInfoModel
constructor
Initialize the ApHeaderInfoModel using the provided prototype.
-
#to_json(*options) ⇒ String
This object converted to a JSON string.
Constructor Details
#initialize(params = {}) ⇒ ApHeaderInfoModel
Initialize the ApHeaderInfoModel using the provided prototype
25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 25 def initialize(params = {}) @group_key = params.dig(:group_key) @report_period = params.dig(:report_period) @total_vendors = params.dig(:total_vendors) @total_bills = params.dig(:total_bills) @total_billed_amount = params.dig(:total_billed_amount) @total_advance_payments = params.dig(:total_advance_payments) @total_paid = params.dig(:total_paid) @total_ap_amount = params.dig(:total_ap_amount) @total_bills_paid = params.dig(:total_bills_paid) @total_bills_past_due = params.dig(:total_bills_past_due) @total_bills90_days_past_due = params.dig(:total_bills90_days_past_due) @total_past_due_amount = params.dig(:total_past_due_amount) @total_past_due_amount90_days = params.dig(:total_past_due_amount90_days) @percentage_of_total_ap = params.dig(:percentage_of_total_ap) @total_billed_amount_current_year = params.dig(:total_billed_amount_current_year) @total_billed_amount_previous_year = params.dig(:total_billed_amount_previous_year) @total_paid_amount_current_year = params.dig(:total_paid_amount_current_year) @percentage_of_total_ap90_days_past_due = params.dig(:percentage_of_total_ap90_days_past_due) @vendors_paid_past_thirty_days = params.dig(:vendors_paid_past_thirty_days) @amount_paid_past_thirty_days = params.dig(:amount_paid_past_thirty_days) @advance_payment_amount_past_thirty_days = params.dig(:advance_payment_amount_past_thirty_days) @bills_paid_past_thirty_days = params.dig(:bills_paid_past_thirty_days) @billing_vendors_past_thirty_days = params.dig(:billing_vendors_past_thirty_days) @amount_billed_past_thirty_days = params.dig(:amount_billed_past_thirty_days) @amount_due_past_thirty_days = params.dig(:amount_due_past_thirty_days) @bills_past_thirty_days = params.dig(:bills_past_thirty_days) end |
Instance Attribute Details
#advance_payment_amount_past_thirty_days ⇒ Double
Returns The amount in advance from the payments made over the past thirty days.
136 137 138 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 136 def advance_payment_amount_past_thirty_days @advance_payment_amount_past_thirty_days end |
#amount_billed_past_thirty_days ⇒ Double
Returns The total amount billed over the past thirty days.
148 149 150 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 148 def amount_billed_past_thirty_days @amount_billed_past_thirty_days end |
#amount_due_past_thirty_days ⇒ Double
Returns The amount outstanding on the bills received over the past thirty days.
152 153 154 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 152 def amount_due_past_thirty_days @amount_due_past_thirty_days end |
#amount_paid_past_thirty_days ⇒ Double
Returns The total amount paid over the past thirty days.
132 133 134 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 132 def amount_paid_past_thirty_days @amount_paid_past_thirty_days end |
#billing_vendors_past_thirty_days ⇒ Int32
Returns The number of vendors that sent bills over the the past thirty days.
144 145 146 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 144 def billing_vendors_past_thirty_days @billing_vendors_past_thirty_days end |
#bills_paid_past_thirty_days ⇒ Int32
Returns The number of bills paid over the past thirty days.
140 141 142 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 140 def bills_paid_past_thirty_days @bills_paid_past_thirty_days end |
#bills_past_thirty_days ⇒ Int32
Returns The number of bills received over the past thirty days.
156 157 158 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 156 def bills_past_thirty_days @bills_past_thirty_days 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).
56 57 58 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 56 def group_key @group_key end |
#percentage_of_total_ap ⇒ Double
Returns Portion of Total AP that is Past due.
108 109 110 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 108 def percentage_of_total_ap @percentage_of_total_ap end |
#percentage_of_total_ap90_days_past_due ⇒ Double
Returns Portion of Total AP that is 90+ days Past due.
124 125 126 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 124 def percentage_of_total_ap90_days_past_due @percentage_of_total_ap90_days_past_due end |
#report_period ⇒ Date-time
Returns The date of the report.
60 61 62 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 60 def report_period @report_period end |
#total_advance_payments ⇒ Double
Returns The total number of advance payments.
76 77 78 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 76 def total_advance_payments @total_advance_payments end |
#total_ap_amount ⇒ Double
Returns The total accounts payable amount.
84 85 86 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 84 def total_ap_amount @total_ap_amount end |
#total_billed_amount ⇒ Double
Returns The total amount billed.
72 73 74 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 72 def total_billed_amount @total_billed_amount end |
#total_billed_amount_current_year ⇒ Double
Returns The total amount billed, due this year.
112 113 114 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 112 def total_billed_amount_current_year @total_billed_amount_current_year end |
#total_billed_amount_previous_year ⇒ Double
Returns The total amount billed, due last year.
116 117 118 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 116 def total_billed_amount_previous_year @total_billed_amount_previous_year end |
#total_bills ⇒ Int32
Returns The total number of bills.
68 69 70 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 68 def total_bills @total_bills end |
#total_bills90_days_past_due ⇒ Int32
Returns The number of bills 90+ days past due.
96 97 98 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 96 def total_bills90_days_past_due @total_bills90_days_past_due end |
#total_bills_paid ⇒ Int32
Returns The number of paid bills.
88 89 90 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 88 def total_bills_paid @total_bills_paid end |
#total_bills_past_due ⇒ Int32
Returns The number of past due bills.
92 93 94 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 92 def total_bills_past_due @total_bills_past_due end |
#total_paid ⇒ Double
Returns The total amount paid.
80 81 82 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 80 def total_paid @total_paid end |
#total_paid_amount_current_year ⇒ Double
Returns The total of all payments made this year.
120 121 122 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 120 def total_paid_amount_current_year @total_paid_amount_current_year end |
#total_past_due_amount ⇒ Double
Returns The total amount past due.
100 101 102 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 100 def total_past_due_amount @total_past_due_amount end |
#total_past_due_amount90_days ⇒ Double
Returns The total amount for bills 90+ days past due.
104 105 106 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 104 def total_past_due_amount90_days @total_past_due_amount90_days end |
#total_vendors ⇒ Int32
Returns The total number of vendors.
64 65 66 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 64 def total_vendors @total_vendors end |
#vendors_paid_past_thirty_days ⇒ Int32
Returns The number of vendors who were paid within the past thirty days.
128 129 130 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 128 def vendors_paid_past_thirty_days @vendors_paid_past_thirty_days end |
Instance Method Details
#as_json(options = {}) ⇒ object
Returns This object as a JSON key-value structure.
160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 160 def as_json(={}) { 'groupKey' => @group_key, 'reportPeriod' => @report_period, 'totalVendors' => @total_vendors, 'totalBills' => @total_bills, 'totalBilledAmount' => @total_billed_amount, 'totalAdvancePayments' => @total_advance_payments, 'totalPaid' => @total_paid, 'totalApAmount' => @total_ap_amount, 'totalBillsPaid' => @total_bills_paid, 'totalBillsPastDue' => @total_bills_past_due, 'totalBills90DaysPastDue' => @total_bills90_days_past_due, 'totalPastDueAmount' => @total_past_due_amount, 'totalPastDueAmount90Days' => @total_past_due_amount90_days, 'percentageOfTotalAp' => @percentage_of_total_ap, 'totalBilledAmountCurrentYear' => @total_billed_amount_current_year, 'totalBilledAmountPreviousYear' => @total_billed_amount_previous_year, 'totalPaidAmountCurrentYear' => @total_paid_amount_current_year, 'percentageOfTotalAp90DaysPastDue' => @percentage_of_total_ap90_days_past_due, 'vendorsPaidPastThirtyDays' => @vendors_paid_past_thirty_days, 'amountPaidPastThirtyDays' => @amount_paid_past_thirty_days, 'advancePaymentAmountPastThirtyDays' => @advance_payment_amount_past_thirty_days, 'billsPaidPastThirtyDays' => @bills_paid_past_thirty_days, 'billingVendorsPastThirtyDays' => @billing_vendors_past_thirty_days, 'amountBilledPastThirtyDays' => @amount_billed_past_thirty_days, 'amountDuePastThirtyDays' => @amount_due_past_thirty_days, 'billsPastThirtyDays' => @bills_past_thirty_days, } end |
#to_json(*options) ⇒ String
Returns This object converted to a JSON string.
193 194 195 |
# File 'lib/lockstep_sdk/models/ap_header_info_model.rb', line 193 def to_json(*) "[#{as_json(*).to_json(*)}]" end |