public function editlink()
{
$perm = 'contenttype:' . $this->contenttype['slug'] . ':edit:' . $this->id;
if ($this->app['users']->isAllowed($perm)) {
return $this->app['url_generator']->generate('editcontent', ['contenttypeslug' => $this->contenttype['slug'], 'id' => $this->id]);
} else {
return false;
}
}