/** * Get the action for an "action" option. * * @param array|string $options * @return string */ protected function getControllerAction($options) { if (is_array($options)) { return $this->url->action($options[0], array_slice($options, 1)); } return $this->url->action($options); }
/** * Create a new redirect response. * * @param string $path * @param int $status * @param array $headers * @return \Nova\Http\RedirectResponse */ protected function createRedirect($path, $status, $headers) { $redirect = new RedirectResponse($path, $status, $headers); if (isset($this->session)) { $redirect->setSession($this->session); } $redirect->setRequest($this->generator->getRequest()); return $redirect; }
/** * Generate a HTML link to a controller action. * * @param string $action * @param string $title * @param array $parameters * @param array $attributes * @return string */ public function linkAction($action, $title = null, $parameters = array(), $attributes = array()) { return $this->link($this->url->action($action, $parameters), $title, $attributes); }