parent
73e9db3704
commit
05e0568ef1
|
@ -434,7 +434,7 @@ class StatusQuery extends IdoQuery
|
||||||
array('so' => $this->prefix . 'objects'),
|
array('so' => $this->prefix . 'objects'),
|
||||||
'so.' . $this->object_id . ' = s.service_object_id AND so.is_active = 1',
|
'so.' . $this->object_id . ' = s.service_object_id AND so.is_active = 1',
|
||||||
array()
|
array()
|
||||||
)->joinLeft(
|
)->join(
|
||||||
array('ss' => $this->prefix . 'servicestatus'),
|
array('ss' => $this->prefix . 'servicestatus'),
|
||||||
'so.' . $this->object_id . ' = ss.service_object_id',
|
'so.' . $this->object_id . ' = ss.service_object_id',
|
||||||
array()
|
array()
|
||||||
|
@ -452,15 +452,15 @@ class StatusQuery extends IdoQuery
|
||||||
|
|
||||||
protected function joinHostHostgroups()
|
protected function joinHostHostgroups()
|
||||||
{
|
{
|
||||||
$this->select->join(
|
$this->select->joinLeft(
|
||||||
array('hgm' => $this->prefix . 'hostgroup_members'),
|
array('hgm' => $this->prefix . 'hostgroup_members'),
|
||||||
'hgm.host_object_id = h.host_object_id',
|
'hgm.host_object_id = h.host_object_id',
|
||||||
array()
|
array()
|
||||||
)->join(
|
)->joinLeft(
|
||||||
array('hg' => $this->prefix . 'hostgroups'),
|
array('hg' => $this->prefix . 'hostgroups'),
|
||||||
'hgm.hostgroup_id = hg.' . $this->hostgroup_id,
|
'hgm.hostgroup_id = hg.' . $this->hostgroup_id,
|
||||||
array()
|
array()
|
||||||
)->join(
|
)->joinLeft(
|
||||||
array('hgo' => $this->prefix . 'objects'),
|
array('hgo' => $this->prefix . 'objects'),
|
||||||
'hgo.' . $this->object_id . ' = hg.hostgroup_object_id AND hgo.is_active = 1',
|
'hgo.' . $this->object_id . ' = hg.hostgroup_object_id AND hgo.is_active = 1',
|
||||||
array()
|
array()
|
||||||
|
@ -477,15 +477,15 @@ class StatusQuery extends IdoQuery
|
||||||
|
|
||||||
protected function joinServiceHostgroups()
|
protected function joinServiceHostgroups()
|
||||||
{
|
{
|
||||||
$this->select->join(
|
$this->select->joinLeft(
|
||||||
array('hgm' => $this->prefix . 'hostgroup_members'),
|
array('hgm' => $this->prefix . 'hostgroup_members'),
|
||||||
'hgm.host_object_id = s.host_object_id',
|
'hgm.host_object_id = s.host_object_id',
|
||||||
array()
|
array()
|
||||||
)->join(
|
)->joinLeft(
|
||||||
array('hg' => $this->prefix . 'hostgroups'),
|
array('hg' => $this->prefix . 'hostgroups'),
|
||||||
'hgm.hostgroup_id = hg.' . $this->hostgroup_id,
|
'hgm.hostgroup_id = hg.' . $this->hostgroup_id,
|
||||||
array()
|
array()
|
||||||
)->join(
|
)->joinLeft(
|
||||||
array('hgo' => $this->prefix . 'objects'),
|
array('hgo' => $this->prefix . 'objects'),
|
||||||
'hgo.' . $this->object_id . ' = hg.hostgroup_object_id'
|
'hgo.' . $this->object_id . ' = hg.hostgroup_object_id'
|
||||||
. ' AND hgo.is_active = 1',
|
. ' AND hgo.is_active = 1',
|
||||||
|
@ -502,15 +502,15 @@ class StatusQuery extends IdoQuery
|
||||||
protected function joinServicegroups()
|
protected function joinServicegroups()
|
||||||
{
|
{
|
||||||
$this->requireVirtualTable('services');
|
$this->requireVirtualTable('services');
|
||||||
$this->select->join(
|
$this->select->joinLeft(
|
||||||
array('sgm' => $this->prefix . 'servicegroup_members'),
|
array('sgm' => $this->prefix . 'servicegroup_members'),
|
||||||
'sgm.service_object_id = s.service_object_id',
|
'sgm.service_object_id = s.service_object_id',
|
||||||
array()
|
array()
|
||||||
)->join(
|
)->joinLeft(
|
||||||
array('sg' => $this->prefix . 'servicegroups'),
|
array('sg' => $this->prefix . 'servicegroups'),
|
||||||
'sgm.servicegroup_id = sg.' . $this->servicegroup_id,
|
'sgm.servicegroup_id = sg.' . $this->servicegroup_id,
|
||||||
array()
|
array()
|
||||||
)->join(
|
)->joinLeft(
|
||||||
array('sgo' => $this->prefix . 'objects'),
|
array('sgo' => $this->prefix . 'objects'),
|
||||||
'sgo.' . $this->object_id. ' = sg.servicegroup_object_id'
|
'sgo.' . $this->object_id. ' = sg.servicegroup_object_id'
|
||||||
. ' AND sgo.is_active = 1',
|
. ' AND sgo.is_active = 1',
|
||||||
|
|
Loading…
Reference in New Issue