net9.0 - "Microsoft.AspNetCore.OData" Version="9.4.1"
**
I have minimal api controller
.MapGet("", (
HttpContext context,
IApplicationDbContext dbContext,
ODataQueryOptions<Category> queryOptions,
CancellationToken _) =>
{
var userId = context.User.FindFirst(ClaimTypes.NameIdentifier)?.Value;
var baseQuery = dbContext.Category
.Where(c => c.OwnerId == new Guid(userId));
var b = context.RequestServices.GetService<ISearchBinder>();
return queryOptions.ApplyTo(baseQuery);
})
.WithODataResult();
and next odata settings
.AddOData(opt =>
opt.EnableQueryFeatures()
.AddRouteComponents("api/v{version:apiVersion}/odata", edmModel,
s => s.AddSingleton<ISearchBinder, TableSearchBinder>()));
All query features is working except $search. I implemted ISearchBinder and regitered it, but it does not help, this binder dont work
public class TableSearchBinder : QueryBinder,ISearchBinder
Does it expect behavior or OData does not support minimal api fully?
net9.0 - "Microsoft.AspNetCore.OData" Version="9.4.1"
**
I have minimal api controller
and next odata settings
All query features is working except $search. I implemted ISearchBinder and regitered it, but it does not help, this binder dont work
public class TableSearchBinder : QueryBinder,ISearchBinderDoes it expect behavior or OData does not support minimal api fully?