如何从Symfony2实体字段中的Twig模板检索基础实体对象?

I have a form builder which creates a form with an 'entity' field type (let's call that entity MyBundle:MyEntity). MyEntity has a property entitled 'description'. In addition to the __tostring() method automatically called by Symfony2 that is used for the label of each radio button, I'd like to access the description property.

I've overridden the choice_widget block and attempted to get {{ child.vars.value }}, but that's just the ID of the entity rather than the object itself.

Does anyone know how to do this, or if it is even possible?

I didn't understand well what you want to do exactly since you didn't provide any code but from what I understood you want to access the object of the child right?

If that's the case you can use child.get('value') and this will return the object

Which means you can call child.get('value').getDescription() or whatever function child object has