mirror of
https://github.com/Icinga/icinga2.git
synced 2025-07-27 07:34:15 +02:00
ido: Fix hostgroup members.
This commit is contained in:
parent
f5c7cde99b
commit
e73f34ad02
@ -46,7 +46,7 @@ Dictionary::Ptr HostGroupDbObject::GetConfigFields(void) const
|
|||||||
Dictionary::Ptr fields = boost::make_shared<Dictionary>();
|
Dictionary::Ptr fields = boost::make_shared<Dictionary>();
|
||||||
HostGroup::Ptr group = static_pointer_cast<HostGroup>(GetObject());
|
HostGroup::Ptr group = static_pointer_cast<HostGroup>(GetObject());
|
||||||
|
|
||||||
fields->Set("alias", Empty);
|
fields->Set("alias", group->GetDisplayName());
|
||||||
|
|
||||||
return fields;
|
return fields;
|
||||||
}
|
}
|
||||||
@ -81,7 +81,7 @@ void HostGroupDbObject::MembersChangedHandler(void)
|
|||||||
query2.Type = DbQueryInsert;
|
query2.Type = DbQueryInsert;
|
||||||
query2.Fields = boost::make_shared<Dictionary>();
|
query2.Fields = boost::make_shared<Dictionary>();
|
||||||
query2.Fields->Set("instance_id", 0); /* DbConnection class fills in real ID */
|
query2.Fields->Set("instance_id", 0); /* DbConnection class fills in real ID */
|
||||||
query2.Fields->Set("hostgroup_id", hg);
|
query2.Fields->Set("hostgroup_id", DbValue::FromObjectInsertID(hg));
|
||||||
query2.Fields->Set("host_object_id", host);
|
query2.Fields->Set("host_object_id", host);
|
||||||
OnQuery(query2);
|
OnQuery(query2);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user