Add in_current_month? method to the TimeEntry model

This commit is contained in:
Paul van Tilburg 2014-11-01 22:09:21 +01:00
parent 68c6a337a1
commit d613a095e1
1 changed files with 4 additions and 0 deletions

View File

@ -427,6 +427,10 @@ module StopTime::Models
((self.end - self.start) / 1.hour).round(2)
end
def in_current_month?
self.end.month == Time.now.month
end
#########
protected