method
touch_attributes_with_time
rails latest stable - Class:
ActiveRecord::Timestamp
touch_attributes_with_time(*names, time: nil)public
No documentation available.
# File activerecord/lib/active_record/timestamp.rb, line 56
def touch_attributes_with_time(*names, time: nil)
attribute_names = timestamp_attributes_for_update_in_model
attribute_names |= names.map(&:to_s)
time ||= current_time_from_proper_timezone
attribute_names.each_with_object({}) { |attr_name, result| result[attr_name] = time }
end