resolve deprecated form stuff
This commit is contained in:
parent
58b80628dd
commit
8b4cd94db8
7 changed files with 104 additions and 88 deletions
|
|
@ -19,9 +19,7 @@ use Symfony\Component\OptionsResolver\OptionsResolverInterface;
|
|||
*/
|
||||
abstract class BaseAbstractType extends AbstractType
|
||||
{
|
||||
protected $options = array(
|
||||
'name' => '',
|
||||
);
|
||||
protected $options = array();
|
||||
|
||||
public function __construct($mergeOptions = null)
|
||||
{
|
||||
|
|
@ -63,17 +61,11 @@ abstract class BaseAbstractType extends AbstractType
|
|||
$resolver->setDefaults($this->options);
|
||||
}
|
||||
|
||||
// BC for SF < 2.7
|
||||
public function setDefaultOptions(OptionsResolverInterface $resolver)
|
||||
{
|
||||
$this->configureOptions($resolver);
|
||||
}
|
||||
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function getName()
|
||||
{
|
||||
return $this->getOption('name');
|
||||
return get_class($this);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue