php - Sonata Admin render "with" of Child -
i added field contact (type: sonata_type_admin) adminclass
entity activity.
my contactadmin
looks that:
protected function configureformfields(formmapper $formmapper) { $formmapper ->with('adresse', array('class' => 'col-md-6')) ->add( 'location.address', addresstype::class, array( 'label' => 'adresse' )) ->end() ->with('contact', array('label' => 'contact')) ->add('name', 'text') ->add('email', 'text') ->add('websiteurl') ->add('description') ->add('telephonenumber') ->add('telefaxnumber') ->end() ; }
in activityadmin
added that:
$formmapper->add('contact', 'sonata_type_admin', array('label' => false));
now want fields form contactadmin
looks in activityadmin
if directly open contactadmin
.
if understood wanted. should @ type form of sonata , sonata_type_collection
https://sonata-project.org/bundles/admin/master/doc/reference/form_types.html#sonata-type-collection
Comments
Post a Comment