On 7 December 2014 at 20:30, Antenne <[email protected]> wrote:

> As you see in the ProductForm, I've added two options for adding the
> related label (ObjectSelect works fine), but I just want to enter the name
> of the related Label and find the related label to relate it to the product.
> What is the best and most efficient way to implement this?
>

Consider that I grew a passionate hate for form components (any framework)
over these years, so I may be biased.

My suggestion is to build a custom fieldset that aggregates:

 - entity name
 - entity identifier (label may be different in your dropdown)

The `getObject()` method of your fieldset would then return either `null`
or the fetched item on-demand.

Requires testing, as form magic is typically headache-prone.

Marco Pivetta

http://twitter.com/Ocramius

http://ocramius.github.com/

-- 
You received this message because you are subscribed to the Google Groups 
"doctrine-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/doctrine-user.
For more options, visit https://groups.google.com/d/optout.

Reply via email to