src/Forms/FormRequestHandler.php
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;
    }
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;
    }
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 ; }
Get link for this form

@param string $action
@return string
Get link for this form