8000 [Form] Configuration of custom adders/removers · Issue #1227 · symfony/symfony-docs · GitHub
[go: up one dir, main page]

Skip to content

[Form] Configuration of custom adders/removers #1227

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

Closed
webmozart opened this issue Apr 7, 2012 · 7 comments
< 8000 div class="mr-2 mb-2 flex-shrink-0"> Closed

[Form] Configuration of custom adders/removers #1227

webmozart opened this issue Apr 7, 2012 · 7 comments
Labels
actionable Clear and specific issues ready for anyone to take them. Form
Milestone

Comments

@webmozart
Copy link
Contributor

Set the "property_path" option as described in symfony/symfony#3819

@weaverryan
Copy link
Member

Most of what we need is documented in #1057 - this is a placeholder for the added detail of how the "singular" version of the adder/remove method can be configured.

For example, the normal:

$propertyPath = new PropertyPath('article.tags');

versus the customized:

$propertyPath = new PropertyPath('article.genera|genus');

We would show this as the property_path option on a collection-type form field:

    $builder->add('tags', 'collection', array(
        'property_path' => 'tags|tag'),
    ));

@peterrehm
Copy link
Contributor

Is it possible that the behaviour has changed?

Neither the property "tags|tag" nor one of the methods "addTags|tag()", "setTags|tag()", "__set()" or "__call()" exist and have public access in class "Vendor\Bundle\Entity\Article".

@stof
Copy link
Member
stof commented Feb 6, 2014

@weaverryan the support of custom pluralization was reverted before the release because it was not considered good enough in its state

@peterrehm
Copy link
Contributor

@stof So this is currently not possible at all?

@stof
Copy link
Member
stof commented Feb 6, 2014

@peterrehm no, it is not possible to use another singular than the one guessed by Symfony

@peterrehm
Copy link
Contributor

@weaverryan So you can close this issue. Thanks @stof for the clarification.

@wouterj
Copy link
Member
wouterj commented Feb 6, 2014

Thank you @stof & @peterrehm Closing this one :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
actionable Clear and specific issues ready for anyone to take them. Form
Projects
None yet
Development

No branches or pull requests

5 participants
0