relair / odata-data-source

Data source for material table and angular cdk table that can work with OData version 4 API.
MIT License
12 stars 6 forks source link

Support for 'expand' operator #5

Closed jasondicker-zz closed 3 years ago

jasondicker-zz commented 5 years ago

Thanks for the great library! Unfortunately there's no way to expand properties. Please add this functionality. Thanks,

jsmuise commented 4 years ago

I have the same requirement I would like to display the "name" property of the related entity instead of the id that links the two entities. With the current implementation I cannot pass the following to the constructor "http://someapi.com/api/myresource?$expand=myrelatedresource" as the class will then append "?$top=5&$count=true" (based on my configuration) to the end of the URI making it invalid.

relair commented 3 years ago

I have released version 9.3.0 which adds support for using expand. Use expandedFields property with either object or array of strings.

igortelheiro commented 3 years ago

Thanks @relair, I´ve recently started using your library and Expand support is a huge improve I was needing so bad. Great job!