pcp.views.inc in Profile Complete Percent 7
Declare Profile Complete Percent fields.
File
includes/pcp.views.incView source
<?php
/**
* @file
* Declare Profile Complete Percent fields.
*/
/**
* Implements hook_views_data_alter().
*
* Here we define pseudo-fields for the {profile} table.
*/
function pcp_views_data_alter(&$data) {
$data['users']['profile_completeness'] = array(
'title' => t('Profile Completeness'),
'help' => t('Profile completeness expressed as a percentage 0..100'),
'field' => array(
'handler' => 'pcp_handler_field_profile_completeness_core',
'click sortable' => FALSE,
),
);
$data['profile']['profile_completeness'] = array(
'title' => t('Profile Completeness'),
'help' => t('Profile2 completeness expressed as a percentage 0..100'),
'field' => array(
'handler' => 'pcp_handler_field_profile_completeness',
'click sortable' => FALSE,
),
);
}
Functions
Name | Description |
---|---|
pcp_views_data_alter | Implements hook_views_data_alter(). |