ODataConventionModelBuilder.EnableLowerCamelCase() breaks navigation properties
@xuzhg is already working on this.
Since Nov 30, 2021.
- Dominant language
- C#
- Stars
- 505
- Forks
- 186
- PR merge metrics
- No merged PRs in 30d
Description
Hi,
Following on from my comment on issue #251 (https://github.com/OData/AspNetCoreOData/issues/251#issuecomment-937673732), I attach a sample demonstrating the problem (Microsoft.AspNetCore.OData v8.0.4).
Initially, the sample code has ODataConventionModelBuilder.EnableLowerCamelCase() commented out.
If you run the sample in IIS Express and navigate to https://localhost:44310/$odata, the list of mapped endpoints is as listed below.
However, uncommenting EnableLowerCamelCase() (Startup.cs, Line 67) and running again results in the loss of 4 endpoints (bold + italic below).
- odata/ProductGroups
- odata/ProductGroups/$count
- odata/ProductGroups({key})
- odata/ProductGroups/{key}
- odata/ProductGroups({key})/ODataSample.Models.ProductGroup
- odata/ProductGroups/{key}/ODataSample.Models.ProductGroup
- odata/ProductGroups({key})/Products
- odata/ProductGroups/{key}/Products
- odata/ProductGroups({key})/Products/$count
- odata/ProductGroups/{key}/Products/$count
- odata/$metadata
- odata
This worked fine in v7.5.11.
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.