1 Star 1 Fork 0

bigbase / pg

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
inflection.go 378 Bytes
一键复制 编辑 原始数据 按行查看 历史
package orm
import (
"github.com/jinzhu/inflection"
)
var tableNameInflector func(string) string
func init() {
SetTableNameInflector(inflection.Plural)
}
// SetTableNameInflector overrides the default func that pluralizes
// model name to get table name, e.g. my_article becomes my_articles.
func SetTableNameInflector(fn func(string) string) {
tableNameInflector = fn
}
Go
1
https://gitee.com/bigbase/pg.git
git@gitee.com:bigbase/pg.git
bigbase
pg
pg
v6.6.6

搜索帮助