1
私はWCF Web APIを使用して、odataクエリからcoplexオブジェクトを返す休憩サービスを使用しています。残念ながら、複雑な型のクエリは機能していないようです。例えば。WCF Web APIとodataを使用した複合型
public IQueryable<Person> Get()
{
var people = new List<Person>()
{
new Person {
Name="John",
Department = new Department{Id=2, Description="Lion Swaddling"}
},
new Person {
Name="Jane",
Department = new Department{Id=4, Description="Face Surgery"}
},
};
return people.AsQueryable();
}
次のURIは何も返しません。 ?$ filter = Department/Id%20eq%20'2 '
実際、Web APIは複合型のクエリをサポートしていますか?もしそうなら、私はそれを可能にするために特別な何かが必要ですか?