function commerce_price_decimals_formatter_field_formatter_info in Commerce Price Decimals Formatter 7
Implements hook_field_formatter_info().
File
- ./
commerce_price_decimals_formatter.module, line 12 - Provides a display formatter for the price field in which you can specify the decimal places are displayed.
Code
function commerce_price_decimals_formatter_field_formatter_info() {
return array(
'commerce_price_decimals_formatter' => array(
'label' => t('Formatted amount with n decimals'),
'field types' => array(
'commerce_price',
),
'settings' => array(
'calculation' => 'calculated_sell_price',
'currencies' => commerce_price_decimals_formatter_get_default_currencies_settings(),
),
),
'commerce_price_decimals_formatter_components' => array(
'label' => t('Formatted amount with n decimals and components'),
'field types' => array(
'commerce_price',
),
'settings' => array(
'calculation' => 'calculated_sell_price',
'currencies' => commerce_price_decimals_formatter_get_default_currencies_settings(),
),
),
);
}