I am new in this situation. I create a route and controller. here is my code:
<?php
// /src/Acme/DemoBundle/Controller/MediaCRUDController.php
namespace AppBundle\Controller;
use Sonata\AdminBundle\Controller\CRUDController;
class RatingController extends CRUDController
{
public function indexAction()
{
eturn $this->render('CCApplicationBundle:Default:rating.html.twig');
}
}
and my route:
admin_dashboard_rating:
path: /rating
defaults: { _controller: AppBundle:Rating:index }
Is there a way I can embed a link to the sonata admin?
Please help.
thank you
In your sonata_admin.yaml
config file:
dashboard:
groups:
...
rating:
on_top: true
label: label.rating
icon: '<i class="fa fa-star"></i>'
items:
- route: admin_dashboard_rating
label: rating
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.