Merge branch 'ent-7369-wizard-snmp-no-funciona' into 'develop'
Fixed issue with id_plugin Closes pandora_enterprise#7369 See merge request artica/pandorafms!4058
This commit is contained in:
commit
67467e7a90
|
@ -2085,7 +2085,13 @@ class AgentWizard extends HTML
|
||||||
$tmp->ip_target($this->targetIp);
|
$tmp->ip_target($this->targetIp);
|
||||||
$tmp->id_modulo(MODULE_PLUGIN);
|
$tmp->id_modulo(MODULE_PLUGIN);
|
||||||
|
|
||||||
if (empty($candidate['macros']) === true) {
|
if ($this->wizardSection === 'snmp_interfaces_explorer'
|
||||||
|
&& empty($candidate['macros']) === true
|
||||||
|
) {
|
||||||
|
// Use definition provided.
|
||||||
|
$tmp->id_plugin($candidate['id_plugin']);
|
||||||
|
$tmp->macros(base64_decode($candidate['macros']));
|
||||||
|
} else {
|
||||||
$fieldsPlugin = db_get_value_sql(
|
$fieldsPlugin = db_get_value_sql(
|
||||||
sprintf(
|
sprintf(
|
||||||
'SELECT macros FROM tplugin WHERE id=%d',
|
'SELECT macros FROM tplugin WHERE id=%d',
|
||||||
|
@ -2115,10 +2121,6 @@ class AgentWizard extends HTML
|
||||||
|
|
||||||
$tmp->id_plugin($infoMacros['server_plugin']);
|
$tmp->id_plugin($infoMacros['server_plugin']);
|
||||||
$tmp->macros(json_encode($fieldsPlugin));
|
$tmp->macros(json_encode($fieldsPlugin));
|
||||||
} else {
|
|
||||||
// Use definition provided.
|
|
||||||
$tmp->id_plugin($candidate['id_plugin']);
|
|
||||||
$tmp->macros(base64_decode($candidate['macros']));
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -4313,15 +4315,6 @@ class AgentWizard extends HTML
|
||||||
'form="form-create-modules"'
|
'form="form-create-modules"'
|
||||||
);
|
);
|
||||||
|
|
||||||
// Execution type module.
|
|
||||||
$data[6] .= html_print_input_hidden(
|
|
||||||
'module-execution_type-'.$uniqueId,
|
|
||||||
$module['execution_type'],
|
|
||||||
true,
|
|
||||||
$md5IdBlock,
|
|
||||||
'form="form-create-modules"'
|
|
||||||
);
|
|
||||||
|
|
||||||
// WMI Query class.
|
// WMI Query class.
|
||||||
$data[6] .= html_print_input_hidden(
|
$data[6] .= html_print_input_hidden(
|
||||||
'module-query_class-'.$uniqueId,
|
'module-query_class-'.$uniqueId,
|
||||||
|
|
Loading…
Reference in New Issue