Use "workflow_triggers" table instead of an inline JSON

[MAILPOET-4778]
This commit is contained in:
Jan Jakes
2022-11-07 15:42:29 +03:00
committed by David Remer
parent 407f3d1609
commit cc5959805b
4 changed files with 100 additions and 41 deletions

View File

@@ -167,14 +167,6 @@ class Workflow {
return $step->toArray();
}, $this->steps)
),
'trigger_keys' => Json::encode(
array_reduce($this->steps, function (array $triggerKeys, Step $step): array {
if ($step->getType() === Step::TYPE_TRIGGER) {
$triggerKeys[] = $step->getKey();
}
return $triggerKeys;
}, [])
),
];
}