You are here

function workflow_extensions_handler_field_workflow_comment_link_edit::render in Workflow Extensions 6

Same name and namespace in other branches
  1. 7 views/workflow_extensions_handler_field_workflow_comment_link_edit.inc \workflow_extensions_handler_field_workflow_comment_link_edit::render()

File

views/workflow_extensions_handler_field_workflow_comment_link_edit.inc, line 33

Class

workflow_extensions_handler_field_workflow_comment_link_edit
Field handler to present a link to edit a workflow log comment.

Code

function render($values) {
  if (!user_access('edit workflow log')) {
    return;
  }
  $hid = $values->{$this->aliases['hid']};
  $text = empty($this->options['text']) ? t('edit comment') : $this->options['text'];
  return l($text, "workflow-log/{$hid}", array(
    'query' => drupal_get_destination(),
  ));
}