parent
0a98cb0255
commit
55a6b79ee5
|
@ -53,15 +53,8 @@ class HostgroupQuery extends IdoQuery
|
|||
array()
|
||||
)->join(
|
||||
array('hgo' => $this->prefix . 'objects'),
|
||||
'hgo.object_id = hg.hostgroup_object_id',
|
||||
'hgo.object_id = hg.hostgroup_object_id AND hgo.is_active = 1 AND hgo.objecttype_id = 3',
|
||||
array()
|
||||
)->where(
|
||||
'hgo.is_active = ?',
|
||||
1
|
||||
)
|
||||
->where(
|
||||
'hgo.objecttype_id = ?',
|
||||
3
|
||||
);
|
||||
$this->joinedVirtualTables['hostgroups'] = true;
|
||||
}
|
||||
|
@ -77,15 +70,8 @@ class HostgroupQuery extends IdoQuery
|
|||
array()
|
||||
)->join(
|
||||
array('ho' => $this->prefix . 'objects'),
|
||||
'hgm.host_object_id = ho.object_id',
|
||||
'hgm.host_object_id = ho.object_id AND ho.is_active = 1 AND ho.objecttype_id = 1',
|
||||
array()
|
||||
)->where(
|
||||
'ho.is_active = ?',
|
||||
1
|
||||
)
|
||||
->where(
|
||||
'ho.objecttype_id = ?',
|
||||
1
|
||||
);
|
||||
$this->group('hgo.name1');
|
||||
}
|
||||
|
@ -119,15 +105,8 @@ class HostgroupQuery extends IdoQuery
|
|||
array()
|
||||
)->join(
|
||||
array('sgo' => $this->prefix . 'objects'),
|
||||
'sgo.object_id = sg.servicegroup_object_id',
|
||||
'sgo.object_id = sg.servicegroup_object_id AND sgo.is_active = 1 AND sgo.objecttype_id = 4',
|
||||
array()
|
||||
)->where(
|
||||
'sgo.is_active = ?',
|
||||
1
|
||||
)
|
||||
->where(
|
||||
'sgo.objecttype_id = ?',
|
||||
4
|
||||
);
|
||||
}
|
||||
|
||||
|
@ -143,15 +122,8 @@ class HostgroupQuery extends IdoQuery
|
|||
array()
|
||||
)->join(
|
||||
array('so' => $this->prefix . 'objects'),
|
||||
'so.object_id = s.service_object_id AND so.is_active = 1',
|
||||
'so.object_id = s.service_object_id AND so.is_active = 1 AND so.objecttype_id = 2',
|
||||
array()
|
||||
)->where(
|
||||
'so.is_active = ?',
|
||||
1
|
||||
)
|
||||
->where(
|
||||
'so.objecttype_id = ?',
|
||||
2
|
||||
);
|
||||
$this->group('hgo.name1');
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue