fix deprecations: getName → getBlockPrefix

This commit is contained in:
nobohan
2018-03-30 14:06:54 +02:00
parent ffd2ee6f69
commit 85018f1927
5 changed files with 19 additions and 17 deletions

View File

@@ -5,6 +5,7 @@ namespace Chill\MainBundle\Form;
use Symfony\Component\Form\AbstractType;
use Symfony\Component\Form\FormBuilderInterface;
use Symfony\Component\OptionsResolver\OptionsResolver;
use Symfony\Component\Form\Extension\Core\Type\TextType;
class CenterType extends AbstractType
{
@@ -15,10 +16,10 @@ class CenterType extends AbstractType
public function buildForm(FormBuilderInterface $builder, array $options)
{
$builder
->add('name')
->add('name', TextType::class)
;
}
/**
* @param OptionsResolverInterface $resolver
*/
@@ -32,8 +33,9 @@ class CenterType extends AbstractType
/**
* @return string
*/
public function getName()
public function getBlockPrefix()
{
return 'chill_mainbundle_center';
}
return 'chill_mainbundle_center';
}
}