mirror of
https://github.com/astaxie/beego.git
synced 2024-11-25 11:40:54 +00:00
Merge pull request #1343 from onealtang/oneal-dev
always use server's locale to parse date
This commit is contained in:
commit
9038cdfaae
@ -352,7 +352,7 @@ func ParseForm(form url.Values, obj interface{}) error {
|
|||||||
if len(tags) > 1 {
|
if len(tags) > 1 {
|
||||||
format = tags[1]
|
format = tags[1]
|
||||||
}
|
}
|
||||||
t, err := time.Parse(format, value)
|
t, err := time.ParseInLocation(format, value, time.Local)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user