From 7ad78fbce145ed0d1e918b78501a9d767513b5db Mon Sep 17 00:00:00 2001 From: Pol Dellaiera Date: Tue, 22 Feb 2022 12:52:09 +0100 Subject: [PATCH] remove regex --- src/Bundle/ChillPersonBundle/Entity/Person.php | 6 ------ src/Bundle/ChillPersonBundle/config/validation.yaml | 3 --- 2 files changed, 9 deletions(-) diff --git a/src/Bundle/ChillPersonBundle/Entity/Person.php b/src/Bundle/ChillPersonBundle/Entity/Person.php index ce906ed64..9a8555d8e 100644 --- a/src/Bundle/ChillPersonBundle/Entity/Person.php +++ b/src/Bundle/ChillPersonBundle/Entity/Person.php @@ -372,9 +372,6 @@ class Person implements HasCenterInterface, TrackCreationInterface, TrackUpdateI * The person's mobile phone number. * * @ORM\Column(type="text") - * @Assert\Regex( - * pattern="/^([\+{1}])([0-9\s*]{4,20})$/", - * ) * @PhonenumberConstraint( * type="mobile", * ) @@ -430,9 +427,6 @@ class Person implements HasCenterInterface, TrackCreationInterface, TrackUpdateI * The person's phonenumber. * * @ORM\Column(type="text", nullable=true) - * @Assert\Regex( - * pattern="/^([\+{1}])([0-9\s*]{4,20})$/", - * ) * @PhonenumberConstraint( * type="landline", * ) diff --git a/src/Bundle/ChillPersonBundle/config/validation.yaml b/src/Bundle/ChillPersonBundle/config/validation.yaml index 192fc60f6..9719ec2d9 100644 --- a/src/Bundle/ChillPersonBundle/config/validation.yaml +++ b/src/Bundle/ChillPersonBundle/config/validation.yaml @@ -19,8 +19,5 @@ Chill\PersonBundle\Entity\AccompanyingPeriod: Chill\PersonBundle\Entity\PersonPhone: properties: phonenumber: - - Regex: - pattern: '/^([\+{1}])([0-9\s*]{4,20})$/' - message: 'Invalid phone number: it should begin with the international prefix starting with "+", hold only digits and be smaller than 20 characters. Ex: +33123456789' - Chill\MainBundle\Validation\Constraint\PhonenumberConstraint: type: any