This commit is contained in:
albert
2013-02-19 21:57:25 -05:00
parent 1a4b5782ea
commit 5202ee42f6
6 changed files with 7 additions and 15 deletions

View File

@@ -67,15 +67,7 @@ module ApplicationHelper
end
def compact_time(time)
if time > Time.now.end_of_day
time_tag(time.strftime("%b %e, %Y"), time)
elsif time > Time.now.beginning_of_day
time_tag(time.strftime("%l:%M %P"), time)
elsif time > Time.now.beginning_of_year
time_tag(time.strftime("%b %e"), time)
else
time_tag(time.strftime("%b %e, %Y"), time)
end
time_tag(time.strftime("%Y-%m-%d %H:%M"), time)
end
def mod_link_to_user(user, positive_or_negative)