Quantcast
Channel: ASPNETWebStack Issue Tracker Rss Feed
Viewing all articles
Browse latest Browse all 7215

Edited Issue: Always available actions that don´t follow conventions should appear in minimal and no metadata [789]

$
0
0
Scenario:

I create an entityset.
I define an entity bound action that is always available.
I define that the link for the action doesn't follows conventions.
I query for a feed in minimal metadata or no metadata.
The action doesn't show in the payload

Request:

GET http://localhost:5000/Actions/StubEntity HTTP/1.1
User-Agent: Fiddler
accept: application/json;odata=minimalmetadata
Host: localhost:5000

Response:

HTTP/1.1 200 OK
Content-Length: 327
Content-Type: application/json; odata=minimalmetadata; charset=utf-8
Server: Microsoft-HTTPAPI/2.0
DataServiceVersion: 3.0
Date: Fri, 18 Jan 2013 17:56:19 GMT

{
"odata.metadata":"http://localhost:5000/Actions/$metadata#StubEntity","value":[
{
"Id":0
},{
"Id":1
},{
"Id":2
},{
"Id":3
},{
"Id":4
},{
"Id":5
},{
"Id":6
},{
"Id":7
},{
"Id":8
},{
"Id":9
}
]
}

Metadata:

<?xml version="1.0" encoding="utf-8"?>
<edmx:Edmx Version="1.0" xmlns:edmx="http://schemas.microsoft.com/ado/2007/06/edmx">
<edmx:DataServices m:DataServiceVersion="3.0" m:MaxDataServiceVersion="3.0" xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata">
<Schema Namespace="CustomActionConventionRepro.Models" xmlns="http://schemas.microsoft.com/ado/2009/11/edm">
<EntityType Name="StubEntity">
<Key>
<PropertyRef Name="Id" />
</Key>
<Property Name="Id" Type="Edm.Int32" Nullable="false" />
</EntityType>
</Schema>
<Schema Namespace="Default" xmlns="http://schemas.microsoft.com/ado/2009/11/edm">
<EntityContainer Name="Container" m:IsDefaultEntityContainer="true">
<EntitySet Name="StubEntity" EntityType="CustomActionConventionRepro.Models.StubEntity" />
<FunctionImport Name="Sample" IsBindable="true" m:IsAlwaysBindable="true">
<Parameter Name="bindingParameter" Type="CustomActionConventionRepro.Models.StubEntity" />
</FunctionImport>
</EntityContainer>
</Schema>
</edmx:DataServices>
</edmx:Edmx>

Repro steps:
1) Open the project as administrator.
2) Point the System.Web.Odata.dll to your product code dll.
3) Restore nugget packages.
4) Run

Viewing all articles
Browse latest Browse all 7215

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>