Add firewalls

This commit is contained in:
Romain Neutron
2012-10-04 16:54:47 +02:00
parent fae290f930
commit a9a24d5424
22 changed files with 157 additions and 51 deletions

View File

@@ -29,6 +29,11 @@ class Users implements ControllerProviderInterface
{
$controllers = $app['controllers_factory'];
$controllers->before(function(Request $request) use ($app) {
$app['firewall']->requireAccessToModule('admin')
->requireRight('manageusers');
});
$controllers->post('/rights/', function(Application $app) {
$rights = new UserHelper\Edit($app, $app['request']);