mirror of
https://github.com/Icinga/icingaweb2-module-director.git
synced 2025-07-30 09:14:09 +02:00
parent
d4b769b8d7
commit
66ee5fb325
@ -40,6 +40,20 @@ class IcingaZoneTable extends IcingaObjectTable
|
||||
);
|
||||
}
|
||||
|
||||
public function count()
|
||||
{
|
||||
$db = $this->db();
|
||||
$sub = clone($this->getBaseQuery());
|
||||
$sub->columns($this->getColumns());
|
||||
$this->applyFiltersToQuery($sub);
|
||||
$query = $db->select()->from(
|
||||
array('sub' => $sub),
|
||||
'COUNT(*)'
|
||||
);
|
||||
|
||||
return $db->fetchOne($query);
|
||||
}
|
||||
|
||||
public function getBaseQuery()
|
||||
{
|
||||
return $this->db()->select()->from(
|
||||
|
Loading…
x
Reference in New Issue
Block a user