This commit is contained in:
Peter Smit 2015-01-25 13:26:42 +00:00
commit 35f55c3ffa
1 changed files with 1 additions and 1 deletions

View File

@ -915,7 +915,7 @@ func (engine *Engine) mapType(v reflect.Value) *core.Table {
table.AddColumn(col)
if fieldType.Kind() == reflect.Int64 && (col.FieldName == "Id" || strings.HasSuffix(col.FieldName, ".Id")) {
if fieldType.Kind() == reflect.Int64 && (col.FieldName == "ID" || col.FieldName == "Id" || strings.HasSuffix(col.FieldName, ".Id") || strings.HasSuffix(col.FieldName, ".ID")) {
idFieldColName = col.Name
}
} // end for