Reputation: 2575
I installed FOSUserBundle and i would like to add any additional role, such ROLE_NEW. In sfGuardUser just had to do
$this->getUser()->addCredential('new');
in action, and here?
Besides, how can I (admin) manage all (first of all manage ROLES) users? In sfGuardUser I had generated default admin page, and here?
Upvotes: 6
Views: 15873
Reputation: 3530
By default FOSUserBundle manage roles as array, but you can use the concept of "Groups" for this purpose.
Read in docs https://github.com/FriendsOfSymfony/FOSUserBundle/blob/master/Resources/doc/groups.md
And read some discussions about advantages and disadvantages FOS bundle - How to select users with a specific role?
Upvotes: 7