Source
: 'zabbix.php?action=template.list&').'filter_set=1&filter_groups%5B0%5D='.$group_id, $this->page->getCurrentUrl()
<?php
/*
** Copyright (C) 2001-2025 Zabbix SIA
**
** This program is free software: you can redistribute it and/or modify it under the terms of
** the GNU Affero General Public License as published by the Free Software Foundation, version 3.
**
** 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 Affero General Public License for more details.
**
** You should have received a copy of the GNU Affero General Public License along with this program.
** If not, see <https://www.gnu.org/licenses/>.
**/
require_once dirname(__FILE__).'/../../include/CWebTest.php';
require_once dirname(__FILE__).'/../behaviors/CMessageBehavior.php';
require_once dirname(__FILE__).'/../behaviors/CTableBehavior.php';
/**
* Base class for Host and Template groups page.
*/
class testPageGroups extends CWebTest {
/**
* Attach MessageBehavior and TableBehavior to the test.
*
* @return array
*/
public function getBehaviors() {
return [
CMessageBehavior::class,
CTableBehavior::class
];
}
/**
* Objects created in dataSource DiscoveredHosts.
*/
const DISCOVERED_GROUP = 'Group created from host prototype 1';
const DISCOVERED_GROUP2 = 'Group created from host prototype 11';
const HOST_PROTOTYPE = 'Host created from host prototype {#KEY}';
const LLD = 'LLD for Discovered host tests';
/**
* Objects created in dataSource HostTemplateGroups.
*/
const DELETE_ONE_GROUP = 'One group belongs to one object for Delete test';
const DELETE_EMPTY_GROUP = 'Group empty for Delete test';
const DELETE_GROUP2 = 'First group to one object for Delete test';
/**
* The group was created in host/template page test for multiple group deletion.
*/
const DELETE_GROUP3 = 'Group 3 for Delete test';
/**
* SQL query to get groups to compare hash values.
*/
const GROUPS_SQL = 'SELECT * FROM hstgrp g INNER JOIN hosts_groups hg ON g.groupid=hg.groupid'.
' ORDER BY g.groupid, hg.hostgroupid';