add acknowledge trigger event function.

This commit is contained in:
Tom Zhang
2016-07-14 11:10:48 +09:30
parent ac9b4d249d
commit 7842f468d4
3 changed files with 62 additions and 1 deletions

View File

@@ -47,6 +47,7 @@ function ZabbixAPIService($q, alertSrv, zabbixAPICoreService) {
},
// Handle API errors
function(error) {
console.log('Zabbix error: '+error.data);
if (isNotAuthorized(error.data)) {
return self.loginOnce().then(
function() {
@@ -113,6 +114,13 @@ function ZabbixAPIService($q, alertSrv, zabbixAPICoreService) {
////////////////////////////////
// Zabbix API method wrappers //
////////////////////////////////
acknowledgeEvent(eventid,message){
var params = {
eventids:eventid,
message:message
};
return this.request('event.acknowledge',params);
}
getGroups() {
var params = {