parent
0cc693810b
commit
755da0c210
|
@ -96,15 +96,15 @@ class ServicedowntimestarthistoryQuery extends IdoQuery
|
||||||
protected function joinHostgroups()
|
protected function joinHostgroups()
|
||||||
{
|
{
|
||||||
$this->requireVirtualTable('services');
|
$this->requireVirtualTable('services');
|
||||||
$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'),
|
||||||
'hg.hostgroup_id = hgm.hostgroup_id',
|
'hg.hostgroup_id = hgm.hostgroup_id',
|
||||||
array()
|
array()
|
||||||
)->join(
|
)->joinLeft(
|
||||||
array('hgo' => $this->prefix . 'objects'),
|
array('hgo' => $this->prefix . 'objects'),
|
||||||
'hgo.object_id = hg.hostgroup_object_id AND hgo.is_active = 1 AND hgo.objecttype_id = 3',
|
'hgo.object_id = hg.hostgroup_object_id AND hgo.is_active = 1 AND hgo.objecttype_id = 3',
|
||||||
array()
|
array()
|
||||||
|
@ -130,15 +130,15 @@ class ServicedowntimestarthistoryQuery extends IdoQuery
|
||||||
*/
|
*/
|
||||||
protected function joinServicegroups()
|
protected function joinServicegroups()
|
||||||
{
|
{
|
||||||
$this->select->join(
|
$this->select->joinLeft(
|
||||||
array('sgm' => $this->prefix . 'servicegroup_members'),
|
array('sgm' => $this->prefix . 'servicegroup_members'),
|
||||||
'sgm.service_object_id = so.object_id',
|
'sgm.service_object_id = so.object_id',
|
||||||
array()
|
array()
|
||||||
)->join(
|
)->joinLeft(
|
||||||
array('sg' => $this->prefix . 'servicegroups'),
|
array('sg' => $this->prefix . 'servicegroups'),
|
||||||
'sg.' . $this->servicegroup_id . ' = sgm.servicegroup_id',
|
'sg.' . $this->servicegroup_id . ' = sgm.servicegroup_id',
|
||||||
array()
|
array()
|
||||||
)->join(
|
)->joinLeft(
|
||||||
array('sgo' => $this->prefix . 'objects'),
|
array('sgo' => $this->prefix . 'objects'),
|
||||||
'sgo.object_id = sg.servicegroup_object_id AND sgo.is_active = 1 AND sgo.objecttype_id = 4',
|
'sgo.object_id = sg.servicegroup_object_id AND sgo.is_active = 1 AND sgo.objecttype_id = 4',
|
||||||
array()
|
array()
|
||||||
|
|
Loading…
Reference in New Issue