You are here

function feeds_tamper_number_format_form in Feeds Tamper 6

Same name and namespace in other branches
  1. 7 plugins/number_format.inc \feeds_tamper_number_format_form()
1 string reference to 'feeds_tamper_number_format_form'
number_format.inc in plugins/number_format.inc

File

plugins/number_format.inc, line 17

Code

function feeds_tamper_number_format_form($importer, $element_key, $settings) {
  $form = array();
  $form['decimals'] = array(
    '#type' => 'textfield',
    '#title' => t('Decimals'),
    '#default_value' => isset($settings['decimals']) ? $settings['decimals'] : 0,
    '#description' => t('The number of decimal places.'),
  );
  $form['dec_point'] = array(
    '#type' => 'textfield',
    '#title' => t('Decimal point'),
    '#default_value' => isset($settings['dec_point']) ? $settings['dec_point'] : '.',
    '#description' => t('The character to use as the decimal point.'),
  );
  $form['thousands_sep'] = array(
    '#type' => 'textfield',
    '#title' => t('Thousands separator'),
    '#default_value' => isset($settings['thousands_sep']) ? $settings['thousands_sep'] : ',',
    '#description' => t('The character to use as the thousands separator.'),
  );
  return $form;
}