mirror of
https://github.com/Icinga/icinga2.git
synced 2025-07-24 22:24:44 +02:00
Add and populate Downtime#authoritative_zone
refs #6542 (cherry picked from commit 5431eae116df92d0b856e7f856da24df5a948144)
This commit is contained in:
parent
a24256993c
commit
53248a70c2
@ -251,6 +251,10 @@ String Downtime::AddDowntime(const Checkable::Ptr& checkable, const String& auth
|
||||
attrs->Set("config_owner", scheduledDowntime);
|
||||
attrs->Set("entry_time", Utility::GetTime());
|
||||
|
||||
if (!scheduledDowntime.IsEmpty()) {
|
||||
attrs->Set("authoritative_zone", Zone::GetLocalZone()->GetName());
|
||||
}
|
||||
|
||||
Host::Ptr host;
|
||||
Service::Ptr service;
|
||||
tie(host, service) = GetHostService(checkable);
|
||||
|
@ -84,6 +84,7 @@ class Downtime : ConfigObject < DowntimeNameComposer
|
||||
[state] int legacy_id;
|
||||
[state] bool was_cancelled;
|
||||
[config] String config_owner;
|
||||
[config] String authoritative_zone;
|
||||
};
|
||||
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user