2010-02-16 Raul Mateos <raulofpandora@gmail.com>

* extensions/module_groups.php: Better description text. Changed font
	colour.

git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@2371 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
raulmateos 2010-02-16 22:36:12 +00:00
parent 23af6b04ff
commit e0e853741d
2 changed files with 19 additions and 11 deletions

View File

@ -1,4 +1,9 @@
2010-02-15 Miguel de Dios <miguel.dedios@artica.es> 2010-02-16 Raúl Mateos <raulofpandora@gmail.com>
* extensions/module_groups.php: Better description text. Changed font
colour.
2010-02-16 Miguel de Dios <miguel.dedios@artica.es>
* include/functions_gis.php: add the function "getMapConnection" get the row * include/functions_gis.php: add the function "getMapConnection" get the row
of connection for id connection, "updateMap" function update the all data in of connection for id connection, "updateMap" function update the all data in

View File

@ -84,6 +84,7 @@ function mainModuleGroups() {
} }
$color = 'transparent'; //Defaut color for cell $color = 'transparent'; //Defaut color for cell
$font_color = '#ffffff'; //Default font color for cell
if ($count == 0) { if ($count == 0) {
$color = '#babdb6'; //Grey when the cell for this model group and agent group hasn't modules. $color = '#babdb6'; //Grey when the cell for this model group and agent group hasn't modules.
$alinkStart = ''; $alinkStart = '';
@ -91,14 +92,16 @@ function mainModuleGroups() {
} }
else { else {
$alinkStart = '<a href="index.php?sec=estado&sec2=operation/agentes/status_monitor&status=-1&ag_group=' . $idAgentGroup . $alinkStart = '<a href="index.php?sec=estado&sec2=operation/agentes/status_monitor&status=-1&ag_group=' . $idAgentGroup .
'&modulegroup=' . $idModelGroup . '">'; '&modulegroup=' . $idModelGroup . '".
style="color: ' . $font_color . '";>';
$alinkEnd = '</a>'; $alinkEnd = '</a>';
if (array_key_exists(0,$states) && (count($states) == 1)) if (array_key_exists(0,$states) && (count($states) == 1))
$color = '#8ae234'; //Green when the cell for this model group and agent has OK state all modules. $color = '#8ae234'; //Green when the cell for this model group and agent has OK state all modules.
else { else {
if (array_key_exists(1,$states)) if (array_key_exists(1,$states)) {
$color = '#cc0000'; //Red when the cell for this model group and agent has at least one module in critical state and the rest in any state. $color = '#cc0000'; //Red when the cell for this model group and agent has at least one module in critical state and the rest in any state.
}
else else
$color = '#fce94f'; //Yellow when the cell for this model group and agent has at least one in warning state and the rest in green state. $color = '#fce94f'; //Yellow when the cell for this model group and agent has at least one in warning state and the rest in green state.
} }
@ -106,10 +109,10 @@ function mainModuleGroups() {
array_push($row, array_push($row,
'<div '<div
style="background: ' . $color . ' ; style="background: ' . $color . ';
height: 15px; height: 15px;
margin-left: auto; margin-right: auto; margin-left: auto; margin-right: auto;
text-align: center; padding-top: 5px;"> text-align: center; padding-top: 5px;">
' . $alinkStart . $count . ' modules' . $alinkEnd . '</div>'); ' . $alinkStart . $count . ' modules' . $alinkEnd . '</div>');
} }
array_push($tableData,$row); array_push($tableData,$row);
@ -122,19 +125,19 @@ function mainModuleGroups() {
"<ul style='float: left;'>" . "<ul style='float: left;'>" .
'<li style="clear: both;"> '<li style="clear: both;">
<div style="float: left; background: #cc0000; height: 20px; width: 80px;margin-right: 5px; margin-bottom: 5px;">&nbsp;</div>' . <div style="float: left; background: #cc0000; height: 20px; width: 80px;margin-right: 5px; margin-bottom: 5px;">&nbsp;</div>' .
__("Red when the cell for this model group and agent has at least one module in critical state and the others in any state.") . __("Red cell when the module group and agent have at least one module in critical state and the others in any state.") .
'</li>' . '</li>' .
'<li style="clear: both;"> '<li style="clear: both;">
<div style="float: left; background: #fce94f; height: 20px; width: 80px;margin-right: 5px; margin-bottom: 5px;">&nbsp;</div>' . <div style="float: left; background: #fce94f; height: 20px; width: 80px;margin-right: 5px; margin-bottom: 5px;">&nbsp;</div>' .
__("Yellow when the cell for this model group and agent has at least one in warning state and the others in green state.") . __("Yellow cell when the module group and agent have at least one in warning state and the others in green state.") .
'</li>' . '</li>' .
'<li style="clear: both;"> '<li style="clear: both;">
<div style="float: left; background: #8ae234; height: 20px; width: 80px;margin-right: 5px; margin-bottom: 5px;">&nbsp;</div>' . <div style="float: left; background: #8ae234; height: 20px; width: 80px;margin-right: 5px; margin-bottom: 5px;">&nbsp;</div>' .
__("Green when the cell for this model group and agent has OK state all modules.") . __("Green cell when the module group and agent have all modules in OK state.") .
'</li>' . '</li>' .
'<li style="clear: both;"> '<li style="clear: both;">
<div style="float: left; background: #babdb6; height: 20px; width: 80px;margin-right: 5px; margin-bottom: 5px;">&nbsp;</div>' . <div style="float: left; background: #babdb6; height: 20px; width: 80px;margin-right: 5px; margin-bottom: 5px;">&nbsp;</div>' .
__("Grey when the cell for this model group and agent group haven't modules.") . __("Grey cell when the module group and agent don't have any modules.") .
'</li>' . '</li>' .
"</ul>" . "</ul>" .
"</p>"; "</p>";