We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The [email protected] properties are missing.
[email protected]
In the following sample, there are two examples
Sample https://github.com/cheng93/AutoMapper.OData/blob/master/ApiController.cs
http://localhost:5238/odata/categories?$expand=products($count=true)
expected
{ "@odata.context": "http://localhost:5238/odata/$metadata#categories(Products())", "value": [ { "CategoryId": 1, "CategoryName": "CategoryOne", "[email protected]": 3, <-- visible "Products": [ { "ProductId": 1, "ProductName": "ProductOne" }, { "ProductId": 2, "ProductName": "ProductTwo" }, { "ProductId": 3, "ProductName": "ProductThree" } ] }, { "CategoryId": 2, "CategoryName": "CategoryTwo", "[email protected]": 2, <-- visible "Products": [ { "ProductId": 4, "ProductName": "ProductFour" }, { "ProductId": 5, "ProductName": "ProductFive" } ] } ] }
actual
{ "@odata.context": "http://localhost:5238/odata/$metadata#categories(Products())", "value": [ { "CategoryId": 1, "CategoryName": "CategoryOne", "Products": [ { "ProductId": 1, "ProductName": "ProductOne" }, { "ProductId": 2, "ProductName": "ProductTwo" }, { "ProductId": 3, "ProductName": "ProductThree" } ] }, { "CategoryId": 2, "CategoryName": "CategoryTwo", "Products": [ { "ProductId": 4, "ProductName": "ProductFour" }, { "ProductId": 5, "ProductName": "ProductFive" } ] } ] }
The text was updated successfully, but these errors were encountered:
You are correct - that is not currently supported. There is a CountOption property in the expansion.
CountOption
At the root level it is being applied by setting a property as implemented here.
Still - Ok to create a PR to return count for expansions if you have a solution.
Sorry, something went wrong.
Hi, any progress with this? Also any chance of supporting filter on expand? So something like :
api/Entity?$expand=Child($filter=name eq "Bob")
The tests show examples of filter with expand. Ok to submit a PR on the count feature.
count
No branches or pull requests
The
[email protected]
properties are missing.In the following sample, there are two examples
Sample https://github.com/cheng93/AutoMapper.OData/blob/master/ApiController.cs
http://localhost:5238/odata/categories?$expand=products($count=true)
expected
actual
The text was updated successfully, but these errors were encountered: