fix(09): WR-16 resolve model columns through embedded structs and explicit column tags
This commit is contained in:
@@ -397,11 +397,8 @@ func listModelContract(ctl pact.AdminController) (map[string]struct{}, map[strin
|
||||
}
|
||||
cols := map[string]struct{}{}
|
||||
rels := map[string]struct{}{}
|
||||
for i := 0; i < t.NumField(); i++ {
|
||||
field := t.Field(i)
|
||||
if field.PkgPath != "" {
|
||||
continue
|
||||
}
|
||||
for _, mf := range modelFields(t) {
|
||||
field := mf.Field
|
||||
if isListRelation(field.Type) {
|
||||
rels[field.Name] = struct{}{}
|
||||
// Winter YAML spells relations in lowercase (relation: genre)
|
||||
|
||||
Reference in New Issue
Block a user