diff --git a/application/tables/IcingaHostTable.php b/application/tables/IcingaHostTable.php deleted file mode 100644 index 4efdf0bc..00000000 --- a/application/tables/IcingaHostTable.php +++ /dev/null @@ -1,86 +0,0 @@ -objectRestrictions[$restriction->getName()] = $restriction; - return $this; - } - - public function getColumns() - { - return array( - 'id' => 'h.id', - 'host' => 'h.object_name', - 'object_type' => 'h.object_type', - 'address' => 'h.address', - 'disabled' => 'h.disabled', - 'display_name' => 'h.address', - ); - } - - protected function getActionUrl($row) - { - return $this->url('director/host', array('name' => $row->host)); - } - - protected function getMultiselectProperties() - { - return array( - 'url' => 'director/hosts/edit', - 'sourceUrl' => 'director/hosts', - 'keys' => array('name'), - ); - } - - protected function getRowClasses($row) - { - if ($row->disabled === 'y') { - return 'disabled'; - } else { - return null; - } - } - - public function getTitles() - { - $view = $this->view(); - return array( - 'host' => $view->translate('Hostname'), - 'address' => $view->translate('Address'), - ); - } - - protected function getUnfilteredQuery() - { - $query = $this->db()->select()->from( - array('h' => 'icinga_host'), - array() - )->order('h.object_name'); - - foreach ($this->objectRestrictions as $restriction) { - $restriction->applyToHostsQuery($query); - } - - return $query; - } - - public function getBaseQuery() - { - return $this->getUnfilteredQuery(); - } -}