mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-07-26 15:25:03 +02:00
2012-06-06 Vanessa Gil <vanessa.gil@artica.es>
* operation/agentes/exportdata.php: Fixed bug: If the data type of module is string, don't export the data in format: table, Excel or CSV. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@6424 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
1a871c7603
commit
be8d87e9e7
@ -1,3 +1,8 @@
|
|||||||
|
2012-06-06 Vanessa Gil <vanessa.gil@artica.es>
|
||||||
|
|
||||||
|
* operation/agentes/exportdata.php: Fixed bug:
|
||||||
|
If the data type of module is string, don't export the data in format: table, Excel or CSV.
|
||||||
|
|
||||||
2012-06-06 Vanessa Gil <vanessa.gil@artica.es>
|
2012-06-06 Vanessa Gil <vanessa.gil@artica.es>
|
||||||
|
|
||||||
* include/functions_modules.php: Fixed bug: When you
|
* include/functions_modules.php: Fixed bug: When you
|
||||||
|
@ -327,6 +327,7 @@ if (empty($export_btn)) {
|
|||||||
|
|
||||||
//Module selector
|
//Module selector
|
||||||
$table->data[2][0] = '<b>'.__('Modules').'</b>';
|
$table->data[2][0] = '<b>'.__('Modules').'</b>';
|
||||||
|
$table->data[2][0] .= ui_print_help_tip(__("No modules of type string. You can not calculate their average"),true);
|
||||||
|
|
||||||
if ($agent > 0) {
|
if ($agent > 0) {
|
||||||
$modules = agents_get_modules ($agent);
|
$modules = agents_get_modules ($agent);
|
||||||
@ -334,6 +335,23 @@ if (empty($export_btn)) {
|
|||||||
$modules = array ();
|
$modules = array ();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(!empty($modules)) { //remove modules of type string because you cant calculate their average.
|
||||||
|
$i = 0;
|
||||||
|
foreach ($modules as $key=>$module) {
|
||||||
|
$id_module_type = modules_get_agentmodule_type ($key);
|
||||||
|
switch ($id_module_type) {
|
||||||
|
case 3:
|
||||||
|
case 10:
|
||||||
|
case 17:
|
||||||
|
case 23:
|
||||||
|
case 33:
|
||||||
|
unset($modules[$i]);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
$i++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
$disabled_export_button = false;
|
$disabled_export_button = false;
|
||||||
if (empty($modules)) {
|
if (empty($modules)) {
|
||||||
$disabled_export_button = true;
|
$disabled_export_button = true;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user