mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-07-28 16:24:54 +02:00
2012-08-21 Miguel de Dios <miguel.dedios@artica.es>
* pandoradb.oracle.sql, operation/agentes/estado_generalagente.php, operation/agentes/estado_agente.php, operation/agentes/ver_agente.php, extras/pandoradb_migrate_4.0.x_to_5.0.postgreSQL.sql, extras/pandoradb_migrate_4.0.x_to_5.0.mysql.sql, extras/pandoradb_migrate_4.0.x_to_5.0.oracle.sql, godmode/agentes/agent_manager.php, godmode/agentes/modificar_agente.php, godmode/agentes/configurar_agente.php, pandoradb.sql, pandoradb.postgreSQL.sql: added the feature to set a agent in "Quiet" mode. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@6896 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
431f1bbe76
commit
6eeda98886
@ -1,3 +1,17 @@
|
|||||||
|
2012-08-21 Miguel de Dios <miguel.dedios@artica.es>
|
||||||
|
|
||||||
|
* pandoradb.oracle.sql, operation/agentes/estado_generalagente.php,
|
||||||
|
operation/agentes/estado_agente.php,
|
||||||
|
operation/agentes/ver_agente.php,
|
||||||
|
extras/pandoradb_migrate_4.0.x_to_5.0.postgreSQL.sql,
|
||||||
|
extras/pandoradb_migrate_4.0.x_to_5.0.mysql.sql,
|
||||||
|
extras/pandoradb_migrate_4.0.x_to_5.0.oracle.sql,
|
||||||
|
godmode/agentes/agent_manager.php,
|
||||||
|
godmode/agentes/modificar_agente.php,
|
||||||
|
godmode/agentes/configurar_agente.php, pandoradb.sql,
|
||||||
|
pandoradb.postgreSQL.sql: added the feature to set a agent in
|
||||||
|
"Quiet" mode.
|
||||||
|
|
||||||
2012-08-21 Dario Rodriguez <dario.rodriguez@artica.es>
|
2012-08-21 Dario Rodriguez <dario.rodriguez@artica.es>
|
||||||
|
|
||||||
* operation/agentes/ver_agente.php: Added code to support new
|
* operation/agentes/ver_agente.php: Added code to support new
|
||||||
|
@ -55,6 +55,7 @@ ALTER TABLE `tincidencia` ADD COLUMN `id_agent` int(10) unsigned NULL default 0;
|
|||||||
-- Table `tagente`
|
-- Table `tagente`
|
||||||
-- -----------------------------------------------------
|
-- -----------------------------------------------------
|
||||||
ALTER TABLE `tagente` ADD COLUMN `url_address` mediumtext NULL;
|
ALTER TABLE `tagente` ADD COLUMN `url_address` mediumtext NULL;
|
||||||
|
ALTER TABLE `tagente` ADD COLUMN `quiet` tinyint(1) NOT NULL DEFAULT '0';
|
||||||
|
|
||||||
-- -----------------------------------------------------
|
-- -----------------------------------------------------
|
||||||
-- Table `talert_special_days`
|
-- Table `talert_special_days`
|
||||||
@ -86,20 +87,22 @@ ALTER TABLE tplanned_downtime_agents
|
|||||||
-- Table `tevento`
|
-- Table `tevento`
|
||||||
-- -----------------------------------------------------
|
-- -----------------------------------------------------
|
||||||
ALTER TABLE `tevento` ADD COLUMN (`source` tinytext NOT NULL,
|
ALTER TABLE `tevento` ADD COLUMN (`source` tinytext NOT NULL,
|
||||||
`id_extra` tinytext NOT NULL);
|
`id_extra` tinytext NOT NULL);
|
||||||
|
|
||||||
-- -----------------------------------------------------
|
-- -----------------------------------------------------
|
||||||
-- Table `talert_snmp`
|
-- Table `talert_snmp`
|
||||||
-- -----------------------------------------------------
|
-- -----------------------------------------------------
|
||||||
ALTER TABLE `talert_snmp` ADD COLUMN (`_snmp_f1_` text, `_snmp_f2_` text, `_snmp_f3_` text,
|
ALTER TABLE `talert_snmp` ADD COLUMN (`_snmp_f1_` text, `_snmp_f2_` text, `_snmp_f3_` text,
|
||||||
`_snmp_f4_` text, `_snmp_f5_` text, `_snmp_f6_` text, `trap_type` int(11) NOT NULL default '-1',
|
`_snmp_f4_` text, `_snmp_f5_` text, `_snmp_f6_` text, `trap_type` int(11) NOT NULL default '-1',
|
||||||
`single_value` varchar(255) DEFAULT '');
|
`single_value` varchar(255) DEFAULT '');
|
||||||
|
|
||||||
-- -----------------------------------------------------
|
-- -----------------------------------------------------
|
||||||
-- Table `tagente_modulo`
|
-- Table `tagente_modulo`
|
||||||
-- -----------------------------------------------------
|
-- -----------------------------------------------------
|
||||||
ALTER TABLE `tagente_modulo` ADD COLUMN `module_ff_interval` int(4) unsigned default '0';
|
ALTER TABLE `tagente_modulo` ADD COLUMN `module_ff_interval` int(4) unsigned default '0';
|
||||||
ALTER TABLE `tagente_modulo` CHANGE COLUMN `post_process` `post_process` double(18,5) default NULL;
|
ALTER TABLE `tagente_modulo` CHANGE COLUMN `post_process` `post_process` double(18,5) default NULL;
|
||||||
|
ALTER TABLE `tagente_modulo` ADD COLUMN `wizard_level` enum('basic','advanced','custom','nowizard') default 'nowizard';
|
||||||
|
ALTER TABLE `tagente_modulo` ADD COLUMN `macros` text;
|
||||||
|
|
||||||
-- -----------------------------------------------------
|
-- -----------------------------------------------------
|
||||||
-- Table `tnetwork_component`
|
-- Table `tnetwork_component`
|
||||||
@ -244,12 +247,6 @@ ALTER TABLE tnetwork_component ADD `wizard_level` enum('basic','advanced','custo
|
|||||||
ALTER TABLE tnetwork_component ADD `only_metaconsole` tinyint(1) unsigned default '0';
|
ALTER TABLE tnetwork_component ADD `only_metaconsole` tinyint(1) unsigned default '0';
|
||||||
ALTER TABLE tnetwork_component ADD `macros` text;
|
ALTER TABLE tnetwork_component ADD `macros` text;
|
||||||
|
|
||||||
-- -----------------------------------------------------
|
|
||||||
-- Table `tagente_modulo`
|
|
||||||
-- -----------------------------------------------------
|
|
||||||
ALTER TABLE tagente_modulo ADD `wizard_level` enum('basic','advanced','custom','nowizard') default 'nowizard';
|
|
||||||
ALTER TABLE tagente_modulo ADD `macros` text;
|
|
||||||
|
|
||||||
-- -----------------------------------------------------
|
-- -----------------------------------------------------
|
||||||
-- Table `tplugin`
|
-- Table `tplugin`
|
||||||
-- -----------------------------------------------------
|
-- -----------------------------------------------------
|
||||||
|
@ -74,6 +74,7 @@ alter table tincidencia add (id_agent NUMBER(10,0) default 0 NULL);
|
|||||||
-- Table `tagente`
|
-- Table `tagente`
|
||||||
-- -----------------------------------------------------
|
-- -----------------------------------------------------
|
||||||
alter table tagente add (url_address CLOB default '' NULL);
|
alter table tagente add (url_address CLOB default '' NULL);
|
||||||
|
alter table tagente add (quiet NUMBER(5, 0) default 0 NOT NULL);
|
||||||
|
|
||||||
-- -----------------------------------------------------
|
-- -----------------------------------------------------
|
||||||
-- Table `talert_special_days`
|
-- Table `talert_special_days`
|
||||||
|
@ -62,14 +62,13 @@ CREATE TABLE "tnetflow_report_content" (
|
|||||||
-- -----------------------------------------------------
|
-- -----------------------------------------------------
|
||||||
-- Table `tincidencia`
|
-- Table `tincidencia`
|
||||||
-- -----------------------------------------------------
|
-- -----------------------------------------------------
|
||||||
|
|
||||||
ALTER TABLE "tincidencia" ADD COLUMN "id_agent" INTEGER NULL DEFAULT 0;
|
ALTER TABLE "tincidencia" ADD COLUMN "id_agent" INTEGER NULL DEFAULT 0;
|
||||||
|
|
||||||
-- -----------------------------------------------------
|
-- -----------------------------------------------------
|
||||||
-- Table `tagente`
|
-- Table `tagente`
|
||||||
-- -----------------------------------------------------
|
-- -----------------------------------------------------
|
||||||
|
|
||||||
ALTER TABLE "tagente" ADD COLUMN "url_address" text NULL default '';
|
ALTER TABLE "tagente" ADD COLUMN "url_address" text NULL default '';
|
||||||
|
ALTER TABLE "tagente" ADD COLUMN "quiet" SMALLINT NOT NULL default 0;
|
||||||
|
|
||||||
-- -----------------------------------------------------
|
-- -----------------------------------------------------
|
||||||
-- Table `talert_special_days`
|
-- Table `talert_special_days`
|
||||||
|
@ -14,7 +14,6 @@
|
|||||||
// GNU General Public License for more details.
|
// GNU General Public License for more details.
|
||||||
|
|
||||||
if (is_ajax ()) {
|
if (is_ajax ()) {
|
||||||
|
|
||||||
global $config;
|
global $config;
|
||||||
|
|
||||||
$search_parents = (bool) get_parameter ('search_parents');
|
$search_parents = (bool) get_parameter ('search_parents');
|
||||||
@ -28,7 +27,7 @@ if (is_ajax ()) {
|
|||||||
|
|
||||||
$filter = array ();
|
$filter = array ();
|
||||||
|
|
||||||
switch ($config['dbtype']){
|
switch ($config['dbtype']) {
|
||||||
case "mysql":
|
case "mysql":
|
||||||
case "postgresql":
|
case "postgresql":
|
||||||
$filter[] = '(nombre COLLATE utf8_general_ci LIKE "%'.$string.'%" OR direccion LIKE "%'.$string.'%" OR comentarios LIKE "%'.$string.'%")';
|
$filter[] = '(nombre COLLATE utf8_general_ci LIKE "%'.$string.'%" OR direccion LIKE "%'.$string.'%" OR comentarios LIKE "%'.$string.'%")';
|
||||||
@ -58,7 +57,7 @@ if (is_ajax ()) {
|
|||||||
|
|
||||||
$filter = array ();
|
$filter = array ();
|
||||||
|
|
||||||
switch ($config['dbtype']){
|
switch ($config['dbtype']) {
|
||||||
case "mysql":
|
case "mysql":
|
||||||
case "postgresql":
|
case "postgresql":
|
||||||
$filter[] = '(nombre COLLATE utf8_general_ci LIKE "%'.$string.'%" OR direccion LIKE "%'.$string.'%" OR comentarios LIKE "%'.$string.'%")';
|
$filter[] = '(nombre COLLATE utf8_general_ci LIKE "%'.$string.'%" OR direccion LIKE "%'.$string.'%" OR comentarios LIKE "%'.$string.'%")';
|
||||||
@ -96,8 +95,8 @@ if (is_ajax ()) {
|
|||||||
|
|
||||||
$oid_snmp = array();
|
$oid_snmp = array();
|
||||||
$out = false;
|
$out = false;
|
||||||
foreach($idSNMP as $id) {
|
foreach ($idSNMP as $id) {
|
||||||
foreach($snmp[$id] as $key => $value){
|
foreach ($snmp[$id] as $key => $value){
|
||||||
|
|
||||||
// Check if it has "ifXXXX" syntax and skip it
|
// Check if it has "ifXXXX" syntax and skip it
|
||||||
if (! preg_match ( "/if/", $key)) {
|
if (! preg_match ( "/if/", $key)) {
|
||||||
@ -107,7 +106,7 @@ if (is_ajax ()) {
|
|||||||
$oid_snmp[$value['oid']] = $key;
|
$oid_snmp[$value['oid']] = $key;
|
||||||
}
|
}
|
||||||
|
|
||||||
if($out === false){
|
if ($out === false) {
|
||||||
$out = $oid_snmp;
|
$out = $oid_snmp;
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
@ -341,9 +340,13 @@ if ($config['activate_gis']) {
|
|||||||
$update_gis_data, false, '', 'style="margin-right: 40px;"', true);
|
$update_gis_data, false, '', 'style="margin-right: 40px;"', true);
|
||||||
}
|
}
|
||||||
|
|
||||||
$table->data[6][0] = __('Url address:');
|
$table->data[6][0] = __('Url address');
|
||||||
$table->data[6][1] = html_print_input_text ('url_description', $url_description, '', 45, 255, true);
|
$table->data[6][1] = html_print_input_text ('url_description', $url_description, '', 45, 255, true);
|
||||||
|
|
||||||
|
$table->data[7][0] = __('Quiet');
|
||||||
|
$table->data[7][0] .= ui_print_help_tip(__('The agent still runs but the alerts and events will be stop'), true);
|
||||||
|
$table->data[7][1] = html_print_checkbox('quiet', 1, $quiet, true);
|
||||||
|
|
||||||
ui_toggle(html_print_table ($table, true), __('Advanced options'));
|
ui_toggle(html_print_table ($table, true), __('Advanced options'));
|
||||||
unset($table);
|
unset($table);
|
||||||
|
|
||||||
|
@ -124,6 +124,7 @@ $unit = "";
|
|||||||
$id_tag = array();
|
$id_tag = array();
|
||||||
$tab_description = '';
|
$tab_description = '';
|
||||||
$url_description = '';
|
$url_description = '';
|
||||||
|
$quiet = 0;
|
||||||
$macros = '';
|
$macros = '';
|
||||||
|
|
||||||
$create_agent = (bool) get_parameter ('create_agent');
|
$create_agent = (bool) get_parameter ('create_agent');
|
||||||
@ -146,6 +147,7 @@ if ($create_agent) {
|
|||||||
$icon_path = (string) get_parameter_post ("icon_path",'');
|
$icon_path = (string) get_parameter_post ("icon_path",'');
|
||||||
$update_gis_data = (int) get_parameter_post("update_gis_data", 0);
|
$update_gis_data = (int) get_parameter_post("update_gis_data", 0);
|
||||||
$url_description = (string) get_parameter("url_description");
|
$url_description = (string) get_parameter("url_description");
|
||||||
|
$quiet = (int) get_parameter("quiet", 0);
|
||||||
|
|
||||||
$fields = db_get_all_fields_in_table('tagent_custom_fields');
|
$fields = db_get_all_fields_in_table('tagent_custom_fields');
|
||||||
|
|
||||||
@ -179,7 +181,8 @@ if ($create_agent) {
|
|||||||
'id_parent' => $id_parent, 'custom_id' => $custom_id,
|
'id_parent' => $id_parent, 'custom_id' => $custom_id,
|
||||||
'icon_path' => $icon_path,
|
'icon_path' => $icon_path,
|
||||||
'update_gis_data' => $update_gis_data,
|
'update_gis_data' => $update_gis_data,
|
||||||
'url_address' => $url_description));
|
'url_address' => $url_description,
|
||||||
|
'quiet' => $quiet));
|
||||||
enterprise_hook ('update_agent', array ($id_agente));
|
enterprise_hook ('update_agent', array ($id_agente));
|
||||||
if ($id_agente !== false) {
|
if ($id_agente !== false) {
|
||||||
// Create custom fields for this agent
|
// Create custom fields for this agent
|
||||||
@ -197,9 +200,12 @@ if ($create_agent) {
|
|||||||
' Comments: ' . $comentarios . ' Mode: ' . $modo .
|
' Comments: ' . $comentarios . ' Mode: ' . $modo .
|
||||||
' ID_parent: ' . $id_parent . ' Server: ' . $server_name .
|
' ID_parent: ' . $id_parent . ' Server: ' . $server_name .
|
||||||
' ID os: ' . $id_os . ' Disabled: ' . $disabled .
|
' ID os: ' . $id_os . ' Disabled: ' . $disabled .
|
||||||
' Custom ID: ' . $custom_id . ' Cascade protection: ' . $cascade_protection .
|
' Custom ID: ' . $custom_id .
|
||||||
' Icon path: ' . $icon_path . ' Update GIS data: ' . $update_gis_data .
|
' Cascade protection: ' . $cascade_protection .
|
||||||
' Url description: ' . $url_description;
|
' Icon path: ' . $icon_path .
|
||||||
|
' Update GIS data: ' . $update_gis_data .
|
||||||
|
' Url description: ' . $url_description .
|
||||||
|
' Quiet: ' . (int)$quiet;
|
||||||
|
|
||||||
db_pandora_audit("Agent management",
|
db_pandora_audit("Agent management",
|
||||||
"Created agent $nombre_agente", false, false, $info);
|
"Created agent $nombre_agente", false, false, $info);
|
||||||
@ -275,8 +281,8 @@ if ($id_agente) {
|
|||||||
|
|
||||||
|
|
||||||
$has_remote_conf = enterprise_hook('config_agents_has_remote_configuration',array($id_agente));
|
$has_remote_conf = enterprise_hook('config_agents_has_remote_configuration',array($id_agente));
|
||||||
|
|
||||||
if($has_remote_conf === true) {
|
if ($has_remote_conf === true) {
|
||||||
/* Plugins */
|
/* Plugins */
|
||||||
$pluginstab = enterprise_hook ('plugins_tab');
|
$pluginstab = enterprise_hook ('plugins_tab');
|
||||||
if ($pluginstab == -1)
|
if ($pluginstab == -1)
|
||||||
@ -497,13 +503,14 @@ if ($update_agent) { // if modified some agent paramenter
|
|||||||
$id_os = (int) get_parameter_post ("id_os");
|
$id_os = (int) get_parameter_post ("id_os");
|
||||||
$disabled = (bool) get_parameter_post ("disabled");
|
$disabled = (bool) get_parameter_post ("disabled");
|
||||||
$server_name = (string) get_parameter_post ("server_name", "");
|
$server_name = (string) get_parameter_post ("server_name", "");
|
||||||
$id_parent = (string) get_parameter_post ("id_parent");
|
$parent_name = (string) get_parameter_post ("id_parent");
|
||||||
$id_parent = (int) agents_get_agent_id ($id_parent);
|
$id_parent = (int) agents_get_agent_id ($parent_name);
|
||||||
$custom_id = (string) get_parameter_post ("custom_id", "");
|
$custom_id = (string) get_parameter_post ("custom_id", "");
|
||||||
$cascade_protection = (int) get_parameter_post ("cascade_protection", 0);
|
$cascade_protection = (int) get_parameter_post ("cascade_protection", 0);
|
||||||
$icon_path = (string) get_parameter_post ("icon_path",'');
|
$icon_path = (string) get_parameter_post ("icon_path",'');
|
||||||
$update_gis_data = (int) get_parameter_post("update_gis_data", 0);
|
$update_gis_data = (int) get_parameter_post("update_gis_data", 0);
|
||||||
$url_description = (string) get_parameter("url_description");
|
$url_description = (string) get_parameter("url_description");
|
||||||
|
$quiet = (int) get_parameter("quiet", 0);
|
||||||
|
|
||||||
$fields = db_get_all_fields_in_table('tagent_custom_fields');
|
$fields = db_get_all_fields_in_table('tagent_custom_fields');
|
||||||
|
|
||||||
@ -552,7 +559,7 @@ if ($update_agent) { // if modified some agent paramenter
|
|||||||
$delete_ip = get_parameter_post ("address_list");
|
$delete_ip = get_parameter_post ("address_list");
|
||||||
agents_delete_address ($id_agente, $delete_ip);
|
agents_delete_address ($id_agente, $delete_ip);
|
||||||
}
|
}
|
||||||
|
|
||||||
$result = db_process_sql_update ('tagente',
|
$result = db_process_sql_update ('tagente',
|
||||||
array ('disabled' => $disabled,
|
array ('disabled' => $disabled,
|
||||||
'id_parent' => $id_parent,
|
'id_parent' => $id_parent,
|
||||||
@ -568,7 +575,8 @@ if ($update_agent) { // if modified some agent paramenter
|
|||||||
'custom_id' => $custom_id,
|
'custom_id' => $custom_id,
|
||||||
'icon_path' => $icon_path,
|
'icon_path' => $icon_path,
|
||||||
'update_gis_data' => $update_gis_data,
|
'update_gis_data' => $update_gis_data,
|
||||||
'url_address' => $url_description),
|
'url_address' => $url_description,
|
||||||
|
'quiet' => $quiet),
|
||||||
array ('id_agente' => $id_agente));
|
array ('id_agente' => $id_agente));
|
||||||
|
|
||||||
if ($result === false) {
|
if ($result === false) {
|
||||||
@ -582,7 +590,8 @@ if ($update_agent) { // if modified some agent paramenter
|
|||||||
' Server Name: ' . $server_name . ' ID parent: ' . $id_parent .
|
' Server Name: ' . $server_name . ' ID parent: ' . $id_parent .
|
||||||
' Custom ID: ' . $custom_id . ' Cascade Protection: ' . $cascade_protection .
|
' Custom ID: ' . $custom_id . ' Cascade Protection: ' . $cascade_protection .
|
||||||
' Icon Path: ' . $icon_path . 'Update GIS data: ' .$update_gis_data .
|
' Icon Path: ' . $icon_path . 'Update GIS data: ' .$update_gis_data .
|
||||||
' Url description: ' . $url_description;
|
' Url description: ' . $url_description .
|
||||||
|
' Quiet: ' . (int)$quiet;
|
||||||
|
|
||||||
enterprise_hook ('update_agent', array ($id_agente));
|
enterprise_hook ('update_agent', array ($id_agente));
|
||||||
ui_print_success_message (__('Successfully updated'));
|
ui_print_success_message (__('Successfully updated'));
|
||||||
@ -631,6 +640,7 @@ if ($id_agente) {
|
|||||||
$icon_path = $agent["icon_path"];
|
$icon_path = $agent["icon_path"];
|
||||||
$update_gis_data = $agent["update_gis_data"];
|
$update_gis_data = $agent["update_gis_data"];
|
||||||
$url_description = $agent["url_address"];
|
$url_description = $agent["url_address"];
|
||||||
|
$quiet = $agent["quiet"];
|
||||||
}
|
}
|
||||||
|
|
||||||
$update_module = (bool) get_parameter ('update_module');
|
$update_module = (bool) get_parameter ('update_module');
|
||||||
@ -690,14 +700,14 @@ if ($update_module || $create_module) {
|
|||||||
|
|
||||||
// Get macros
|
// Get macros
|
||||||
$macros = (string) get_parameter ('macros');
|
$macros = (string) get_parameter ('macros');
|
||||||
|
|
||||||
if(!empty($macros)) {
|
if (!empty($macros)) {
|
||||||
$macros = json_decode(base64_decode($macros), true);
|
$macros = json_decode(base64_decode($macros), true);
|
||||||
|
|
||||||
foreach($macros as $k => $m) {
|
foreach($macros as $k => $m) {
|
||||||
$macros[$k]['value'] = get_parameter($m['macro'], '');
|
$macros[$k]['value'] = get_parameter($m['macro'], '');
|
||||||
}
|
}
|
||||||
|
|
||||||
$macros = json_encode($macros);
|
$macros = json_encode($macros);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -873,7 +883,7 @@ if ($create_module) {
|
|||||||
switch ($config["dbtype"]) {
|
switch ($config["dbtype"]) {
|
||||||
case "oracle":
|
case "oracle":
|
||||||
if (empty($description) || !isset($description)) {
|
if (empty($description) || !isset($description)) {
|
||||||
$description=' ';
|
$description = ' ';
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@ -918,15 +928,15 @@ if ($create_module) {
|
|||||||
'unit' => $unit,
|
'unit' => $unit,
|
||||||
'macros' => $macros);
|
'macros' => $macros);
|
||||||
|
|
||||||
if($prediction_module == 3 && $serialize_ops == '') {
|
if ($prediction_module == 3 && $serialize_ops == '') {
|
||||||
$id_agent_module = false;
|
$id_agent_module = false;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
$id_agent_module = modules_create_agent_module ($id_agente, $name, $values, false, $id_tag);
|
$id_agent_module = modules_create_agent_module ($id_agente, $name, $values, false, $id_tag);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (is_error($id_agent_module)) {
|
if (is_error($id_agent_module)) {
|
||||||
switch($id_agent_module) {
|
switch ($id_agent_module) {
|
||||||
case ERR_EXIST:
|
case ERR_EXIST:
|
||||||
$msg = __('There was a problem adding module. Another module already exists with the same name.');
|
$msg = __('There was a problem adding module. Another module already exists with the same name.');
|
||||||
break;
|
break;
|
||||||
@ -947,7 +957,7 @@ if ($create_module) {
|
|||||||
"Fail to try added module '$name' for agent ".$agent["nombre"]);
|
"Fail to try added module '$name' for agent ".$agent["nombre"]);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
if($prediction_module == 3) {
|
if ($prediction_module == 3) {
|
||||||
enterprise_hook('modules_create_synthetic_operations', array($id_agent_module, $serialize_ops));
|
enterprise_hook('modules_create_synthetic_operations', array($id_agent_module, $serialize_ops));
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1217,4 +1227,4 @@ switch ($tab) {
|
|||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
?>
|
?>
|
@ -252,12 +252,12 @@ if ($ag_group > 0) {
|
|||||||
else {
|
else {
|
||||||
// CLEAN: sql_extra
|
// CLEAN: sql_extra
|
||||||
$sql_extra = '';
|
$sql_extra = '';
|
||||||
|
|
||||||
// Admin user get ANY group, even if they doesnt exist
|
// Admin user get ANY group, even if they doesnt exist
|
||||||
if (check_acl ($config['id_user'], 0, "PM")) {
|
if (check_acl ($config['id_user'], 0, "PM")) {
|
||||||
$sql = sprintf ('SELECT COUNT(*) FROM tagente WHERE (1=1 %s) %s', $search_sql, $sql_extra);
|
$sql = sprintf ('SELECT COUNT(*) FROM tagente WHERE (1=1 %s) %s', $search_sql, $sql_extra);
|
||||||
$total_agents = db_get_sql ($sql);
|
$total_agents = db_get_sql ($sql);
|
||||||
switch ($config["dbtype"]) {
|
switch ($config["dbtype"]) {
|
||||||
case "mysql":
|
case "mysql":
|
||||||
$sql = sprintf ('SELECT *
|
$sql = sprintf ('SELECT *
|
||||||
FROM tagente WHERE (1=1 %s) %s
|
FROM tagente WHERE (1=1 %s) %s
|
||||||
@ -280,15 +280,15 @@ else {
|
|||||||
$sql = oracle_recode_query ($sql, $set);
|
$sql = oracle_recode_query ($sql, $set);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
$sql = sprintf ('SELECT COUNT(*)
|
$sql = sprintf ('SELECT COUNT(*)
|
||||||
FROM tagente
|
FROM tagente
|
||||||
WHERE (id_grupo IN (%s)
|
WHERE (id_grupo IN (%s)
|
||||||
%s) %s',
|
%s) %s',
|
||||||
implode (',', array_keys (users_get_groups ())),
|
implode (',', array_keys (users_get_groups ())),
|
||||||
$search_sql, $sql_extra);
|
$search_sql, $sql_extra);
|
||||||
|
|
||||||
$total_agents = db_get_sql ($sql);
|
$total_agents = db_get_sql ($sql);
|
||||||
|
|
||||||
switch ($config["dbtype"]) {
|
switch ($config["dbtype"]) {
|
||||||
@ -324,7 +324,7 @@ else {
|
|||||||
$sql = oracle_recode_query ($sql, $set);
|
$sql = oracle_recode_query ($sql, $set);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
$agents = db_get_all_rows_sql ($sql);
|
$agents = db_get_all_rows_sql ($sql);
|
||||||
@ -365,7 +365,7 @@ if ($agents !== false) {
|
|||||||
foreach ($agents as $agent) {
|
foreach ($agents as $agent) {
|
||||||
$id_grupo = $agent["id_grupo"];
|
$id_grupo = $agent["id_grupo"];
|
||||||
$is_extra = enterprise_hook('policies_is_agent_extra_policy', array($agent["id_agente"]));
|
$is_extra = enterprise_hook('policies_is_agent_extra_policy', array($agent["id_agente"]));
|
||||||
|
|
||||||
if($is_extra === ENTERPRISE_NOT_HOOK) {
|
if($is_extra === ENTERPRISE_NOT_HOOK) {
|
||||||
$is_extra = false;
|
$is_extra = false;
|
||||||
}
|
}
|
||||||
@ -394,11 +394,17 @@ if ($agents !== false) {
|
|||||||
echo "<em>";
|
echo "<em>";
|
||||||
}
|
}
|
||||||
echo '<span class="left">';
|
echo '<span class="left">';
|
||||||
echo "<strong><a href='index.php?sec=gagente&
|
echo "<strong>";
|
||||||
|
if ($agent['quiet']) {
|
||||||
|
html_print_image("images/dot_green.disabled.png", false, array("border" => '0', "title" => __('Quiet'), "alt" => ""));
|
||||||
|
echo " ";
|
||||||
|
}
|
||||||
|
echo "<a href='index.php?sec=gagente&
|
||||||
sec2=godmode/agentes/configurar_agente&tab=main&
|
sec2=godmode/agentes/configurar_agente&tab=main&
|
||||||
id_agente=" . $agent["id_agente"] . "'>" .
|
id_agente=" . $agent["id_agente"] . "'>" .
|
||||||
ui_print_truncate_text($agent["nombre"], 'agent_medium', true, true, true, '[…]', 'font-size: 7pt') .
|
ui_print_truncate_text($agent["nombre"], 'agent_medium', true, true, true, '[…]', 'font-size: 7pt') .
|
||||||
"</a></strong>";
|
"</a>";
|
||||||
|
echo "</strong>";
|
||||||
if ($agent["disabled"]) {
|
if ($agent["disabled"]) {
|
||||||
ui_print_help_tip(__('Disabled'));
|
ui_print_help_tip(__('Disabled'));
|
||||||
echo "</em>";
|
echo "</em>";
|
||||||
|
@ -47,7 +47,7 @@ if (is_ajax ()) {
|
|||||||
|
|
||||||
$filter_groups = '';
|
$filter_groups = '';
|
||||||
$filter_groups = implode(',', array_keys($usr_groups));
|
$filter_groups = implode(',', array_keys($usr_groups));
|
||||||
|
|
||||||
switch ($config["dbtype"]) {
|
switch ($config["dbtype"]) {
|
||||||
case "mysql":
|
case "mysql":
|
||||||
$sql = sprintf ("SELECT t1.id, t1.name,
|
$sql = sprintf ("SELECT t1.id, t1.name,
|
||||||
@ -325,11 +325,11 @@ switch ($sortField) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
$search_sql = '';
|
$search_sql = '';
|
||||||
if ($search != ""){
|
if ($search != "") {
|
||||||
$search_sql = " AND ( nombre COLLATE utf8_general_ci LIKE '%$search%' OR direccion LIKE '%$search%' OR comentarios LIKE '%$search%') ";
|
$search_sql = " AND ( nombre COLLATE utf8_general_ci LIKE '%$search%' OR direccion LIKE '%$search%' OR comentarios LIKE '%$search%') ";
|
||||||
}
|
}
|
||||||
|
|
||||||
// Show only selected groups
|
// Show only selected groups
|
||||||
if ($group_id > 0) {
|
if ($group_id > 0) {
|
||||||
$groups = array($group_id);
|
$groups = array($group_id);
|
||||||
if ($recursion) {
|
if ($recursion) {
|
||||||
@ -361,13 +361,13 @@ $agents = agents_get_agents(array (
|
|||||||
'search' => $search_sql,
|
'search' => $search_sql,
|
||||||
'offset' => (int) get_parameter ('offset'),
|
'offset' => (int) get_parameter ('offset'),
|
||||||
'limit' => (int) $config['block_size'] ),
|
'limit' => (int) $config['block_size'] ),
|
||||||
|
|
||||||
array ('id_agente',
|
array ('id_agente',
|
||||||
'id_grupo',
|
'id_grupo',
|
||||||
'id_os',
|
'id_os',
|
||||||
'ultimo_contacto',
|
'ultimo_contacto',
|
||||||
'intervalo',
|
'intervalo',
|
||||||
'comentarios description'),
|
'comentarios description', 'quiet'),
|
||||||
'AR',
|
'AR',
|
||||||
$order);
|
$order);
|
||||||
|
|
||||||
@ -457,6 +457,9 @@ foreach ($agents as $agent) {
|
|||||||
|
|
||||||
$data[0] = '';
|
$data[0] = '';
|
||||||
$data[0] .= '<span class="left">';
|
$data[0] .= '<span class="left">';
|
||||||
|
if ($agent['quiet']) {
|
||||||
|
$data[0] .= html_print_image("images/dot_green.disabled.png", true, array("border" => '0', "title" => __('Quiet'), "alt" => "")) . " ";
|
||||||
|
}
|
||||||
$data[0] .= ui_print_agent_name($agent["id_agente"], true, 60, 'font-size:6.5pt !important;', true);
|
$data[0] .= ui_print_agent_name($agent["id_agente"], true, 60, 'font-size:6.5pt !important;', true);
|
||||||
$data[0] .= '</span>';
|
$data[0] .= '</span>';
|
||||||
$data[0] .= '<div class="left actions" style="visibility: hidden; clear: left">';
|
$data[0] .= '<div class="left actions" style="visibility: hidden; clear: left">';
|
||||||
|
@ -45,7 +45,7 @@ if($is_extra === ENTERPRISE_NOT_HOOK) {
|
|||||||
|
|
||||||
if (! check_acl ($config["id_user"], $agent["id_grupo"], "AR") && !$is_extra) {
|
if (! check_acl ($config["id_user"], $agent["id_grupo"], "AR") && !$is_extra) {
|
||||||
db_pandora_audit("ACL Violation",
|
db_pandora_audit("ACL Violation",
|
||||||
"Trying to access Agent General Information");
|
"Trying to access Agent General Information");
|
||||||
require_once ("general/noaccess.php");
|
require_once ("general/noaccess.php");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -59,7 +59,7 @@ echo '<div style="height: 10px"> </div>';
|
|||||||
|
|
||||||
if ($config["agentaccess"]){
|
if ($config["agentaccess"]){
|
||||||
echo '<b>'.__('Agent access rate (24h)').'</b><br />';
|
echo '<b>'.__('Agent access rate (24h)').'</b><br />';
|
||||||
|
|
||||||
graphic_agentaccess($id_agente, 280, 110, 86400);
|
graphic_agentaccess($id_agente, 280, 110, 86400);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -70,7 +70,7 @@ echo '<br>';
|
|||||||
graph_graphic_agentevents ($id_agente, 290, 15, 86400, '');
|
graph_graphic_agentevents ($id_agente, 290, 15, 86400, '');
|
||||||
|
|
||||||
echo '</div>';
|
echo '</div>';
|
||||||
|
|
||||||
echo '<div width="450px">';
|
echo '<div width="450px">';
|
||||||
echo '<table cellspacing="4" cellpadding="4" border="0" class="databox" style="width:53%">';
|
echo '<table cellspacing="4" cellpadding="4" border="0" class="databox" style="width:53%">';
|
||||||
//Agent name
|
//Agent name
|
||||||
@ -78,9 +78,14 @@ echo '<tr><td class="datos"><b>'.__('Agent name').'</b></td>';
|
|||||||
if ($agent['disabled']) {
|
if ($agent['disabled']) {
|
||||||
$cellName = "<em>" . ui_print_agent_name ($agent["id_agente"], true, 500, "text-transform: uppercase;", true) . ui_print_help_tip(__('Disabled'), true) . "</em>";
|
$cellName = "<em>" . ui_print_agent_name ($agent["id_agente"], true, 500, "text-transform: uppercase;", true) . ui_print_help_tip(__('Disabled'), true) . "</em>";
|
||||||
}
|
}
|
||||||
|
else if ($agent['quiet']) {
|
||||||
|
$cellName = "<em>" . ui_print_agent_name ($agent["id_agente"], true, 500, "text-transform: uppercase;", true) .
|
||||||
|
" " . html_print_image("images/dot_green.disabled.png", true, array("border" => '0', "title" => __('Quiet'), "alt" => "")) . "</em>";
|
||||||
|
}
|
||||||
else {
|
else {
|
||||||
$cellName = ui_print_agent_name ($agent["id_agente"], true, 500, "text-transform: uppercase;", true);
|
$cellName = ui_print_agent_name ($agent["id_agente"], true, 500, "text-transform: uppercase;", true);
|
||||||
}
|
}
|
||||||
|
|
||||||
echo '<td class="datos"><b>'.$cellName.'</b></td>';
|
echo '<td class="datos"><b>'.$cellName.'</b></td>';
|
||||||
echo '<td class="datos" width="40"><a href="index.php?sec=estado&sec2=operation/agentes/ver_agente&id_agente='.$id_agente.'&refr=60">' . html_print_image("images/refresh.png", true, array("border" => '0', "title" => __('Refresh data'), "alt" => "")) . '</a> ';
|
echo '<td class="datos" width="40"><a href="index.php?sec=estado&sec2=operation/agentes/ver_agente&id_agente='.$id_agente.'&refr=60">' . html_print_image("images/refresh.png", true, array("border" => '0', "title" => __('Refresh data'), "alt" => "")) . '</a> ';
|
||||||
echo '<a href="index.php?sec=estado&sec2=operation/agentes/ver_agente&flag_agent=1&id_agente='.$id_agente.'">' . html_print_image("images/target.png", true, array("border" => '0', "title" => __('Force'), "alt" => "")) . '</a></td></tr>';
|
echo '<a href="index.php?sec=estado&sec2=operation/agentes/ver_agente&flag_agent=1&id_agente='.$id_agente.'">' . html_print_image("images/target.png", true, array("border" => '0', "title" => __('Force'), "alt" => "")) . '</a></td></tr>';
|
||||||
|
@ -301,10 +301,10 @@ if (is_ajax ()) {
|
|||||||
foreach($agent_modules as $key => $module) {
|
foreach($agent_modules as $key => $module) {
|
||||||
$agent_modules[$key]['nombre'] = io_safe_output($module['nombre']);
|
$agent_modules[$key]['nombre'] = io_safe_output($module['nombre']);
|
||||||
}
|
}
|
||||||
|
|
||||||
//Hack to translate text "any" in PHP to javascript
|
//Hack to translate text "any" in PHP to javascript
|
||||||
//$agent_modules['any_text'] = __('Any');
|
//$agent_modules['any_text'] = __('Any');
|
||||||
|
|
||||||
echo json_encode ($agent_modules);
|
echo json_encode ($agent_modules);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -317,7 +317,7 @@ if (is_ajax ()) {
|
|||||||
echo '<strong>'.__('Group').':</strong> ';
|
echo '<strong>'.__('Group').':</strong> ';
|
||||||
echo html_print_image('images/groups_small/'.groups_get_icon ($agent['id_grupo']).'.png', true);
|
echo html_print_image('images/groups_small/'.groups_get_icon ($agent['id_grupo']).'.png', true);
|
||||||
echo groups_get_name ($agent['id_grupo']).'<br />';
|
echo groups_get_name ($agent['id_grupo']).'<br />';
|
||||||
|
|
||||||
echo '<strong>'.__('Last contact').':</strong> '.human_time_comparation($agent['ultimo_contacto']).'<br />';
|
echo '<strong>'.__('Last contact').':</strong> '.human_time_comparation($agent['ultimo_contacto']).'<br />';
|
||||||
echo '<strong>'.__('Last remote contact').':</strong> '.human_time_comparation($agent['ultimo_contacto_remoto']).'<br />';
|
echo '<strong>'.__('Last remote contact').':</strong> '.human_time_comparation($agent['ultimo_contacto_remoto']).'<br />';
|
||||||
|
|
||||||
@ -518,33 +518,33 @@ else {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
///-------------Code for the tabs in the header of agent page-----------
|
||||||
$tab = get_parameter ("tab", "main");
|
$tab = get_parameter ("tab", "main");
|
||||||
|
|
||||||
/* Manage tab */
|
/* Manage tab */
|
||||||
|
|
||||||
$managetab = "";
|
$managetab = "";
|
||||||
|
|
||||||
if (check_acl ($config['id_user'],$id_grupo, "AW") || $is_extra) {
|
if (check_acl ($config['id_user'],$id_grupo, "AW") || $is_extra) {
|
||||||
$managetab['text'] ='<a href="index.php?sec=gagente&sec2=godmode/agentes/configurar_agente&id_agente='.$id_agente.'">'
|
$managetab['text'] ='<a href="index.php?sec=gagente&sec2=godmode/agentes/configurar_agente&id_agente='.$id_agente.'">'
|
||||||
. html_print_image("images/setup.png", true, array ("title" => __('Manage')))
|
. html_print_image("images/setup.png", true, array ("title" => __('Manage')))
|
||||||
. '</a>';
|
. '</a>';
|
||||||
|
|
||||||
if ($tab == 'manage')
|
if ($tab == 'manage')
|
||||||
$managetab['active'] = true;
|
$managetab['active'] = true;
|
||||||
else
|
else
|
||||||
$managetab['active'] = false;
|
$managetab['active'] = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/* Main tab */
|
/* Main tab */
|
||||||
$maintab['text'] = '<a href="index.php?sec=estado&sec2=operation/agentes/ver_agente&id_agente='.$id_agente.'">'
|
$maintab['text'] = '<a href="index.php?sec=estado&sec2=operation/agentes/ver_agente&id_agente='.$id_agente.'">'
|
||||||
. html_print_image("images/monitor.png", true, array("title" => __('Main')))
|
. html_print_image("images/monitor.png", true, array("title" => __('Main')))
|
||||||
. '</a>';
|
. '</a>';
|
||||||
|
|
||||||
if ($tab == 'main')
|
if ($tab == 'main')
|
||||||
$maintab['active'] = true;
|
$maintab['active'] = true;
|
||||||
else
|
else
|
||||||
$maintab['active'] = false;
|
$maintab['active'] = false;
|
||||||
|
|
||||||
|
|
||||||
/* Data */
|
/* Data */
|
||||||
$datatab['text']= '<a href="index.php?sec=estado&sec2=operation/agentes/ver_agente&id_agente='.$id_agente.'&tab=data">'
|
$datatab['text']= '<a href="index.php?sec=estado&sec2=operation/agentes/ver_agente&id_agente='.$id_agente.'&tab=data">'
|
||||||
. html_print_image("images/lightbulb.png", true, array("title" => __('Data')))
|
. html_print_image("images/lightbulb.png", true, array("title" => __('Data')))
|
||||||
@ -555,21 +555,21 @@ if (($tab == 'data') OR ($tab == 'data_view'))
|
|||||||
else
|
else
|
||||||
$datatab['active'] = false;
|
$datatab['active'] = false;
|
||||||
|
|
||||||
|
|
||||||
/* Alert tab */
|
/* Alert tab */
|
||||||
$alerttab['text'] = '<a href="index.php?sec=estado&sec2=operation/agentes/ver_agente&id_agente='.$id_agente.'&tab=alert">'
|
$alerttab['text'] = '<a href="index.php?sec=estado&sec2=operation/agentes/ver_agente&id_agente='.$id_agente.'&tab=alert">'
|
||||||
. html_print_image("images/bell.png", true, array("title" => __('Alerts')))
|
. html_print_image("images/bell.png", true, array("title" => __('Alerts')))
|
||||||
. '</a>';
|
. '</a>';
|
||||||
|
|
||||||
if ($tab == 'alert')
|
if ($tab == 'alert')
|
||||||
$alerttab['active'] = true;
|
$alerttab['active'] = true;
|
||||||
else
|
else
|
||||||
$alerttab['active'] = false;
|
$alerttab['active'] = false;
|
||||||
|
|
||||||
|
|
||||||
/* SLA view */
|
/* SLA view */
|
||||||
$slatab['text']= '<a href="index.php?sec=estado&sec2=operation/agentes/ver_agente&tab=sla&id_agente='.$id_agente.'">'
|
$slatab['text']= '<a href="index.php?sec=estado&sec2=operation/agentes/ver_agente&tab=sla&id_agente='.$id_agente.'">'
|
||||||
. html_print_image("images/images.png", true, array("title" => __('S.L.A.')))
|
. html_print_image("images/images.png", true, array("title" => __('S.L.A.')))
|
||||||
. '</a>';
|
. '</a>';
|
||||||
|
|
||||||
if ($tab == 'sla') {
|
if ($tab == 'sla') {
|
||||||
$slatab['active'] = true;
|
$slatab['active'] = true;
|
||||||
}
|
}
|
||||||
@ -577,35 +577,35 @@ else {
|
|||||||
$slatab['active'] = false;
|
$slatab['active'] = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/* Inventory */
|
/* Inventory */
|
||||||
$inventorytab = enterprise_hook ('inventory_tab');
|
$inventorytab = enterprise_hook ('inventory_tab');
|
||||||
|
|
||||||
if ($inventorytab == -1)
|
if ($inventorytab == -1)
|
||||||
$inventorytab = "";
|
$inventorytab = "";
|
||||||
|
|
||||||
|
|
||||||
/* Collection */
|
/* Collection */
|
||||||
$collectiontab = enterprise_hook('collection_tab');
|
$collectiontab = enterprise_hook('collection_tab');
|
||||||
|
|
||||||
if ($collectiontab == -1)
|
if ($collectiontab == -1)
|
||||||
$collectiontab = "";
|
$collectiontab = "";
|
||||||
|
|
||||||
|
|
||||||
/* Policy */
|
/* Policy */
|
||||||
$policyTab = enterprise_hook('policy_tab');
|
$policyTab = enterprise_hook('policy_tab');
|
||||||
if ($policyTab == -1)
|
if ($policyTab == -1)
|
||||||
$policyTab = "";
|
$policyTab = "";
|
||||||
|
|
||||||
/* Group tab */
|
|
||||||
|
|
||||||
|
/* Group tab */
|
||||||
$grouptab['text']= '<a href="index.php?sec=estado&sec2=operation/agentes/estado_agente&group_id='.$id_grupo.'">'
|
$grouptab['text']= '<a href="index.php?sec=estado&sec2=operation/agentes/estado_agente&group_id='.$id_grupo.'">'
|
||||||
. html_print_image("images/agents_group.png", true, array( "title" => __('Group')))
|
. html_print_image("images/agents_group.png", true, array( "title" => __('Group')))
|
||||||
. '</a>';
|
. '</a>';
|
||||||
|
|
||||||
$grouptab['active']=false;
|
$grouptab['active']=false;
|
||||||
|
|
||||||
|
|
||||||
/* GIS tab */
|
/* GIS tab */
|
||||||
$gistab="";
|
$gistab="";
|
||||||
if ($config['activate_gis']) {
|
if ($config['activate_gis']) {
|
||||||
|
|
||||||
$gistab['text'] = '<a href="index.php?sec=estado&sec2=operation/agentes/ver_agente&tab=gis&id_agente='.$id_agente.'">'
|
$gistab['text'] = '<a href="index.php?sec=estado&sec2=operation/agentes/ver_agente&tab=gis&id_agente='.$id_agente.'">'
|
||||||
.html_print_image("images/world.png", true, array( "title" => __('GIS data')))
|
.html_print_image("images/world.png", true, array( "title" => __('GIS data')))
|
||||||
.'</a>';
|
.'</a>';
|
||||||
@ -616,41 +616,37 @@ if ($config['activate_gis']) {
|
|||||||
$gistab['active'] = false;
|
$gistab['active'] = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
$total_incidents = agents_get_count_incidents($id_agente);
|
|
||||||
|
|
||||||
/* Incident tab */
|
/* Incident tab */
|
||||||
if ($config['integria_enabled'] == 0 and $total_incidents > 0){
|
$total_incidents = agents_get_count_incidents($id_agente);
|
||||||
|
if ($config['integria_enabled'] == 0 and $total_incidents > 0) {
|
||||||
$incidenttab['text'] = '<a href="index.php?sec=gagente&sec2=operation/agentes/ver_agente&tab=incident&id_agente='.$id_agente.'">'
|
$incidenttab['text'] = '<a href="index.php?sec=gagente&sec2=operation/agentes/ver_agente&tab=incident&id_agente='.$id_agente.'">'
|
||||||
. html_print_image ("images/book_edit.png", true, array ("title" =>__('Incidents')))
|
. html_print_image ("images/book_edit.png", true, array ("title" =>__('Incidents')))
|
||||||
. '</a>';
|
. '</a>';
|
||||||
|
|
||||||
if($tab == 'incident')
|
if ($tab == 'incident')
|
||||||
$incidenttab['active'] = true;
|
$incidenttab['active'] = true;
|
||||||
else
|
else
|
||||||
$incidenttab['active'] = false;
|
$incidenttab['active'] = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
$custom_fields['text']= '<a href="index.php?sec=estado&sec2=operation/agentes/ver_agente&tab=custom_fields&id_agente='.$id_agente.'">'
|
|
||||||
. html_print_image("images/note.png", true, array("title" => __('Custom fields')))
|
|
||||||
. '</a>';
|
|
||||||
|
|
||||||
/* Url address tab */
|
/* Url address tab */
|
||||||
if ($agent['url_address'] != ''){
|
if ($agent['url_address'] != '') {
|
||||||
$urladdresstab['text'] = '<a href="index.php?sec=gagente&sec2=operation/agentes/ver_agente&tab=url_address&id_agente='.$id_agente.'">'
|
$urladdresstab['text'] = '<a href="index.php?sec=gagente&sec2=operation/agentes/ver_agente&tab=url_address&id_agente='.$id_agente.'">'
|
||||||
. html_print_image ("images/link2.png", true, array ("title" =>__('Url address')))
|
. html_print_image ("images/link2.png", true, array ("title" =>__('Url address')))
|
||||||
. '</a>';
|
. '</a>';
|
||||||
}
|
}
|
||||||
|
if ($tab == 'url_address')
|
||||||
if($tab == 'url_address')
|
|
||||||
$urladdresstab['active'] = true;
|
$urladdresstab['active'] = true;
|
||||||
else
|
else
|
||||||
$urladdresstab['active'] = false;
|
$urladdresstab['active'] = false;
|
||||||
|
|
||||||
$custom_fields['text']= '<a href="index.php?sec=estado&sec2=operation/agentes/ver_agente&tab=custom_fields&id_agente='.$id_agente.'">'
|
|
||||||
. html_print_image("images/note.png", true, array("title" => __('Custom fields')))
|
|
||||||
. '</a>';
|
|
||||||
|
|
||||||
|
|
||||||
|
/* Custom fields tab */
|
||||||
|
$custom_fields['text'] = '<a href="index.php?sec=estado&sec2=operation/agentes/ver_agente&tab=custom_fields&id_agente='.$id_agente.'">'
|
||||||
|
. html_print_image("images/note.png", true, array("title" => __('Custom fields')))
|
||||||
|
. '</a>';
|
||||||
if ($tab == 'custom_fields') {
|
if ($tab == 'custom_fields') {
|
||||||
$custom_fields['active'] = true;
|
$custom_fields['active'] = true;
|
||||||
}
|
}
|
||||||
@ -658,9 +654,11 @@ else {
|
|||||||
$custom_fields['active'] = false;
|
$custom_fields['active'] = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* Graphs tab */
|
||||||
$graphs['text'] = '<a href="index.php?sec=estado&sec2=operation/agentes/ver_agente&tab=graphs&id_agente='.$id_agente.'">'
|
$graphs['text'] = '<a href="index.php?sec=estado&sec2=operation/agentes/ver_agente&tab=graphs&id_agente='.$id_agente.'">'
|
||||||
. html_print_image("images/chart_curve.png", true, array("title" => __('Graphs')))
|
. html_print_image("images/chart_curve.png", true, array("title" => __('Graphs')))
|
||||||
. '</a>';
|
. '</a>';
|
||||||
if ($tab == 'graphs') {
|
if ($tab == 'graphs') {
|
||||||
$graphs['active'] = true;
|
$graphs['active'] = true;
|
||||||
}
|
}
|
||||||
@ -669,20 +667,30 @@ else {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
$onheader = array('manage' => $managetab, 'separator' => "", 'main' => $maintab,
|
$onheader = array('manage' => $managetab,
|
||||||
'data' => $datatab, 'alert' => $alerttab, 'sla' => $slatab,
|
'separator' => "",
|
||||||
'inventory' => $inventorytab, 'collection' => $collectiontab,
|
'main' => $maintab,
|
||||||
'group' => $grouptab, 'gis' => $gistab, 'custom' => $custom_fields, 'graphs' => $graphs, 'policy' => $policyTab);
|
'data' => $datatab,
|
||||||
|
'alert' => $alerttab,
|
||||||
|
'sla' => $slatab,
|
||||||
|
'inventory' => $inventorytab,
|
||||||
|
'collection' => $collectiontab,
|
||||||
|
'group' => $grouptab,
|
||||||
|
'gis' => $gistab,
|
||||||
|
'custom' => $custom_fields,
|
||||||
|
'graphs' => $graphs,
|
||||||
|
'policy' => $policyTab);
|
||||||
|
|
||||||
// If the agent has incidents associated
|
//Added after it exists
|
||||||
if ($total_incidents){
|
// If the agent has incidents associated
|
||||||
|
if ($total_incidents) {
|
||||||
$onheader['incident'] = $incidenttab;
|
$onheader['incident'] = $incidenttab;
|
||||||
}
|
}
|
||||||
|
if ($agent['url_address'] != '') {
|
||||||
if ($agent['url_address'] != ''){
|
$onheader['url_address'] = $urladdresstab;
|
||||||
$onheader['url_address'] = $urladdresstab;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//Tabs for extensions
|
||||||
foreach($config['extensions'] as $extension) {
|
foreach($config['extensions'] as $extension) {
|
||||||
if (isset($extension['extension_ope_tab'])) {
|
if (isset($extension['extension_ope_tab'])) {
|
||||||
|
|
||||||
@ -849,5 +857,4 @@ switch ($tab) {
|
|||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
?>
|
||||||
?>
|
|
@ -78,7 +78,8 @@ CREATE TABLE tagente (
|
|||||||
icon_path VARCHAR2(127) DEFAULT NULL NULL ,
|
icon_path VARCHAR2(127) DEFAULT NULL NULL ,
|
||||||
--set it to one to update the position data (altitude, longitude, latitude) when getting information from the agent or to 0 to keep the last value and don\'t update it
|
--set it to one to update the position data (altitude, longitude, latitude) when getting information from the agent or to 0 to keep the last value and don\'t update it
|
||||||
update_gis_data NUMBER(5, 0) DEFAULT 1 NOT NULL,
|
update_gis_data NUMBER(5, 0) DEFAULT 1 NOT NULL,
|
||||||
url_address CLOB DEFAULT '' NULL
|
url_address CLOB DEFAULT '' NULL,
|
||||||
|
quiet NUMBER(5, 0) default 0 NOT NULL
|
||||||
);
|
);
|
||||||
CREATE INDEX tagente_nombre_idx ON tagente(nombre);
|
CREATE INDEX tagente_nombre_idx ON tagente(nombre);
|
||||||
CREATE INDEX tagente_direccion_idx ON tagente(direccion);
|
CREATE INDEX tagente_direccion_idx ON tagente(direccion);
|
||||||
|
@ -76,7 +76,8 @@ CREATE TABLE "tagente" (
|
|||||||
"icon_path" VARCHAR(127) NULL DEFAULT NULL,
|
"icon_path" VARCHAR(127) NULL DEFAULT NULL,
|
||||||
--set it to one to update the position data (altitude, longitude, latitude) when getting information from the agent or to 0 to keep the last value and don\'t update it
|
--set it to one to update the position data (altitude, longitude, latitude) when getting information from the agent or to 0 to keep the last value and don\'t update it
|
||||||
"update_gis_data" SMALLINT NOT NULL DEFAULT 1,
|
"update_gis_data" SMALLINT NOT NULL DEFAULT 1,
|
||||||
"url_address" TEXT NULL default ''
|
"url_address" TEXT NULL default '',
|
||||||
|
"quiet" SMALLINT NOT NULL default 0
|
||||||
);
|
);
|
||||||
CREATE INDEX "tagente_nombre_idx" ON "tagente"("nombre");
|
CREATE INDEX "tagente_nombre_idx" ON "tagente"("nombre");
|
||||||
CREATE INDEX "tagente_direccion_idx" ON "tagente"("direccion");
|
CREATE INDEX "tagente_direccion_idx" ON "tagente"("direccion");
|
||||||
|
@ -18,6 +18,12 @@
|
|||||||
-- Because Pandora Installer don't understand them
|
-- Because Pandora Installer don't understand them
|
||||||
-- and fails creating database !!!
|
-- and fails creating database !!!
|
||||||
|
|
||||||
|
-- Priority : 0 - Maintance (grey)
|
||||||
|
-- Priority : 1 - Low (green)
|
||||||
|
-- Priority : 2 - Normal (blue)
|
||||||
|
-- Priority : 3 - Warning (yellow)
|
||||||
|
-- Priority : 4 - Critical (red)
|
||||||
|
|
||||||
-- -----------------------------------------------------
|
-- -----------------------------------------------------
|
||||||
-- Table `taddress`
|
-- Table `taddress`
|
||||||
-- -----------------------------------------------------
|
-- -----------------------------------------------------
|
||||||
@ -64,6 +70,7 @@ CREATE TABLE IF NOT EXISTS `tagente` (
|
|||||||
`icon_path` VARCHAR(127) NULL DEFAULT NULL COMMENT 'path in the server to the image of the icon representing the agent' ,
|
`icon_path` VARCHAR(127) NULL DEFAULT NULL COMMENT 'path in the server to the image of the icon representing the agent' ,
|
||||||
`update_gis_data` TINYINT(1) NOT NULL DEFAULT '1' COMMENT 'set it to one to update the position data (altitude, longitude, latitude) when getting information from the agent or to 0 to keep the last value and do not update it' ,
|
`update_gis_data` TINYINT(1) NOT NULL DEFAULT '1' COMMENT 'set it to one to update the position data (altitude, longitude, latitude) when getting information from the agent or to 0 to keep the last value and do not update it' ,
|
||||||
`url_address` mediumtext NULL,
|
`url_address` mediumtext NULL,
|
||||||
|
`quiet` tinyint(1) NOT NULL default '0',
|
||||||
PRIMARY KEY (`id_agente`),
|
PRIMARY KEY (`id_agente`),
|
||||||
KEY `nombre` (`nombre`),
|
KEY `nombre` (`nombre`),
|
||||||
KEY `direccion` (`direccion`),
|
KEY `direccion` (`direccion`),
|
||||||
@ -146,13 +153,11 @@ CREATE TABLE `tagente_estado` (
|
|||||||
KEY `running_by` (`running_by`),
|
KEY `running_by` (`running_by`),
|
||||||
KEY `last_execution_try` (`last_execution_try`)
|
KEY `last_execution_try` (`last_execution_try`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
||||||
|
|
||||||
-- Probably last_execution_try index is not useful and loads more than benefits
|
-- Probably last_execution_try index is not useful and loads more than benefits
|
||||||
|
|
||||||
-- -----------------------------------------------------
|
-- -----------------------------------------------------
|
||||||
-- Table `tagente_modulo`
|
-- Table `tagente_modulo`
|
||||||
-- -----------------------------------------------------
|
-- -----------------------------------------------------
|
||||||
|
|
||||||
-- id_modulo now uses tmodule
|
-- id_modulo now uses tmodule
|
||||||
-- ---------------------------
|
-- ---------------------------
|
||||||
-- 1 - Data server modules (agent related modules)
|
-- 1 - Data server modules (agent related modules)
|
||||||
@ -416,103 +421,118 @@ CREATE TABLE IF NOT EXISTS `talert_compound` (
|
|||||||
ON DELETE CASCADE ON UPDATE CASCADE
|
ON DELETE CASCADE ON UPDATE CASCADE
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
||||||
|
|
||||||
|
-- -----------------------------------------------------
|
||||||
|
-- Table `talert_compound_elements`
|
||||||
|
-- -----------------------------------------------------
|
||||||
CREATE TABLE IF NOT EXISTS `talert_compound_elements` (
|
CREATE TABLE IF NOT EXISTS `talert_compound_elements` (
|
||||||
`id_alert_compound` int(10) unsigned NOT NULL,
|
`id_alert_compound` int(10) unsigned NOT NULL,
|
||||||
`id_alert_template_module` int(10) unsigned NOT NULL,
|
`id_alert_template_module` int(10) unsigned NOT NULL,
|
||||||
`operation` enum('NOP', 'AND','OR','XOR','NAND','NOR','NXOR'),
|
`operation` enum('NOP', 'AND','OR','XOR','NAND','NOR','NXOR'),
|
||||||
`order` tinyint(2) unsigned default 0,
|
`order` tinyint(2) unsigned default 0,
|
||||||
UNIQUE (`id_alert_compound`, `id_alert_template_module`, `operation`),
|
UNIQUE (`id_alert_compound`, `id_alert_template_module`, `operation`),
|
||||||
FOREIGN KEY (`id_alert_compound`) REFERENCES talert_compound(`id`)
|
FOREIGN KEY (`id_alert_compound`) REFERENCES talert_compound(`id`)
|
||||||
ON DELETE CASCADE ON UPDATE CASCADE,
|
ON DELETE CASCADE ON UPDATE CASCADE,
|
||||||
FOREIGN KEY (`id_alert_template_module`) REFERENCES talert_template_modules(`id`)
|
FOREIGN KEY (`id_alert_template_module`) REFERENCES talert_template_modules(`id`)
|
||||||
ON DELETE CASCADE ON UPDATE CASCADE
|
ON DELETE CASCADE ON UPDATE CASCADE
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
||||||
|
|
||||||
|
-- -----------------------------------------------------
|
||||||
|
-- Table `talert_compound_actions`
|
||||||
|
-- -----------------------------------------------------
|
||||||
CREATE TABLE IF NOT EXISTS `talert_compound_actions` (
|
CREATE TABLE IF NOT EXISTS `talert_compound_actions` (
|
||||||
`id` int(10) unsigned NOT NULL auto_increment,
|
`id` int(10) unsigned NOT NULL auto_increment,
|
||||||
`id_alert_compound` int(10) unsigned NOT NULL,
|
`id_alert_compound` int(10) unsigned NOT NULL,
|
||||||
`id_alert_action` int(10) unsigned NOT NULL,
|
`id_alert_action` int(10) unsigned NOT NULL,
|
||||||
`fires_min` int(3) unsigned default 0,
|
`fires_min` int(3) unsigned default 0,
|
||||||
`fires_max` int(3) unsigned default 0,
|
`fires_max` int(3) unsigned default 0,
|
||||||
PRIMARY KEY (`id`),
|
PRIMARY KEY (`id`),
|
||||||
FOREIGN KEY (`id_alert_compound`) REFERENCES talert_compound(`id`)
|
FOREIGN KEY (`id_alert_compound`) REFERENCES talert_compound(`id`)
|
||||||
ON DELETE CASCADE ON UPDATE CASCADE,
|
ON DELETE CASCADE ON UPDATE CASCADE,
|
||||||
FOREIGN KEY (`id_alert_action`) REFERENCES talert_actions(`id`)
|
FOREIGN KEY (`id_alert_action`) REFERENCES talert_actions(`id`)
|
||||||
ON DELETE CASCADE ON UPDATE CASCADE
|
ON DELETE CASCADE ON UPDATE CASCADE
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
||||||
|
|
||||||
|
-- -----------------------------------------------------
|
||||||
|
-- Table `talert_special_days`
|
||||||
|
-- -----------------------------------------------------
|
||||||
CREATE TABLE IF NOT EXISTS `talert_special_days` (
|
CREATE TABLE IF NOT EXISTS `talert_special_days` (
|
||||||
`id` int(10) unsigned NOT NULL AUTO_INCREMENT,
|
`id` int(10) unsigned NOT NULL AUTO_INCREMENT,
|
||||||
`date` date NOT NULL DEFAULT '0000-00-00',
|
`date` date NOT NULL DEFAULT '0000-00-00',
|
||||||
`same_day` enum('monday','tuesday','wednesday','thursday','friday','saturday','sunday') NOT NULL DEFAULT 'sunday',
|
`same_day` enum('monday','tuesday','wednesday','thursday','friday','saturday','sunday') NOT NULL DEFAULT 'sunday',
|
||||||
`description` text,
|
`description` text,
|
||||||
PRIMARY KEY (`id`)
|
PRIMARY KEY (`id`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
||||||
|
|
||||||
-- Priority : 0 - Maintance (grey)
|
-- -----------------------------------------------------
|
||||||
-- Priority : 1 - Low (green)
|
-- Table `tattachment`
|
||||||
-- Priority : 2 - Normal (blue)
|
-- -----------------------------------------------------
|
||||||
-- Priority : 3 - Warning (yellow)
|
|
||||||
-- Priority : 4 - Critical (red)
|
|
||||||
|
|
||||||
CREATE TABLE IF NOT EXISTS `tattachment` (
|
CREATE TABLE IF NOT EXISTS `tattachment` (
|
||||||
`id_attachment` int(10) unsigned NOT NULL auto_increment,
|
`id_attachment` int(10) unsigned NOT NULL auto_increment,
|
||||||
`id_incidencia` int(10) unsigned NOT NULL default '0',
|
`id_incidencia` int(10) unsigned NOT NULL default '0',
|
||||||
`id_usuario` varchar(60) NOT NULL default '',
|
`id_usuario` varchar(60) NOT NULL default '',
|
||||||
`filename` varchar(255) NOT NULL default '',
|
`filename` varchar(255) NOT NULL default '',
|
||||||
`description` varchar(150) default '',
|
`description` varchar(150) default '',
|
||||||
`size` bigint(20) unsigned NOT NULL default '0',
|
`size` bigint(20) unsigned NOT NULL default '0',
|
||||||
PRIMARY KEY (`id_attachment`)
|
PRIMARY KEY (`id_attachment`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
||||||
|
|
||||||
|
-- -----------------------------------------------------
|
||||||
|
-- Table `tconfig`
|
||||||
|
-- -----------------------------------------------------
|
||||||
CREATE TABLE IF NOT EXISTS `tconfig` (
|
CREATE TABLE IF NOT EXISTS `tconfig` (
|
||||||
`id_config` int(10) unsigned NOT NULL auto_increment,
|
`id_config` int(10) unsigned NOT NULL auto_increment,
|
||||||
`token` varchar(100) NOT NULL default '',
|
`token` varchar(100) NOT NULL default '',
|
||||||
`value` text NOT NULL,
|
`value` text NOT NULL,
|
||||||
PRIMARY KEY (`id_config`)
|
PRIMARY KEY (`id_config`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
||||||
|
|
||||||
|
-- -----------------------------------------------------
|
||||||
|
-- Table `tconfig_os`
|
||||||
|
-- -----------------------------------------------------
|
||||||
CREATE TABLE IF NOT EXISTS `tconfig_os` (
|
CREATE TABLE IF NOT EXISTS `tconfig_os` (
|
||||||
`id_os` int(10) unsigned NOT NULL auto_increment,
|
`id_os` int(10) unsigned NOT NULL auto_increment,
|
||||||
`name` varchar(100) NOT NULL default '',
|
`name` varchar(100) NOT NULL default '',
|
||||||
`description` varchar(250) default '',
|
`description` varchar(250) default '',
|
||||||
`icon_name` varchar(100) default '',
|
`icon_name` varchar(100) default '',
|
||||||
PRIMARY KEY (`id_os`)
|
PRIMARY KEY (`id_os`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
||||||
|
|
||||||
|
-- -----------------------------------------------------
|
||||||
|
-- Table `tevento`
|
||||||
|
-- -----------------------------------------------------
|
||||||
CREATE TABLE IF NOT EXISTS `tevento` (
|
CREATE TABLE IF NOT EXISTS `tevento` (
|
||||||
`id_evento` bigint(20) unsigned NOT NULL auto_increment,
|
`id_evento` bigint(20) unsigned NOT NULL auto_increment,
|
||||||
`id_agente` int(10) NOT NULL default '0',
|
`id_agente` int(10) NOT NULL default '0',
|
||||||
`id_usuario` varchar(100) NOT NULL default '0',
|
`id_usuario` varchar(100) NOT NULL default '0',
|
||||||
`id_grupo` mediumint(4) NOT NULL default '0',
|
`id_grupo` mediumint(4) NOT NULL default '0',
|
||||||
`estado` tinyint(3) unsigned NOT NULL default '0',
|
`estado` tinyint(3) unsigned NOT NULL default '0',
|
||||||
`timestamp` datetime NOT NULL default '1970-01-01 00:00:00',
|
`timestamp` datetime NOT NULL default '1970-01-01 00:00:00',
|
||||||
`evento` text NOT NULL,
|
`evento` text NOT NULL,
|
||||||
`utimestamp` bigint(20) NOT NULL default '0',
|
`utimestamp` bigint(20) NOT NULL default '0',
|
||||||
`event_type` enum('unknown','alert_fired','alert_recovered','alert_ceased','alert_manual_validation','recon_host_detected','system','error','new_agent','going_up_warning','going_up_critical','going_down_warning','going_down_normal','going_down_critical','going_up_normal', 'configuration_change') default 'unknown',
|
`event_type` enum('unknown','alert_fired','alert_recovered','alert_ceased','alert_manual_validation','recon_host_detected','system','error','new_agent','going_up_warning','going_up_critical','going_down_warning','going_down_normal','going_down_critical','going_up_normal', 'configuration_change') default 'unknown',
|
||||||
`id_agentmodule` int(10) NOT NULL default '0',
|
`id_agentmodule` int(10) NOT NULL default '0',
|
||||||
`id_alert_am` int(10) NOT NULL default '0',
|
`id_alert_am` int(10) NOT NULL default '0',
|
||||||
`criticity` int(4) unsigned NOT NULL default '0',
|
`criticity` int(4) unsigned NOT NULL default '0',
|
||||||
`user_comment` text NOT NULL,
|
`user_comment` text NOT NULL,
|
||||||
`tags` text NOT NULL,
|
`tags` text NOT NULL,
|
||||||
`source` tinytext NOT NULL,
|
`source` tinytext NOT NULL,
|
||||||
`id_extra` tinytext NOT NULL,
|
`id_extra` tinytext NOT NULL,
|
||||||
PRIMARY KEY (`id_evento`),
|
PRIMARY KEY (`id_evento`),
|
||||||
KEY `indice_1` (`id_agente`,`id_evento`),
|
KEY `indice_1` (`id_agente`,`id_evento`),
|
||||||
KEY `indice_2` (`utimestamp`,`id_evento`),
|
KEY `indice_2` (`utimestamp`,`id_evento`),
|
||||||
KEY `idx_agentmodule` (`id_agentmodule`),
|
KEY `idx_agentmodule` (`id_agentmodule`),
|
||||||
INDEX criticity (`criticity`),
|
INDEX criticity (`criticity`),
|
||||||
INDEX estado (`estado`)
|
INDEX estado (`estado`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
||||||
|
|
||||||
-- Criticity: 0 - Maintance (grey)
|
-- Criticity: 0 - Maintance (grey)
|
||||||
-- Criticity: 1 - Informational (blue)
|
-- Criticity: 1 - Informational (blue)
|
||||||
-- Criticity: 2 - Normal (green) (status 0)
|
-- Criticity: 2 - Normal (green) (status 0)
|
||||||
-- Criticity: 3 - Warning (yellow) (status 2)
|
-- Criticity: 3 - Warning (yellow) (status 2)
|
||||||
-- Criticity: 4 - Critical (red) (status 1)
|
-- Criticity: 4 - Critical (red) (status 1)
|
||||||
|
|
||||||
|
-- -----------------------------------------------------
|
||||||
|
-- Table `tgrupo`
|
||||||
|
-- -----------------------------------------------------
|
||||||
CREATE TABLE IF NOT EXISTS `tgrupo` (
|
CREATE TABLE IF NOT EXISTS `tgrupo` (
|
||||||
`id_grupo` mediumint(4) unsigned NOT NULL auto_increment,
|
`id_grupo` mediumint(4) unsigned NOT NULL auto_increment,
|
||||||
`nombre` varchar(100) NOT NULL default '',
|
`nombre` varchar(100) NOT NULL default '',
|
||||||
|
Loading…
x
Reference in New Issue
Block a user