fanybook
|
aea91cc7de
|
add table & column comment for postgres(add table comment for mysql) (#2067)
让 postgres 支持字段注释,只在 v1.2.5 上测试过(不知道怎么 import master)
发现 master 分支好像大改了?模式表名带 schema 了
使用方式和 mysql 相同
```go
type User struct {
Id int64 `xorm:"pk autoincr"`
Name string `json:"name" xorm:"not null default '' varchar(50) index(name_age) comment('用户 (it''s) 1; 名')"`
Salt string
Age int `json:"age" xorm:"not null default 0 int(10) index(name_age) comment('年龄')"`
Passwd string `xorm:"varchar(200)"`
CreatedAt time.Time `xorm:"created"`
UpdatedAt time.Time `xorm:"updated"`
}
_ = engine.Sync(new(User))
func (model User) TableComment() string {
return "表注释"
}
```
Co-authored-by: fanybook <fanybook@gmail.com>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Reviewed-on: https://gitea.com/xorm/xorm/pulls/2067
Co-authored-by: fanybook <fanybook@noreply.gitea.io>
Co-committed-by: fanybook <fanybook@noreply.gitea.io>
|
2021-11-12 20:58:05 +08:00 |
Lunny Xiao
|
a7e010df2d
|
refactor insert condition generation (#1998)
Reviewed-on: https://gitea.com/xorm/xorm/pulls/1998
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-committed-by: Lunny Xiao <xiaolunwen@gmail.com>
|
2021-07-20 13:46:24 +08:00 |
Lunny Xiao
|
ce2a743e88
|
Fix comments (#1896)
Reviewed-on: https://gitea.com/xorm/xorm/pulls/1896
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-committed-by: Lunny Xiao <xiaolunwen@gmail.com>
|
2021-04-12 16:00:07 +08:00 |
appleboy
|
f071e5eb96
|
chore: improve titleCasedName performance (#1691)
udpate
Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>
chore: improve titleCasedName performance
Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>
Co-authored-by: Bo-Yi Wu <appleboy.tw@gmail.com>
Reviewed-on: https://gitea.com/xorm/xorm/pulls/1691
|
2020-05-23 02:22:08 +00:00 |
Lunny Xiao
|
d485101331
|
chore: improve snakeCasedName performance (#1688)
chore: update
chore: udpate
chore: improve snakeCasedName performance
Co-authored-by: Bo-Yi Wu <appleboy.tw@gmail.com>
Reviewed-on: https://gitea.com/xorm/xorm/pulls/1688
Reviewed-by: appleboy <appleboy.tw@gmail.com>
|
2020-05-22 02:53:55 +00:00 |
Lunny Xiao
|
6485adb722
|
Fix table name (#1590)
add test
Fix table name
Reviewed-on: https://gitea.com/xorm/xorm/pulls/1590
|
2020-03-10 08:15:13 +00:00 |
Lunny Xiao
|
bf25a77bca
|
Merge core package back into the main repository and split into serval sub packages. (#1543)
Fix test
Improve fmt
update go.mod
Move core as a sub package
Reviewed-on: https://gitea.com/xorm/xorm/pulls/1543
|
2020-02-24 08:53:18 +00:00 |