Commit f2a077c3 authored by Raidelet Nicolas's avatar Raidelet Nicolas Committed by Guillaume Perréal
Browse files

Migration des Forms + CS + PHPDocs

Showing with 6 additions and 8 deletions
+6 -8
......@@ -23,7 +23,6 @@ use Symfony\Component\Validator\Constraints\NotBlank;
/** Type de champ 'file_upload'.
* Options :.
*
* * multiple (boolean) : fichier unique ou multiple ? false par défaut.
* * accept_file_types (string) : expression régulière de contrôle des types MIME acceptés. Aucune par défaut.
* * max_file_size (integer) : taille maximale d'un fichier. 0 (illimité) par défaut.
......@@ -113,14 +112,13 @@ class FileUploadType extends AbstractType
]
);
$resolver->setAllowedTypes(['max_chunk_size' => 'int']);
$resolver->addAllowedTypes('max_chunk_size', 'int');
$resolver->setNormalizers(
[
'constraints' => function (OptionsResolver $options, $constraints) {
return $this->addConstraints($options, $constraints);
},
]
$resolver->setNormalizer(
'constraints',
function (OptionsResolver $options, $constraints) {
return $this->addConstraints($options, $constraints);
}
);
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment