summaryrefslogtreecommitdiffstats
path: root/library/Director/Web/Table/ObjectsTableService.php
diff options
context:
space:
mode:
Diffstat (limited to 'library/Director/Web/Table/ObjectsTableService.php')
-rw-r--r--library/Director/Web/Table/ObjectsTableService.php6
1 files changed, 6 insertions, 0 deletions
diff --git a/library/Director/Web/Table/ObjectsTableService.php b/library/Director/Web/Table/ObjectsTableService.php
index 2d4ad41..c9bce72 100644
--- a/library/Director/Web/Table/ObjectsTableService.php
+++ b/library/Director/Web/Table/ObjectsTableService.php
@@ -203,8 +203,14 @@ class ObjectsTableService extends ObjectsTable
'hsb.service_id = o.id AND hsb.host_id = o.host_id',
[]
)->where('o.service_set_id IS NULL')
+ ->group(['o.id', 'h.id','hsb.service_id', 'hsb.host_id'])
->order('o.object_name')->order('h.object_name');
+ if ($this->branchUuid) {
+ $subQuery->where('bo.service_set IS NULL')
+ ->group(['bo.uuid', 'bo.branch_uuid']);
+ }
+
if ($this->host) {
if ($this->branchUuid) {
$subQuery->where('COALESCE(h.object_name, bo.host) = ?', $this->host->getObjectName());