feat(api): docs basic curd implemention
This commit is contained in:
20
cmd/gen/main.go
Normal file
20
cmd/gen/main.go
Normal file
@@ -0,0 +1,20 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"octopus/internal/dal/model"
|
||||
|
||||
"gorm.io/gen"
|
||||
)
|
||||
|
||||
// generate code.
|
||||
func main() {
|
||||
g := gen.NewGenerator(gen.Config{
|
||||
OutPath: "internal/dal/query",
|
||||
Mode: gen.WithDefaultQuery | gen.WithoutContext,
|
||||
})
|
||||
g.ApplyBasic(
|
||||
new(model.Doc),
|
||||
new(model.DocFolder),
|
||||
)
|
||||
g.Execute()
|
||||
}
|
||||
Reference in New Issue
Block a user