Get a relative link to the current controller

@param null $action

@return string
550236
public function Link($action = null)
    {
        if (!$action) {
            $action = $this->step;
        }

        return $this->dataRecord->RelativeLink($action);
    }
151971
protected function urlAction ($action)
    {
        // Get controller public name
        $ctrlPubName = \Teon\Base\Stdlib\ClassUtils::getPublicControllerName(get_class($this));

        // Return generated URL
        return $this->url()->fromRoute($ctrlPubName, array('action' => $action));
    }
581621
public function Link($action = null)
    {
        /** @skipUpgrade */
        $link = Controller::join_links(Director::baseURL(), "Security", $action);
        $this->extend('updateLink', $link, $action);
        return $link;
    }
328696
public function getPositionByName($controller, $action = null)
    {
        if ($action === null) {
            list($controller, $action) = explode('.', $controller);
        }
        return array_search("{$controller}.{$action}", $this->action_names);
    }
566196
public function getFilterKey($action = null)
    {
        // controller.action
        $controller = $this->getName();
        return $action ? $controller . '.' . $action : $controller;
    }
988678
public function getAction()
    {
        if (!is_null(self::$action)) {
            return self::$action;
        }
        $controllerParam = array_get($this->routeParams, 'controller');
        $match           = null;

        if (!preg_match("/.+?(?=@)@(.*)/", $controllerParam, $match)) {
            return;
        }
        self::$action = strtolower($match[1]);
        return self::$action;
    }
337712
public function Link($action = null) {
		$link = $this->data()->Link(($action ? $action : true));
		
		$params = array();
		
		$tags = $this->getRequest()->getVar('tags');
		if (strlen($tags)) {
			$params['tags'] = $tags;
		}

		$popup = $this->getRequest()->getVar('popup');
		if ($popup) {
			$params['popup'] = 1;
		}
		
		$tagstr = count($params) ? '?' . http_build_query($params) : '';
		return Controller::join_links($link, $tagstr);
	}
738516
protected function actionReferencesController($action)
    {
        if ($action instanceof Closure) {
            return false;
        }

        return is_string($action) || is_string(array_get($action, 'uses'));
    }
860381
protected function actionReferencesController($action)
    {
        if (! $action instanceof Closure) {
            return is_string($action) || (isset($action['uses']) && is_string($action['uses']));
        }

        return false;
    }
1242204
public function AbsoluteLink($action = null)
    {
        if ($this->owner->hasMethod('alternateAbsoluteLink')) {
            return $this->owner->alternateAbsoluteLink($action);
        } else {
            return Director::absoluteURL($this->owner->Link($action));
        }
    }
692246
public function Link($action = null)
    {
        $page = Director::get_current_page();

        if ($page && !($page instanceof ElementController)) {
            return Controller::join_links(
                $page->Link($action),
                '#'. $this->element->getAnchor()
            );
        }

        $curr = Controller::curr();

        if ($curr && !($curr instanceof ElementController)) {
            return Controller::join_links(
                $curr->Link($action),
                '#'. $this->element->getAnchor()
            );
        }
    }
89707
public function getByAction($action)
    {
        return isset($this->actions[$action]) ? $this->actions[$action] : null;
    }
1363464
public function updatePreviewLink(&$link, $action = null)
    {
        $url = Director::absoluteURL($this->owner->Link($action));
        $link = HTTP::setGetVar('SubsiteID', $this->owner->SubsiteID, $url);
        return $link;
    }
408117
public function currentRouteAction()
	{
		if ( ! $this->current()) return;

		$action = $this->current()->getAction();

		return isset($action['controller']) ? $action['controller'] : null;
	}
1315860
public function Link($action = null)
    {
        if (!$action) {
            $action = $this->sanitiseClassName($this->modelClass);
        }
        return parent::Link($action);
    }
575071
public function Link($action = null)
    {
        // Forms without parent controller have no link;
        // E.g. Submission handled via graphql
        $controller = $this->form->getController();
        if (empty($controller)) {
            return null;
        }

        // Respect FormObjectLink() method
        if ($controller->hasMethod("FormObjectLink")) {
            $base = $controller->FormObjectLink($this->form->getName());
        } else {
            $base = Controller::join_links($controller->Link(), $this->form->getName());
        }

        // Join with action and decorate
        $link = Controller::join_links($base, $action, '/');
        $this->extend('updateLink', $link, $action);
        return $link;
    }
876636
public function Link($action = null)
    {
        if (!$action
            && Member::currentUserID()
            && !$this->AllowProfileEditing
            && $this->CanAddMembers()
        ) {
            $action = 'add';
        }

        return parent::Link($action);
    }