Horrible fix to prevent variable from being modified later
This commit is contained in:
parent
548d9cde09
commit
0fe40e0ab9
@ -110,7 +110,7 @@ class Icinga extends GenericServer {
|
||||
|
||||
getUrlForService ( service )
|
||||
{
|
||||
return '%s/?type=2&host=%s&service=%s'.format ( this._settings.get_string ( 'urlcgi' ).replace ( /status.cgi/, 'extinfo.cgi' ),
|
||||
return '%s?type=2&host=%s&service=%s'.format ( this._settings.get_string ( 'urlcgi' ).replace ( /status.cgi/, 'extinfo.cgi' ),
|
||||
encodeURI ( service.real_host_name ),
|
||||
encodeURI ( service.service_display_name ) );
|
||||
}
|
||||
|
@ -82,9 +82,8 @@ class Icinga2 extends GenericServer {
|
||||
|
||||
getUrlForService ( service )
|
||||
{
|
||||
log ( service );
|
||||
return '%s/monitoring/service/show?host=%s&service=%s'.format ( this._settings.get_string ( 'url' ),
|
||||
service.host_name,
|
||||
service.real_host_name,
|
||||
service.service_display_name );
|
||||
}
|
||||
|
||||
|
@ -102,7 +102,7 @@ class Icinga2API extends GenericServer {
|
||||
// log ( JSON.stringify(entry) );
|
||||
this.status.service_status.push ( {
|
||||
status: _statuses[entry.attrs.state],
|
||||
real_host_name: entry.attrs.host_name,
|
||||
real_host_name: entry.attrs.host_name + '',
|
||||
host_name: entry.attrs.host_name,
|
||||
service_display_name: entry.attrs.display_name,
|
||||
has_been_acknowledged: parseInt(entry.attrs.acknowledgement),
|
||||
|
Loading…
Reference in New Issue
Block a user