Skip to content

Commit

Permalink
Be consistent about OnModelCreating as the terminology for fluent API
Browse files Browse the repository at this point in the history
Use "navigation" rather than "navigation property"
Check usage of {foreignKey} and for correct quoting and use foreignKeyProperties where appropriate
Fix AnnotationNotFound, BadFilterDerivedType, CircularDependency
Update DisplayName for shared-type entity types to include the entity type name

Part of #7201
Fixes #22310
  • Loading branch information
AndriySvyryd committed Sep 1, 2020
1 parent 78cdc71 commit 006a113
Show file tree
Hide file tree
Showing 31 changed files with 470 additions and 438 deletions.
2 changes: 1 addition & 1 deletion src/EFCore.Cosmos/Properties/CosmosStrings.Designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src/EFCore.Cosmos/Properties/CosmosStrings.resx
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@
<value>There is no string-based representation of this query as it's executed using 'ReadItemQueryAsync({resourceId}, {partitionKey})'.</value>
</data>
<data name="NullTypeMappingInSqlTree" xml:space="preserve">
<value>Null TypeMapping in Sql Tree.</value>
<value>Null TypeMapping in SQL tree.</value>
</data>
<data name="OffsetRequiresLimit" xml:space="preserve">
<value>Offset is not supported without Limit.</value>
Expand Down
8 changes: 4 additions & 4 deletions src/EFCore.Design/Properties/DesignStrings.Designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src/EFCore.Design/Properties/DesignStrings.resx
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@
<value>Could not scaffold the foreign key '{foreignKeyName}'. The referenced table could not be found. This most likely occurred because the referenced table was excluded from scaffolding.</value>
</data>
<data name="ForeignKeyScaffoldErrorPrincipalTableScaffoldingError" xml:space="preserve">
<value>Could not scaffold the foreign key '{foreignKeyName}'. The referenced table '{principaltableName}' could not be scaffolded.</value>
<value>Could not scaffold the foreign key '{foreignKeyName}'. The referenced table '{principalTableName}' could not be scaffolded.</value>
</data>
<data name="ForeignKeyScaffoldErrorPropertyNotFound" xml:space="preserve">
<value>Could not scaffold the foreign key '{foreignKeyName}'. The following columns in the foreign key could not be scaffolded: {columnNames}.</value>
Expand Down
6 changes: 2 additions & 4 deletions src/EFCore.Relational/Extensions/Internal/TupleExtensions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ public static class TupleExtensions
/// </summary>
public static string FormatTables([NotNull] this IEnumerable<(string Table, string Schema)> tables)
=> "{"
+ string.Join(", ", tables.Select(FormatTable))
+ string.Join(", ", tables.Select(t => "'" + FormatTable(t) + "'"))
+ "}";

/// <summary>
Expand All @@ -34,8 +34,6 @@ public static string FormatTables([NotNull] this IEnumerable<(string Table, stri
/// doing so can result in application failures when updating to a new Entity Framework Core release.
/// </summary>
public static string FormatTable(this (string Table, string Schema) table)
=> "'"
+ (table.Schema == null ? table.Table : table.Schema + "." + table.Table)
+ "'";
=> table.Schema == null ? table.Table : table.Schema + "." + table.Table;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -2577,7 +2577,7 @@ private readonly IDictionary<ITable, DropTableOperation> _dropTableOperations
= new Dictionary<ITable, DropTableOperation>();

private readonly IDictionary<IColumn, DropColumnOperation> _dropColumnOperations
= new Dictionary<IColumn, DropColumnOperation>();
= new Dictionary<IColumn, DropColumnOperation>();

private readonly IDictionary<DropTableOperation, ITable> _removedTables
= new Dictionary<DropTableOperation, ITable>();
Expand Down
Loading

0 comments on commit 006a113

Please sign in to comment.