fix: disable autocompletion on personal data fields

This commit is contained in:
Björn Fromme
2025-12-08 16:20:20 +01:00
parent 1aa564960d
commit 1726523eaf
2 changed files with 21 additions and 0 deletions
+9
View File
@@ -20,16 +20,25 @@ class AddressType extends AbstractType
'label' => 'Straße',
'required' => $options['required'],
'sanitize_html' => true,
'attr' => [
'autocomplete' => 'off',
],
])
->add('postCode', TextType::class, [
'label' => 'PLZ',
'required' => $options['required'],
'sanitize_html' => true,
'attr' => [
'autocomplete' => 'off',
],
])
->add('city', TextType::class, [
'label' => 'Ort',
'required' => $options['required'],
'sanitize_html' => true,
'attr' => [
'autocomplete' => 'off',
],
])
->add('country', CountryType::class, [
'label' => 'Land',
+12
View File
@@ -168,6 +168,9 @@ class BookingParticipantType extends AbstractType
'label' => 'Vorname',
'sanitize_html' => true,
'property_path' => 'participant.firstName',
'attr' => [
'autocomplete' => 'off',
],
], $getFieldState('firstName')));
}
@@ -176,6 +179,9 @@ class BookingParticipantType extends AbstractType
'label' => 'Nachname',
'sanitize_html' => true,
'property_path' => 'participant.lastName',
'attr' => [
'autocomplete' => 'off',
],
], $getFieldState('lastName')));
}
@@ -216,6 +222,9 @@ class BookingParticipantType extends AbstractType
$form->add('email', EmailType::class, $this->mergeFieldState([
'label' => 'E-Mail',
'property_path' => 'participant.email',
'attr' => [
'autocomplete' => 'off',
],
], $getFieldState('email')));
}
@@ -225,6 +234,9 @@ class BookingParticipantType extends AbstractType
'required' => false,
'sanitize_html' => true,
'property_path' => 'participant.mobile',
'attr' => [
'autocomplete' => 'off',
],
], $getFieldState('mobile')));
}