@ParamConverter("user",class="AcmeDemoBundle:User")查詢報(bào)錯(cuò)
/**
* @Route("/edit/{id}")
* @ParamConverter("user",class="AcmeDemoBundle:User")
*/
public function editAction(User $user){
return new Response($user->getUsername());
}
/**
* @Route("/edit/{id}")
* @ParamConverter("user",class="AcmeDemoBundle:User")
*/
public function editAction(User $user){
return new Response($user->getUsername());
}
2016-05-05
舉報(bào)
2016-05-19
提示上,是你沒有導(dǎo)入某個(gè)文件,用use導(dǎo)入