You are here

function content_views_data in Content Construction Kit (CCK) 6

Same name and namespace in other branches
  1. 6.3 includes/views/content.views.inc \content_views_data()
  2. 6.2 includes/views/content.views.inc \content_views_data()

Implementation of hook_views_data().

Exposes all fields to the views system.

File

includes/content.views.inc, line 23

Code

function content_views_data() {
  $data = array();
  foreach (content_fields() as $field) {
    $module = $field['module'];
    $result = module_invoke($module, 'field_settings', 'views data', $field);
    if (empty($result)) {
      $result = content_views_field_views_data($field);
    }
    if (is_array($result)) {
      $data = array_merge($data, $result);
    }
  }
  return $data;
}