WebApi icon indicating copy to clipboard operation
WebApi copied to clipboard

v4 HasActionLink returning null not working

Open jricke opened this issue 9 years ago • 2 comments

When returning null from HasActionLink, the action still appears in the response.

Has anyone gotten conditional actions to work in v4?

Thanks,

jricke avatar Apr 29 '17 23:04 jricke

Figured it out after many hours of researching.

Must set the FollowsConvention parameter to false and not use odata.metadata=full in the Accept header.

jricke avatar Apr 30 '17 00:04 jricke

Must also make sure not to use the ActionLinkGenerationConvention

jricke avatar Apr 30 '17 00:04 jricke