Make sure that dates are stored as YYYY-MM-DD in journal details (#12713).

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@11117 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang
2013-01-04 15:38:52 +00:00
parent 9a66463ff8
commit 9adb0c61a9
2 changed files with 26 additions and 2 deletions
+5 -2
View File
@@ -27,10 +27,13 @@ class JournalDetail < ActiveRecord::Base
end
def normalize(v)
if v == true
case v
when true
"1"
elsif v == false
when false
"0"
when Date
v.strftime("%Y-%m-%d")
else
v
end