Time zone settings not propagated to query
Open
@xuzhg is already working on this.
Since Nov 23, 2021.
bug
Fixed
- Dominant language
- C#
- Stars
- 505
- Forks
- 186
- PR merge metrics
- No merged PRs in 30d
Description
Using Microsoft.AspNetCore.OData V 8.0.4
in my startup I set
.AddOData(opt =>
{
opt.Select().Filter().OrderBy().Count().SetMaxTop(1000)
.AddRouteComponents("api", EdmModelBuilder.GetEdmModel())
.TimeZone = TimeZoneInfo.Utc;
opt.EnableAttributeRouting = true;
})
And specify the time zone i want to use
When using
[HttpGet("api/my-endpoint")]
[EnableQuery(PageSize = 44, MaxTop = 100, AllowedQueryOptions = AllowedQueryOptions.All)]
The ExpressionBinderHelper is not setting the TimeZone
right = DateTimeOffsetToDateTime(right, querySettings.TimeZone, querySettings);
Has a null timezone
I've read https://github.com/OData/AspNetCoreOData/issues/268 But this doesn't seem to have fixed the issue in 8.0.4
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.