我需要添加对我的网站的级别访问权限,我通常将我的路线编码为:
Route::get('/', array(
'as' => 'home-view',
'uses' => 'HomeController@viewHome'
));
/* Authenticated Group */
Route::group(array('before' => 'auth'), function(){
Route::get('/', array(
'as' => 'admin-view',
'uses' => 'AdminController@viewAdmin'
));
}
/* Unauthenticated Group */
Route::group(array('before' => 'guest'), function(){
Route::get('/signin', array(
'as' => 'user-signin-get',
'uses' => 'UserController@getSignIn'
));
}
我需要将级别访问权限添加为“用户”或“管理员”。我怎么能做那个过滤路线?尽可能简单或您有什么建议?