I'm quite new to the Sonata project, and as "playing" with it, I wanted to use it for one of my projects.
But there are a few questions that still remains for me about Sonata and the way it works and can be customized.
Here are they :
I'd like to use roles and only roles to manage my security
but can't figure out how to add Roles to the list that is displayed
when you use the users creation form (by default located at
/admin/my/bundle/user/create
) under the "management" tab. Is it
possible?
Screen to explain more :
If yes, if anyone has hints about how to do this, they are welcome! :)
In symfony you can customize third party bundle by inheriting that bundle. So to use your own controller do the followings step by step:
In your custom bundle: AcmeDemoBundle.php
add:
public function getParent()
{
return 'SonataAdminBundle';
}
Now your bundle is inheriting SonataAdminBundle
.
In your custom controller: AcmeDemoBundleCustomController.php
class CustomController extends CoreController {
public function dashboardAction()
{
...
/* Here goes your code */
}
}