나는 이런 식으로 현재 시간을 저장하는 경우 : Golang/mgo : mongodb에 날짜 (ISODate 제외)를 저장하려면 어떻게해야합니까?
type Test struct {
Id string `bson:"id" json:"id,omitempty"`
TestTime time.Time `bson:"testTime" json:"testTime,omitempty"`
}
...
t := Test {
Id : "TEST0001",
TestTime : time.Now(),
}
...
c.Insert(t)
그때 나는 그것을 검색 할 mongochef를 사용
이
{
"_id" : ObjectId("576bc7a48114a14b47920d60"),
"id" : "TEST0001",
"testTime" : ISODate("2016-06-23T11:27:30.447+0000")
}
그래서, 기본적으로 산화 마그네슘 저장 ISODate, 내가 날짜를 저장할 수있는 방법을 ISODate하지?