You are here

function nodehierarchy_views_content_extra_fields in Node Hierarchy 6.2

Same name and namespace in other branches
  1. 6.3 nodehierarchy_views/nodehierarchy_views.module \nodehierarchy_views_content_extra_fields()

Implementation of hook_content_extra_fields.

File

nodehierarchy_views/nodehierarchy_views.module, line 29
Embed a view of children onto a node.

Code

function nodehierarchy_views_content_extra_fields($type_name) {
  $extra = array();
  if (nodehierarchy_node_can_be_parent($type_name)) {
    $extra['nodehierarchy_children'] = array(
      'label' => t('Node Hierarchy Children'),
      'description' => t('Node Hierarchy embedded children view.'),
      'weight' => 10,
    );
    $extra['nodehierarchy_children_links'] = array(
      'label' => t('Node Hierarchy Add Child Links'),
      'description' => t('Links to create a new child.'),
      'weight' => 10,
    );
  }
  return $extra;
}