change time format

This commit is contained in:
hzmnet 2015-11-03 00:47:22 +08:00
parent 54996fd3c7
commit 8cbe7b1c7e
1 changed files with 1 additions and 1 deletions

View File

@ -142,7 +142,7 @@ func reflect2value(rawValue *reflect.Value) (str string, err error) {
//时间类型
case reflect.Struct:
if aa.ConvertibleTo(core.TimeType) {
str = vv.Convert(core.TimeType).Interface().(time.Time).Format(time.RFC3339Nano)
str = vv.Convert(core.TimeType).Interface().(time.Time).Format("2006-01-02 15:04:05")
} else {
err = fmt.Errorf("Unsupported struct type %v", vv.Type().Name())
}