function currency_views_data in Currency 6
Same name and namespace in other branches
- 7 includes/views/currency.views.inc \currency_views_data()
Implementation of hook_views_data().
File
- views/
currency.views.inc, line 33 - Register all of the basic handlers that views uses.
Code
function currency_views_data() {
$data['currencyapi']['table']['group'] = t('Currency');
$data['currencyapi']['table']['base'] = array(
'title' => t('Exchange Rates'),
'help' => t('Exchange rates provided by the currency_api module'),
);
$data['currencyapi']['currency_from'] = array(
'title' => t('Currency from'),
'help' => t('The currency that the amount is converted from'),
'field' => array(
'handler' => 'currency_handler_field_currency',
),
'argument' => array(
'handler' => 'currency_handler_argument_currency',
),
'filter' => array(
'handler' => 'currency_handler_filter_currency',
),
);
$data['currencyapi']['currency_to'] = array(
'title' => t('Currency to'),
'help' => t('The currency that the amount is converted to'),
'field' => array(
'handler' => 'currency_handler_field_currency',
),
'argument' => array(
'handler' => 'currency_handler_argument_currency',
),
'filter' => array(
'handler' => 'currency_handler_filter_currency',
),
);
$data['currencyapi']['rate'] = array(
'title' => t('Exchange rate'),
'help' => t('The exchange rate used for conversion'),
'field' => array(
'handler' => 'views_handler_field_numeric',
),
);
$data['currencyapi']['timestamp'] = array(
'title' => t('Timestamp'),
'help' => t('The time that the exchange rate was last updated'),
'field' => array(
'handler' => 'views_handler_field_date',
),
);
return $data;
}