Elcodi\Store\UserBundle\Form\Type\ProfileType::buildForm PHP Метод

buildForm() публичный Метод

Buildform function
public buildForm ( Symfony\Component\Form\FormBuilderInterface $builder, array $options )
$builder Symfony\Component\Form\FormBuilderInterface the formBuilder
$options array the options for this form
    public function buildForm(FormBuilderInterface $builder, array $options)
    {
        $builder->setMethod('POST')->add('firstname', 'text', ['required' => true, 'label' => 'store.user.form.fields.firstname.label'])->add('lastname', 'text', ['required' => true, 'label' => 'store.user.form.fields.lastname.label'])->add('email', 'email', ['required' => true, 'label' => 'store.user.form.fields.email.label'])->add('password', 'repeated', ['type' => 'password', 'first_options' => ['label' => 'store.user.form.fields.password.label'], 'second_options' => ['label' => 'store.user.form.fields.repeat_password.label'], 'required' => false])->add('send', 'submit', ['label' => 'store.user.form.fields.send.label']);
    }