-
-
Notifications
You must be signed in to change notification settings - Fork 350
Open
Description
Description
My generation code setup:
g := gen.NewGenerator(gen.Config{
OutPath: "internal/db/gen/query",
ModelPkgPath: "internal/db/gen/model",
FieldNullable: true,
FieldSignable: true,
FieldCoverable: true,
FieldWithIndexTag: true,
FieldWithTypeTag: true,
Mode: gen.WithDefaultQuery | gen.WithQueryInterface,
})
// Clean model and query folders
cleanGenFolder()
// Use the generated dataMap from datamap package
g.WithDataTypeMap(datamap.BuildDataMap())
g.UseDB(db.GetInstance())
g.ApplyBasic(g.GenerateAllTable()...)
g.Execute()
The above creates a model from the database however the models doesnt contain any relationship between the tables. Is there any configuraion for loading relations that I am missing?
Gorm gen version: 0.3.26
Metadata
Metadata
Assignees
Labels
No labels