IcingaObjectTables: remove filters, fix object_type

This commit is contained in:
Thomas Gelf 2015-12-15 19:01:48 +01:00
parent 7fe6eb2528
commit f6490f8926
4 changed files with 8 additions and 7 deletions

View File

@ -13,10 +13,11 @@ class IcingaEndpointTable extends IcingaObjectTable
public function getColumns()
{
return array(
'id' => 'e.id',
'endpoint' => 'e.object_name',
'host' => "(CASE WHEN e.host IS NULL THEN NULL ELSE CONCAT(e.host || ':' || COALESCE(e.port, 5665)) END)",
'zone' => 'z.object_name',
'id' => 'e.id',
'endpoint' => 'e.object_name',
'object_type' => 'e.object_type',
'host' => "(CASE WHEN e.host IS NULL THEN NULL ELSE CONCAT(e.host || ':' || COALESCE(e.port, 5665)) END)",
'zone' => 'z.object_name',
);
}

View File

@ -76,6 +76,6 @@ class IcingaHostTable extends IcingaObjectTable
public function getBaseQuery()
{
return $this->getUnfilteredQuery()->where('h.object_type = ?', 'object');
return $this->getUnfilteredQuery();
}
}

View File

@ -57,6 +57,6 @@ class IcingaServiceTable extends IcingaObjectTable
public function getBaseQuery()
{
return $this->getUnfilteredQuery()->where('s.object_type = ?', 'object');
return $this->getUnfilteredQuery();
}
}

View File

@ -56,6 +56,6 @@ class IcingaUserTable extends IcingaObjectTable
public function getBaseQuery()
{
return $this->getUnfilteredQuery()->where('u.object_type = ?', 'object');
return $this->getUnfilteredQuery();
}
}