src/Form/ClientType.php line 11
<?phpnamespace App\Form;use App\Entity\Client;use Symfony\Component\Form\AbstractType;use Symfony\Component\Form\Extension\Core\Type\ChoiceType;use Symfony\Component\Form\FormBuilderInterface;use Symfony\Component\OptionsResolver\OptionsResolver;class ClientType extends AbstractType{public function buildForm(FormBuilderInterface $builder, array $options): void{$builder->add('firstname', null, ['label' => 'Jméno'])->add('lastname', null, ['label' => 'Příjmení'])->add('nationalityOther', null, ['label' => 'Jiný stát'])->add('nationality', ChoiceType::class, ['label' => 'Občanství','placeholder' => 'Vyberte občanství','choices' => ['Česká republika' => 'Česká republika','Slovensko' => 'Slovensko','Polsko' => 'Polsko','Ukrajina' => 'Ukrajina','Německo' => 'Německo','Jiný' => 'Jiný'],'required' => true])->add('birthPlace', null, ['label' => 'Místo narození'])->add('birthDate', null, ['label' => 'Datum narození', 'widget' => 'single_text'])->add('idNumber', null, ['label' => 'Číslo dokladu', 'required' => true])->add('street', null, ['label' => 'Ulice'])->add('city', null, ['label' => 'Město'])->add('postcode', null, ['label' => 'PSČ'])->add('phone', null, ['label' => 'Telefon'])->add('phone2', null, ['label' => 'Telefon 2'])->add('email', null, ['label' => 'Email'])// ->add('note', null, ['label' => 'Poznámka']);}public function configureOptions(OptionsResolver $resolver): void{$resolver->setDefaults(['data_class' => Client::class,]);}}