#8365 ftp server ip

This commit is contained in:
Jonathan 2023-12-12 15:46:42 +01:00
parent a2f60a1d22
commit 6e60d19193
2 changed files with 33 additions and 0 deletions

View File

@ -896,6 +896,35 @@ echo '<legend>'.__('Mail configuration').'</legend>';
echo '</fieldset>';
echo '<fieldset class="margin-bottom-10">';
echo '<legend>'.__('NCM Configuration').'</legend>';
$table_ncm_config = new stdClass();
$table_ncm_config->width = '100%';
$table_ncm_config->class = 'databox filter-table-adv';
$table_ncm_config->size = [];
$table_ncm_config->size[0] = '50%';
$table_ncm_config->data = [];
$table_ncm_config->data[0][] = html_print_label_input_block(
__('FTP server IP').ui_print_help_tip(__('This value will be used by TFTP_SERVER_IP macro in NCM scripts.'), true),
html_print_input_text(
'tftp_server_ip',
$config['tftp_server_ip'],
'',
false,
255,
true,
false,
false,
'',
'w50p'
)
);
html_print_table($table_ncm_config);
echo '</fieldset>';
html_print_action_buttons(
html_print_submit_button(

View File

@ -431,6 +431,10 @@ function config_update_config()
if (config_update_value('inventory_changes_blacklist', implode(',', $inventory_changes_blacklist), true) === false) {
$error_update[] = __('Inventory changes blacklist');
}
if (config_update_value('tftp_server_ip', (string) get_parameter('tftp_server_ip'), true) === false) {
$error_update[] = __('Ftp server ip');
}
break;
case 'enterprise':