Skip to content

Instantly share code, notes, and snippets.

@emagma
Created June 11, 2013 11:08
Show Gist options
  • Save emagma/5756084 to your computer and use it in GitHub Desktop.
Save emagma/5756084 to your computer and use it in GitHub Desktop.
Symfony2admingenerator changed the way you can provide Entity/Model parameters to your custom route
builders:
list:
params:
title: List of elements
display: [a, b, c]
actions:
new: ~
object_actions:
your_custom_action:
route: your_custom_route
params:
pk: '{{YourModel.id}}' # Notice that curly braces are quoted, allowing parsing in the generated twig template
edit: ~
delete: ~
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment