Merge branch '498-fix-workflow-initiator' into 'master'

Take workflow creator into account when granting edit permissions on documents

Closes #498

See merge request Chill-Projet/chill-bundles!959
This commit is contained in:
2026-02-10 15:05:50 +00:00
2 changed files with 10 additions and 0 deletions

View File

@@ -0,0 +1,6 @@
kind: Fixed
body: For giving edit permissions on documents, take into account the workflow creator
time: 2026-02-10T15:52:09.785649121+01:00
custom:
Issue: "498"
SchemaChange: No schema change

View File

@@ -394,6 +394,10 @@ class EntityWorkflow implements TrackCreationInterface, TrackUpdateInterface
public function isUserInvolved(User $user): bool
{
if ($this->getCreatedBy() === $user) {
return true;
}
foreach ($this->getSteps() as $step) {
if ($step->getAllDestUser()->contains($user)) {
return true;