You are here

function sheetnode_handler_field_cell::render in Sheetnode 7

Same name and namespace in other branches
  1. 6 views/sheetnode_handler_field_cell.inc \sheetnode_handler_field_cell::render()
  2. 7.2 views/sheetnode_handler_field_cell.inc \sheetnode_handler_field_cell::render()

Render the field.

Parameters

array $values: The values retrieved from the database.

Overrides views_handler_field::render

File

views/sheetnode_handler_field_cell.inc, line 24
Views handler for sheetnode cells.

Class

sheetnode_handler_field_cell
@file Views handler for sheetnode cells.

Code

function render($values) {
  module_load_include('inc', 'sheetnode', 'socialcalc');
  $sheet = $values->{$this->field_alias};
  if (empty($sheet)) {
    return NULL;
  }
  $sc = socialcalc_parse_values($sheet);
  return isset($sc['cells'][$this->options['reference']]) ? $sc['cells'][$this->options['reference']]['datavalue'] : NULL;
}