Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge pull request #169 from jaugustin/patch-4

Update Resources/doc/param_converter.markdown
  • Loading branch information...
commit 4980f54b6ea0b1ad906d230e6b51f998e64bf6d5 2 parents 8299a76 + fb1095c
William Durand willdurand authored
Showing with 17 additions and 1 deletion.
  1. +17 −1 Resources/doc/param_converter.markdown
18 Resources/doc/param_converter.markdown
View
@@ -1,7 +1,7 @@
The PropelParamConverter
========================
-You can use the PropelParamConverter with the [SensioFrameworkExtraBundle](http://github.com/sensio/SensioFrameworkExtraBundle).
+You can use the `PropelParamConverter` with the [SensioFrameworkExtraBundle](http://github.com/sensio/SensioFrameworkExtraBundle).
You just need to put the right _Annotation_ on top of your controller:
``` php
@@ -27,6 +27,22 @@ public function myAction(Post $post)
}
```
+**New** with last version of `SensioFrameworkExtraBundle`,
+you can ommit the `class` parameter if your controller parameter is typed,
+this is usefull when you need to set extra `options`.
+
+``` php
+<?php
+use BlogBundle\Model\Post;
+
+/**
+ * @ParamConverter("post")
+ */
+public function myAction(Post $post)
+{
+}
+```
+
#### Exclude some parameters ####
You can exclude some attributes from being used by the converter:
Please sign in to comment.
Something went wrong with that request. Please try again.