File tree Expand file tree Collapse file tree 1 file changed +14
-2
lines changed
Tests/Functional/Bundle/TestBundle/Controller Expand file tree Collapse file tree 1 file changed +14
-2
lines changed Original file line number Diff line number Diff line change @@ -32,14 +32,26 @@ public function cpostAction(Request $request)
3232 }
3333
3434 /**
35- * @Get("/articles.{_format}", name="get_article ", defaults={"_format": "html"})
35+ * @Get("/articles.{_format}", name="get_articles ", defaults={"_format": "html"})
3636 *
3737 * @View()
3838 */
39- #[Get(path: '/articles.{_format} ' , name: 'get_article ' , defaults: ['_format ' => 'html ' ])]
39+ #[Get(path: '/articles.{_format} ' , name: 'get_articles ' , defaults: ['_format ' => 'html ' ])]
4040 #[View]
4141 public function cgetAction ()
4242 {
4343 return $ this ->view ();
4444 }
45+
46+ /**
47+ * @Get("/articles/{id}.{_format}", name="get_article", defaults={"_format": "html"})
48+ *
49+ * @View()
50+ */
51+ #[Get(path: '/articles/{id}.{_format} ' , name: 'get_article ' , defaults: ['_format ' => 'html ' ])]
52+ #[View]
53+ public function cgetSingleAction (int $ id )
54+ {
55+ return ['id ' => $ id ];
56+ }
4557}
You can’t perform that action at this time.
0 commit comments