/** * * @param string $type * @param Element\ButtonElement|string $button * @param array $params Decorator parameters * @throws Exception */ public function addRowAction($link, $button = null, array $params = null) { if (!$button instanceof ButtonElement) { $title = $button; $button = new ButtonElement(); $button->setTitle($title); } $button->setLink($link); if (is_array($params)) { $button->setDecoratorParams($params); } return $this->_addEvent('row', $button); }