public function getStatusLabel($statusName) { if (!$this->workflow) { throw new \Exception('Decorator needs a workflow to produce labels'); } $config = $this->workflow->getStatusConfig($statusName); return $this->translateLabel($config['label']); }
/** * Returns the objects layout configuration given the current place in the workflow * If no layout is specified then null will be returned * @return string|null */ public function getObjectLayout() { $statusConfig = $this->workflow->getStatusConfig($this->getElementStatus()); if (!empty($statusConfig['objectLayout']) && is_numeric($statusConfig['objectLayout'])) { return $statusConfig['objectLayout']; } return null; }