1
0
mirror of https://github.com/astaxie/beego.git synced 2025-06-11 15:00:40 +00:00

Support etcd

This commit is contained in:
Ming Deng
2020-08-26 03:46:22 +00:00
parent 5b35bf6065
commit c2361170b3
20 changed files with 581 additions and 257 deletions

View File

@ -69,7 +69,7 @@ checkColumn:
// the precision of sqlite is not implemented
if al.Driver == 2 || fi.timePrecision == nil {
col = T["time.Time"]
}else {
} else {
s := T["time.Time-precision"]
col = fmt.Sprintf(s, *fi.timePrecision)
}

View File

@ -243,7 +243,7 @@ type UserBig struct {
}
type TM struct {
ID int `orm:"column(id)"`
ID int `orm:"column(id)"`
TMPrecision1 time.Time `orm:"type(datetime);precision(3)"`
TMPrecision2 time.Time `orm:"auto_now_add;type(datetime);precision(4)"`
}