livestatus: servicegroup members as host/service array

refs #4372
This commit is contained in:
Michael Friedrich 2013-07-12 17:50:41 +02:00
parent 9f9f3623fc
commit 8c02c3a75a
1 changed files with 4 additions and 1 deletions

View File

@ -110,7 +110,10 @@ Value ServiceGroupsTable::MembersAccessor(const Value& row)
Array::Ptr members = boost::make_shared<Array>();
BOOST_FOREACH(const Service::Ptr& service, static_cast<ServiceGroup::Ptr>(row)->GetMembers()) {
members->Add(service->GetName());
Array::Ptr host_svc = boost::make_shared<Array>();
host_svc->Add(service->GetHost()->GetName());
host_svc->Add(service->GetShortName());
members->Add(host_svc);
}
return members;