重构提取逻辑,新增 area 表
This commit is contained in:
@@ -218,6 +218,12 @@ func newChannel(db *gorm.DB, opts ...gen.DOOption) channel {
|
||||
}
|
||||
Edge struct {
|
||||
field.RelationField
|
||||
Area struct {
|
||||
field.RelationField
|
||||
Parent struct {
|
||||
field.RelationField
|
||||
}
|
||||
}
|
||||
}
|
||||
}{
|
||||
RelationField: field.NewRelation("Proxy.Channels", "models.Channel"),
|
||||
@@ -238,8 +244,27 @@ func newChannel(db *gorm.DB, opts ...gen.DOOption) channel {
|
||||
},
|
||||
Edge: struct {
|
||||
field.RelationField
|
||||
Area struct {
|
||||
field.RelationField
|
||||
Parent struct {
|
||||
field.RelationField
|
||||
}
|
||||
}
|
||||
}{
|
||||
RelationField: field.NewRelation("Proxy.Channels.Edge", "models.Edge"),
|
||||
Area: struct {
|
||||
field.RelationField
|
||||
Parent struct {
|
||||
field.RelationField
|
||||
}
|
||||
}{
|
||||
RelationField: field.NewRelation("Proxy.Channels.Edge.Area", "models.Area"),
|
||||
Parent: struct {
|
||||
field.RelationField
|
||||
}{
|
||||
RelationField: field.NewRelation("Proxy.Channels.Edge.Area.Parent", "models.Area"),
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
||||
@@ -617,6 +642,12 @@ type channelBelongsToProxy struct {
|
||||
}
|
||||
Edge struct {
|
||||
field.RelationField
|
||||
Area struct {
|
||||
field.RelationField
|
||||
Parent struct {
|
||||
field.RelationField
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user