lib/quickbooks/model.rb
# Returns a hash of the attributes and their (new) values that have been changed since the object was last loaded or updated from Quickbooks.
# If you send in some attributes, it will compare to those given instead of original_attributes.
Returns a hash of the attributes and their (new) values that have been changed since the object was last loaded or updated from Quickbooks.
If you send in some attributes, it will compare to those given instead of original_attributes.
Returns a hash of the attributes and their ( new ) values that have been changed since the object was last loaded or updated from Quickbooks . If you send in some attributes it will compare to those given instead of original_attributes .
def dirty_attributes(compare={})
      compare = original_values if compare.empty?
      pairs = {}
      self.class.read_write.each do |column|
        value = instance_variable_get('@' + column.to_s)
        if value != compare[column.to_s]
          pairs[column.to_s] = value
        end
      end
      pairs
    end
def dirty_attributes ( compare = { } ) compare = original_values if compare . empty? pairs = { } self . class . read_write . each do | column | value = instance_variable_get ( '@' + column . to_s ) if value != compare [ column . to_s ] pairs [ column . to_s ] = value end end pairs end
Returns a hash of the attributes and their (new) values that have been changed since the object was last loaded or updated from Quickbooks.
Returns a hash of the attributes and their ( new ) values that have been changed since the object was last loaded or updated from Quickbooks .
compare
<not_specific>