feat: ensure teamer accepts terms when confirming driver's license

This commit is contained in:
Björn Fromme
2026-03-15 12:42:28 +01:00
parent 3b6ebdaddc
commit 3d71dcfc14
3 changed files with 52 additions and 14 deletions
+13 -7
View File
@@ -6,6 +6,7 @@ use App\Model\DriverLicenseDeclarationDto;
use App\Model\UploadSessionDto;
use App\Service\Upload\UploadHandler;
use Symfony\Component\Form\AbstractType;
use Symfony\Component\Form\Extension\Core\Type\CheckboxType;
use Symfony\Component\Form\Extension\Core\Type\ChoiceType;
use Symfony\Component\Form\FormBuilderInterface;
use Symfony\Component\Form\FormInterface;
@@ -16,13 +17,18 @@ class DriverLicenseDeclarationType extends AbstractType
{
public function buildForm(FormBuilderInterface $builder, array $options): void
{
$builder->add('hasDriverLicense', ChoiceType::class, [
'label' => 'Besitzt du einen gültigen Führerschein?',
'choices' => [
'Ja' => true,
'Nein' => false,
],
]);
$builder
->add('hasDriverLicense', ChoiceType::class, [
'label' => 'Besitzt du einen gültigen Führerschein?',
'choices' => [
'Ja' => true,
'Nein' => false,
],
])
->add('confirmTermsOfUse', CheckboxType::class, [
'label' => 'Ich bestätige, die KfZ-Nutzungsbedingungen gelesen zu haben und stimme ihnen zu.',
])
;
}
public function buildView(FormView $view, FormInterface $form, array $options): void