/[drupal]/contributions/modules/forward/forward.views.inc
ViewVC logotype

Contents of /contributions/modules/forward/forward.views.inc

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.1 - (show annotations) (download) (as text)
Sat Sep 6 21:04:50 2008 UTC (14 months, 2 weeks ago) by seanr
Branch: MAIN
CVS Tags: DRUPAL-6--1-7, DRUPAL-6--1-8, DRUPAL-6--1-9, DRUPAL-6--1-4, DRUPAL-6--1-6, DRUPAL-5--1-23, DRUPAL-6--1-0, DRUPAL-6--1-1, HEAD
Branch point for: DRUPAL-6--1
File MIME type: text/x-php
Views 2 integration
1 <?php
2 // $Id$
3
4 /**
5 * Implementation of hook_views_data()
6 */
7 function forward_views_data() {
8 // Basic table information.
9
10 // Define the base group of this table. Fields that don't
11 // have a group defined will go into this field by default.
12 $data['forward_statistics']['table'] = array(
13 'group' => t('Forward'),
14 );
15
16 // For other base tables, explain how we join
17 $data['forward_statistics']['table']['join']['node'] = array(
18 'left_field' => 'nid',
19 'field' => 'nid',
20 );
21
22 // Fields
23 $data['forward_statistics']['forward_count'] = array(
24 'title' => t('forward count'),
25 'help' => t('The module that associated a product with the node.'),
26 'field' => array('handler' => 'views_handler_field_numeric',),
27 'filter' => array('handler' => 'views_handler_filter_numeric',),
28 'sort' => array('handler' => 'views_handler_sort',),
29 );
30 $data['forward_statistics']['clickthrough_count'] = array(
31 'title' => t('clickthrough count'),
32 'help' => t('The module that associated a product with the node.'),
33 'field' => array('handler' => 'views_handler_field_numeric',),
34 'filter' => array('handler' => 'views_handler_filter_numeric',),
35 'sort' => array('handler' => 'views_handler_sort',),
36 );
37 $data['forward_statistics']['last_forward_timestamp'] = array(
38 'title' => t('most recent timestamp'),
39 'help' => t('The module that associated a product with the node.'),
40 'field' => array('handler' => 'views_handler_field_date',),
41 'filter' => array('handler' => 'views_handler_filter_timestamp',),
42 'sort' => array('handler' => 'views_handler_sort_date',),
43 );
44
45 return $data;
46 }
47

  ViewVC Help
Powered by ViewVC 1.1.2