You are here

function theme_views_tree_inner in Views tree 7.2

Same name and namespace in other branches
  1. 6.2 views_tree.module \theme_views_tree_inner()
  2. 6 views_tree.module \theme_views_tree_inner()

Inner recursive theme function for views tree theming.

Parameters

$view:

$options:

$row:

$title:

$result: An array representing the raw data returned from the query.

$parent: The id of the parent entry in the call stack.

1 theme call to theme_views_tree_inner()
theme_views_tree in ./views_tree.module
Theme function for the tree style plugin.

File

./views_tree.module, line 135
Views Tree module.

Code

function theme_views_tree_inner($variables) {
  $view = $variables['view'];
  $options = $variables['options'];
  $rows = $variables['rows'];
  $title = $variables['title'];
  $result = $variables['result'];
  $parent = $variables['parent'];
  $items = array();
  foreach ($result as $i => $record) {
    if ($record->views_tree_parent == $parent) {
      $variables['parent'] = $record->views_tree_main;
      $items[] = $rows[$i] . call_user_func(__FUNCTION__, $variables);
    }
  }
  return count($items) ? theme('item_list', array(
    'items' => $items,
    'type' => $options['type'],
  )) : '';
}