fix some stuff, break some stuff (ports disaply is missing some stuff atm)

git-svn-id: http://www.observium.org/svn/observer/trunk@2290 61d68cd4-352d-0410-923a-c4978735b2b8
This commit is contained in:
Adam Amstrong
2011-05-12 22:14:56 +00:00
parent 48f4c0e131
commit 6bcc4f4e48
17 changed files with 90 additions and 146 deletions

View File

@@ -24,14 +24,7 @@ foreach ($_POST as $key => $val)
continue;
}
if (!mysql_query('UPDATE `ports` SET `ignore`='.$newign.' WHERE `device_id`='.$device_id.' AND `interface_id`='.$interface_id))
{
$n = -1;
}
else
{
$n = mysql_affected_rows();
}
$n = dbUpdate(array('ignore' => $newign), 'ports', '`device_id` = ? AND `interface_id` = ?', array($device_id, $interface_id));
if ($n <0)
{
@@ -58,14 +51,7 @@ foreach ($_POST as $key => $val)
continue;
}
if (!mysql_query('UPDATE `ports` SET `disabled`='.$newdis.' WHERE `device_id`='.$device_id.' AND `interface_id`='.$interface_id))
{
$n = -1;
}
else
{
$n = mysql_affected_rows();
}
$n = dbUpdate(array('disabled' => $newdis), 'ports', '`device_id` = ? AND `interface_id` = ?', array($device_id, $interface_id));
if ($n <0)
{