Module: RTrail::Helpers::HasCreateTime
Overview
Include this in any Entity with a ‘created_on` attribute to allow getting creation date as a Time instance.
Instance Method Summary collapse
Instance Method Details
#create_time ⇒ Object
51 52 53 |
# File 'lib/rtrail/helpers.rb', line 51 def create_time return Time.at(self[:created_on].to_i).utc end |