mirror of
https://github.com/zhufuyi/sponge.git
synced 2025-10-06 01:07:08 +08:00
extended api
This commit is contained in:
@@ -39,6 +39,7 @@ type Args struct {
|
||||
ColumnPrefix string
|
||||
NoNullType bool
|
||||
NullStyle string
|
||||
IsExtendedApi bool // true: generate extended api (9 api), false: generate basic api (5 api)
|
||||
}
|
||||
|
||||
func (a *Args) checkValid() error {
|
||||
@@ -177,6 +178,9 @@ func setOptions(args *Args) []parser.Option {
|
||||
if args.ForceTableName {
|
||||
opts = append(opts, parser.WithForceTableName())
|
||||
}
|
||||
if args.IsExtendedApi {
|
||||
opts = append(opts, parser.WithExtendedApi())
|
||||
}
|
||||
|
||||
return opts
|
||||
}
|
||||
|
Reference in New Issue
Block a user