私のWebAPIコントローラーでは、次のように結果をメソッド呼び出しに返します。
// GET api/profile/5
public VCompleteProjectProfile GetBasicProjectProfile(int id)
{
return _dbss.GetBasicProfile(id);
}
そして、これが実際の結果です:
{
"$id":"1",
"Id":1,
"ProjectName":"Caribbean Challenge",
"IsMrRcSelected":true,
"IsMrdProject":true,
"RegionName":"North America",
"EntityKey":{
"$id":"2",
"EntitySetName":"VCompleteProjectProfile",
"EntityContainerName":"MrdViewEntities",
"EntityKeyValues":[
{"Key":"Id","Type":"System.Int32","Value":"1"},
{"Key":"ProjectName","Type":"System.String","Value":"Caribbean Challenge"},
{"Key":"IsMrRcSelected","Type":"System.Boolean","Value":"True"}
]
}
}
抑制できEntityKey
ますか?もしそうなら、どのように?これはMVC4です。
ありがとうエリック