本文整理汇总了PHP中CWidget::addPageHeader方法的典型用法代码示例。如果您正苦于以下问题:PHP CWidget::addPageHeader方法的具体用法?PHP CWidget::addPageHeader怎么用?PHP CWidget::addPageHeader使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类CWidget
的用法示例。
在下文中一共展示了CWidget::addPageHeader方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: period
$msg[] = _s('IT service data storage period (in days) "%1$s".', getRequest('hk_services'));
$msg[] = _s('Audit data storage period (in days) "%1$s".', getRequest('hk_audit'));
$msg[] = _s('User session data storage period (in days) "%1$s".', getRequest('hk_sessions'));
$msg[] = _s('History data storage period (in days) "%1$s".', getRequest('hk_history'));
$msg[] = _s('Trend data storage period (in days) "%1$s".', getRequest('hk_trends'));
add_audit(AUDIT_ACTION_UPDATE, AUDIT_RESOURCE_ZABBIX_CONFIG, implode('; ', $msg));
}
DBend($result);
}
$form = new CForm();
$form->cleanItems();
$cmbConf = new CComboBox('configDropDown', 'adm.housekeeper.php', 'redirect(this.options[this.selectedIndex].value);');
$cmbConf->addItems(array('adm.gui.php' => _('GUI'), 'adm.housekeeper.php' => _('Housekeeping'), 'adm.images.php' => _('Images'), 'adm.iconmapping.php' => _('Icon mapping'), 'adm.regexps.php' => _('Regular expressions'), 'adm.macros.php' => _('Macros'), 'adm.valuemapping.php' => _('Value mapping'), 'adm.workingtime.php' => _('Working time'), 'adm.triggerseverities.php' => _('Trigger severities'), 'adm.triggerdisplayoptions.php' => _('Trigger displaying options'), 'adm.other.php' => _('Other')));
$form->addItem($cmbConf);
$cnf_wdgt = new CWidget(null, 'hk');
$cnf_wdgt->addPageHeader(_('CONFIGURATION OF HOUSEKEEPING'), $form);
$data['form_refresh'] = getRequest('form_refresh', 0);
if ($data['form_refresh']) {
$data['config']['hk_events_mode'] = getRequest('hk_events_mode');
$data['config']['hk_events_trigger'] = isset($_REQUEST['hk_events_trigger']) ? getRequest('hk_events_trigger') : $data['config']['hk_events_trigger'];
$data['config']['hk_events_internal'] = isset($_REQUEST['hk_events_internal']) ? getRequest('hk_events_internal') : $data['config']['hk_events_internal'];
$data['config']['hk_events_discovery'] = isset($_REQUEST['hk_events_discovery']) ? getRequest('hk_events_discovery') : $data['config']['hk_events_discovery'];
$data['config']['hk_events_autoreg'] = isset($_REQUEST['hk_events_autoreg']) ? getRequest('hk_events_autoreg') : $data['config']['hk_events_autoreg'];
$data['config']['hk_services_mode'] = getRequest('hk_services_mode');
$data['config']['hk_services'] = isset($_REQUEST['hk_services']) ? getRequest('hk_services') : $data['config']['hk_services'];
$data['config']['hk_audit_mode'] = getRequest('hk_audit_mode');
$data['config']['hk_audit'] = isset($_REQUEST['hk_audit']) ? getRequest('hk_audit') : $data['config']['hk_audit'];
$data['config']['hk_sessions_mode'] = getRequest('hk_sessions_mode');
$data['config']['hk_sessions'] = isset($_REQUEST['hk_sessions']) ? getRequest('hk_sessions') : $data['config']['hk_sessions'];
$data['config']['hk_history_mode'] = getRequest('hk_history_mode');
$data['config']['hk_history_global'] = getRequest('hk_history_global');
示例2: CCol
$row->addItem(new CCol(SPACE, getSeverityStyle($i)));
}
$col = new CTable('', 'blink overview-mon-severities');
$col->addRow($row);
// double div necassary for FireFox
$col = new CCol(new CDiv(new CDiv($col), 'overview-mon-severities-container'));
$hintTable->addRow(array($col, _s('Age less than %s', convertUnitsS($config['blink_period']))));
}
$hintTable->addRow(array(new CCol(SPACE), _('No trigger')));
} else {
$hintTable->addRow(array(new CCol(SPACE), _('OK or no trigger')));
}
$help = new CHelp('web.view.php', 'right');
$help->setHint($hintTable, '', '', true, false);
// header right
$overviewWidget->addPageHeader(_('OVERVIEW'), array(get_icon('fullscreen', array('fullscreen' => $this->data['fullscreen'])), SPACE, $help));
// header left
$styleComboBox = new CComboBox('view_style', $this->data['view_style'], 'submit()');
$styleComboBox->addItem(STYLE_TOP, _('Top'));
$styleComboBox->addItem(STYLE_LEFT, _('Left'));
$hostLocationForm = new CForm('get');
$hostLocationForm->addVar('groupid', $this->data['groupid']);
$hostLocationForm->additem(array(_('Hosts location'), SPACE, $styleComboBox));
$overviewWidget->addHeader($hostLocationForm);
if ($config['dropdown_first_entry'] || $this->data['pageFilter']->applicationsSelected || $this->data['pageFilter']->groupsSelected) {
if ($this->data['type'] == SHOW_DATA) {
$dataTable = getItemsDataOverview(array_keys($this->data['pageFilter']->hosts), $this->data['pageFilter']->application, $this->data['view_style']);
} elseif ($this->data['type'] == SHOW_TRIGGERS) {
global $page;
$dataTable = getTriggersOverview(array_keys($this->data['pageFilter']->hosts), $this->data['pageFilter']->application, $page['file'], $this->data['view_style']);
}
示例3: CWidget
** 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.
**/
$itemsWidget = new CWidget();
$discoveryRule = $this->data['discovery_rule'];
// create new item button
$createForm = new CForm('get');
$createForm->cleanItems();
$createForm->addVar('parent_discoveryid', $this->data['parent_discoveryid']);
$createForm->addItem(new CSubmit('form', _('Create host prototype')));
$itemsWidget->addPageHeader(_('CONFIGURATION OF HOST PROTOTYPES'), $createForm);
// header
$itemsWidget->addHeader(array(_('Host prototypes of') . SPACE, new CSpan($this->data['discovery_rule']['name'], 'parent-discovery')));
$itemsWidget->addHeaderRowNumber();
$itemsWidget->addItem(get_header_host_table('hosts', $discoveryRule['hostid'], $this->data['parent_discoveryid']));
// create form
$itemForm = new CForm();
$itemForm->setName('hosts');
$itemForm->addVar('parent_discoveryid', $this->data['parent_discoveryid']);
// create table
$hostTable = new CTableInfo(_('No host prototypes found.'));
$sortLink = new CUrl();
$sortLink->setArgument('parent_discoveryid', $this->data['parent_discoveryid']);
$sortLink = $sortLink->getUrl();
$hostTable->setHeader(array(new CCheckBox('all_hosts', null, "checkAll('" . $itemForm->getName() . "', 'all_hosts', 'group_hostid');"), make_sorting_header(_('Name'), 'name', $sortLink), _('Templates'), make_sorting_header(_('Status'), 'status', $sortLink)));
foreach ($this->data['hostPrototypes'] as $hostPrototype) {
示例4: dirname
<?php
/*
** Zabbix
** Copyright (C) 2001-2014 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.
**/
require_once dirname(__FILE__) . '/include/config.inc.php';
require_once dirname(__FILE__) . '/include/blocks.inc.php';
$page['title'] = _('Status of Zabbix');
$page['file'] = 'report1.php';
$page['hist_arg'] = array();
require_once dirname(__FILE__) . '/include/page_header.php';
$reportWidget = new CWidget();
$reportWidget->addPageHeader(_('STATUS OF ZABBIX'));
$reportWidget->addItem(make_status_of_zbx());
$reportWidget->show();
require_once dirname(__FILE__) . '/include/page_footer.php';
示例5: CWidget
** 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.
**/
$usersWidget = new CWidget();
// append page header to widget
$createForm = new CForm('get');
$createForm->cleanItems();
$configurationComboBox = new CComboBox('config', 'users.php', 'javascript: redirect(this.options[this.selectedIndex].value);');
$configurationComboBox->addItem('usergrps.php', _('User groups'));
$configurationComboBox->addItem('users.php', _('Users'));
$createForm->addItem(array($configurationComboBox, new CSubmit('form', _('Create user'))));
$usersWidget->addPageHeader(_('CONFIGURATION OF USERS'), $createForm);
// append form header to widget
$userGroupListForm = new CForm('get');
$userGroupComboBox = new CComboBox('filter_usrgrpid', $_REQUEST['filter_usrgrpid'], 'submit()');
$userGroupComboBox->addItem(0, _('All'));
foreach ($this->data['userGroups'] as $userGroup) {
$userGroupComboBox->addItem($userGroup['usrgrpid'], $userGroup['name']);
}
$userGroupListForm->addItem(array(_('User group') . SPACE, $userGroupComboBox));
$usersWidget->addHeader(_('Users'), $userGroupListForm);
$usersWidget->addHeaderRowNumber();
// create form
$usersForm = new CForm();
$usersForm->setName('userForm');
// create users table
$usersTable = new CTableInfo(_('No users found.'));
示例6: CWidget
**
** 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.
**/
$discoveryWidget = new CWidget();
// create new discovery rule button
$createForm = new CForm('get');
$createForm->cleanItems();
$createForm->addItem(new CSubmit('form', _('Create discovery rule')));
$discoveryWidget->addPageHeader(_('CONFIGURATION OF DISCOVERY RULES'), $createForm);
$discoveryWidget->addHeader(_('Discovery rules'));
$discoveryWidget->addHeaderRowNumber();
// create form
$discoveryForm = new CForm();
$discoveryForm->setName('druleForm');
// create table
$discoveryTable = new CTableInfo(_('No discovery rules found.'));
$discoveryTable->setHeader(array(new CCheckBox('all_drules', null, "checkAll('" . $discoveryForm->getName() . "', 'all_drules', 'g_druleid');"), make_sorting_header(_('Name'), 'name', $this->data['sort'], $this->data['sortorder']), _('IP range'), _('Delay'), _('Checks'), _('Status')));
foreach ($data['drules'] as $drule) {
array_push($drule['description'], new CLink($drule['name'], '?form=update&druleid=' . $drule['druleid']));
$status = new CCol(new CLink(discovery_status2str($drule['status']), '?g_druleid[]=' . $drule['druleid'] . '&action=' . ($drule['status'] == DRULE_STATUS_ACTIVE ? 'drule.massdisable' : 'drule.massenable'), discovery_status2style($drule['status'])));
$discoveryTable->addRow(array(new CCheckBox('g_druleid[' . $drule['druleid'] . ']', null, null, $drule['druleid']), $drule['description'], $drule['iprange'], $drule['delay'], !empty($drule['checks']) ? implode(', ', $drule['checks']) : '', $status));
}
// create go buttons
$goComboBox = new CComboBox('action');
示例7: array
$page['hist_arg'] = array('period');
require_once dirname(__FILE__) . '/include/page_header.php';
// VAR TYPE OPTIONAL FLAGS VALIDATION EXCEPTION
$fields = array('period' => array(T_ZBX_STR, O_OPT, P_SYS | P_NZERO, IN('"day","week","month","year"'), NULL));
check_fields($fields);
$rprt_wdgt = new CWidget();
$_REQUEST['period'] = getRequest('period', 'day');
$admin_links = CWebUser::$data['type'] == USER_TYPE_ZABBIX_ADMIN || CWebUser::$data['type'] == USER_TYPE_SUPER_ADMIN;
$form = new CForm('get');
$cmbPeriod = new CComboBox('period', $_REQUEST['period'], 'submit()');
$cmbPeriod->addItem('day', _('Day'));
$cmbPeriod->addItem('week', _('Week'));
$cmbPeriod->addItem('month', _('Month'));
$cmbPeriod->addItem('year', _('Year'));
$form->addItem($cmbPeriod);
$rprt_wdgt->addPageHeader(_('MOST BUSY TRIGGERS TOP 100'));
$rprt_wdgt->addHeader(_('Report'), $form);
$rprt_wdgt->addItem(BR());
$table = new CTableInfo(_('No triggers found.'));
$table->setHeader(array(_('Host'), _('Trigger'), _('Severity'), _('Number of status changes')));
switch ($_REQUEST['period']) {
case 'week':
$time_dif = SEC_PER_WEEK;
break;
case 'month':
$time_dif = SEC_PER_MONTH;
break;
case 'year':
$time_dif = SEC_PER_YEAR;
break;
case 'day':
示例8: CWidget
**
** 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.
**/
$maintenanceWidget = new CWidget();
// create new maintenance button
$createForm = new CForm('get');
$createForm->cleanItems();
$createForm->addItem(new CSubmit('form', _('Create maintenance period')));
$maintenanceWidget->addPageHeader(_('CONFIGURATION OF MAINTENANCE PERIODS'), $createForm);
// header
$filterForm = new CForm('get');
$filterForm->addItem(array(_('Group') . SPACE, $this->data['pageFilter']->getGroupsCB(true)));
$maintenanceWidget->addHeader(_('Maintenance periods'), $filterForm);
$maintenanceWidget->addHeaderRowNumber();
// create form
$maintenanceForm = new CForm();
$maintenanceForm->setName('maintenanceForm');
// create table
$maintenanceTable = new CTableInfo(_('No maintenance periods found.'));
$maintenanceTable->setHeader(array(new CCheckBox('all_maintenances', null, "checkAll('" . $maintenanceForm->getName() . "', 'all_maintenances', 'maintenanceids');"), $this->data['displayNodes'] ? _('Node') : null, make_sorting_header(_('Name'), 'name'), make_sorting_header(_('Type'), 'maintenance_type'), _('State'), _('Description')));
foreach ($this->data['maintenances'] as $maintenance) {
$maintenanceid = $maintenance['maintenanceid'];
switch ($maintenance['status']) {
case MAINTENANCE_STATUS_EXPIRED:
示例9: dirname
** 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.
**/
require_once dirname(__FILE__) . '/js/configuration.slideconf.edit.js.php';
$slideWidget = new CWidget();
$slideWidget->addPageHeader(_('CONFIGURATION OF SLIDE SHOWS'));
// create form
$slideForm = new CForm();
$slideForm->setName('slideForm');
$slideForm->addVar('form', $this->data['form']);
$slideForm->addVar('slides', $this->data['slides_without_delay']);
if (!empty($this->data['slideshowid'])) {
$slideForm->addVar('slideshowid', $this->data['slideshowid']);
}
// create slide form list
$slideFormList = new CFormList('slideFormList');
$slideFormList->addRow(_('Name'), new CTextBox('name', $this->data['name'], ZBX_TEXTBOX_STANDARD_SIZE));
$slideFormList->addRow(_('Default delay (in seconds)'), new CNumericBox('delay', $this->data['delay'], 5, 'no', false, false));
// append slide table
$slideTable = new CTableInfo(_('No slides defined.'), 'formElementTable');
$slideTable->setAttribute('style', 'min-width: 500px;');
示例10: CWidget
break;
}
}
}
}
// --------
if (isset($_REQUEST['filter_set']) || isset($_REQUEST['filter_rst'])) {
CProfile::update('web.events.filter.triggerid', $_REQUEST['triggerid'], PROFILE_TYPE_ID);
CProfile::update('web.events.filter.hide_unknown', $_REQUEST['hide_unknown'], PROFILE_TYPE_INT);
}
// --------------
CProfile::update('web.events.source', $source, PROFILE_TYPE_INT);
$events_wdgt = new CWidget();
// PAGE HEADER {{{
$fs_icon = get_icon('fullscreen', array('fullscreen' => $_REQUEST['fullscreen']));
$events_wdgt->addPageHeader(array(S_HISTORY_OF_EVENTS_BIG . SPACE . S_ON_BIG . SPACE, zbx_date2str(S_EVENTS_DATE_FORMAT, time())), $fs_icon);
// }}}PAGE HEADER
// HEADER {{{
$r_form = new CForm(null, 'get');
$r_form->addVar('fullscreen', $_REQUEST['fullscreen']);
$r_form->addVar('triggerid', get_request('triggerid'));
$r_form->addVar('stime', get_request('stime'));
$r_form->addVar('period', get_request('period'));
if (EVENT_SOURCE_TRIGGERS == $source) {
$options = array('groups' => array('monitored_hosts' => 1, 'with_items' => 1), 'hosts' => array('monitored_hosts' => 1, 'with_items' => 1), 'triggers' => array(), 'hostid' => get_request('hostid', null), 'groupid' => get_request('groupid', null), 'triggerid' => get_request('triggerid', null));
$pageFilter = new CPageFilter($options);
$_REQUEST['groupid'] = $pageFilter->groupid;
$_REQUEST['hostid'] = $pageFilter->hostid;
if ($pageFilter->triggerid > 0) {
$_REQUEST['triggerid'] = $pageFilter->triggerid;
}
示例11: CWidget
** 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.
**/
$mediaTypeWidget = new CWidget();
$mediaTypeWidget->addPageHeader(_('CONFIGURATION OF MEDIA TYPES'));
// create form
$mediaTypeForm = new CForm();
$mediaTypeForm->setName('mediaTypeForm');
$mediaTypeForm->addVar('form', $this->data['form']);
$mediaTypeForm->addVar('mediatypeid', $this->data['mediatypeid']);
// create form list
$mediaTypeFormList = new CFormList('mediaTypeFormList');
$nameTextBox = new CTextBox('description', $this->data['description'], ZBX_TEXTBOX_STANDARD_SIZE, false, 100);
$nameTextBox->attr('autofocus', 'autofocus');
$mediaTypeFormList->addRow(_('Name'), $nameTextBox);
// append type to form list
$cmbType = new CComboBox('type', $this->data['type'], 'submit()');
$cmbType->addItems(array(MEDIA_TYPE_EMAIL => _('Email'), MEDIA_TYPE_EXEC => _('Script'), MEDIA_TYPE_SMS => _('SMS'), MEDIA_TYPE_JABBER => _('Jabber')));
$cmbType->addItemsInGroup(_('Commercial'), array(MEDIA_TYPE_EZ_TEXTING => _('Ez Texting')));
$cmbTypeRow = array($cmbType);
示例12: dirname
require_once dirname(__FILE__) . '/include/page_footer.php';
exit;
}
$options = array('groups' => array('real_hosts' => 1), 'groupid' => get_request('groupid', null));
$pageFilter = new CPageFilter($options);
$_REQUEST['groupid'] = $pageFilter->groupid;
$_REQUEST['hostid'] = get_request('hostid', 0);
// permission check, imo should be removed in future.
if ($_REQUEST['hostid'] > 0) {
$res = API::Host()->get(array('real_hosts' => 1, 'hostids' => $_REQUEST['hostid']));
if (empty($res)) {
access_deny();
}
}
$hostinvent_wdgt = new CWidget();
$hostinvent_wdgt->addPageHeader(_('HOST INVENTORIES'));
// host details
if ($_REQUEST['hostid'] > 0) {
$hostinvent_wdgt->addItem(insert_host_inventory_form());
} else {
$r_form = new CForm('get');
$r_form->addItem(array(_('Group'), SPACE, $pageFilter->getGroupsCB(true)));
$hostinvent_wdgt->addHeader(_('Hosts'), $r_form);
// HOST INVENTORY FILTER {{{
if (isset($_REQUEST['filter_set'])) {
$_REQUEST['filter_field'] = get_request('filter_field');
$_REQUEST['filter_field_value'] = get_request('filter_field_value');
$_REQUEST['filter_exact'] = get_request('filter_exact');
CProfile::update('web.hostinventories.filter_field', $_REQUEST['filter_field'], PROFILE_TYPE_STR);
CProfile::update('web.hostinventories.filter_field_value', $_REQUEST['filter_field_value'], PROFILE_TYPE_STR);
CProfile::update('web.hostinventories.filter_exact', $_REQUEST['filter_exact'], PROFILE_TYPE_INT);
示例13: dirname
** 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.
**/
require_once dirname(__FILE__) . '/js/monitoring.triggerComment.js.php';
$commentWidget = new CWidget('triggerComment');
$commentWidget->addPageHeader(_('TRIGGER DESCRIPTION'));
// create form
$commentForm = new CForm();
$commentForm->setName('commentForm');
$commentForm->addVar('triggerid', $this->data['triggerid']);
// create form list
$commentFormList = new CFormList('commentFormList');
$commentTextArea = new CTextArea('comments', CMacrosResolverHelper::resolveTriggerDescription($this->data['trigger']), array('rows' => 25, 'width' => ZBX_TEXTAREA_BIG_WIDTH, 'readonly' => $this->data['isCommentExist']));
$commentTextArea->attr('autofocus', 'autofocus');
$commentFormList->addRow(_('Description'), $commentTextArea);
// append tabs to form
$commentTab = new CTabView();
$commentTab->addTab('commentTab', _s('Description for "%s".', $this->data['trigger']['description']), $commentFormList);
$commentForm->addItem($commentTab);
// append buttons to form
$updateButton = new CSubmit('update', _('Update'));
示例14: CWidget
** 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.
**/
include 'include/views/js/configuration.services.edit.js.php';
$servicesParentWidget = new CWidget();
$servicesParentWidget->addPageHeader(_('IT service parent'));
// create form
$servicesParentForm = new CForm();
$servicesParentForm->setName('servicesForm');
if (!empty($this->data['service'])) {
$servicesParentForm->addVar('serviceid', $this->data['service']['serviceid']);
}
// create table
$servicesParentTable = new CTableInfo();
$servicesParentTable->setHeader(array(_('Service'), _('Status calculation'), _('Trigger')));
$prefix = null;
// root
$description = new CLink(_('root'), '#', null, 'javascript:
jQuery(\'#parent_name\', window.opener.document).val(' . zbx_jsvalue(_('root')) . ');
jQuery(\'#parentname\', window.opener.document).val(' . zbx_jsvalue(_('root')) . ');
jQuery(\'#parentid\', window.opener.document).val(' . zbx_jsvalue(0) . ');
示例15: CWidget
$show_events = $_REQUEST['show_events'];
$show_severity = $_REQUEST['show_severity'];
$ack_status = $_REQUEST['ack_status'];
// --------------
validate_sort_and_sortorder('lastchange', ZBX_SORT_DOWN);
$mute = CProfile::get('web.tr_status.mute', 0);
if (isset($audio) && !$mute) {
play_sound($audio);
}
$trigg_wdgt = new CWidget();
$r_form = new CForm(null, 'get');
$r_form->addItem(array(S_GROUP . SPACE, $pageFilter->getGroupsCB(true)));
$r_form->addItem(array(SPACE . S_HOST . SPACE, $pageFilter->getHostsCB(true)));
$r_form->addVar('fullscreen', $_REQUEST['fullscreen']);
$fs_icon = get_icon('fullscreen', array('fullscreen' => $_REQUEST['fullscreen']));
$trigg_wdgt->addPageHeader(S_STATUS_OF_TRIGGERS_BIG . ' [' . date(S_DATE_FORMAT_YMDHMS) . ']', array($fs_icon));
$numrows = new CDiv();
$numrows->setAttribute('name', 'numrows');
$trigg_wdgt->addHeader(S_TRIGGERS_BIG, $r_form);
$trigg_wdgt->addHeader($numrows);
/************************* FILTER **************************/
/***********************************************************/
$filterForm = new CFormTable(null, null, 'get');
//,'tr_status.php?filter_set=1','POST',null,'sform');
$filterForm->setAttribute('name', 'zbx_filter');
$filterForm->setAttribute('id', 'zbx_filter');
$filterForm->addVar('fullscreen', $_REQUEST['fullscreen']);
$filterForm->addVar('groupid', $_REQUEST['groupid']);
$filterForm->addVar('hostid', $_REQUEST['hostid']);
$tr_select = new CComboBox('show_triggers', $show_triggers);
$tr_select->addItem(TRIGGERS_OPTION_ALL, S_ANY);