NotificationQuery: Use query column `host_name' instead of `host'

refs #8613
This commit is contained in:
Johannes Meyer 2015-04-13 15:24:15 +02:00
parent 24e06e5bc0
commit 96954ea9a1
6 changed files with 8 additions and 8 deletions

View File

@ -59,7 +59,7 @@ class Monitoring_AlertsummaryController extends Controller
$query = $this->backend->select()->from( $query = $this->backend->select()->from(
'notification', 'notification',
array( array(
'host', 'host_name',
'host_display_name', 'host_display_name',
'service', 'service',
'service_display_name', 'service_display_name',
@ -477,7 +477,7 @@ class Monitoring_AlertsummaryController extends Controller
$query = $this->backend->select()->from( $query = $this->backend->select()->from(
'notification', 'notification',
array( array(
'host', 'host_name',
'host_display_name', 'host_display_name',
'service', 'service',
'service_display_name', 'service_display_name',

View File

@ -325,7 +325,7 @@ class Monitoring_ListController extends Controller
); );
$this->setAutorefreshInterval(15); $this->setAutorefreshInterval(15);
$query = $this->backend->select()->from('notification', array( $query = $this->backend->select()->from('notification', array(
'host', 'host_name',
'service', 'service',
'notification_output', 'notification_output',
'notification_contact', 'notification_contact',

View File

@ -156,7 +156,7 @@ class Monitoring_ShowController extends Controller
$this->view->commands = $commands->paginate(); $this->view->commands = $commands->paginate();
$notifications = $this->backend->select()->from('notification', array( $notifications = $this->backend->select()->from('notification', array(
'host', 'host_name',
'service', 'service',
'notification_output', 'notification_output',
'notification_contact', 'notification_contact',

View File

@ -46,12 +46,12 @@ use Icinga\Module\Monitoring\Object\Service;
<?= $this->link()->service( <?= $this->link()->service(
$notification->service, $notification->service,
$notification->service_display_name, $notification->service_display_name,
$notification->host, $notification->host_name,
$notification->host_display_name $notification->host_display_name
) ?> ) ?>
<?php else: ?> <?php else: ?>
<?= $this->icon('host', $this->translate('Host')); ?> <?= $this->icon('host', $this->translate('Host')); ?>
<?= $this->link()->host($notification->host, $notification->host_display_name) ?> <?= $this->link()->host($notification->host_name, $notification->host_display_name) ?>
<?php endif ?> <?php endif ?>
<br> <br>
<?= $this->escape($this->ellipsis($notification->notification_output, 10000)) ?> <?= $this->escape($this->ellipsis($notification->notification_output, 10000)) ?>

View File

@ -13,7 +13,7 @@ class NotificationQuery extends IdoQuery
'notification_object_id' => 'n.object_id' 'notification_object_id' => 'n.object_id'
), ),
'objects' => array( 'objects' => array(
'host' => 'o.name1', 'host_name' => 'o.name1',
'service' => 'o.name2' 'service' => 'o.name2'
), ),
'contact' => array( 'contact' => array(

View File

@ -13,7 +13,7 @@ class Notification extends DataView
public function getColumns() public function getColumns()
{ {
return array( return array(
'host', 'host_name',
'service', 'service',
'notification_state', 'notification_state',
'notification_start_time', 'notification_start_time',