Upload image input


#1

How to have the correct css and behavior (the thumbnail is not displayed in edit mode) ?

this is my code php :
class ServiceType extends AbstractResourceType
{

public function buildForm(FormBuilderInterface $builder, array $options)
{
$builder ->add(‘images’, CollectionType::class, [
‘entry_type’ => ServiceImageType::class,
‘allow_add’ => true,
‘allow_delete’ => true,
‘by_reference’ => false,
‘label’ => ‘sylius.form.service.images’,
])
} …
in twig :
{% form_theme form ‘SyliusUiBundle:Form:imagesTheme.html.twig’ %}

{{ 'sylius.ui.media'|trans }}


{{ form_row(form.images, {'label': false}) }}
...