instance method
to_s
Ruby on Rails 7.1.6
Since v2.2.3Signature
to_s()
Returns a string of the object’s date and time.
Source
# File activesupport/lib/active_support/time_with_zone.rb, line 200
def to_s
"#{time.strftime("%Y-%m-%d %H:%M:%S")} #{formatted_offset(false, 'UTC')}" # mimicking Ruby Time#to_s format
end
Defined in activesupport/lib/active_support/time_with_zone.rb line 200
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in ActiveSupport::TimeWithZone