企业🤖AI智能体构建引擎,智能编排和调试,一键部署,支持私有化部署方案 广告
1、annotation `编辑:app/config/routing.yml` ~~~ app: resource: "@AppBundle/Controller/" type: annotation prefix: / ~~~ `编辑:src/AppBundle/Controller/TestController` ~~~ <?php namespace AppBundle\Controller; use Symfony\Bundle\FrameworkBundle\Controller\Controller; use Symfony\Component\HttpFoundation\Response; use Sensio\Bundle\FrameworkExtraBundle\Configuration\Route; class AppController extends Controller { /** * @Route("/test", name="app_test") * @return Response */ public function hightchartsAction() { return new Response(); } } ~~~ 2、yml `编辑:app/config/routing.yml` ~~~ app: resource: '@AppBundle/Resources/config/routing.yml' prefix: /app ~~~ `编辑:src/AppBundle/Resources/config/routing.yml`