OData support. :)
This commit is contained in:
@@ -7,6 +7,7 @@
|
||||
<ItemGroup>
|
||||
<PackageReference Include="FluentValidation.AspNetCore" Version="9.5.0" />
|
||||
<PackageReference Include="HotChocolate.AspNetCore" Version="11.0.9" />
|
||||
<PackageReference Include="Microsoft.AspNetCore.OData" Version="7.5.5" />
|
||||
<PackageReference Include="PoweredSoft.Data" Version="2.0.0" />
|
||||
<PackageReference Include="Swashbuckle.AspNetCore.Swagger" Version="5.6.3" />
|
||||
<PackageReference Include="Swashbuckle.AspNetCore.SwaggerGen" Version="5.6.3" />
|
||||
@@ -14,6 +15,7 @@
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\PoweredSoft.CQRS.AspNetCore.OData\PoweredSoft.CQRS.AspNetCore.OData.csproj" />
|
||||
<ProjectReference Include="..\PoweredSoft.CQRS.AspNetCore\PoweredSoft.CQRS.AspNetCore.csproj" />
|
||||
<ProjectReference Include="..\PoweredSoft.CQRS.DynamicQuery.Abstractions\PoweredSoft.CQRS.DynamicQuery.Abstractions.csproj" />
|
||||
<ProjectReference Include="..\PoweredSoft.CQRS.DynamicQuery.AspNetCore\PoweredSoft.CQRS.DynamicQuery.AspNetCore.csproj" />
|
||||
|
||||
+8
-2
@@ -24,6 +24,7 @@ using System.Linq;
|
||||
using PoweredSoft.CQRS.GraphQL.HotChocolate.DynamicQuery;
|
||||
using PoweredSoft.CQRS.Abstractions.Security;
|
||||
using Demo.Security;
|
||||
using Microsoft.AspNet.OData.Extensions;
|
||||
|
||||
namespace Demo
|
||||
{
|
||||
@@ -50,14 +51,15 @@ namespace Demo
|
||||
services.AddPoweredSoftDataServices();
|
||||
services.AddPoweredSoftDynamicQuery();
|
||||
|
||||
services
|
||||
.AddPoweredSoftCQRS();
|
||||
services.AddPoweredSoftCQRS();
|
||||
services.AddOData();
|
||||
|
||||
services
|
||||
.AddControllers()
|
||||
.AddPoweredSoftQueries()
|
||||
.AddPoweredSoftCommands()
|
||||
.AddPoweredSoftDynamicQueries()
|
||||
.AddPoweredSoftODataQueries()
|
||||
.AddFluentValidation();
|
||||
|
||||
services
|
||||
@@ -128,6 +130,10 @@ namespace Demo
|
||||
{
|
||||
endpoints.MapControllers();
|
||||
endpoints.MapGraphQL();
|
||||
|
||||
endpoints.Select().Filter().OrderBy().Count().MaxTop(10);
|
||||
|
||||
endpoints.MapODataRoute("odata", "odata", endpoints.GetPoweredSoftODataEdmModel());
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user