CommentQuery: Fix grouping
There was only one comment for each host or service being fetched. refs #9009
This commit is contained in:
parent
83c21f08e3
commit
a4ad4e2372
|
@ -101,7 +101,7 @@ class HostcommentQuery extends IdoQuery
|
|||
'hgo.objecttype_id = ?',
|
||||
3
|
||||
);
|
||||
$this->group('ho.name1');
|
||||
$this->group(array('c.comment_id', 'ho.name1'));
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -177,6 +177,6 @@ class HostcommentQuery extends IdoQuery
|
|||
'so.objecttype_id = ?',
|
||||
2
|
||||
);
|
||||
$this->group('ho.name1');
|
||||
$this->group(array('c.comment_id', 'ho.name1'));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -106,7 +106,7 @@ class ServicecommentQuery extends IdoQuery
|
|||
'hgo.objecttype_id = ?',
|
||||
3
|
||||
);
|
||||
$this->group(array('so.name2', 'so.name1'));
|
||||
$this->group(array('c.comment_id', 'so.name2', 'so.name1'));
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -160,7 +160,7 @@ class ServicecommentQuery extends IdoQuery
|
|||
'sgo.objecttype_id = ?',
|
||||
4
|
||||
);
|
||||
$this->group(array('so.name2', 'so.name1'));
|
||||
$this->group(array('c.comment_id', 'so.name2', 'so.name1'));
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue