mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-13 13:54:23 +00:00
fix deprecations: use fqcn for chill classes
This commit is contained in:
parent
75b4ef5a7d
commit
ba79200e55
@ -24,7 +24,10 @@ namespace Chill\PersonBundle\Form;
|
||||
use Symfony\Component\Form\AbstractType;
|
||||
use Symfony\Component\Form\FormBuilderInterface;
|
||||
use Symfony\Component\OptionsResolver\OptionsResolverInterface;
|
||||
|
||||
use Chill\PersonBundle\Form\Type\GenderType;
|
||||
use Chill\MainBundle\Form\Type\Select2CountryType;
|
||||
use Chill\MainBundle\Form\Type\Select2LanguageType;
|
||||
|
||||
class PersonType extends AbstractType
|
||||
{
|
||||
@ -76,19 +79,19 @@ class PersonType extends AbstractType
|
||||
}
|
||||
|
||||
if ($this->config['country_of_birth'] === 'visible') {
|
||||
$builder->add('countryOfBirth', 'select2_chill_country', array(
|
||||
$builder->add('countryOfBirth', Select2CountryType::class, array(
|
||||
'required' => false
|
||||
));
|
||||
}
|
||||
|
||||
if ($this->config['nationality'] === 'visible') {
|
||||
$builder->add('nationality', 'select2_chill_country', array(
|
||||
$builder->add('nationality', Select2CountryType::class, array(
|
||||
'required' => false
|
||||
));
|
||||
}
|
||||
|
||||
if ($this->config['spoken_languages'] === 'visible') {
|
||||
$builder->add('spokenLanguages', 'select2_chill_language', array(
|
||||
$builder->add('spokenLanguages', Select2LanguageType::class, array(
|
||||
'required' => false,
|
||||
'multiple' => true
|
||||
));
|
||||
|
@ -26,6 +26,7 @@ use Chill\MainBundle\Form\Type\DataTransformer\ObjectToIdTransformer;
|
||||
use Symfony\Component\Form\FormBuilderInterface;
|
||||
use Symfony\Component\HttpFoundation\RequestStack;
|
||||
use Doctrine\Common\Persistence\ObjectManager;
|
||||
use Chill\MainBundle\Form\Type\Select2ChoiceType;
|
||||
|
||||
/**
|
||||
* A type to select the marital status
|
||||
@ -51,7 +52,7 @@ class Select2MaritalStatusType extends AbstractType
|
||||
}
|
||||
|
||||
public function getParent() {
|
||||
return 'select2_choice';
|
||||
return Select2ChoiceType::class;
|
||||
}
|
||||
|
||||
public function buildForm(FormBuilderInterface $builder, array $options)
|
||||
|
Loading…
x
Reference in New Issue
Block a user