Show validation errors in SIUnitType

This commit is contained in:
Jan Böhmer 2019-08-25 13:14:30 +02:00
parent 6da2057a7e
commit 59748ecc22
2 changed files with 2 additions and 0 deletions

View file

@ -57,6 +57,7 @@ class SIUnitType extends AbstractType implements DataMapperInterface
$resolver->setDefaults([
'show_prefix' => true,
'is_integer' => false,
'error_mapping' => [ '.' => 'value']
]);
$resolver->setRequired('unit');

View file

@ -43,4 +43,5 @@
{% endif %}
</div>
</div>
{{ form_errors(form.value) }}
{% endblock %}