I was create some methods for different users with different roles. I have 2 type users with roles: user and admin. And try to manage access to some methods which users should not have access. Manage its by accessRules YiiFramework method. Example:
public function accessRules()
{
return array(
array('allow',
'roles'=>array('user'),
),
array('allow', // allow authenticated users with role 'admin' to access listed actions
'actions'=>array('chain', 'chainSettings'),
'roles'=>array('admin'),
),
array('deny',
'users'=>array('*'),
),
);
}
And any users with role "user" have access to actions 'chain' and 'chainSettings'. May be someone know what I'm doing wrong?