Files
mautic-marketing-program-bu…/Validator/Constraints/TaskDates.php
T
Alexandre Gain 71ff11390b refactor(plugin): rename Plan to Program and add audience/UTM routes
Rename the Plan bundle to Program across config, routes, menus, and
controllers (Plan -> Initiative), bump version to 0.16.0, and introduce
new audience and UTM taxonomy routes and permissions to support the
expanded Programs feature set.
2026-11-13 22:01:32 +01:00

25 lines
697 B
PHP

<?php
declare(strict_types=1);
namespace MauticPlugin\ProgramBundle\Validator\Constraints;
use Symfony\Component\Validator\Constraint;
/**
* Applies the task kind's rules to the dates:
* - a milestone's end date is enslaved to its start date (saved as equals);
* - a phase keeps its own dates, like any task.
*
* The start-before-end rule itself is EndDateAfterStartDate, shared by plans and tasks.
*/
#[\Symfony\Component\Validator\Attribute\HasNamedArguments]
class TaskDates extends Constraint
{
public const MILESTONE_END_ENSLAVED = 'mautic.program.task.milestone.end_enslaved';
public function getTargets(): string|array
{
return self::CLASS_CONSTRAINT;
}
}