better
This commit is contained in:
parent
344caf689e
commit
087153b5b7
@ -9,7 +9,7 @@
|
||||
<RepositoryUrl>https://github.com/PoweredSoft/DynamicQuery</RepositoryUrl>
|
||||
<RepositoryType>github</RepositoryType>
|
||||
<PackageTags>powered,soft,dynamic,criteria,query,builder,asp,net,core</PackageTags>
|
||||
<Version>1.0.1</Version>
|
||||
<Version>1.0.2</Version>
|
||||
<PackageIconUrl>https://secure.gravatar.com/avatar/4e32f73820c16718909a06c2927f1f8b?s=512&amp;r=g&amp;d=retro</PackageIconUrl>
|
||||
</PropertyGroup>
|
||||
|
||||
|
@ -1,23 +0,0 @@
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using PoweredSoft.DynamicQuery.Core;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace PoweredSoft.DynamicQuery.AspNetCore
|
||||
{
|
||||
public static class ServiceCollectionExtensions
|
||||
{
|
||||
public static IServiceCollection AddPoweredSoftDynamicQuery(this IServiceCollection services)
|
||||
{
|
||||
services.AddTransient<ISort, Sort>();
|
||||
services.AddTransient<IAggregate, Aggregate>();
|
||||
services.AddTransient<ISimpleFilter, SimpleFilter>();
|
||||
services.AddTransient<ICompositeFilter, CompositeFilter>();
|
||||
services.AddTransient<IGroup, Group>();
|
||||
services.AddTransient<IQueryCriteria, QueryCriteria>();
|
||||
services.AddTransient<IQueryHandler, QueryHandler>();
|
||||
return services;
|
||||
}
|
||||
}
|
||||
}
|
@ -9,7 +9,7 @@
|
||||
<RepositoryUrl>https://github.com/PoweredSoft/DynamicQuery</RepositoryUrl>
|
||||
<RepositoryType>github</RepositoryType>
|
||||
<PackageTags>powered,soft,dynamic,criteria,query,builder</PackageTags>
|
||||
<Version>1.0.5</Version>
|
||||
<Version>1.0.6</Version>
|
||||
<PackageIconUrl>https://secure.gravatar.com/avatar/4e32f73820c16718909a06c2927f1f8b?s=512&amp;r=g&amp;d=retro</PackageIconUrl>
|
||||
</PropertyGroup>
|
||||
|
||||
@ -18,4 +18,10 @@
|
||||
<ProjectReference Include="..\PoweredSoft.DynamicQuery.Core\PoweredSoft.DynamicQuery.Core.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<Reference Include="Microsoft.Extensions.DependencyInjection.Abstractions">
|
||||
<HintPath>..\..\..\Program Files\dotnet\sdk\NuGetFallbackFolder\microsoft.extensions.dependencyinjection.abstractions\2.1.1\lib\netstandard2.0\Microsoft.Extensions.DependencyInjection.Abstractions.dll</HintPath>
|
||||
</Reference>
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
|
24
PoweredSoft.DynamicQuery/ServiceCollectionExtensions.cs
Normal file
24
PoweredSoft.DynamicQuery/ServiceCollectionExtensions.cs
Normal file
@ -0,0 +1,24 @@
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.Extensions.DependencyInjection.Extensions;
|
||||
using PoweredSoft.DynamicQuery.Core;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace PoweredSoft.DynamicQuery
|
||||
{
|
||||
public static class ServiceCollectionExtensions
|
||||
{
|
||||
public static IServiceCollection AddPoweredSoftDynamicQuery(this IServiceCollection services)
|
||||
{
|
||||
services.TryAddTransient<ISort, Sort>();
|
||||
services.TryAddTransient<IAggregate, Aggregate>();
|
||||
services.TryAddTransient<ISimpleFilter, SimpleFilter>();
|
||||
services.TryAddTransient<ICompositeFilter, CompositeFilter>();
|
||||
services.TryAddTransient<IGroup, Group>();
|
||||
services.TryAddTransient<IQueryCriteria, QueryCriteria>();
|
||||
services.TryAddTransient<IQueryHandler, QueryHandler>();
|
||||
return services;
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user