1
0
mirror of https://github.com/astaxie/beego.git synced 2024-12-26 12:30:50 +00:00

Merge pull request #1343 from onealtang/oneal-dev

always use server's locale to parse date
This commit is contained in:
astaxie 2015-09-04 21:32:18 +08:00
commit 9038cdfaae

View File

@ -352,7 +352,7 @@ func ParseForm(form url.Values, obj interface{}) error {
if len(tags) > 1 {
format = tags[1]
}
t, err := time.Parse(format, value)
t, err := time.ParseInLocation(format, value, time.Local)
if err != nil {
return err
}