class Quickeebooks::Online::Model::Item
Constants
- REST_RESOURCE
<baseURL>/resource/items/v2/<realmID>
- XML_NODE
Public Instance Methods
taxable?()
click to toggle source
# File lib/quickeebooks/online/model/item.rb, line 55 def taxable? taxable == "true" end
to_xml_ns(options = {})
click to toggle source
# File lib/quickeebooks/online/model/item.rb, line 37 def to_xml_ns(options = {}) to_xml_inject_ns('Item', options) end
valid_for_deletion?()
click to toggle source
To delete a record Intuit requires we provide Id
and SyncToken fields
# File lib/quickeebooks/online/model/item.rb, line 42 def valid_for_deletion? return false if(id.nil? || sync_token.nil?) id.to_i > 0 && !sync_token.to_s.empty? && sync_token.to_i >= 0 end
valid_for_update?()
click to toggle source
# File lib/quickeebooks/online/model/item.rb, line 47 def valid_for_update? if sync_token.nil? errors.add(:sync_token, "Missing required attribute SyncToken for update") end valid? errors.empty? end