protected function getUriById( $paragraphId, $absolute = false )
    {
        /* @var $model \Grid\Paragraph\Model\Paragraph\Model */
        $service    = $this->getServiceLocator();
        $model      = $service->get( 'Grid\Paragraph\Model\Paragraph\Model' );
        $paragraph  = $model->find( $paragraphId );

        if ( empty( $paragraph ) )
        {
            return '#error-paragraph-notFound:' . $paragraphId;
        }

        if ( 'content' == $paragraph->type )
        {
            return $this->getUriForContent( $this->contentId, $absolute );
        }

        if ( $paragraph->id == $paragraph->rootId )
        {
            return $this->getFallbackUri( $paragraphId, $absolute );
        }

        return $this->getUriById( $paragraph->rootId, $absolute )
             . '#paragraph-' . $paragraph->id;
    }
protected function getUriById( $paragraphId, $absolute = false )
    {
        /* @var $model \Grid\Paragraph\Model\Paragraph\Model */
        $service    = $this->getServiceLocator();
        $model      = $service->get( 'Grid\Paragraph\Model\Paragraph\Model' );
        $paragraph  = $model->find( $paragraphId );

        if ( empty( $paragraph ) )
        {
            return '#error-paragraph-notFound:' . $paragraphId;
        }

        if ( 'content' == $paragraph->type )
        {
            return $this->getUriForContent( $this->contentId, $absolute );
        }

        if ( $paragraph->id == $paragraph->rootId )
        {
            return $this->getFallbackUri( $paragraphId, $absolute );
        }

        return $this->getUriById( $paragraph->rootId, $absolute )
             . '#paragraph-' . $paragraph->id;
    }
protected function getUriById ( $ paragraphId , $ absolute = false ) { /* @var $model \Grid\Paragraph\Model\Paragraph\Model */ $ service = $ this -> getServiceLocator ( ) ; $ model = $ service -> get ( 'Grid\Paragraph\Model\Paragraph\Model' ) ; $ paragraph = $ model -> find ( $ paragraphId ) ; if ( empty ( $ paragraph ) ) { return '#error-paragraph-notFound:' . $ paragraphId ; } if ( 'content' == $ paragraph -> type ) { return $ this -> getUriForContent ( $ this -> contentId , $ absolute ) ; } if ( $ paragraph -> id == $ paragraph -> rootId ) { return $ this -> getFallbackUri ( $ paragraphId , $ absolute ) ; } return $ this -> getUriById ( $ paragraph -> rootId , $ absolute ) . '#paragraph-' . $ paragraph -> id ; }
Get uri by id

@param   int     $paragraphId
@param   bool    $absolute
@return  string
Get uri by id