Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions docs/files/Association.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ Name | Type | Description | Notes
**name** | **String** | The name of the associated file. Note- The Name element is only returned when using /Associations/{ObjectId} endpoint. | [optional]
**size** | **Integer** | The size of the associated file in bytes. Note- The Size element is only returned when using /Associations/{ObjectId} endpoint. | [optional]
**file_id** | **String** | The unique identifier of the file | [optional]
**object_id** | **String** | The identifier of the object that the file is being associated with (e.g. InvoiceID, BankTransactionID, ContactID) | [optional]
**xero_object_id** | **String** | The identifier of the object that the file is being associated with (e.g. InvoiceID, BankTransactionID, ContactID) | [optional]
**object_group** | [**ObjectGroup**](ObjectGroup.md) | | [optional]
**object_type** | [**ObjectType**](ObjectType.md) | | [optional]

Expand All @@ -21,7 +21,7 @@ instance = XeroRuby::Files::Association.new(send_with_object: true,
name: Test.pdf,
size: 12357,
file_id: null,
object_id: null,
xero_object_id: null,
object_group: null,
object_type: null)
```
Expand Down
14 changes: 7 additions & 7 deletions lib/xero-ruby/models/files/association.rb
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ class Association
attr_accessor :file_id

# The identifier of the object that the file is being associated with (e.g. InvoiceID, BankTransactionID, ContactID)
attr_accessor :object_id
attr_accessor :xero_object_id


attr_accessor :object_group
Expand All @@ -44,7 +44,7 @@ def self.attribute_map
:'name' => :'Name',
:'size' => :'Size',
:'file_id' => :'FileId',
:'object_id' => :'ObjectId',
:'xero_object_id' => :'ObjectId',
:'object_group' => :'ObjectGroup',
:'object_type' => :'ObjectType'
}
Expand All @@ -57,7 +57,7 @@ def self.openapi_types
:'name' => :'String',
:'size' => :'Integer',
:'file_id' => :'String',
:'object_id' => :'String',
:'xero_object_id' => :'String',
:'object_group' => :'ObjectGroup',
:'object_type' => :'ObjectType'
}
Expand Down Expand Up @@ -94,8 +94,8 @@ def initialize(attributes = {})
self.file_id = attributes[:'file_id']
end

if attributes.key?(:'object_id')
self.object_id = attributes[:'object_id']
if attributes.key?(:'xero_object_id')
self.xero_object_id = attributes[:'xero_object_id']
end

if attributes.key?(:'object_group')
Expand Down Expand Up @@ -129,7 +129,7 @@ def ==(o)
name == o.name &&
size == o.size &&
file_id == o.file_id &&
object_id == o.object_id &&
xero_object_id == o.xero_object_id &&
object_group == o.object_group &&
object_type == o.object_type
end
Expand All @@ -143,7 +143,7 @@ def eql?(o)
# Calculates hash code according to all attributes.
# @return [Integer] Hash code
def hash
[send_with_object, name, size, file_id, object_id, object_group, object_type].hash
[send_with_object, name, size, file_id, xero_object_id, object_group, object_type].hash
end

# Builds the object from hash
Expand Down
2 changes: 1 addition & 1 deletion spec/files/models/association_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
end
end

describe 'test attribute "object_id"' do
describe 'test attribute "xero_object_id"' do
it 'should work' do
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
end
Expand Down