2013-04-30 Sergio Martin <sergio.martin@artica.es>
* include/styles/pandora.css: Fix bad reposition action of bar graphs values in pure mode * include/graphs/flot/pandora.flot.js: Fix bad reposition action of bar graphs values when resize container * include/functions_graph.php: Fix the graph of database info of agents with most modules. Now avoid pending delete and the data is showed properly * operation/agentes/estado_generalagente.php: Fix a missing change of agent view layout fix git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@8087 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
e50bd98831
commit
d64964f6b8
|
@ -1,3 +1,19 @@
|
||||||
|
2013-04-30 Sergio Martin <sergio.martin@artica.es>
|
||||||
|
|
||||||
|
* include/styles/pandora.css: Fix bad reposition
|
||||||
|
action of bar graphs values in pure mode
|
||||||
|
|
||||||
|
* include/graphs/flot/pandora.flot.js: Fix bad
|
||||||
|
reposition action of bar graphs values when resize
|
||||||
|
container
|
||||||
|
|
||||||
|
* include/functions_graph.php: Fix the graph of
|
||||||
|
database info of agents with most modules. Now
|
||||||
|
avoid pending delete and the data is showed properly
|
||||||
|
|
||||||
|
* operation/agentes/estado_generalagente.php: Fix a
|
||||||
|
missing change of agent view layout fix
|
||||||
|
|
||||||
2013-04-30 Sergio Martin <sergio.martin@artica.es>
|
2013-04-30 Sergio Martin <sergio.martin@artica.es>
|
||||||
|
|
||||||
* godmode/modules/manage_network_components.php: Added
|
* godmode/modules/manage_network_components.php: Added
|
||||||
|
|
|
@ -1705,6 +1705,7 @@ function graph_db_agentes_modulos($width, $height) {
|
||||||
case "postgresql":
|
case "postgresql":
|
||||||
$modules = db_get_all_rows_sql ('SELECT COUNT(id_agente_modulo), id_agente
|
$modules = db_get_all_rows_sql ('SELECT COUNT(id_agente_modulo), id_agente
|
||||||
FROM tagente_modulo
|
FROM tagente_modulo
|
||||||
|
WHERE delete_pending = 0
|
||||||
GROUP BY id_agente
|
GROUP BY id_agente
|
||||||
ORDER BY 1 DESC LIMIT 10');
|
ORDER BY 1 DESC LIMIT 10');
|
||||||
break;
|
break;
|
||||||
|
@ -1712,6 +1713,7 @@ function graph_db_agentes_modulos($width, $height) {
|
||||||
$modules = db_get_all_rows_sql ('SELECT COUNT(id_agente_modulo), id_agente
|
$modules = db_get_all_rows_sql ('SELECT COUNT(id_agente_modulo), id_agente
|
||||||
FROM tagente_modulo
|
FROM tagente_modulo
|
||||||
WHERE rownum <= 10
|
WHERE rownum <= 10
|
||||||
|
AND delete_pending = 0
|
||||||
GROUP BY id_agente
|
GROUP BY id_agente
|
||||||
ORDER BY 1 DESC');
|
ORDER BY 1 DESC');
|
||||||
break;
|
break;
|
||||||
|
@ -1721,6 +1723,10 @@ function graph_db_agentes_modulos($width, $height) {
|
||||||
|
|
||||||
foreach ($modules as $module) {
|
foreach ($modules as $module) {
|
||||||
$agent_name = agents_get_name ($module['id_agente'], "none");
|
$agent_name = agents_get_name ($module['id_agente'], "none");
|
||||||
|
|
||||||
|
if(empty($agent_name)) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
switch ($config['dbtype']){
|
switch ($config['dbtype']){
|
||||||
case "mysql":
|
case "mysql":
|
||||||
case "postgresql":
|
case "postgresql":
|
||||||
|
|
|
@ -215,8 +215,16 @@ function pandoraFlotHBars(graph_id, values, labels, water_mark, maxvalue, water_
|
||||||
|
|
||||||
$('#'+graph_id+' .yAxis .tickLabel').each(function() {
|
$('#'+graph_id+' .yAxis .tickLabel').each(function() {
|
||||||
inCanvasValuePos = parseInt(pixelPerValue * ($('#value_'+i+'_'+graph_id).html()));
|
inCanvasValuePos = parseInt(pixelPerValue * ($('#value_'+i+'_'+graph_id).html()));
|
||||||
|
label_width = ($('#value_'+i+'_'+graph_id).css('width').split('px')[0] - 3);
|
||||||
|
|
||||||
$('#value_'+i+'_'+graph_id).css('left',plot.offset().left + inCanvasValuePos - $('#value_'+i+'_'+graph_id).css('width').split('px')[0] - 3);
|
label_left_offset = plot.offset().left + inCanvasValuePos + 5; //Label located on right side of bar + 5 pixels
|
||||||
|
|
||||||
|
//If label fit into the bar just recalculate left position to fit on right side of bar
|
||||||
|
if (inCanvasValuePos > label_width) {
|
||||||
|
label_left_offset = plot.offset().left + inCanvasValuePos - $('#value_'+i+'_'+graph_id).css('width').split('px')[0] - 3;
|
||||||
|
}
|
||||||
|
|
||||||
|
$('#value_'+i+'_'+graph_id).css('left',label_left_offset);
|
||||||
i++;
|
i++;
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
|
@ -1629,7 +1629,7 @@ div#main_pure {
|
||||||
margin-right: 10px;
|
margin-right: 10px;
|
||||||
height: auto;
|
height: auto;
|
||||||
width: 98%;
|
width: 98%;
|
||||||
position: absolute;
|
position: static;
|
||||||
}
|
}
|
||||||
#table-agent-configuration radio {
|
#table-agent-configuration radio {
|
||||||
margin-right: 40px;
|
margin-right: 40px;
|
||||||
|
|
|
@ -231,7 +231,7 @@ if ($config['activate_gis'] || $agent['url_address'] != '') {
|
||||||
$data[1] = __('There is no GIS data.');
|
$data[1] = __('There is no GIS data.');
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
$data[$col] = '<a href="index.php?sec=estado&sec2=operation/agentes/ver_agente&tab=gis&id_agente='.$id_agente.'">';
|
$data[1] = '<a href="index.php?sec=estado&sec2=operation/agentes/ver_agente&tab=gis&id_agente='.$id_agente.'">';
|
||||||
if ($dataPositionAgent['description'] != "")
|
if ($dataPositionAgent['description'] != "")
|
||||||
$data[1] .= $dataPositionAgent['description'];
|
$data[1] .= $dataPositionAgent['description'];
|
||||||
else
|
else
|
||||||
|
|
Loading…
Reference in New Issue