You are here

function sheetnode_handler_field_cell::render in Sheetnode 7.2

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

Render the views field.

Overrides views_handler_field::render

File

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

Class

sheetnode_handler_field_cell
Provides a custom sheetnode handler.

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;
}