Source
xxxxxxxxxx
zbx_db_add_condition_alloc(&sql, &sql_alloc, &sql_offset, "i.hostid", templateids->values, templateids->values_num);
/*
** Zabbix
** Copyright (C) 2001-2023 Zabbix SIA
**
** This program is free software; you can redistribute it and/or modify
** it under the terms of the GNU General Public License as published by
** the Free Software Foundation; either version 2 of the License, or
** (at your option) any later version.
**
** This program is distributed in the hope that it will be useful,
** but WITHOUT ANY WARRANTY; without even the implied warranty of
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
** GNU General Public License for more details.
**
** You should have received a copy of the GNU General Public License
** along with this program; if not, write to the Free Software
** Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
**/
typedef struct
{
zbx_uint64_t hostid;
zbx_uint64_t triggerid;
char *description;
char *expression;
char *recovery_expression;
zbx_uint64_t templateid;
unsigned char flags;
unsigned char recovery_mode;
unsigned char correlation_mode;
unsigned char manual_close;
char *opdata;
unsigned char discover;
char *event_name;
unsigned char priority;
char *comments;
char *url;
char *url_name;
char *correlation_tag;
unsigned char status;
unsigned char type;
}
zbx_trigger_copy_t;
ZBX_PTR_VECTOR_DECL(trigger_copies_templates, zbx_trigger_copy_t *)
ZBX_PTR_VECTOR_IMPL(trigger_copies_templates, zbx_trigger_copy_t *)
ZBX_PTR_VECTOR_DECL(trigger_copies_insert, zbx_trigger_copy_t *)
ZBX_PTR_VECTOR_IMPL(trigger_copies_insert, zbx_trigger_copy_t *)
/* TARGET HOST TRIGGER DATA */
typedef struct
{
zbx_uint64_t triggerid;
char *description;
char *expression;
char *recovery_expression;
zbx_uint64_t templateid_orig;
zbx_uint64_t templateid;
unsigned char flags;
unsigned char recovery_mode_orig;
unsigned char recovery_mode;
unsigned char correlation_mode_orig;
unsigned char correlation_mode;
char *correlation_tag_orig;
char *correlation_tag;
unsigned char manual_close_orig;
unsigned char manual_close;
char *opdata_orig;
char *opdata;
unsigned char discover_orig;
unsigned char discover;
char *event_name_orig;
char *event_name;
unsigned char priority_orig;
unsigned char priority;
char *comments_orig;