".__('Delete Data')."";
// First checkings
$max = $_POST["max"];
$min = $_POST["min"];
if ($max == $min) {
echo "
ERROR ".__('Maximum equal to minimum')."
";
echo "";
include ("general/footer.php");
exit;
}
$origen_modulo = mysql_real_esape_string ($_POST["origen_modulo"]);
if (count($origen_modulo) <= 0) {
echo "ERROR: ".__('No modules has been selected')."
";
echo "";
include ("general/footer.php");
exit;
}
// Source (agent)
$id_origen = $_POST["origen"];
// Copy
for ($a = 0; $a < count ($origen_modulo); $a++) { // For every agent selected
$id_agentemodulo = $origen_modulo[$a];
echo "
".__('Filtering data module')." [".dame_nombre_modulo_agentemodulo ($id_agentemodulo)."]";
$sql ='DELETE FROM tagente_datos WHERE id_agente_modulo = '.$origen_modulo[$a].' AND ( datos < '.$min.' OR datos > '.$max.' )';
process_sql ($sql);
//echo "
DEBUG DELETE $sql1
";
}
} //if copy modules or alerts
} else { // Form view
?>
>