*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see
| '; if (!empty($field_info['help'])) { print $form->textwithpicto($langs->trans($field_info['label']), $langs->trans($field_info['help'])); } else { print $langs->trans($field_info['label']); } print ' | '; print ''; if (!empty($field_info['picto'])) { print img_picto('', $field_info['picto'], '', false, 0, 0, '', 'pictofixedwidth'); } if (in_array($field_info['type'], array('int', 'integer'))) { $value = GETPOSTISSET($html_name) ?GETPOST($html_name, 'int') : $assetdepreciationoptions->$field_key; } elseif ($field_info['type'] == 'double') { $value = GETPOSTISSET($html_name) ? price2num(GETPOST($html_name, 'alphanohtml')) : $assetdepreciationoptions->$field_key; } elseif (preg_match('/^(text|html)/', $field_info['type'])) { $tmparray = explode(':', $field_info['type']); if (!empty($tmparray[1])) { $check = $tmparray[1]; } else { $check = 'restricthtml'; } $value = GETPOSTISSET($html_name) ? GETPOST($html_name, $check) : $assetdepreciationoptions->$field_key; } elseif ($field_info['type'] == 'price') { $value = GETPOSTISSET($html_name) ? price2num(GETPOST($html_name)) : ($assetdepreciationoptions->$field_key ? price2num($assetdepreciationoptions->$field_key) : (!empty($field_info['default']) ? dol_eval($field_info['default'], 1) : 0)); } elseif ($field_key == 'lang') { $value = GETPOSTISSET($html_name) ? GETPOST($html_name, 'aZ09') : $assetdepreciationoptions->lang; } else { $value = GETPOSTISSET($html_name) ? GETPOST($html_name, 'alpha') : $assetdepreciationoptions->$field_key; } if (!empty($field_info['noteditable'])) { print $assetdepreciationoptions->showOutputField($field_info, $field_key, $value, '', '', $prefix_html_name, 0); } else { if ($field_key == 'lang') { print img_picto('', 'language', 'class="pictofixedwidth"'); print $formadmin->select_language($value, $html_name, 0, null, 1, 0, 0, 'minwidth300', 2); } else { print $assetdepreciationoptions->showInputField($field_info, $field_key, $value, '', '', $prefix_html_name, 0); } } print ' | '; print '