xero-ruby 9.3.0 → 18.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.
Files changed (75) hide show
  1. checksums.yaml +4 -4
  2. data/lib/xero-ruby/api/accounting_api.rb +178 -319
  3. data/lib/xero-ruby/api/files_api.rb +9 -2
  4. data/lib/xero-ruby/api/finance_api.rb +0 -299
  5. data/lib/xero-ruby/api/payroll_au_v2_api.rb +751 -0
  6. data/lib/xero-ruby/api/payroll_nz_api.rb +0 -86
  7. data/lib/xero-ruby/api/payroll_uk_api.rb +0 -86
  8. data/lib/xero-ruby/models/accounting/bank_transfer.rb +71 -1
  9. data/lib/xero-ruby/models/accounting/bank_transfer_delete.rb +244 -0
  10. data/lib/xero-ruby/models/accounting/bank_transfer_delete_by_url_param.rb +229 -0
  11. data/lib/xero-ruby/models/accounting/bank_transfers_delete.rb +224 -0
  12. data/lib/xero-ruby/models/accounting/contact.rb +27 -1
  13. data/lib/xero-ruby/models/accounting/credit_note.rb +11 -1
  14. data/lib/xero-ruby/models/accounting/invoice.rb +12 -2
  15. data/lib/xero-ruby/models/accounting/organisation.rb +25 -6
  16. data/lib/xero-ruby/models/accounting/overpayment.rb +21 -1
  17. data/lib/xero-ruby/models/accounting/payment.rb +11 -1
  18. data/lib/xero-ruby/models/accounting/prepayment.rb +31 -1
  19. data/lib/xero-ruby/models/accounting/tracking_reference.rb +277 -0
  20. data/lib/xero-ruby/models/accounting/user.rb +3 -2
  21. data/lib/xero-ruby/models/app_store/product.rb +4 -3
  22. data/lib/xero-ruby/models/assets/book_depreciation_detail.rb +54 -4
  23. data/lib/xero-ruby/models/files/association.rb +21 -1
  24. data/lib/xero-ruby/models/finance/current_statement_response.rb +1 -1
  25. data/lib/xero-ruby/models/finance/data_source_response.rb +1 -31
  26. data/lib/xero-ruby/models/payroll_au/earnings_rate.rb +16 -1
  27. data/lib/xero-ruby/models/payroll_au/employee.rb +1 -13
  28. data/lib/xero-ruby/models/payroll_au/leave_line.rb +16 -1
  29. data/lib/xero-ruby/models/payroll_au/leave_type.rb +19 -4
  30. data/lib/xero-ruby/models/payroll_au/opening_balance_leave_line.rb +232 -0
  31. data/lib/xero-ruby/models/payroll_au/opening_balances.rb +1 -1
  32. data/lib/xero-ruby/models/payroll_au/tax_declaration.rb +14 -4
  33. data/lib/xero-ruby/models/payroll_au_v2/invalid_field.rb +232 -0
  34. data/lib/xero-ruby/models/payroll_au_v2/pagination.rb +252 -0
  35. data/lib/xero-ruby/models/payroll_au_v2/problem.rb +275 -0
  36. data/lib/xero-ruby/models/payroll_au_v2/timesheet.rb +361 -0
  37. data/lib/xero-ruby/models/payroll_au_v2/timesheet_line.rb +277 -0
  38. data/lib/xero-ruby/models/payroll_au_v2/timesheet_line_object.rb +242 -0
  39. data/lib/xero-ruby/models/payroll_au_v2/timesheet_object.rb +242 -0
  40. data/lib/xero-ruby/models/payroll_au_v2/timesheets.rb +244 -0
  41. data/lib/xero-ruby/models/payroll_nz/employee.rb +20 -0
  42. data/lib/xero-ruby/models/payroll_nz/employee_leave_setup.rb +29 -19
  43. data/lib/xero-ruby/models/payroll_nz/employee_leave_type.rb +31 -11
  44. data/lib/xero-ruby/models/payroll_nz/employee_pay_template.rb +5 -0
  45. data/lib/xero-ruby/models/payroll_nz/employment.rb +15 -0
  46. data/lib/xero-ruby/models/payroll_nz/leave_period.rb +35 -4
  47. data/lib/xero-ruby/models/payroll_nz/leave_type.rb +24 -4
  48. data/lib/xero-ruby/models/payroll_uk/contract_type.rb +38 -0
  49. data/lib/xero-ruby/models/payroll_uk/contracts.rb +297 -0
  50. data/lib/xero-ruby/models/payroll_uk/developmental_role_details.rb +267 -0
  51. data/lib/xero-ruby/models/payroll_uk/earnings_rate.rb +5 -2
  52. data/lib/xero-ruby/models/payroll_uk/employee.rb +68 -4
  53. data/lib/xero-ruby/models/payroll_uk/employee_pay_template.rb +5 -0
  54. data/lib/xero-ruby/models/payroll_uk/employee_statutory_leave_balance.rb +4 -2
  55. data/lib/xero-ruby/models/payroll_uk/employee_statutory_leave_summary.rb +5 -2
  56. data/lib/xero-ruby/models/payroll_uk/employment.rb +49 -52
  57. data/lib/xero-ruby/models/payroll_uk/employment_status.rb +37 -0
  58. data/lib/xero-ruby/models/payroll_uk/ni_category.rb +318 -0
  59. data/lib/xero-ruby/models/payroll_uk/ni_category_letter.rb +51 -0
  60. data/lib/xero-ruby/models/payroll_uk/ni_category_one_of.rb +264 -0
  61. data/lib/xero-ruby/models/payroll_uk/ni_category_one_of1.rb +257 -0
  62. data/lib/xero-ruby/version.rb +2 -2
  63. data/lib/xero-ruby.rb +22 -10
  64. data/spec/finance/api/finance_api_spec.rb +0 -53
  65. metadata +393 -391
  66. data/spec/finance/models/account_usage_response_spec.rb +0 -58
  67. data/spec/finance/models/account_usage_spec.rb +0 -112
  68. data/spec/finance/models/history_record_response_spec.rb +0 -64
  69. data/spec/finance/models/lock_history_model_spec.rb +0 -52
  70. data/spec/finance/models/lock_history_response_spec.rb +0 -52
  71. data/spec/finance/models/practice_response_spec.rb +0 -64
  72. data/spec/finance/models/report_history_model_spec.rb +0 -52
  73. data/spec/finance/models/report_history_response_spec.rb +0 -52
  74. data/spec/finance/models/user_activities_response_spec.rb +0 -52
  75. data/spec/finance/models/user_response_spec.rb +0 -106
@@ -25,11 +25,12 @@ module XeroRuby::AppStore
25
25
  # The unit of the per seat product. e.g. \"user\", \"organisation\", \"SMS\", etc
26
26
  attr_accessor :seat_unit
27
27
 
28
- # The pricing model of the product: * FIXED: Customers are charged a fixed amount for each billing period * PER_SEAT: Customers are charged based on the number of units they purchase * METERED: Customers are charged per use of this product
28
+ # The pricing model of the product: * FIXED: Customers are charged a fixed amount for each billing period * PER_SEAT: Customers are charged based on the number of units they purchase * METERED: Customers are charged per use of this product * SIMPLE: Customers are charged on a fixed amount for each billing period with an optional add-on feature
29
29
  attr_accessor :type
30
30
  FIXED ||= "FIXED".freeze
31
31
  PER_SEAT ||= "PER_SEAT".freeze
32
32
  METERED ||= "METERED".freeze
33
+ SIMPLE ||= "SIMPLE".freeze
33
34
 
34
35
  # The unit of the usage product. e.g. \"user\", \"minutes\", \"SMS\", etc
35
36
  attr_accessor :usage_unit
@@ -124,7 +125,7 @@ module XeroRuby::AppStore
124
125
  # Check to see if the all the properties in the model are valid
125
126
  # @return true if the model is valid
126
127
  def valid?
127
- type_validator = EnumAttributeValidator.new('String', ["FIXED", "PER_SEAT", "METERED"])
128
+ type_validator = EnumAttributeValidator.new('String', ["FIXED", "PER_SEAT", "METERED", "SIMPLE"])
128
129
  return false unless type_validator.valid?(@type)
129
130
  true
130
131
  end
@@ -132,7 +133,7 @@ module XeroRuby::AppStore
132
133
  # Custom attribute writer method checking allowed values (enum).
133
134
  # @param [Object] type Object to be assigned
134
135
  def type=(type)
135
- validator = EnumAttributeValidator.new('String', ["FIXED", "PER_SEAT", "METERED"])
136
+ validator = EnumAttributeValidator.new('String', ["FIXED", "PER_SEAT", "METERED", "SIMPLE"])
136
137
  unless validator.valid?(type)
137
138
  fail ArgumentError, "invalid value for \"type\", must be one of #{validator.allowable_values}."
138
139
  end
@@ -37,6 +37,21 @@ module XeroRuby::Assets
37
37
  # All depreciation occurring in the current financial year.
38
38
  attr_accessor :current_accum_depreciation_amount
39
39
 
40
+ # (New Zealand Orgs Only) The portion of capital gain realised from the disposal of a fixed asset that is attributable to its business use.
41
+ attr_accessor :business_use_capital_gain
42
+
43
+ # (New Zealand Orgs Only) Represents the gain or loss from the disposal of the business use portion of a fixed asset. This value records the financial result (profit or loss) related specifically to the asset’s business use.
44
+ attr_accessor :business_use_current_gain_loss
45
+
46
+ # (New Zealand Orgs Only) The portion of capital gain realised from the disposal of a fixed asset that is attributable to its private (non-business) use.
47
+ attr_accessor :private_use_capital_gain
48
+
49
+ # (New Zealand Orgs Only) Represents the gain or loss from the disposal of the private use portion of a fixed asset. This value records the financial result (profit or loss) related specifically to the asset’s private use.
50
+ attr_accessor :private_use_current_gain_loss
51
+
52
+ # (New Zealand Orgs Only) The Investment Boost deduction percentage.
53
+ attr_accessor :initial_deduction_percentage
54
+
40
55
  # Attribute mapping from ruby-style variable name to JSON key.
41
56
  def self.attribute_map
42
57
  {
@@ -46,7 +61,12 @@ module XeroRuby::Assets
46
61
  :'cost_limit' => :'costLimit',
47
62
  :'residual_value' => :'residualValue',
48
63
  :'prior_accum_depreciation_amount' => :'priorAccumDepreciationAmount',
49
- :'current_accum_depreciation_amount' => :'currentAccumDepreciationAmount'
64
+ :'current_accum_depreciation_amount' => :'currentAccumDepreciationAmount',
65
+ :'business_use_capital_gain' => :'businessUseCapitalGain',
66
+ :'business_use_current_gain_loss' => :'businessUseCurrentGainLoss',
67
+ :'private_use_capital_gain' => :'privateUseCapitalGain',
68
+ :'private_use_current_gain_loss' => :'privateUseCurrentGainLoss',
69
+ :'initial_deduction_percentage' => :'initialDeductionPercentage'
50
70
  }
51
71
  end
52
72
 
@@ -59,7 +79,12 @@ module XeroRuby::Assets
59
79
  :'cost_limit' => :'BigDecimal',
60
80
  :'residual_value' => :'BigDecimal',
61
81
  :'prior_accum_depreciation_amount' => :'BigDecimal',
62
- :'current_accum_depreciation_amount' => :'BigDecimal'
82
+ :'current_accum_depreciation_amount' => :'BigDecimal',
83
+ :'business_use_capital_gain' => :'BigDecimal',
84
+ :'business_use_current_gain_loss' => :'BigDecimal',
85
+ :'private_use_capital_gain' => :'BigDecimal',
86
+ :'private_use_current_gain_loss' => :'BigDecimal',
87
+ :'initial_deduction_percentage' => :'Float'
63
88
  }
64
89
  end
65
90
 
@@ -105,6 +130,26 @@ module XeroRuby::Assets
105
130
  if attributes.key?(:'current_accum_depreciation_amount')
106
131
  self.current_accum_depreciation_amount = attributes[:'current_accum_depreciation_amount']
107
132
  end
133
+
134
+ if attributes.key?(:'business_use_capital_gain')
135
+ self.business_use_capital_gain = attributes[:'business_use_capital_gain']
136
+ end
137
+
138
+ if attributes.key?(:'business_use_current_gain_loss')
139
+ self.business_use_current_gain_loss = attributes[:'business_use_current_gain_loss']
140
+ end
141
+
142
+ if attributes.key?(:'private_use_capital_gain')
143
+ self.private_use_capital_gain = attributes[:'private_use_capital_gain']
144
+ end
145
+
146
+ if attributes.key?(:'private_use_current_gain_loss')
147
+ self.private_use_current_gain_loss = attributes[:'private_use_current_gain_loss']
148
+ end
149
+
150
+ if attributes.key?(:'initial_deduction_percentage')
151
+ self.initial_deduction_percentage = attributes[:'initial_deduction_percentage']
152
+ end
108
153
  end
109
154
 
110
155
  # Show invalid properties with the reasons. Usually used together with valid?
@@ -131,7 +176,12 @@ module XeroRuby::Assets
131
176
  cost_limit == o.cost_limit &&
132
177
  residual_value == o.residual_value &&
133
178
  prior_accum_depreciation_amount == o.prior_accum_depreciation_amount &&
134
- current_accum_depreciation_amount == o.current_accum_depreciation_amount
179
+ current_accum_depreciation_amount == o.current_accum_depreciation_amount &&
180
+ business_use_capital_gain == o.business_use_capital_gain &&
181
+ business_use_current_gain_loss == o.business_use_current_gain_loss &&
182
+ private_use_capital_gain == o.private_use_capital_gain &&
183
+ private_use_current_gain_loss == o.private_use_current_gain_loss &&
184
+ initial_deduction_percentage == o.initial_deduction_percentage
135
185
  end
136
186
 
137
187
  # @see the `==` method
@@ -143,7 +193,7 @@ module XeroRuby::Assets
143
193
  # Calculates hash code according to all attributes.
144
194
  # @return [Integer] Hash code
145
195
  def hash
146
- [current_capital_gain, current_gain_loss, depreciation_start_date, cost_limit, residual_value, prior_accum_depreciation_amount, current_accum_depreciation_amount].hash
196
+ [current_capital_gain, current_gain_loss, depreciation_start_date, cost_limit, residual_value, prior_accum_depreciation_amount, current_accum_depreciation_amount, business_use_capital_gain, business_use_current_gain_loss, private_use_capital_gain, private_use_current_gain_loss, initial_deduction_percentage].hash
147
197
  end
148
198
 
149
199
  # Builds the object from hash
@@ -25,6 +25,12 @@ module XeroRuby::Files
25
25
  # The size of the associated file in bytes. Note- The Size element is only returned when using /Associations/{ObjectId} endpoint.
26
26
  attr_accessor :size
27
27
 
28
+ # The date the file was created (UTC). Note- The CreatedDateUtc element is only returned when using /Associations/{ObjectId} endpoint.
29
+ attr_accessor :created_date_utc
30
+
31
+ # The date the file was associated with the object (UTC). Note- The AssociationDateUtc element is only returned when using /Associations/{ObjectId} endpoint.
32
+ attr_accessor :association_date_utc
33
+
28
34
  # The unique identifier of the file
29
35
  attr_accessor :file_id
30
36
 
@@ -43,6 +49,8 @@ module XeroRuby::Files
43
49
  :'send_with_object' => :'SendWithObject',
44
50
  :'name' => :'Name',
45
51
  :'size' => :'Size',
52
+ :'created_date_utc' => :'CreatedDateUtc',
53
+ :'association_date_utc' => :'AssociationDateUtc',
46
54
  :'file_id' => :'FileId',
47
55
  :'object_id' => :'ObjectId',
48
56
  :'object_group' => :'ObjectGroup',
@@ -56,6 +64,8 @@ module XeroRuby::Files
56
64
  :'send_with_object' => :'Boolean',
57
65
  :'name' => :'String',
58
66
  :'size' => :'Integer',
67
+ :'created_date_utc' => :'DateTime',
68
+ :'association_date_utc' => :'DateTime',
59
69
  :'file_id' => :'String',
60
70
  :'object_id' => :'String',
61
71
  :'object_group' => :'ObjectGroup',
@@ -90,6 +100,14 @@ module XeroRuby::Files
90
100
  self.size = attributes[:'size']
91
101
  end
92
102
 
103
+ if attributes.key?(:'created_date_utc')
104
+ self.created_date_utc = attributes[:'created_date_utc']
105
+ end
106
+
107
+ if attributes.key?(:'association_date_utc')
108
+ self.association_date_utc = attributes[:'association_date_utc']
109
+ end
110
+
93
111
  if attributes.key?(:'file_id')
94
112
  self.file_id = attributes[:'file_id']
95
113
  end
@@ -128,6 +146,8 @@ module XeroRuby::Files
128
146
  send_with_object == o.send_with_object &&
129
147
  name == o.name &&
130
148
  size == o.size &&
149
+ created_date_utc == o.created_date_utc &&
150
+ association_date_utc == o.association_date_utc &&
131
151
  file_id == o.file_id &&
132
152
  object_id == o.object_id &&
133
153
  object_group == o.object_group &&
@@ -143,7 +163,7 @@ module XeroRuby::Files
143
163
  # Calculates hash code according to all attributes.
144
164
  # @return [Integer] Hash code
145
165
  def hash
146
- [send_with_object, name, size, file_id, object_id, object_group, object_type].hash
166
+ [send_with_object, name, size, created_date_utc, association_date_utc, file_id, object_id, object_group, object_type].hash
147
167
  end
148
168
 
149
169
  # Builds the object from hash
@@ -31,7 +31,7 @@ module XeroRuby::Finance
31
31
  # Looking at the most recent bank statement, this field indicates when the document was imported into Xero. This date is represented in ISO 8601 format.
32
32
  attr_accessor :imported_date_time_utc
33
33
 
34
- # Looking at the most recent bank statement, this field indicates the source of the data (direct bank feed, indirect bank feed, file upload, or manual keying).
34
+ # Looking at the most recent bank statement, this field indicates the source of the data (direct bank feed, file upload, or manual keying).
35
35
  attr_accessor :import_source_type
36
36
 
37
37
  # Attribute mapping from ruby-style variable name to JSON key.
@@ -19,9 +19,6 @@ module XeroRuby::Finance
19
19
  # Sum of the amounts of all statement lines where the source of the data was a direct bank feed in to Xero via an API integration. This could be from a bank or aggregator. This gives an indication on the certainty of correctness of the data.
20
20
  attr_accessor :direct_bank_feed
21
21
 
22
- # No longer in use.
23
- attr_accessor :indirect_bank_feed
24
-
25
22
  # Sum of the amounts of all statement lines where the source of the data was a file manually uploaded in to Xero. This gives an indication on the certainty of correctness of the data.
26
23
  attr_accessor :file_upload
27
24
 
@@ -31,9 +28,6 @@ module XeroRuby::Finance
31
28
  # Sum of the amounts of all statement lines where the source of the data was a direct bank feed in to Xero via an API integration. This could be from a bank or aggregator. This gives an indication on the certainty of correctness of the data. Only positive transactions are included.
32
29
  attr_accessor :direct_bank_feed_pos
33
30
 
34
- # No longer in use.
35
- attr_accessor :indirect_bank_feed_pos
36
-
37
31
  # Sum of the amounts of all statement lines where the source of the data was a file manually uploaded in to Xero. This gives an indication on the certainty of correctness of the data. Only positive transactions are included.
38
32
  attr_accessor :file_upload_pos
39
33
 
@@ -43,9 +37,6 @@ module XeroRuby::Finance
43
37
  # Sum of the amounts of all statement lines where the source of the data was a direct bank feed in to Xero via an API integration. This could be from a bank or aggregator. This gives an indication on the certainty of correctness of the data. Only negative transactions are included.
44
38
  attr_accessor :direct_bank_feed_neg
45
39
 
46
- # No longer in use.
47
- attr_accessor :indirect_bank_feed_neg
48
-
49
40
  # Sum of the amounts of all statement lines where the source of the data was a file manually uploaded in to Xero. This gives an indication on the certainty of correctness of the data. Only negative transactions are included.
50
41
  attr_accessor :file_upload_neg
51
42
 
@@ -65,15 +56,12 @@ module XeroRuby::Finance
65
56
  def self.attribute_map
66
57
  {
67
58
  :'direct_bank_feed' => :'directBankFeed',
68
- :'indirect_bank_feed' => :'indirectBankFeed',
69
59
  :'file_upload' => :'fileUpload',
70
60
  :'manual' => :'manual',
71
61
  :'direct_bank_feed_pos' => :'directBankFeedPos',
72
- :'indirect_bank_feed_pos' => :'indirectBankFeedPos',
73
62
  :'file_upload_pos' => :'fileUploadPos',
74
63
  :'manual_pos' => :'manualPos',
75
64
  :'direct_bank_feed_neg' => :'directBankFeedNeg',
76
- :'indirect_bank_feed_neg' => :'indirectBankFeedNeg',
77
65
  :'file_upload_neg' => :'fileUploadNeg',
78
66
  :'manual_neg' => :'manualNeg',
79
67
  :'other_pos' => :'otherPos',
@@ -86,15 +74,12 @@ module XeroRuby::Finance
86
74
  def self.openapi_types
87
75
  {
88
76
  :'direct_bank_feed' => :'BigDecimal',
89
- :'indirect_bank_feed' => :'BigDecimal',
90
77
  :'file_upload' => :'BigDecimal',
91
78
  :'manual' => :'BigDecimal',
92
79
  :'direct_bank_feed_pos' => :'BigDecimal',
93
- :'indirect_bank_feed_pos' => :'BigDecimal',
94
80
  :'file_upload_pos' => :'BigDecimal',
95
81
  :'manual_pos' => :'BigDecimal',
96
82
  :'direct_bank_feed_neg' => :'BigDecimal',
97
- :'indirect_bank_feed_neg' => :'BigDecimal',
98
83
  :'file_upload_neg' => :'BigDecimal',
99
84
  :'manual_neg' => :'BigDecimal',
100
85
  :'other_pos' => :'BigDecimal',
@@ -122,10 +107,6 @@ module XeroRuby::Finance
122
107
  self.direct_bank_feed = attributes[:'direct_bank_feed']
123
108
  end
124
109
 
125
- if attributes.key?(:'indirect_bank_feed')
126
- self.indirect_bank_feed = attributes[:'indirect_bank_feed']
127
- end
128
-
129
110
  if attributes.key?(:'file_upload')
130
111
  self.file_upload = attributes[:'file_upload']
131
112
  end
@@ -138,10 +119,6 @@ module XeroRuby::Finance
138
119
  self.direct_bank_feed_pos = attributes[:'direct_bank_feed_pos']
139
120
  end
140
121
 
141
- if attributes.key?(:'indirect_bank_feed_pos')
142
- self.indirect_bank_feed_pos = attributes[:'indirect_bank_feed_pos']
143
- end
144
-
145
122
  if attributes.key?(:'file_upload_pos')
146
123
  self.file_upload_pos = attributes[:'file_upload_pos']
147
124
  end
@@ -154,10 +131,6 @@ module XeroRuby::Finance
154
131
  self.direct_bank_feed_neg = attributes[:'direct_bank_feed_neg']
155
132
  end
156
133
 
157
- if attributes.key?(:'indirect_bank_feed_neg')
158
- self.indirect_bank_feed_neg = attributes[:'indirect_bank_feed_neg']
159
- end
160
-
161
134
  if attributes.key?(:'file_upload_neg')
162
135
  self.file_upload_neg = attributes[:'file_upload_neg']
163
136
  end
@@ -198,15 +171,12 @@ module XeroRuby::Finance
198
171
  return true if self.equal?(o)
199
172
  self.class == o.class &&
200
173
  direct_bank_feed == o.direct_bank_feed &&
201
- indirect_bank_feed == o.indirect_bank_feed &&
202
174
  file_upload == o.file_upload &&
203
175
  manual == o.manual &&
204
176
  direct_bank_feed_pos == o.direct_bank_feed_pos &&
205
- indirect_bank_feed_pos == o.indirect_bank_feed_pos &&
206
177
  file_upload_pos == o.file_upload_pos &&
207
178
  manual_pos == o.manual_pos &&
208
179
  direct_bank_feed_neg == o.direct_bank_feed_neg &&
209
- indirect_bank_feed_neg == o.indirect_bank_feed_neg &&
210
180
  file_upload_neg == o.file_upload_neg &&
211
181
  manual_neg == o.manual_neg &&
212
182
  other_pos == o.other_pos &&
@@ -223,7 +193,7 @@ module XeroRuby::Finance
223
193
  # Calculates hash code according to all attributes.
224
194
  # @return [Integer] Hash code
225
195
  def hash
226
- [direct_bank_feed, indirect_bank_feed, file_upload, manual, direct_bank_feed_pos, indirect_bank_feed_pos, file_upload_pos, manual_pos, direct_bank_feed_neg, indirect_bank_feed_neg, file_upload_neg, manual_neg, other_pos, other_neg, other].hash
196
+ [direct_bank_feed, file_upload, manual, direct_bank_feed_pos, file_upload_pos, manual_pos, direct_bank_feed_neg, file_upload_neg, manual_neg, other_pos, other_neg, other].hash
227
197
  end
228
198
 
229
199
  # Builds the object from hash
@@ -34,6 +34,9 @@ module XeroRuby::PayrollAu
34
34
  # Boolean to determine if the earnings rate is reportable or exempt from W1
35
35
  attr_accessor :is_reportable_as_w1
36
36
 
37
+ # Boolean to determine if the earnings rate is considered as qualifying earnings for superannuation guarantee calculations
38
+ attr_accessor :is_qualifying_earnings
39
+
37
40
  # Boolean to determine if the allowance earnings rate contributes towards annual leave rate. Only applicable if EarningsType is ALLOWANCE and RateType is RATEPERUNIT
38
41
  attr_accessor :allowance_contributes_to_annual_leave_rate
39
42
 
@@ -85,6 +88,7 @@ module XeroRuby::PayrollAu
85
88
  :'is_exempt_from_tax' => :'IsExemptFromTax',
86
89
  :'is_exempt_from_super' => :'IsExemptFromSuper',
87
90
  :'is_reportable_as_w1' => :'IsReportableAsW1',
91
+ :'is_qualifying_earnings' => :'IsQualifyingEarnings',
88
92
  :'allowance_contributes_to_annual_leave_rate' => :'AllowanceContributesToAnnualLeaveRate',
89
93
  :'allowance_contributes_to_overtime_rate' => :'AllowanceContributesToOvertimeRate',
90
94
  :'earnings_type' => :'EarningsType',
@@ -111,6 +115,7 @@ module XeroRuby::PayrollAu
111
115
  :'is_exempt_from_tax' => :'Boolean',
112
116
  :'is_exempt_from_super' => :'Boolean',
113
117
  :'is_reportable_as_w1' => :'Boolean',
118
+ :'is_qualifying_earnings' => :'Boolean',
114
119
  :'allowance_contributes_to_annual_leave_rate' => :'Boolean',
115
120
  :'allowance_contributes_to_overtime_rate' => :'Boolean',
116
121
  :'earnings_type' => :'EarningsType',
@@ -167,6 +172,10 @@ module XeroRuby::PayrollAu
167
172
  self.is_reportable_as_w1 = attributes[:'is_reportable_as_w1']
168
173
  end
169
174
 
175
+ if attributes.key?(:'is_qualifying_earnings')
176
+ self.is_qualifying_earnings = attributes[:'is_qualifying_earnings']
177
+ end
178
+
170
179
  if attributes.key?(:'allowance_contributes_to_annual_leave_rate')
171
180
  self.allowance_contributes_to_annual_leave_rate = attributes[:'allowance_contributes_to_annual_leave_rate']
172
181
  end
@@ -236,6 +245,10 @@ module XeroRuby::PayrollAu
236
245
  invalid_properties.push('invalid value for "type_of_units", the character length must be smaller than or equal to 50.')
237
246
  end
238
247
 
248
+ if @is_qualifying_earnings.nil?
249
+ invalid_properties.push('invalid value for "is_qualifying_earnings", is_qualifying_earnings cannot be nil.')
250
+ end
251
+
239
252
  invalid_properties
240
253
  end
241
254
 
@@ -244,6 +257,7 @@ module XeroRuby::PayrollAu
244
257
  def valid?
245
258
  return false if !@name.nil? && @name.to_s.length > 100
246
259
  return false if !@type_of_units.nil? && @type_of_units.to_s.length > 50
260
+ return false if @is_qualifying_earnings.nil?
247
261
  true
248
262
  end
249
263
 
@@ -278,6 +292,7 @@ module XeroRuby::PayrollAu
278
292
  is_exempt_from_tax == o.is_exempt_from_tax &&
279
293
  is_exempt_from_super == o.is_exempt_from_super &&
280
294
  is_reportable_as_w1 == o.is_reportable_as_w1 &&
295
+ is_qualifying_earnings == o.is_qualifying_earnings &&
281
296
  allowance_contributes_to_annual_leave_rate == o.allowance_contributes_to_annual_leave_rate &&
282
297
  allowance_contributes_to_overtime_rate == o.allowance_contributes_to_overtime_rate &&
283
298
  earnings_type == o.earnings_type &&
@@ -303,7 +318,7 @@ module XeroRuby::PayrollAu
303
318
  # Calculates hash code according to all attributes.
304
319
  # @return [Integer] Hash code
305
320
  def hash
306
- [name, account_code, type_of_units, is_exempt_from_tax, is_exempt_from_super, is_reportable_as_w1, allowance_contributes_to_annual_leave_rate, allowance_contributes_to_overtime_rate, earnings_type, earnings_rate_id, rate_type, rate_per_unit, multiplier, accrue_leave, amount, employment_termination_payment_type, updated_date_utc, current_record, allowance_type, allowance_category].hash
321
+ [name, account_code, type_of_units, is_exempt_from_tax, is_exempt_from_super, is_reportable_as_w1, is_qualifying_earnings, allowance_contributes_to_annual_leave_rate, allowance_contributes_to_overtime_rate, earnings_type, earnings_rate_id, rate_type, rate_per_unit, multiplier, accrue_leave, amount, employment_termination_payment_type, updated_date_utc, current_record, allowance_type, allowance_category].hash
307
322
  end
308
323
 
309
324
  # Builds the object from hash
@@ -121,9 +121,6 @@ module XeroRuby::PayrollAu
121
121
  attr_accessor :leave_balances
122
122
 
123
123
 
124
- attr_accessor :leave_lines
125
-
126
-
127
124
  attr_accessor :super_memberships
128
125
 
129
126
 
@@ -191,7 +188,6 @@ module XeroRuby::PayrollAu
191
188
  :'country_of_residence' => :'CountryOfResidence',
192
189
  :'is_stp2_qualified' => :'IsSTP2Qualified',
193
190
  :'leave_balances' => :'LeaveBalances',
194
- :'leave_lines' => :'LeaveLines',
195
191
  :'super_memberships' => :'SuperMemberships',
196
192
  :'status' => :'Status',
197
193
  :'updated_date_utc' => :'UpdatedDateUTC',
@@ -233,7 +229,6 @@ module XeroRuby::PayrollAu
233
229
  :'country_of_residence' => :'CountryOfResidence',
234
230
  :'is_stp2_qualified' => :'Boolean',
235
231
  :'leave_balances' => :'Array<LeaveBalance>',
236
- :'leave_lines' => :'Array<LeaveLine>',
237
232
  :'super_memberships' => :'Array<SuperMembership>',
238
233
  :'status' => :'EmployeeStatus',
239
234
  :'updated_date_utc' => :'DateTime',
@@ -384,12 +379,6 @@ module XeroRuby::PayrollAu
384
379
  end
385
380
  end
386
381
 
387
- if attributes.key?(:'leave_lines')
388
- if (value = attributes[:'leave_lines']).is_a?(Array)
389
- self.leave_lines = value
390
- end
391
- end
392
-
393
382
  if attributes.key?(:'super_memberships')
394
383
  if (value = attributes[:'super_memberships']).is_a?(Array)
395
384
  self.super_memberships = value
@@ -499,7 +488,6 @@ module XeroRuby::PayrollAu
499
488
  country_of_residence == o.country_of_residence &&
500
489
  is_stp2_qualified == o.is_stp2_qualified &&
501
490
  leave_balances == o.leave_balances &&
502
- leave_lines == o.leave_lines &&
503
491
  super_memberships == o.super_memberships &&
504
492
  status == o.status &&
505
493
  updated_date_utc == o.updated_date_utc &&
@@ -515,7 +503,7 @@ module XeroRuby::PayrollAu
515
503
  # Calculates hash code according to all attributes.
516
504
  # @return [Integer] Hash code
517
505
  def hash
518
- [first_name, last_name, date_of_birth, home_address, start_date, title, middle_names, email, gender, phone, mobile, twitter_user_name, is_authorised_to_approve_leave, is_authorised_to_approve_timesheets, job_title, classification, ordinary_earnings_rate_id, payroll_calendar_id, employee_group_name, employee_id, termination_date, termination_reason, bank_accounts, pay_template, opening_balances, tax_declaration, income_type, employment_type, country_of_residence, is_stp2_qualified, leave_balances, leave_lines, super_memberships, status, updated_date_utc, validation_errors].hash
506
+ [first_name, last_name, date_of_birth, home_address, start_date, title, middle_names, email, gender, phone, mobile, twitter_user_name, is_authorised_to_approve_leave, is_authorised_to_approve_timesheets, job_title, classification, ordinary_earnings_rate_id, payroll_calendar_id, employee_group_name, employee_id, termination_date, termination_reason, bank_accounts, pay_template, opening_balances, tax_declaration, income_type, employment_type, country_of_residence, is_stp2_qualified, leave_balances, super_memberships, status, updated_date_utc, validation_errors].hash
519
507
  end
520
508
 
521
509
  # Builds the object from hash
@@ -31,6 +31,9 @@ module XeroRuby::PayrollAu
31
31
  # amount of leave line
32
32
  attr_accessor :include_superannuation_guarantee_contribution
33
33
 
34
+ # Boolean to determine if the leave line is considered as qualifying earnings for superannuation guarantee calculations
35
+ attr_accessor :is_qualifying_earnings
36
+
34
37
  # Number of units for leave line.
35
38
  attr_accessor :number_of_units
36
39
 
@@ -48,6 +51,7 @@ module XeroRuby::PayrollAu
48
51
  :'entitlement_final_pay_payout_type' => :'EntitlementFinalPayPayoutType',
49
52
  :'employment_termination_payment_type' => :'EmploymentTerminationPaymentType',
50
53
  :'include_superannuation_guarantee_contribution' => :'IncludeSuperannuationGuaranteeContribution',
54
+ :'is_qualifying_earnings' => :'IsQualifyingEarnings',
51
55
  :'number_of_units' => :'NumberOfUnits',
52
56
  :'annual_number_of_units' => :'AnnualNumberOfUnits',
53
57
  :'full_time_number_of_units_per_period' => :'FullTimeNumberOfUnitsPerPeriod'
@@ -62,6 +66,7 @@ module XeroRuby::PayrollAu
62
66
  :'entitlement_final_pay_payout_type' => :'EntitlementFinalPayPayoutType',
63
67
  :'employment_termination_payment_type' => :'EmploymentTerminationPaymentType',
64
68
  :'include_superannuation_guarantee_contribution' => :'Boolean',
69
+ :'is_qualifying_earnings' => :'Boolean',
65
70
  :'number_of_units' => :'BigDecimal',
66
71
  :'annual_number_of_units' => :'BigDecimal',
67
72
  :'full_time_number_of_units_per_period' => :'BigDecimal'
@@ -103,6 +108,10 @@ module XeroRuby::PayrollAu
103
108
  self.include_superannuation_guarantee_contribution = attributes[:'include_superannuation_guarantee_contribution']
104
109
  end
105
110
 
111
+ if attributes.key?(:'is_qualifying_earnings')
112
+ self.is_qualifying_earnings = attributes[:'is_qualifying_earnings']
113
+ end
114
+
106
115
  if attributes.key?(:'number_of_units')
107
116
  self.number_of_units = attributes[:'number_of_units']
108
117
  end
@@ -120,12 +129,17 @@ module XeroRuby::PayrollAu
120
129
  # @return Array for valid properties with the reasons
121
130
  def list_invalid_properties
122
131
  invalid_properties = Array.new
132
+ if @is_qualifying_earnings.nil?
133
+ invalid_properties.push('invalid value for "is_qualifying_earnings", is_qualifying_earnings cannot be nil.')
134
+ end
135
+
123
136
  invalid_properties
124
137
  end
125
138
 
126
139
  # Check to see if the all the properties in the model are valid
127
140
  # @return true if the model is valid
128
141
  def valid?
142
+ return false if @is_qualifying_earnings.nil?
129
143
  true
130
144
  end
131
145
 
@@ -139,6 +153,7 @@ module XeroRuby::PayrollAu
139
153
  entitlement_final_pay_payout_type == o.entitlement_final_pay_payout_type &&
140
154
  employment_termination_payment_type == o.employment_termination_payment_type &&
141
155
  include_superannuation_guarantee_contribution == o.include_superannuation_guarantee_contribution &&
156
+ is_qualifying_earnings == o.is_qualifying_earnings &&
142
157
  number_of_units == o.number_of_units &&
143
158
  annual_number_of_units == o.annual_number_of_units &&
144
159
  full_time_number_of_units_per_period == o.full_time_number_of_units_per_period
@@ -153,7 +168,7 @@ module XeroRuby::PayrollAu
153
168
  # Calculates hash code according to all attributes.
154
169
  # @return [Integer] Hash code
155
170
  def hash
156
- [leave_type_id, calculation_type, entitlement_final_pay_payout_type, employment_termination_payment_type, include_superannuation_guarantee_contribution, number_of_units, annual_number_of_units, full_time_number_of_units_per_period].hash
171
+ [leave_type_id, calculation_type, entitlement_final_pay_payout_type, employment_termination_payment_type, include_superannuation_guarantee_contribution, is_qualifying_earnings, number_of_units, annual_number_of_units, full_time_number_of_units_per_period].hash
157
172
  end
158
173
 
159
174
  # Builds the object from hash
@@ -49,6 +49,9 @@ module XeroRuby::PayrollAu
49
49
  # Set this to indicate that the leave type is exempt from superannuation guarantee contribution
50
50
  attr_accessor :sgc_exempt
51
51
 
52
+ # Boolean to determine if the leave type is considered as qualifying earnings for superannuation guarantee calculations
53
+ attr_accessor :is_qualifying_earnings
54
+
52
55
  # Attribute mapping from ruby-style variable name to JSON key.
53
56
  def self.attribute_map
54
57
  {
@@ -62,7 +65,8 @@ module XeroRuby::PayrollAu
62
65
  :'show_on_payslip' => :'ShowOnPayslip',
63
66
  :'current_record' => :'CurrentRecord',
64
67
  :'leave_category_code' => :'LeaveCategoryCode',
65
- :'sgc_exempt' => :'SGCExempt'
68
+ :'sgc_exempt' => :'SGCExempt',
69
+ :'is_qualifying_earnings' => :'IsQualifyingEarnings'
66
70
  }
67
71
  end
68
72
 
@@ -79,7 +83,8 @@ module XeroRuby::PayrollAu
79
83
  :'show_on_payslip' => :'Boolean',
80
84
  :'current_record' => :'Boolean',
81
85
  :'leave_category_code' => :'LeaveCategoryCode',
82
- :'sgc_exempt' => :'Boolean'
86
+ :'sgc_exempt' => :'Boolean',
87
+ :'is_qualifying_earnings' => :'Boolean'
83
88
  }
84
89
  end
85
90
 
@@ -141,6 +146,10 @@ module XeroRuby::PayrollAu
141
146
  if attributes.key?(:'sgc_exempt')
142
147
  self.sgc_exempt = attributes[:'sgc_exempt']
143
148
  end
149
+
150
+ if attributes.key?(:'is_qualifying_earnings')
151
+ self.is_qualifying_earnings = attributes[:'is_qualifying_earnings']
152
+ end
144
153
  end
145
154
 
146
155
  # Show invalid properties with the reasons. Usually used together with valid?
@@ -151,6 +160,10 @@ module XeroRuby::PayrollAu
151
160
  invalid_properties.push('invalid value for "name", the character length must be smaller than or equal to 100.')
152
161
  end
153
162
 
163
+ if @is_qualifying_earnings.nil?
164
+ invalid_properties.push('invalid value for "is_qualifying_earnings", is_qualifying_earnings cannot be nil.')
165
+ end
166
+
154
167
  invalid_properties
155
168
  end
156
169
 
@@ -158,6 +171,7 @@ module XeroRuby::PayrollAu
158
171
  # @return true if the model is valid
159
172
  def valid?
160
173
  return false if !@name.nil? && @name.to_s.length > 100
174
+ return false if @is_qualifying_earnings.nil?
161
175
  true
162
176
  end
163
177
 
@@ -186,7 +200,8 @@ module XeroRuby::PayrollAu
186
200
  show_on_payslip == o.show_on_payslip &&
187
201
  current_record == o.current_record &&
188
202
  leave_category_code == o.leave_category_code &&
189
- sgc_exempt == o.sgc_exempt
203
+ sgc_exempt == o.sgc_exempt &&
204
+ is_qualifying_earnings == o.is_qualifying_earnings
190
205
  end
191
206
 
192
207
  # @see the `==` method
@@ -198,7 +213,7 @@ module XeroRuby::PayrollAu
198
213
  # Calculates hash code according to all attributes.
199
214
  # @return [Integer] Hash code
200
215
  def hash
201
- [name, type_of_units, leave_type_id, normal_entitlement, leave_loading_rate, updated_date_utc, is_paid_leave, show_on_payslip, current_record, leave_category_code, sgc_exempt].hash
216
+ [name, type_of_units, leave_type_id, normal_entitlement, leave_loading_rate, updated_date_utc, is_paid_leave, show_on_payslip, current_record, leave_category_code, sgc_exempt, is_qualifying_earnings].hash
202
217
  end
203
218
 
204
219
  # Builds the object from hash