问答详情
源自:-

@ParamConverter("user",class="AcmeDemoBundle:User")查询报错

/**

* @Route("/edit/{id}")

* @ParamConverter("user",class="AcmeDemoBundle:User")

*/

public function editAction(User $user){

return new Response($user->getUsername());

}

http://img.mukewang.com/572b40680001a6e611020692.jpg

提问者:weibo_木木彡615_03308630 2016-05-05 20:45

个回答

  • williamcarry3384939
    2016-05-19 15:25:22

    提示上,是你没有导入某个文件,用use导入