Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> [SF][SF2][Symfony2]AppBundle\Entity\Orders object not found.
Crash89
post
Post #1





Grupa: Zarejestrowani
Postów: 191
Pomógł: 7
Dołączył: 3.04.2013

Ostrzeżenie: (0%)
-----


Tworząc nową akcję spotkałem się z takim problemem:
AppBundle\Entity\Orders object not found.
404 Not Found - NotFoundHttpException
C:\Users\rosmith\shrub_search\vendor\sensio\framework-extra-bundle\Request\ParamConverter\DoctrineParamConverter.php line 66


Tak jakby nie widział tego entity, adres jest wpisany poprawnie.
Używam Symfony 3.1

Poniżej jest kod gdzie tworzę instancję tej klasy.
  1. /**
  2.   * @Route("/order-without-pay", name="order_without_pay")
  3.   * @Method("GET")
  4.   */
  5. public function orderWithoutPayAction() {
  6. $em = $this->getDoctrine()->getManager();
  7. $cart = new Cart($em);
  8.  
  9. $ordersModel = new OrdersModel($em);
  10. $ordersModel->add($cart);
  11. }
  12.  
  13. //klasa ordersModel
  14. public function add($cart) {
  15. $orders = new Orders();
  16. var_dump($cart);
  17. die();
  18. }


Problem występuję przy wczytywaniu klasy Orders w przestrzeni nazw.
Wszystkie inne entity działają, w przestrzeni nazw ścieżka jest wpisana poprawnie.

Proszę o pomoc.

Ten post edytował Crash89 17.03.2018, 17:14:30
Go to the top of the page
+Quote Post

Posty w temacie


Reply to this topicStart new topic
2 Użytkowników czyta ten temat (2 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Aktualny czas: 1.10.2025 - 09:06