function node_expire_views_data in Node expire 6.2
Same name and namespace in other branches
- 8 node_expire.views.inc \node_expire_views_data()
- 7.2 node_expire.views.inc \node_expire_views_data()
- 7 node_expire.views.inc \node_expire_views_data()
Implementation of hook_views_data()
File
- ./
node_expire.views.inc, line 11 - Views module integration.
Code
function node_expire_views_data() {
// Join to 'node' as a base table.
$data['node_expire']['table']['group'] = t('Node');
$data['node_expire']['table']['join'] = array(
'node' => array(
'left_field' => 'nid',
'field' => 'nid',
),
);
$data['node_expire']['expire'] = array(
'title' => t('Expire date'),
'help' => t('Date of when the content expire.'),
'field' => array(
'handler' => 'views_handler_field_date',
'click sortable' => TRUE,
),
'sort' => array(
'handler' => 'views_handler_sort_date',
),
'filter' => array(
'handler' => 'views_handler_filter_date',
),
);
$data['node_expire']['expired'] = array(
'title' => t('Expired'),
'help' => t('Whether the content is expired.'),
'field' => array(
'handler' => 'views_handler_field_boolean',
'click sortable' => TRUE,
),
'filter' => array(
'handler' => 'views_handler_filter_boolean_operator',
'label' => t('Expired'),
'type' => 'yes-no',
),
'sort' => array(
'handler' => 'views_handler_sort',
),
);
return $data;
}