data-and-reporting-sdk 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/LICENSE +28 -0
- data/README.md +104 -0
- data/lib/shell_data_reporting_ap_is/api_helper.rb +10 -0
- data/lib/shell_data_reporting_ap_is/client.rb +84 -0
- data/lib/shell_data_reporting_ap_is/configuration.rb +110 -0
- data/lib/shell_data_reporting_ap_is/controllers/base_controller.rb +66 -0
- data/lib/shell_data_reporting_ap_is/controllers/customer_controller.rb +478 -0
- data/lib/shell_data_reporting_ap_is/controllers/invoice_controller.rb +470 -0
- data/lib/shell_data_reporting_ap_is/controllers/o_auth_authorization_controller.rb +42 -0
- data/lib/shell_data_reporting_ap_is/controllers/transaction_controller.rb +878 -0
- data/lib/shell_data_reporting_ap_is/exceptions/api_exception.rb +10 -0
- data/lib/shell_data_reporting_ap_is/exceptions/default_error_exception.rb +32 -0
- data/lib/shell_data_reporting_ap_is/exceptions/error_object_exception.rb +54 -0
- data/lib/shell_data_reporting_ap_is/exceptions/error_user_access_error1_exception.rb +32 -0
- data/lib/shell_data_reporting_ap_is/exceptions/o_auth_provider_exception.rb +48 -0
- data/lib/shell_data_reporting_ap_is/http/auth/basic_auth.rb +50 -0
- data/lib/shell_data_reporting_ap_is/http/auth/bearer_token.rb +89 -0
- data/lib/shell_data_reporting_ap_is/http/http_call_back.rb +10 -0
- data/lib/shell_data_reporting_ap_is/http/http_method_enum.rb +10 -0
- data/lib/shell_data_reporting_ap_is/http/http_request.rb +10 -0
- data/lib/shell_data_reporting_ap_is/http/http_response.rb +10 -0
- data/lib/shell_data_reporting_ap_is/models/account_access.rb +128 -0
- data/lib/shell_data_reporting_ap_is/models/account_request.rb +252 -0
- data/lib/shell_data_reporting_ap_is/models/account_response.rb +111 -0
- data/lib/shell_data_reporting_ap_is/models/account_response_accounts_items.rb +750 -0
- data/lib/shell_data_reporting_ap_is/models/accounts.rb +65 -0
- data/lib/shell_data_reporting_ap_is/models/address.rb +174 -0
- data/lib/shell_data_reporting_ap_is/models/associated_account.rb +98 -0
- data/lib/shell_data_reporting_ap_is/models/audit_request.rb +256 -0
- data/lib/shell_data_reporting_ap_is/models/audit_response.rb +111 -0
- data/lib/shell_data_reporting_ap_is/models/audit_response_audits_items.rb +450 -0
- data/lib/shell_data_reporting_ap_is/models/bank_account.rb +192 -0
- data/lib/shell_data_reporting_ap_is/models/base_model.rb +62 -0
- data/lib/shell_data_reporting_ap_is/models/bonus_configuration.rb +419 -0
- data/lib/shell_data_reporting_ap_is/models/bonus_history.rb +444 -0
- data/lib/shell_data_reporting_ap_is/models/card_day_time_restrictions.rb +159 -0
- data/lib/shell_data_reporting_ap_is/models/card_exceptions.rb +268 -0
- data/lib/shell_data_reporting_ap_is/models/card_group_request.rb +178 -0
- data/lib/shell_data_reporting_ap_is/models/card_group_response.rb +109 -0
- data/lib/shell_data_reporting_ap_is/models/card_group_response_card_groups_items.rb +301 -0
- data/lib/shell_data_reporting_ap_is/models/card_type_request.rb +145 -0
- data/lib/shell_data_reporting_ap_is/models/card_type_response.rb +79 -0
- data/lib/shell_data_reporting_ap_is/models/card_type_response_customer_card_types_items.rb +470 -0
- data/lib/shell_data_reporting_ap_is/models/card_type_response_error.rb +60 -0
- data/lib/shell_data_reporting_ap_is/models/card_usage_restrictions.rb +281 -0
- data/lib/shell_data_reporting_ap_is/models/card_usage_summary_request.rb +159 -0
- data/lib/shell_data_reporting_ap_is/models/card_usage_summary_response.rb +79 -0
- data/lib/shell_data_reporting_ap_is/models/col_co_access.rb +88 -0
- data/lib/shell_data_reporting_ap_is/models/current_volume.rb +99 -0
- data/lib/shell_data_reporting_ap_is/models/customer_contract.rb +63 -0
- data/lib/shell_data_reporting_ap_is/models/customer_detail_request.rb +123 -0
- data/lib/shell_data_reporting_ap_is/models/customer_detail_response.rb +437 -0
- data/lib/shell_data_reporting_ap_is/models/customer_price_list_request.rb +200 -0
- data/lib/shell_data_reporting_ap_is/models/customer_price_list_response.rb +82 -0
- data/lib/shell_data_reporting_ap_is/models/default_error_fault.rb +60 -0
- data/lib/shell_data_reporting_ap_is/models/default_error_fault_detail.rb +50 -0
- data/lib/shell_data_reporting_ap_is/models/delivery_addresses.rb +258 -0
- data/lib/shell_data_reporting_ap_is/models/eid_access.rb +75 -0
- data/lib/shell_data_reporting_ap_is/models/eid_document.rb +166 -0
- data/lib/shell_data_reporting_ap_is/models/eid_document_response.rb +140 -0
- data/lib/shell_data_reporting_ap_is/models/eid_download_req.rb +86 -0
- data/lib/shell_data_reporting_ap_is/models/eid_download_request.rb +50 -0
- data/lib/shell_data_reporting_ap_is/models/eid_search_req.rb +160 -0
- data/lib/shell_data_reporting_ap_is/models/eid_search_request.rb +70 -0
- data/lib/shell_data_reporting_ap_is/models/error_details.rb +81 -0
- data/lib/shell_data_reporting_ap_is/models/error_status.rb +60 -0
- data/lib/shell_data_reporting_ap_is/models/error_user_access.rb +50 -0
- data/lib/shell_data_reporting_ap_is/models/error_user_access_error.rb +60 -0
- data/lib/shell_data_reporting_ap_is/models/exception_product.rb +65 -0
- data/lib/shell_data_reporting_ap_is/models/exception_site_location.rb +63 -0
- data/lib/shell_data_reporting_ap_is/models/fee_item.rb +977 -0
- data/lib/shell_data_reporting_ap_is/models/fee_item_summary_all_of0.rb +194 -0
- data/lib/shell_data_reporting_ap_is/models/fee_rule_location.rb +153 -0
- data/lib/shell_data_reporting_ap_is/models/fee_rule_product.rb +98 -0
- data/lib/shell_data_reporting_ap_is/models/fee_rule_tier.rb +74 -0
- data/lib/shell_data_reporting_ap_is/models/fee_summary_response.rb +85 -0
- data/lib/shell_data_reporting_ap_is/models/fees_fee_rule_tiers.rb +124 -0
- data/lib/shell_data_reporting_ap_is/models/finance_currency.rb +98 -0
- data/lib/shell_data_reporting_ap_is/models/fuel_consumption_card.rb +73 -0
- data/lib/shell_data_reporting_ap_is/models/fuel_consumption_data.rb +267 -0
- data/lib/shell_data_reporting_ap_is/models/fuel_consumption_request.rb +197 -0
- data/lib/shell_data_reporting_ap_is/models/fuel_consumption_response.rb +79 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_dates_data.rb +62 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_dates_request.rb +50 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_dates_request_filters.rb +146 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_dates_response_data.rb +80 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_distribution_method.rb +99 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_download_req.rb +99 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_download_request.rb +50 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_search_additional_document.rb +80 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_search_details.rb +913 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_search_request.rb +91 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_search_request_filters.rb +344 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_search_response.rb +127 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_summary_details.rb +129 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_summary_request.rb +50 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_summary_request_filters.rb +345 -0
- data/lib/shell_data_reporting_ap_is/models/invoice_summary_response.rb +79 -0
- data/lib/shell_data_reporting_ap_is/models/invoices_summaries.rb +221 -0
- data/lib/shell_data_reporting_ap_is/models/last_statement_of_account.rb +421 -0
- data/lib/shell_data_reporting_ap_is/models/logged_in_user_request.rb +107 -0
- data/lib/shell_data_reporting_ap_is/models/logged_in_user_response.rb +394 -0
- data/lib/shell_data_reporting_ap_is/models/monthly_invoice_trend.rb +112 -0
- data/lib/shell_data_reporting_ap_is/models/multi_priced_transaction_request.rb +360 -0
- data/lib/shell_data_reporting_ap_is/models/multi_priced_transaction_request_accounts_items.rb +84 -0
- data/lib/shell_data_reporting_ap_is/models/multi_priced_transaction_response.rb +110 -0
- data/lib/shell_data_reporting_ap_is/models/multi_priced_transaction_response_transactions_items.rb +1724 -0
- data/lib/shell_data_reporting_ap_is/models/o_auth_provider_error_enum.rb +45 -0
- data/lib/shell_data_reporting_ap_is/models/o_auth_token.rb +100 -0
- data/lib/shell_data_reporting_ap_is/models/past_statement_of_accounts.rb +502 -0
- data/lib/shell_data_reporting_ap_is/models/payer_access.rb +147 -0
- data/lib/shell_data_reporting_ap_is/models/payer_details.rb +1412 -0
- data/lib/shell_data_reporting_ap_is/models/payer_request.rb +126 -0
- data/lib/shell_data_reporting_ap_is/models/payer_response.rb +115 -0
- data/lib/shell_data_reporting_ap_is/models/payers.rb +109 -0
- data/lib/shell_data_reporting_ap_is/models/payments_since_last_soa.rb +322 -0
- data/lib/shell_data_reporting_ap_is/models/pin_advice_types.rb +80 -0
- data/lib/shell_data_reporting_ap_is/models/price_list.rb +485 -0
- data/lib/shell_data_reporting_ap_is/models/price_trans_summary_request.rb +477 -0
- data/lib/shell_data_reporting_ap_is/models/price_transaction_request.rb +572 -0
- data/lib/shell_data_reporting_ap_is/models/priced_request_data.rb +485 -0
- data/lib/shell_data_reporting_ap_is/models/priced_response_data.rb +2132 -0
- data/lib/shell_data_reporting_ap_is/models/priced_trans_summary_response.rb +79 -0
- data/lib/shell_data_reporting_ap_is/models/priced_trans_summary_response_transactions_summary_items.rb +242 -0
- data/lib/shell_data_reporting_ap_is/models/priced_transaction_items_location_items.rb +67 -0
- data/lib/shell_data_reporting_ap_is/models/priced_transaction_req_v2_invoice_status_enum.rb +27 -0
- data/lib/shell_data_reporting_ap_is/models/priced_transaction_req_v2_period_enum.rb +27 -0
- data/lib/shell_data_reporting_ap_is/models/priced_transaction_req_v2_sort_order_enum.rb +37 -0
- data/lib/shell_data_reporting_ap_is/models/priced_transaction_request_v2.rb +72 -0
- data/lib/shell_data_reporting_ap_is/models/priced_transaction_resp_v2_refund_flag_enum.rb +23 -0
- data/lib/shell_data_reporting_ap_is/models/priced_transaction_response.rb +59 -0
- data/lib/shell_data_reporting_ap_is/models/priced_transaction_response_transactions_items.rb +1719 -0
- data/lib/shell_data_reporting_ap_is/models/priced_transaction_response_v2.rb +110 -0
- data/lib/shell_data_reporting_ap_is/models/pricing_current_volume.rb +115 -0
- data/lib/shell_data_reporting_ap_is/models/pricing_history.rb +105 -0
- data/lib/shell_data_reporting_ap_is/models/purchase_categories.rb +114 -0
- data/lib/shell_data_reporting_ap_is/models/recent_transaction_req.rb +217 -0
- data/lib/shell_data_reporting_ap_is/models/recent_transaction_request.rb +66 -0
- data/lib/shell_data_reporting_ap_is/models/recent_transactions.rb +918 -0
- data/lib/shell_data_reporting_ap_is/models/recent_transactions_response.rb +110 -0
- data/lib/shell_data_reporting_ap_is/models/role.rb +102 -0
- data/lib/shell_data_reporting_ap_is/models/search_doc_req.rb +269 -0
- data/lib/shell_data_reporting_ap_is/models/search_documents_invoice.rb +204 -0
- data/lib/shell_data_reporting_ap_is/models/search_documents_request.rb +70 -0
- data/lib/shell_data_reporting_ap_is/models/search_documents_response.rb +122 -0
- data/lib/shell_data_reporting_ap_is/models/search_soa_req.rb +197 -0
- data/lib/shell_data_reporting_ap_is/models/search_statement_of_account.rb +220 -0
- data/lib/shell_data_reporting_ap_is/models/search_statement_of_account_request.rb +70 -0
- data/lib/shell_data_reporting_ap_is/models/search_statement_of_account_response.rb +120 -0
- data/lib/shell_data_reporting_ap_is/models/site_location.rb +67 -0
- data/lib/shell_data_reporting_ap_is/models/statement_of_account_request.rb +50 -0
- data/lib/shell_data_reporting_ap_is/models/statement_of_account_request_filters.rb +197 -0
- data/lib/shell_data_reporting_ap_is/models/statement_of_account_resp.rb +138 -0
- data/lib/shell_data_reporting_ap_is/models/statement_of_account_response.rb +80 -0
- data/lib/shell_data_reporting_ap_is/models/tier.rb +167 -0
- data/lib/shell_data_reporting_ap_is/models/transaction_exceptions.rb +1267 -0
- data/lib/shell_data_reporting_ap_is/models/transaction_exceptions_request.rb +267 -0
- data/lib/shell_data_reporting_ap_is/models/transaction_exceptions_response.rb +100 -0
- data/lib/shell_data_reporting_ap_is/models/transaction_fees_request.rb +348 -0
- data/lib/shell_data_reporting_ap_is/models/transaction_fees_response.rb +111 -0
- data/lib/shell_data_reporting_ap_is/models/update_odometer.rb +62 -0
- data/lib/shell_data_reporting_ap_is/models/update_odometer_reference.rb +67 -0
- data/lib/shell_data_reporting_ap_is/models/update_odometer_request.rb +146 -0
- data/lib/shell_data_reporting_ap_is/models/update_odometer_response.rb +93 -0
- data/lib/shell_data_reporting_ap_is/models/usage_summary.rb +202 -0
- data/lib/shell_data_reporting_ap_is/models/volume_based_bonus_request.rb +118 -0
- data/lib/shell_data_reporting_ap_is/models/volume_based_bonus_response.rb +120 -0
- data/lib/shell_data_reporting_ap_is/models/volume_based_pricing_request.rb +103 -0
- data/lib/shell_data_reporting_ap_is/models/volume_based_pricing_response.rb +120 -0
- data/lib/shell_data_reporting_ap_is/utilities/date_time_helper.rb +11 -0
- data/lib/shell_data_reporting_ap_is/utilities/file_wrapper.rb +16 -0
- data/lib/shell_data_reporting_ap_is.rb +229 -0
- data/test/controllers/controller_test_base.rb +34 -0
- data/test/controllers/test_invoice_controller.rb +398 -0
- data/test/controllers/test_transaction_controller.rb +235 -0
- data/test/http_response_catcher.rb +19 -0
- metadata +302 -0
|
@@ -0,0 +1,572 @@
|
|
|
1
|
+
# shell_data_reporting_ap_is
|
|
2
|
+
#
|
|
3
|
+
# This file was automatically generated by APIMATIC v2.0
|
|
4
|
+
# ( https://apimatic.io ).
|
|
5
|
+
|
|
6
|
+
module ShellDataReportingApIs
|
|
7
|
+
# PriceTransactionRequest Model.
|
|
8
|
+
class PriceTransactionRequest < BaseModel
|
|
9
|
+
SKIP = Object.new
|
|
10
|
+
private_constant :SKIP
|
|
11
|
+
|
|
12
|
+
# Collecting Company Id of the selected payer.
|
|
13
|
+
# Optional if ColCoCode is passed else Mandatory.
|
|
14
|
+
# Example:
|
|
15
|
+
# 1 for Philippines
|
|
16
|
+
# 5 for UK
|
|
17
|
+
# @return [Integer]
|
|
18
|
+
attr_accessor :col_co_id
|
|
19
|
+
|
|
20
|
+
# Collecting Company Code of the selected payer.
|
|
21
|
+
# Mandatory for serviced OUs such as Romania, Latvia, Lithuania, Estonia,
|
|
22
|
+
# Ukraine etc. It is optional for other countries if ColCoID is provided.
|
|
23
|
+
# Example:
|
|
24
|
+
# 86 for Philippines
|
|
25
|
+
# 5 for UK
|
|
26
|
+
# @return [Integer]
|
|
27
|
+
attr_accessor :col_co_code
|
|
28
|
+
|
|
29
|
+
# Payer Id of the selected payer.
|
|
30
|
+
# Optional if PayerNumber is passed else Mandatory
|
|
31
|
+
# @return [Integer]
|
|
32
|
+
attr_accessor :payer_id
|
|
33
|
+
|
|
34
|
+
# Payer Number (Ex: GB000000123) of the selected payer.
|
|
35
|
+
# Optional if PayerId is passed else Mandatory
|
|
36
|
+
# Example: GB000000123
|
|
37
|
+
# @return [String]
|
|
38
|
+
attr_accessor :payer_number
|
|
39
|
+
|
|
40
|
+
# Payer Number (Ex: GB000000123) of the selected payer.
|
|
41
|
+
# Optional if PayerId is passed else Mandatory
|
|
42
|
+
# Example: GB000000123
|
|
43
|
+
# @return [Accounts]
|
|
44
|
+
attr_accessor :accounts
|
|
45
|
+
|
|
46
|
+
# Card Id (i.e. Unique Card Id in GFN)
|
|
47
|
+
# Optional
|
|
48
|
+
# When both Card Id and Card PAN are not present on request, the response
|
|
49
|
+
# will have transactions of all cards under the selected payer or account
|
|
50
|
+
# @return [Integer]
|
|
51
|
+
attr_accessor :card_id
|
|
52
|
+
|
|
53
|
+
# Full Card PAN
|
|
54
|
+
# Optional
|
|
55
|
+
# When both Card Id and Card PAN are not present on request, the response
|
|
56
|
+
# will have transactions of all cards under the selected payer or account.
|
|
57
|
+
# @return [String]
|
|
58
|
+
attr_accessor :card_pan
|
|
59
|
+
|
|
60
|
+
# Driver Name (of Card record)
|
|
61
|
+
# Optional
|
|
62
|
+
# Minimum of 4 characters should be provided else not considered
|
|
63
|
+
# Transactions of the card having the entered value at any part of the
|
|
64
|
+
# Driver Name will be returned
|
|
65
|
+
# @return [String]
|
|
66
|
+
attr_accessor :driver_name
|
|
67
|
+
|
|
68
|
+
# Vehicle Registration (of Card record)
|
|
69
|
+
# Optional
|
|
70
|
+
# Minimum of 4 characters should be provided else not considered
|
|
71
|
+
# Transactions of the card having the entered value at any part of the VRN
|
|
72
|
+
# will be returned
|
|
73
|
+
# @return [String]
|
|
74
|
+
attr_accessor :vehicle_registration_number
|
|
75
|
+
|
|
76
|
+
# Invoice status of the transactions.
|
|
77
|
+
# Mandatory
|
|
78
|
+
# Possible options:
|
|
79
|
+
# I - Invoiced
|
|
80
|
+
# U – Un-Invoiced
|
|
81
|
+
# A – All
|
|
82
|
+
# @return [String]
|
|
83
|
+
attr_accessor :invoice_status
|
|
84
|
+
|
|
85
|
+
# Product Id
|
|
86
|
+
# Example:
|
|
87
|
+
# 21 Unleaded - High octane
|
|
88
|
+
# 22 Unleaded - Medium octane
|
|
89
|
+
# 23 Unleaded - Low octane
|
|
90
|
+
# 24 Unleaded Environmental
|
|
91
|
+
# @return [Integer]
|
|
92
|
+
attr_accessor :product_id
|
|
93
|
+
|
|
94
|
+
# Product Code – Global as per GFN configuration
|
|
95
|
+
# Optional
|
|
96
|
+
# Max Length: 8
|
|
97
|
+
# Example:
|
|
98
|
+
# 10 TMF Charges
|
|
99
|
+
# 11 Tunnel/Bridges
|
|
100
|
+
# 12 Motorway toll
|
|
101
|
+
# 13 Ferries
|
|
102
|
+
# @return [String]
|
|
103
|
+
attr_accessor :product_code
|
|
104
|
+
|
|
105
|
+
# ISO Country Code (ex: UK, FR)
|
|
106
|
+
# Note: If IncludeFees is true then this filter will be ignored
|
|
107
|
+
# @return [String]
|
|
108
|
+
attr_accessor :purchased_in_country
|
|
109
|
+
|
|
110
|
+
# Card Group Id in GFN
|
|
111
|
+
# @return [Integer]
|
|
112
|
+
attr_accessor :card_group_id
|
|
113
|
+
|
|
114
|
+
# Allowed Sorting Options:
|
|
115
|
+
# 1. TransactionDateAscending
|
|
116
|
+
# 2. TransactionDateDescending
|
|
117
|
+
# 3. GrossAmountDescending
|
|
118
|
+
# 4. GrossAmountAscending
|
|
119
|
+
# 5. DriverNameAscending (If Driver Name is null then VRN value will be
|
|
120
|
+
# considered)
|
|
121
|
+
# 6. DriverNameDescending (If Driver Name is null then VRN value will be
|
|
122
|
+
# considered)
|
|
123
|
+
# 7. VRNAscending (If VRN is null then Driver Name value will be considered)
|
|
124
|
+
# 8. VRNDescending (If VRN is null then Driver Name value will be
|
|
125
|
+
# considered)
|
|
126
|
+
# 9. NetAmountAscending
|
|
127
|
+
# 10. NetAmountDescensding
|
|
128
|
+
# Example value to be passed: “1,3”
|
|
129
|
+
# @return [String]
|
|
130
|
+
attr_accessor :sort_order
|
|
131
|
+
|
|
132
|
+
# Transactions from Date/Time.
|
|
133
|
+
# Optional – When provided, it should be with in last 24 months.
|
|
134
|
+
# Format: yyyyMMdd
|
|
135
|
+
# @return [String]
|
|
136
|
+
attr_accessor :from_date
|
|
137
|
+
|
|
138
|
+
# Transactions to Date/Time.
|
|
139
|
+
# Optional- Refer introduction section of this operation for the priority
|
|
140
|
+
# and sequence of different date and invoice number filters that are
|
|
141
|
+
# conditionally applied.
|
|
142
|
+
# Note:
|
|
143
|
+
# 1) When the value is blank and FromDate is provided on the input, all
|
|
144
|
+
# transactions took place 210(Configurable) days after the given FromDate is
|
|
145
|
+
# returned.
|
|
146
|
+
# 2) Difference between FromDate and ToDate cannot be more than 210
|
|
147
|
+
# (Configurable) days.
|
|
148
|
+
# Format: yyyyMMdd
|
|
149
|
+
# @return [String]
|
|
150
|
+
attr_accessor :to_date
|
|
151
|
+
|
|
152
|
+
# Transactions Period.
|
|
153
|
+
# Possible values are:
|
|
154
|
+
# 1. Last 7 Days
|
|
155
|
+
# 2. Last 30 Days
|
|
156
|
+
# 3. Last 90 Days
|
|
157
|
+
# Optional - Refer introduction section of this operation for the priority
|
|
158
|
+
# and sequence of different date and invoice number filters that are
|
|
159
|
+
# conditionally applied.
|
|
160
|
+
# @return [Integer]
|
|
161
|
+
attr_accessor :period
|
|
162
|
+
|
|
163
|
+
# Site Code as configured in GFN
|
|
164
|
+
# Example:
|
|
165
|
+
# 050001 - CHARNOCK RICHARD NTHBOUND MWSA 0755
|
|
166
|
+
# 050002 - CHARNOCK RICHARD STHBOUND MWSA 0755
|
|
167
|
+
# 050005 - HARTSHEAD MOOR EASTBOUND MWSA 0761.
|
|
168
|
+
# 050006 - HARTSHEAD MOOR WESTBOUND MWSA.
|
|
169
|
+
# Note: If IncludeFees is true then this filter will be ignored
|
|
170
|
+
# @return [String]
|
|
171
|
+
attr_accessor :site_code
|
|
172
|
+
|
|
173
|
+
# Site Group Id in GFN
|
|
174
|
+
# Optional
|
|
175
|
+
# Example: 202
|
|
176
|
+
# Note: If IncludeFees is true then this filter will be ignored
|
|
177
|
+
# @return [Integer]
|
|
178
|
+
attr_accessor :site_group_id
|
|
179
|
+
|
|
180
|
+
# Transaction Posting Date/time in the Cards Platform - From Date/time.
|
|
181
|
+
# Note:
|
|
182
|
+
# 1) When the value of both PostingDateFrom and PostingDateTo are present in
|
|
183
|
+
# the request then the value of PostingDateFrom must be less than
|
|
184
|
+
# PostingDateTo.
|
|
185
|
+
# 2) If IncludeFees is true then this filter will be ignored
|
|
186
|
+
# Format: yyyyMMdd HH:mm:ss
|
|
187
|
+
# @return [String]
|
|
188
|
+
attr_accessor :posting_date_from
|
|
189
|
+
|
|
190
|
+
# Transaction Posting Date/time in the Cards Platform – To Date/time.
|
|
191
|
+
# Note:
|
|
192
|
+
# 1) If IncludeFees is true then this filter will be ignored.
|
|
193
|
+
# 2) When the value of both PostingDateFrom and PostingDateTo are present in
|
|
194
|
+
# the request then the value of PostingDateFrom must be less than
|
|
195
|
+
# PostingDateTo.
|
|
196
|
+
# Format: yyyyMMdd HH:mm:ss
|
|
197
|
+
# @return [String]
|
|
198
|
+
attr_accessor :posting_date_to
|
|
199
|
+
|
|
200
|
+
# Unique SalesItemId (Either Billed on Unbilled)
|
|
201
|
+
# Optional
|
|
202
|
+
# Note: If IncludeFees is true then this filter will be ignored
|
|
203
|
+
# @return [String]
|
|
204
|
+
attr_accessor :sales_item_id
|
|
205
|
+
|
|
206
|
+
# Unique Transaction Id
|
|
207
|
+
# Optional
|
|
208
|
+
# Note: If IncludeFees is true then this filter will be ignored
|
|
209
|
+
# @return [String]
|
|
210
|
+
attr_accessor :transaction_id
|
|
211
|
+
|
|
212
|
+
# Invoice Date.
|
|
213
|
+
# Optional
|
|
214
|
+
# Note:
|
|
215
|
+
# 1) If value is not blank then the system will ignore the InvoiceStatus
|
|
216
|
+
# parameter and it will return all the billed transactions for the given
|
|
217
|
+
# invoice date.
|
|
218
|
+
# Format: yyyyMMdd
|
|
219
|
+
# @return [String]
|
|
220
|
+
attr_accessor :invoice_date
|
|
221
|
+
|
|
222
|
+
# Invoice Number.
|
|
223
|
+
# Optional
|
|
224
|
+
# Note:
|
|
225
|
+
# 1) If value is not blank then the system will ignore the InvoiceStatus
|
|
226
|
+
# parameter and it will return all the billed transactions for the given
|
|
227
|
+
# invoice date.
|
|
228
|
+
# @return [String]
|
|
229
|
+
attr_accessor :invoice_number
|
|
230
|
+
|
|
231
|
+
# True/False
|
|
232
|
+
# Optional
|
|
233
|
+
# Default value: True.
|
|
234
|
+
# When passed as ‘True’ the transactions records with report date not equal
|
|
235
|
+
# to 9999-12-30 will be returned.
|
|
236
|
+
# When passed as ‘False’ the above condition will not be checked.
|
|
237
|
+
# @return [TrueClass | FalseClass]
|
|
238
|
+
attr_accessor :valid_invoice_date_only
|
|
239
|
+
|
|
240
|
+
# Start date for transaction search by invoice date.
|
|
241
|
+
# Optional
|
|
242
|
+
# Note:
|
|
243
|
+
# 1) Value should be with in last 24 months (if provided).
|
|
244
|
+
# 2) Maximum of 90(Configurable) day’s duration allowed per search.
|
|
245
|
+
# 3) When provided, InvoiceFromDate has to be less than or equal to
|
|
246
|
+
# InvoiceToDate.
|
|
247
|
+
# Format: yyyyMMdd
|
|
248
|
+
# @return [String]
|
|
249
|
+
attr_accessor :invoice_from_date
|
|
250
|
+
|
|
251
|
+
# End date for transaction search by invoice date.
|
|
252
|
+
# Optional
|
|
253
|
+
# Note:
|
|
254
|
+
# 1) When InvoiceFromDate is provided and InvoiceToDate is null, then
|
|
255
|
+
# InvoiceToDate will be calculated as (InvoiceFromDate + 90 days) or
|
|
256
|
+
# (CurrentDate) whichever is lesser.
|
|
257
|
+
# Format: yyyyMMdd
|
|
258
|
+
# @return [String]
|
|
259
|
+
attr_accessor :invoice_to_date
|
|
260
|
+
|
|
261
|
+
# True/False
|
|
262
|
+
# Optional
|
|
263
|
+
# Default value: False.
|
|
264
|
+
# When passed as ‘True’ Only returned records with Fuel transactions.
|
|
265
|
+
# When passed as ‘False’ the above condition will not be checked.
|
|
266
|
+
# @return [TrueClass | FalseClass]
|
|
267
|
+
attr_accessor :fuel_only
|
|
268
|
+
|
|
269
|
+
# True/False
|
|
270
|
+
# Optional
|
|
271
|
+
# Default value: False
|
|
272
|
+
# When passed as ‘True’ then ignore few filters, all sales items along with
|
|
273
|
+
# fees included on the same response
|
|
274
|
+
# @return [TrueClass | FalseClass]
|
|
275
|
+
attr_accessor :include_fees
|
|
276
|
+
|
|
277
|
+
# True/False
|
|
278
|
+
# Optional
|
|
279
|
+
# Default value – False.
|
|
280
|
+
# When set to True, the property names in the output will be replaced by
|
|
281
|
+
# Field IDs.
|
|
282
|
+
# This will reduce the output payload size significantly for large data sets
|
|
283
|
+
# and help faster transmission of data over networks.
|
|
284
|
+
# @return [TrueClass | FalseClass]
|
|
285
|
+
attr_accessor :use_field_id
|
|
286
|
+
|
|
287
|
+
# Current Page Number
|
|
288
|
+
# @return [Integer]
|
|
289
|
+
attr_accessor :current_page
|
|
290
|
+
|
|
291
|
+
# Page Size – Number of records to show on a page
|
|
292
|
+
# Optional
|
|
293
|
+
# Default value 50
|
|
294
|
+
# @return [Integer]
|
|
295
|
+
attr_accessor :page_size
|
|
296
|
+
|
|
297
|
+
# A mapping from model property names to API property names.
|
|
298
|
+
def self.names
|
|
299
|
+
@_hash = {} if @_hash.nil?
|
|
300
|
+
@_hash['col_co_id'] = 'ColCoId'
|
|
301
|
+
@_hash['col_co_code'] = 'ColCoCode'
|
|
302
|
+
@_hash['payer_id'] = 'PayerId'
|
|
303
|
+
@_hash['payer_number'] = 'PayerNumber'
|
|
304
|
+
@_hash['accounts'] = 'Accounts'
|
|
305
|
+
@_hash['card_id'] = 'CardId'
|
|
306
|
+
@_hash['card_pan'] = 'CardPAN'
|
|
307
|
+
@_hash['driver_name'] = 'DriverName'
|
|
308
|
+
@_hash['vehicle_registration_number'] = 'VehicleRegistrationNumber'
|
|
309
|
+
@_hash['invoice_status'] = 'InvoiceStatus'
|
|
310
|
+
@_hash['product_id'] = 'ProductId'
|
|
311
|
+
@_hash['product_code'] = 'ProductCode'
|
|
312
|
+
@_hash['purchased_in_country'] = 'PurchasedInCountry'
|
|
313
|
+
@_hash['card_group_id'] = 'CardGroupId'
|
|
314
|
+
@_hash['sort_order'] = 'SortOrder'
|
|
315
|
+
@_hash['from_date'] = 'FromDate'
|
|
316
|
+
@_hash['to_date'] = 'ToDate'
|
|
317
|
+
@_hash['period'] = 'Period'
|
|
318
|
+
@_hash['site_code'] = 'SiteCode'
|
|
319
|
+
@_hash['site_group_id'] = 'SiteGroupId'
|
|
320
|
+
@_hash['posting_date_from'] = 'PostingDateFrom'
|
|
321
|
+
@_hash['posting_date_to'] = 'PostingDateTo'
|
|
322
|
+
@_hash['sales_item_id'] = 'SalesItemId'
|
|
323
|
+
@_hash['transaction_id'] = 'TransactionId'
|
|
324
|
+
@_hash['invoice_date'] = 'InvoiceDate'
|
|
325
|
+
@_hash['invoice_number'] = 'InvoiceNumber'
|
|
326
|
+
@_hash['valid_invoice_date_only'] = 'ValidInvoiceDateOnly'
|
|
327
|
+
@_hash['invoice_from_date'] = 'InvoiceFromDate'
|
|
328
|
+
@_hash['invoice_to_date'] = 'InvoiceToDate'
|
|
329
|
+
@_hash['fuel_only'] = 'FuelOnly'
|
|
330
|
+
@_hash['include_fees'] = 'IncludeFees'
|
|
331
|
+
@_hash['use_field_id'] = 'UseFieldId'
|
|
332
|
+
@_hash['current_page'] = 'CurrentPage'
|
|
333
|
+
@_hash['page_size'] = 'PageSize'
|
|
334
|
+
@_hash
|
|
335
|
+
end
|
|
336
|
+
|
|
337
|
+
# An array for optional fields
|
|
338
|
+
def self.optionals
|
|
339
|
+
%w[
|
|
340
|
+
col_co_id
|
|
341
|
+
col_co_code
|
|
342
|
+
payer_id
|
|
343
|
+
payer_number
|
|
344
|
+
accounts
|
|
345
|
+
card_id
|
|
346
|
+
card_pan
|
|
347
|
+
driver_name
|
|
348
|
+
vehicle_registration_number
|
|
349
|
+
invoice_status
|
|
350
|
+
product_id
|
|
351
|
+
product_code
|
|
352
|
+
purchased_in_country
|
|
353
|
+
card_group_id
|
|
354
|
+
sort_order
|
|
355
|
+
from_date
|
|
356
|
+
to_date
|
|
357
|
+
period
|
|
358
|
+
site_code
|
|
359
|
+
site_group_id
|
|
360
|
+
posting_date_from
|
|
361
|
+
posting_date_to
|
|
362
|
+
sales_item_id
|
|
363
|
+
transaction_id
|
|
364
|
+
invoice_date
|
|
365
|
+
invoice_number
|
|
366
|
+
valid_invoice_date_only
|
|
367
|
+
invoice_from_date
|
|
368
|
+
invoice_to_date
|
|
369
|
+
fuel_only
|
|
370
|
+
include_fees
|
|
371
|
+
use_field_id
|
|
372
|
+
current_page
|
|
373
|
+
page_size
|
|
374
|
+
]
|
|
375
|
+
end
|
|
376
|
+
|
|
377
|
+
# An array for nullable fields
|
|
378
|
+
def self.nullables
|
|
379
|
+
%w[
|
|
380
|
+
col_co_id
|
|
381
|
+
col_co_code
|
|
382
|
+
payer_id
|
|
383
|
+
payer_number
|
|
384
|
+
card_id
|
|
385
|
+
card_pan
|
|
386
|
+
driver_name
|
|
387
|
+
vehicle_registration_number
|
|
388
|
+
invoice_status
|
|
389
|
+
product_id
|
|
390
|
+
product_code
|
|
391
|
+
purchased_in_country
|
|
392
|
+
card_group_id
|
|
393
|
+
sort_order
|
|
394
|
+
from_date
|
|
395
|
+
to_date
|
|
396
|
+
period
|
|
397
|
+
site_code
|
|
398
|
+
site_group_id
|
|
399
|
+
posting_date_from
|
|
400
|
+
posting_date_to
|
|
401
|
+
sales_item_id
|
|
402
|
+
transaction_id
|
|
403
|
+
invoice_date
|
|
404
|
+
invoice_number
|
|
405
|
+
valid_invoice_date_only
|
|
406
|
+
invoice_from_date
|
|
407
|
+
invoice_to_date
|
|
408
|
+
fuel_only
|
|
409
|
+
include_fees
|
|
410
|
+
use_field_id
|
|
411
|
+
current_page
|
|
412
|
+
]
|
|
413
|
+
end
|
|
414
|
+
|
|
415
|
+
def initialize(col_co_id = SKIP,
|
|
416
|
+
col_co_code = SKIP,
|
|
417
|
+
payer_id = SKIP,
|
|
418
|
+
payer_number = SKIP,
|
|
419
|
+
accounts = SKIP,
|
|
420
|
+
card_id = SKIP,
|
|
421
|
+
card_pan = SKIP,
|
|
422
|
+
driver_name = SKIP,
|
|
423
|
+
vehicle_registration_number = SKIP,
|
|
424
|
+
invoice_status = SKIP,
|
|
425
|
+
product_id = SKIP,
|
|
426
|
+
product_code = SKIP,
|
|
427
|
+
purchased_in_country = SKIP,
|
|
428
|
+
card_group_id = SKIP,
|
|
429
|
+
sort_order = SKIP,
|
|
430
|
+
from_date = SKIP,
|
|
431
|
+
to_date = SKIP,
|
|
432
|
+
period = SKIP,
|
|
433
|
+
site_code = SKIP,
|
|
434
|
+
site_group_id = SKIP,
|
|
435
|
+
posting_date_from = SKIP,
|
|
436
|
+
posting_date_to = SKIP,
|
|
437
|
+
sales_item_id = SKIP,
|
|
438
|
+
transaction_id = SKIP,
|
|
439
|
+
invoice_date = SKIP,
|
|
440
|
+
invoice_number = SKIP,
|
|
441
|
+
valid_invoice_date_only = SKIP,
|
|
442
|
+
invoice_from_date = SKIP,
|
|
443
|
+
invoice_to_date = SKIP,
|
|
444
|
+
fuel_only = SKIP,
|
|
445
|
+
include_fees = SKIP,
|
|
446
|
+
use_field_id = SKIP,
|
|
447
|
+
current_page = SKIP,
|
|
448
|
+
page_size = SKIP)
|
|
449
|
+
@col_co_id = col_co_id unless col_co_id == SKIP
|
|
450
|
+
@col_co_code = col_co_code unless col_co_code == SKIP
|
|
451
|
+
@payer_id = payer_id unless payer_id == SKIP
|
|
452
|
+
@payer_number = payer_number unless payer_number == SKIP
|
|
453
|
+
@accounts = accounts unless accounts == SKIP
|
|
454
|
+
@card_id = card_id unless card_id == SKIP
|
|
455
|
+
@card_pan = card_pan unless card_pan == SKIP
|
|
456
|
+
@driver_name = driver_name unless driver_name == SKIP
|
|
457
|
+
unless vehicle_registration_number == SKIP
|
|
458
|
+
@vehicle_registration_number =
|
|
459
|
+
vehicle_registration_number
|
|
460
|
+
end
|
|
461
|
+
@invoice_status = invoice_status unless invoice_status == SKIP
|
|
462
|
+
@product_id = product_id unless product_id == SKIP
|
|
463
|
+
@product_code = product_code unless product_code == SKIP
|
|
464
|
+
@purchased_in_country = purchased_in_country unless purchased_in_country == SKIP
|
|
465
|
+
@card_group_id = card_group_id unless card_group_id == SKIP
|
|
466
|
+
@sort_order = sort_order unless sort_order == SKIP
|
|
467
|
+
@from_date = from_date unless from_date == SKIP
|
|
468
|
+
@to_date = to_date unless to_date == SKIP
|
|
469
|
+
@period = period unless period == SKIP
|
|
470
|
+
@site_code = site_code unless site_code == SKIP
|
|
471
|
+
@site_group_id = site_group_id unless site_group_id == SKIP
|
|
472
|
+
@posting_date_from = posting_date_from unless posting_date_from == SKIP
|
|
473
|
+
@posting_date_to = posting_date_to unless posting_date_to == SKIP
|
|
474
|
+
@sales_item_id = sales_item_id unless sales_item_id == SKIP
|
|
475
|
+
@transaction_id = transaction_id unless transaction_id == SKIP
|
|
476
|
+
@invoice_date = invoice_date unless invoice_date == SKIP
|
|
477
|
+
@invoice_number = invoice_number unless invoice_number == SKIP
|
|
478
|
+
@valid_invoice_date_only = valid_invoice_date_only unless valid_invoice_date_only == SKIP
|
|
479
|
+
@invoice_from_date = invoice_from_date unless invoice_from_date == SKIP
|
|
480
|
+
@invoice_to_date = invoice_to_date unless invoice_to_date == SKIP
|
|
481
|
+
@fuel_only = fuel_only unless fuel_only == SKIP
|
|
482
|
+
@include_fees = include_fees unless include_fees == SKIP
|
|
483
|
+
@use_field_id = use_field_id unless use_field_id == SKIP
|
|
484
|
+
@current_page = current_page unless current_page == SKIP
|
|
485
|
+
@page_size = page_size unless page_size == SKIP
|
|
486
|
+
end
|
|
487
|
+
|
|
488
|
+
# Creates an instance of the object from a hash.
|
|
489
|
+
def self.from_hash(hash)
|
|
490
|
+
return nil unless hash
|
|
491
|
+
|
|
492
|
+
# Extract variables from the hash.
|
|
493
|
+
col_co_id = hash.key?('ColCoId') ? hash['ColCoId'] : SKIP
|
|
494
|
+
col_co_code = hash.key?('ColCoCode') ? hash['ColCoCode'] : SKIP
|
|
495
|
+
payer_id = hash.key?('PayerId') ? hash['PayerId'] : SKIP
|
|
496
|
+
payer_number = hash.key?('PayerNumber') ? hash['PayerNumber'] : SKIP
|
|
497
|
+
accounts = Accounts.from_hash(hash['Accounts']) if hash['Accounts']
|
|
498
|
+
card_id = hash.key?('CardId') ? hash['CardId'] : SKIP
|
|
499
|
+
card_pan = hash.key?('CardPAN') ? hash['CardPAN'] : SKIP
|
|
500
|
+
driver_name = hash.key?('DriverName') ? hash['DriverName'] : SKIP
|
|
501
|
+
vehicle_registration_number =
|
|
502
|
+
hash.key?('VehicleRegistrationNumber') ? hash['VehicleRegistrationNumber'] : SKIP
|
|
503
|
+
invoice_status = hash.key?('InvoiceStatus') ? hash['InvoiceStatus'] : SKIP
|
|
504
|
+
product_id = hash.key?('ProductId') ? hash['ProductId'] : SKIP
|
|
505
|
+
product_code = hash.key?('ProductCode') ? hash['ProductCode'] : SKIP
|
|
506
|
+
purchased_in_country =
|
|
507
|
+
hash.key?('PurchasedInCountry') ? hash['PurchasedInCountry'] : SKIP
|
|
508
|
+
card_group_id = hash.key?('CardGroupId') ? hash['CardGroupId'] : SKIP
|
|
509
|
+
sort_order = hash.key?('SortOrder') ? hash['SortOrder'] : SKIP
|
|
510
|
+
from_date = hash.key?('FromDate') ? hash['FromDate'] : SKIP
|
|
511
|
+
to_date = hash.key?('ToDate') ? hash['ToDate'] : SKIP
|
|
512
|
+
period = hash.key?('Period') ? hash['Period'] : SKIP
|
|
513
|
+
site_code = hash.key?('SiteCode') ? hash['SiteCode'] : SKIP
|
|
514
|
+
site_group_id = hash.key?('SiteGroupId') ? hash['SiteGroupId'] : SKIP
|
|
515
|
+
posting_date_from =
|
|
516
|
+
hash.key?('PostingDateFrom') ? hash['PostingDateFrom'] : SKIP
|
|
517
|
+
posting_date_to =
|
|
518
|
+
hash.key?('PostingDateTo') ? hash['PostingDateTo'] : SKIP
|
|
519
|
+
sales_item_id = hash.key?('SalesItemId') ? hash['SalesItemId'] : SKIP
|
|
520
|
+
transaction_id = hash.key?('TransactionId') ? hash['TransactionId'] : SKIP
|
|
521
|
+
invoice_date = hash.key?('InvoiceDate') ? hash['InvoiceDate'] : SKIP
|
|
522
|
+
invoice_number = hash.key?('InvoiceNumber') ? hash['InvoiceNumber'] : SKIP
|
|
523
|
+
valid_invoice_date_only =
|
|
524
|
+
hash.key?('ValidInvoiceDateOnly') ? hash['ValidInvoiceDateOnly'] : SKIP
|
|
525
|
+
invoice_from_date =
|
|
526
|
+
hash.key?('InvoiceFromDate') ? hash['InvoiceFromDate'] : SKIP
|
|
527
|
+
invoice_to_date =
|
|
528
|
+
hash.key?('InvoiceToDate') ? hash['InvoiceToDate'] : SKIP
|
|
529
|
+
fuel_only = hash.key?('FuelOnly') ? hash['FuelOnly'] : SKIP
|
|
530
|
+
include_fees = hash.key?('IncludeFees') ? hash['IncludeFees'] : SKIP
|
|
531
|
+
use_field_id = hash.key?('UseFieldId') ? hash['UseFieldId'] : SKIP
|
|
532
|
+
current_page = hash.key?('CurrentPage') ? hash['CurrentPage'] : SKIP
|
|
533
|
+
page_size = hash.key?('PageSize') ? hash['PageSize'] : SKIP
|
|
534
|
+
|
|
535
|
+
# Create object from extracted values.
|
|
536
|
+
PriceTransactionRequest.new(col_co_id,
|
|
537
|
+
col_co_code,
|
|
538
|
+
payer_id,
|
|
539
|
+
payer_number,
|
|
540
|
+
accounts,
|
|
541
|
+
card_id,
|
|
542
|
+
card_pan,
|
|
543
|
+
driver_name,
|
|
544
|
+
vehicle_registration_number,
|
|
545
|
+
invoice_status,
|
|
546
|
+
product_id,
|
|
547
|
+
product_code,
|
|
548
|
+
purchased_in_country,
|
|
549
|
+
card_group_id,
|
|
550
|
+
sort_order,
|
|
551
|
+
from_date,
|
|
552
|
+
to_date,
|
|
553
|
+
period,
|
|
554
|
+
site_code,
|
|
555
|
+
site_group_id,
|
|
556
|
+
posting_date_from,
|
|
557
|
+
posting_date_to,
|
|
558
|
+
sales_item_id,
|
|
559
|
+
transaction_id,
|
|
560
|
+
invoice_date,
|
|
561
|
+
invoice_number,
|
|
562
|
+
valid_invoice_date_only,
|
|
563
|
+
invoice_from_date,
|
|
564
|
+
invoice_to_date,
|
|
565
|
+
fuel_only,
|
|
566
|
+
include_fees,
|
|
567
|
+
use_field_id,
|
|
568
|
+
current_page,
|
|
569
|
+
page_size)
|
|
570
|
+
end
|
|
571
|
+
end
|
|
572
|
+
end
|