feat: allow editing of email and phone unless applicant
This commit is contained in:
@@ -33,6 +33,7 @@ class ParticipantType extends AbstractType
|
||||
$form = $event->getForm();
|
||||
|
||||
$personalDataMutable = $options['personal_data_mutable'] && $participantData->mutable;
|
||||
$isApplicant = 1 === $participantIndex;
|
||||
|
||||
$form
|
||||
->add('firstName', TextType::class, [
|
||||
@@ -83,14 +84,14 @@ class ParticipantType extends AbstractType
|
||||
'label' => 'E-Mail',
|
||||
'required' => false,
|
||||
'attr' => [
|
||||
'readonly' => false === $personalDataMutable,
|
||||
'readonly' => true === $isApplicant,
|
||||
],
|
||||
])
|
||||
->add('mobile', TextType::class, [
|
||||
'label' => 'Telefon (mobil)',
|
||||
'required' => false,
|
||||
'attr' => [
|
||||
'readonly' => false === $personalDataMutable,
|
||||
'readonly' => true === $isApplicant,
|
||||
],
|
||||
])
|
||||
->add('height', ChoiceType::class, [
|
||||
|
||||
Reference in New Issue
Block a user