]> Raphaƫl G. Git Repositories - airbundle/blob - Form/RegisterType.php
Update translations
[airbundle] / Form / RegisterType.php
1 <?php
2
3 namespace Rapsys\AirBundle\Form;
4
5 use Symfony\Component\Form\Extension\Core\Type\TelType;
6 use Symfony\Component\Form\FormBuilderInterface;
7 use Symfony\Component\Validator\Constraints\NotBlank;
8
9 class RegisterType extends \Rapsys\UserBundle\Form\RegisterType {
10 /**
11 * {@inheritdoc}
12 */
13 public function buildForm(FormBuilderInterface $builder, array $options) {
14 return parent::buildForm($builder, $options)
15 ->add('phone', TelType::class, array('attr' => array('placeholder' => 'Your phone'), 'constraints' => array(new NotBlank(array('message' => 'Please provide your phone')))));
16 }
17
18 /**
19 * {@inheritdoc}
20 */
21 public function getName() {
22 return 'rapsys_air_register';
23 }
24 }