Skip to content

Commit

Permalink
remove constraint from foreign bundle
Browse files Browse the repository at this point in the history
  • Loading branch information
KatjaGlassConsulting committed Nov 3, 2024
1 parent dd87dfc commit c25190f
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changelog

# 1.1.0 to 1.1.1

- fix using no constrait for new setting from VacationBundle (different plugin not always available)

# 1.0.3 to 1.1.0

- instead of working with "Customer for free days", options for "Holiday Activitiy" and "Vacation Activitiy" is to be used
Expand Down
6 changes: 2 additions & 4 deletions Form/SettingsForm.php
Original file line number Diff line number Diff line change
Expand Up @@ -113,17 +113,15 @@ public function buildForm(FormBuilderInterface $builder, array $options)
'class' => Activity::class,
'choice_label' => 'name',
'required' => false,
'data' => $this->activityRepository->findOneBy(['id' => $this->settingsTool->getConfiguration(ConfigEnum::ACTIVITY_FOR_HOLIDAYS)]),
'constraints' => [new \KimaiPlugin\VacationBundle\Validator\Activity()]
'data' => $this->activityRepository->findOneBy(['id' => $this->settingsTool->getConfiguration(ConfigEnum::ACTIVITY_FOR_HOLIDAYS)])
]);

$builder->add(FormEnum::ACTIVITY_FOR_VACATIONS, EntityType::class, [
'label' => 'label.activity_for_vacations',
'class' => Activity::class,
'choice_label' => 'name',
'required' => false,
'data' => $this->activityRepository->findOneBy(['id' => $this->settingsTool->getConfiguration(ConfigEnum::ACTIVITY_FOR_VACATIONS)]),
'constraints' => [new \KimaiPlugin\VacationBundle\Validator\Activity()]
'data' => $this->activityRepository->findOneBy(['id' => $this->settingsTool->getConfiguration(ConfigEnum::ACTIVITY_FOR_VACATIONS)])
]);

$data = $this->settingsTool->getConfiguration(ConfigEnum::META_FIELD_EMAIL_LINK_URL);
Expand Down

0 comments on commit c25190f

Please sign in to comment.