diff --git a/op/op.TriggerWorkflow.php b/op/op.TriggerWorkflow.php index e147dc5fb..7eac816a5 100644 --- a/op/op.TriggerWorkflow.php +++ b/op/op.TriggerWorkflow.php @@ -106,5 +106,7 @@ if($ret = $version->triggerWorkflowTransition($user, $transition, $_POST["commen add_log_line("?documentid=".$documentid."&version".$version_num); -header("Location:../out/out.ViewDocument.php?documentid=".$documentid."¤ttab=workflow"); -?> +if($version->getStatus()['status'] == S_IN_WORKFLOW) + header("Location:../out/out.ViewDocument.php?documentid=".$documentid."¤ttab=workflow"); +else + header("Location:../out/out.ViewDocument.php?documentid=".$documentid);