public function editlink($record)
    {
        $perm = 'contenttype:' . $record->contenttype['slug'] . ':edit:' . $record->id;

        if ($this->users->isAllowed($perm)) {
            return $this->urlGenerator->generate('editcontent', ['contenttypeslug' => $record->contenttype['slug'], 'id' => $record->id]);
        }

        return false;
    }
public function editlink($record)
    {
        $perm = 'contenttype:' . $record->contenttype['slug'] . ':edit:' . $record->id;

        if ($this->users->isAllowed($perm)) {
            return $this->urlGenerator->generate('editcontent', ['contenttypeslug' => $record->contenttype['slug'], 'id' => $record->id]);
        }

        return false;
    }
public function editlink ( $ record ) { $ perm = 'contenttype:' . $ record -> contenttype [ 'slug' ] . ':edit:' . $ record -> id ; if ( $ this -> users -> isAllowed ( $ perm ) ) { return $ this -> urlGenerator -> generate ( 'editcontent' , [ 'contenttypeslug' => $ record -> contenttype [ 'slug' ] , 'id' => $ record -> id ] ) ; } return false ; }
Generate a backend edit link for a given record if the user has the permission

@param $record

@return bool
Generate a backend edit link for a given record if the user has the permission