Sha256: 9af7255a015c5d08f36009e69d962987053acb927dd5bc77ed559fa38c6764d0
Contents?: true
Size: 371 Bytes
Versions: 18
Compression:
Stored size: 371 Bytes
Contents
module Doing ## ## Date helpers ## class ::Time def relative_date if self > Date.today.to_time strftime('%_I:%M%P') elsif self > (Date.today - 6).to_time strftime('%a %_I:%M%P') elsif self.year == Date.today.year strftime('%m/%d %_I:%M%P') else strftime('%m/%d/%Y %_I:%M%P') end end end end
Version data entries
18 entries across 18 versions & 1 rubygems