diff --git a/AMWD.Common.AspNetCore/AMWD.Common.AspNetCore.csproj b/AMWD.Common.AspNetCore/AMWD.Common.AspNetCore.csproj index e36b394..6c120f3 100644 --- a/AMWD.Common.AspNetCore/AMWD.Common.AspNetCore.csproj +++ b/AMWD.Common.AspNetCore/AMWD.Common.AspNetCore.csproj @@ -1,7 +1,7 @@ - netcoreapp3.1;net5.0;net6.0 + netcoreapp3.1;net6.0 10.0 AMWD.Common.AspNetCore diff --git a/AMWD.Common.EntityFrameworkCore/AMWD.Common.EntityFrameworkCore.csproj b/AMWD.Common.EntityFrameworkCore/AMWD.Common.EntityFrameworkCore.csproj index 28866d4..ead1bb2 100644 --- a/AMWD.Common.EntityFrameworkCore/AMWD.Common.EntityFrameworkCore.csproj +++ b/AMWD.Common.EntityFrameworkCore/AMWD.Common.EntityFrameworkCore.csproj @@ -1,7 +1,7 @@  - netcoreapp3.1;net5.0;net6.0 + netcoreapp3.1;net6.0 10.0 AMWD.Common.EntityFrameworkCore @@ -41,13 +41,6 @@ - - - - - - - diff --git a/AMWD.Common.EntityFrameworkCore/Extensions/ModelBuilderExtensions.cs b/AMWD.Common.EntityFrameworkCore/Extensions/ModelBuilderExtensions.cs index b14fd92..cccaf0c 100644 --- a/AMWD.Common.EntityFrameworkCore/Extensions/ModelBuilderExtensions.cs +++ b/AMWD.Common.EntityFrameworkCore/Extensions/ModelBuilderExtensions.cs @@ -3,7 +3,7 @@ using System.Reflection; using System.Text; using AMWD.Common.EntityFrameworkCore.Attributes; using Microsoft.EntityFrameworkCore; -#if NET5_0_OR_GREATER +#if NET6_0_OR_GREATER using Microsoft.EntityFrameworkCore.Metadata; #endif @@ -36,7 +36,7 @@ namespace AMWD.Common.EntityFrameworkCore.Extensions if (!string.IsNullOrWhiteSpace(indexAttribute.Name)) { -#if NET5_0_OR_GREATER +#if NET6_0_OR_GREATER index.SetDatabaseName(indexAttribute.Name.Trim()); #else index.SetName(indexAttribute.Name.Trim()); @@ -61,14 +61,14 @@ namespace AMWD.Common.EntityFrameworkCore.Extensions // skip conversion when table name is explicitly set if ((entityType.ClrType.GetCustomAttribute(typeof(TableAttribute), false) as TableAttribute) == null) { -#if NET5_0_OR_GREATER +#if NET6_0_OR_GREATER entityType.SetTableName(ConvertToSnakeCase(entityType.GetTableName())); #else entityType.SetTableName(ConvertToSnakeCase(entityType.GetTableName())); #endif } -#if NET5_0_OR_GREATER +#if NET6_0_OR_GREATER var identifier = StoreObjectIdentifier.Table(entityType.GetTableName(), entityType.GetSchema()); #endif foreach (var property in entityType.GetProperties()) @@ -76,7 +76,7 @@ namespace AMWD.Common.EntityFrameworkCore.Extensions // skip conversion when column name is explicitly set if ((entityType.ClrType.GetProperty(property.Name)?.GetCustomAttribute(typeof(ColumnAttribute), false) as ColumnAttribute) == null) { -#if NET5_0_OR_GREATER +#if NET6_0_OR_GREATER property.SetColumnName(ConvertToSnakeCase(property.GetColumnName(identifier))); #else property.SetColumnName(ConvertToSnakeCase(property.GetColumnName()));