$source_id_agent, 'Destinity agent' => implode(',', $destiny_id_agents), ]; if ($result) { db_pandora_audit( AUDIT_LOG_MASSIVE_MANAGEMENT, 'Copy modules', false, false, json_encode($info) ); } else { db_pandora_audit( AUDIT_LOG_MASSIVE_MANAGEMENT, 'Fail to try copy modules', false, false, json_encode($info) ); } } $groups = users_get_groups(); $table = new stdClass(); $table->id = 'source_table'; $table->class = 'databox filters filter-table-adv'; $table->width = '100%'; $table->size[0] = '50%'; $table->size[1] = '50%'; $table->data = []; // Source selection. $table->data[0][0] = html_print_label_input_block( __('Group'), html_print_select_groups( false, 'AW', true, 'source_id_group', $source_id_group, false, '', '', true, false, false, 'w100p', false, 'width:100%' ) ); $table->data[0][1] = html_print_label_input_block( __('Group recursion'), html_print_checkbox('source_recursion', 1, $source_recursion, true, false) ); $status_list = []; $status_list[AGENT_STATUS_NORMAL] = __('Normal'); $status_list[AGENT_STATUS_WARNING] = __('Warning'); $status_list[AGENT_STATUS_CRITICAL] = __('Critical'); $status_list[AGENT_STATUS_UNKNOWN] = __('Unknown'); $status_list[AGENT_STATUS_NOT_NORMAL] = __('Not normal'); $status_list[AGENT_STATUS_NOT_INIT] = __('Not init'); $table->data[1][0] = html_print_label_input_block( __('Status'), html_print_select( $status_list, 'status_agents_source', 'selected', '', __('All'), AGENT_STATUS_ALL, true, false, true, 'w100p' ) ); $agents = ( $source_id_group ? agents_get_group_agents($source_id_group, false, 'none') : agents_get_group_agents(array_keys(users_get_groups($config['id_user'], 'AW', false))) ); $table->data[1][1] = html_print_label_input_block( __('Agent').' '.html_print_image('images/spinner.png', true).'', html_print_select( $agents, 'source_id_agent', $source_id_agent, false, __('Select'), 0, true ) ); echo '
'; echo '