Adds date range filter and pagination on time entries detail view (closes #434).
git-svn-id: http://redmine.rubyforge.org/svn/trunk@1173 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
@@ -46,5 +46,10 @@ class TimeEntry < ActiveRecord::Base
|
||||
self.tyear = spent_on ? spent_on.year : nil
|
||||
self.tmonth = spent_on ? spent_on.month : nil
|
||||
self.tweek = spent_on ? Date.civil(spent_on.year, spent_on.month, spent_on.day).cweek : nil
|
||||
end
|
||||
end
|
||||
|
||||
# Returns true if the time entry can be edited by usr, otherwise false
|
||||
def editable_by?(usr)
|
||||
usr == self.user
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user