Commit 76d4ac17 authored by Jean-Philippe Lang's avatar Jean-Philippe Lang

added 999 as a maximum for time entry hours

git-svn-id: http://redmine.rubyforge.org/svn/trunk@369 e93f8b46-1217-0410-a6f0-8f06a7374b81
parent 8d54d970
......@@ -17,7 +17,7 @@ class TimeEntry < ActiveRecord::Base
end
def validate
errors.add :hours, :activerecord_error_invalid if hours && hours < 0
errors.add :hours, :activerecord_error_invalid if hours && (hours < 0 || hours >= 1000)
errors.add :project_id, :activerecord_error_invalid if project.nil?
errors.add :issue_id, :activerecord_error_invalid if (issue_id && !issue) || (issue && project!=issue.project)
end
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment