mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-14 06:14:23 +00:00
add validation rule on slug for custom fields
This commit is contained in:
parent
3d2426d8df
commit
287c70c6f3
7
Resources/config/validation.yml
Normal file
7
Resources/config/validation.yml
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
Chill\CustomFieldsBundle\Entity\CustomField:
|
||||||
|
properties:
|
||||||
|
slug:
|
||||||
|
- Regex:
|
||||||
|
pattern: '/^[0-9a-z\-]{1,}$/'
|
||||||
|
message: Characters not allowed. Only lowercase letters, numbers and "-" are allowed.
|
||||||
|
|
1
Resources/translations/validators.fr.yml
Normal file
1
Resources/translations/validators.fr.yml
Normal file
@ -0,0 +1 @@
|
|||||||
|
Characters not allowed. Only lowercase letters, numbers and "-" are allowed.: Caractères non autorisés. Seules les lettres minuscules, les nombres et le tiret ("-") sont autorisés.
|
Loading…
x
Reference in New Issue
Block a user