Can anyone point me to an example project using IChangeSetItemAuthorizer for custom authorization in RESTier 1.0.
Asked
Active
Viewed 138 times
2
-
+1 - did you get anything back on this or find decent information elsewhere? I've tried implementing according to the documentation at http://odata.github.io/RESTier/, but it doesn't appear to work as described. – Jeff Apr 20 '17 at 16:17
-
Sorry @Jeff nothing, would love to know what happened to the OData team no progress on RESTier in six months – John Little Apr 21 '17 at 01:26
1 Answers
2
Couple months after the fact, but I just came across this issue yesterday. You need to change the access modifier from protected
to public
.
So in their example it would change from this:
protected static new IServiceCollection ConfigureApi(Type apiType, IServiceCollection services)
{
return EntityFrameworkApi<TrippinModel>.ConfigureApi(apiType, services)
.AddService<IChangeSetItemAuthorizer, CustomizedAuthorizer>();
}
To this:
public static new IServiceCollection ConfigureApi(Type apiType, IServiceCollection services)
{
return EntityFrameworkApi<TrippinModel>.ConfigureApi(apiType, services)
.AddService<IChangeSetItemAuthorizer, CustomizedAuthorizer>();
}

Tony Karel
- 176
- 1
- 10