title foreign schema for many2many to avoid panic
This commit is contained in:
parent
16579e00c6
commit
fbfb4c0537
@ -238,7 +238,7 @@ func (schema *Schema) buildMany2ManyRelation(relation *Relationship, field *Fiel
|
||||
}
|
||||
|
||||
for idx, relField := range refForeignFields {
|
||||
joinFieldName := relation.FieldSchema.Name + relField.Name
|
||||
joinFieldName := strings.Title(relation.FieldSchema.Name) + relField.Name
|
||||
if len(joinReferences) > idx {
|
||||
joinFieldName = strings.Title(joinReferences[idx])
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user