Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[AdminListBundle, MenuBundle], Passing arguments to form type is deprecated #950

Merged
merged 11 commits into from
Jan 29, 2016

Conversation

sandergo90
Copy link
Contributor

Q A
Bug fix? yes
New feature? no
BC breaks? no
Deprecations? no
Fixed tickets

In older symfony versions, the first argument of the createForm function allowed a form type with extra parameters. As of symfony 2.7 we need to pass the fully qualified class name of a form as
the first argument. Therefore we added a new option to the AbstractAdminListConfigurator class named $typeOptions. In your AdminListController you can use the setAdminTypeOptions function to pass extra parameters to the form defaults options.

We have made some changes to the AdaptSimpleFormEvent to allow the needed fully qualified form class names.
The second parameter now requires a string instead of a AbstractType. There is also a possibilty now to add a fourth parameter
with the default options you would like to pass to your form.

jockri pushed a commit that referenced this pull request Jan 29, 2016
[AdminListBundle, MenuBundle], Passing arguments to form type is deprecated
@jockri jockri merged commit b293cbe into Kunstmaan:master Jan 29, 2016
@jockri jockri added this to the 3.5.0 milestone Jan 29, 2016
@sandergo90 sandergo90 deleted the dep#routing branch July 7, 2016 06:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants