Sylius/Sylius — pull request #775 by jjanvier (2014-01-05 02:09:20+00:00)
Title: [POC/RFC] Authorization handler for ResourceController

I use `ResourceBundle` for all my new projects. And almost every time, I have to have to check special authorization for a given action and resource.

The goal of this PR is to handle authorizations by doing something as simple as :
```php
class MyResourceController extends ResourceController
{
public function checkEditAuthorization()
{
if (!this->get('security.context')->is_granted('ROLE_TO_CHECK') {
throw new AccessDeniedException();
}
}
}

Note : I did not test anything. This is just a POC, or a RFC.
```