Как видно из заголовка, у меня возникает эта проблема, если я пытаюсь перейти по следующему URL-адресу:
http://app.local/sf/customer-first-progam-level
Вот что у меня есть:
приложение /routing.yml
quote: resource: "@QuoteBundle/Controller/" type: annotation prefix: /sf
QuoteBundle/Controller/CustomerFirstProgramLevelController.php
<?php namespace QuoteBundle\Controller; use Sensio\Bundle\FrameworkExtraBundle\Configuration\Method; use Sensio\Bundle\FrameworkExtraBundle\Configuration\Route; use Symfony\Bundle\FrameworkBundle\Controller\Controller; use Symfony\Component\HttpFoundation\Request; /** * @Route("customer-first-program-level") */ class CustomerFirstProgramLevelController extends Controller { use GridBuilder; /** * @Route("/", name="customer_first_program_level_index") * @Method({"GET", "POST"}) * @param Request $request * * @return \Symfony\Component\HttpFoundation\Response * @throws \LogicException */ public function indexAction(Request $request) { ... } }
Это то, что я пробовал без успеха:
- Очистите кеш как prod, так и dev
- Измените имя маршрута на другое
Если я отлаживаю router
, я получаю следующее:
$ symfony_console debug:router
------------------------------------ ---------- -------- ------ --------------------------------------------
Name Method Scheme Host Path
------------------------------------ ---------- -------- ------ --------------------------------------------
customer_index GET|POST ANY ANY /sf/customer/
customer_first_program_level_index GET|POST ANY ANY /sf/customer-first-program-level/
discount_index GET|POST ANY ANY /sf/discount/
....
------------------------------------ ---------- -------- ------ --------------------------------------------
Я использую Symfony 3.2.7. Любые идеи? я вне их
progam
отсутствовалr
. Я голосую за закрытие этого вопроса, так как это была опечатка. - person A.L   schedule 11.04.2017