2011-05-23 Sergio Martin <sergio.martin@artica.es>
* images/cog_db.png images/cross_undo.png godmode/agentes/module_manager_editor.php: Added two new images to queue and added check when relink a module into policy avoiding it when te policy is applying git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@4377 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
bb9cd2023f
commit
72b00c526e
|
@ -1,3 +1,11 @@
|
|||
2011-05-23 Sergio Martin <sergio.martin@artica.es>
|
||||
|
||||
* images/cog_db.png
|
||||
images/cross_undo.png
|
||||
godmode/agentes/module_manager_editor.php: Added two new images to
|
||||
queue and added check when relink a module into policy avoiding it
|
||||
when te policy is applying
|
||||
|
||||
2011-05-23 Sergio Martin <sergio.martin@artica.es>
|
||||
|
||||
* godmode/agentes/module_manager_editor_common.php: Added hidden field
|
||||
|
|
|
@ -223,23 +223,35 @@ else {
|
|||
$snmp3_security_level = "";
|
||||
}
|
||||
}
|
||||
enterprise_include_once('include/functions_policies.php');
|
||||
|
||||
$relink_policy = get_parameter('relink_policy', 0);
|
||||
$unlink_policy = get_parameter('unlink_policy', 0);
|
||||
$is_function_policies = enterprise_include_once('include/functions_policies.php');
|
||||
|
||||
if($relink_policy) {
|
||||
$result = policies_relink_module($id_agent_module);
|
||||
ui_print_result_message($result, 'Module relinked to the policy successful');
|
||||
|
||||
db_pandora_audit("Agent management", "Re-link module " . $id_agent_module);
|
||||
}
|
||||
if($is_function_policies !== ENTERPRISE_NOT_HOOK) {
|
||||
$relink_policy = get_parameter('relink_policy', 0);
|
||||
$unlink_policy = get_parameter('unlink_policy', 0);
|
||||
|
||||
if($relink_policy) {
|
||||
$policy_info = policies_info_module_policy($id_agent_module);
|
||||
$policy_id = $policy_info['id_policy'];
|
||||
|
||||
if($relink_policy && policies_get_policy_queue_status ($policy_id) == STATUS_IN_QUEUE_APPLYING) {
|
||||
ui_print_error_message(__('This policy is applying and cannot be modified'));
|
||||
}
|
||||
else {
|
||||
$result = policies_relink_module($id_agent_module);
|
||||
ui_print_result_message($result, __('Module relinked to the policy successful'));
|
||||
|
||||
db_pandora_audit("Agent management", "Re-link module " . $id_agent_module);
|
||||
}
|
||||
}
|
||||
|
||||
if($unlink_policy) {
|
||||
$result = policies_unlink_module($id_agent_module);
|
||||
ui_print_result_message($result, __('Module unlinked from the policy successful'));
|
||||
|
||||
db_pandora_audit("Agent management", "Unlink module " . $id_agent_module);
|
||||
}
|
||||
|
||||
if($unlink_policy) {
|
||||
$result = policies_unlink_module($id_agent_module);
|
||||
ui_print_result_message($result, 'Module unlinked from the policy successful');
|
||||
|
||||
db_pandora_audit("Agent management", "Unlink module " . $id_agent_module);
|
||||
}
|
||||
|
||||
switch ($moduletype) {
|
||||
|
|
Binary file not shown.
After Width: | Height: | Size: 746 B |
Binary file not shown.
After Width: | Height: | Size: 699 B |
Loading…
Reference in New Issue