mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-07 18:44:08 +00:00
Feature: send notification on ccuser for workflows
This commit is contained in:
parent
2b3d7f34fc
commit
1789a75216
@ -50,6 +50,10 @@ class EntityWorkflowTransitionEventSubscriber implements EventSubscriberInterfac
|
||||
/** @var EntityWorkflow $entityWorkflow */
|
||||
$entityWorkflow = $event->getSubject();
|
||||
|
||||
foreach ($entityWorkflow->futureCcUsers as $user) {
|
||||
$entityWorkflow->getCurrentStep()->addCcUser($user);
|
||||
}
|
||||
|
||||
foreach ($entityWorkflow->futureDestUsers as $user) {
|
||||
$entityWorkflow->getCurrentStep()->addDestUser($user);
|
||||
}
|
||||
|
@ -85,7 +85,9 @@ class NotificationOnTransition implements EventSubscriberInterface
|
||||
// the subscriber to final, only if final
|
||||
$entityWorkflow->isFinal() ? $entityWorkflow->getSubscriberToFinal()->toArray() : [],
|
||||
// the dests for the current step
|
||||
$entityWorkflow->getCurrentStep()->getDestUser()->toArray()
|
||||
$entityWorkflow->getCurrentStep()->getDestUser()->toArray(),
|
||||
// the cc users for the current step
|
||||
$entityWorkflow->getCurrentStep()->getCcUser()->toArray()
|
||||
) as $dest) {
|
||||
$dests[spl_object_hash($dest)] = $dest;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user