diff --git a/.changes/unreleased/Fixed-20260210-155209.yaml b/.changes/unreleased/Fixed-20260210-155209.yaml new file mode 100644 index 000000000..9cd6c9cb1 --- /dev/null +++ b/.changes/unreleased/Fixed-20260210-155209.yaml @@ -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 diff --git a/src/Bundle/ChillMainBundle/Entity/Workflow/EntityWorkflow.php b/src/Bundle/ChillMainBundle/Entity/Workflow/EntityWorkflow.php index ad5fa9e95..914a71615 100644 --- a/src/Bundle/ChillMainBundle/Entity/Workflow/EntityWorkflow.php +++ b/src/Bundle/ChillMainBundle/Entity/Workflow/EntityWorkflow.php @@ -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;