Merge branch '3.4' of git@github.com:Dolibarr/dolibarr.git into 3.4

This commit is contained in:
Laurent Destailleur 2013-06-09 18:24:52 +02:00
commit 88291e423f

View File

@ -622,7 +622,7 @@ class ExtraFields
$out = $formstat->select_date($value, 'options_'.$key, $showtime, $showtime, $required, '', 1, 1, 1, 0, 1);
//$out='<input type="text" name="options_'.$key.'" size="'.$showsize.'" maxlength="'.$newsize.'" value="'.$value.'"'.($moreparam?$moreparam:'').'>';
}
elseif (in_array($type,array('int','double')))
elseif (in_array($type,array('int')))
{
$tmp=explode(',',$size);
$newsize=$tmp[0];
@ -660,6 +660,10 @@ class ExtraFields
{
$out='<input type="text" name="options_'.$key.'" size="6" value="'.price($value).'"> '.$langs->getCurrencySymbol($conf->currency);
}
elseif ($type == 'double')
{
$out='<input type="text" name="options_'.$key.'" size="6" value="'.price($value).'"> ';
}
elseif ($type == 'select')
{
$out='<select name="options_'.$key.'">';
@ -790,6 +794,10 @@ class ExtraFields
{
$showsize=10;
}
elseif ($type == 'double')
{
$value=price($value);
}
elseif ($type == 'boolean')
{
$checked='';
@ -900,6 +908,11 @@ class ExtraFields
$value_arr=GETPOST("options_".$key);
$value_key=implode($value_arr,',');
}
else if (in_array($key_type,array('price','double')))
{
$value_arr=GETPOST("options_".$key);
$value_key=price2num($value_arr);
}
else
{
$value_key=GETPOST("options_".$key);