• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP Notepad类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了PHP中Notepad的典型用法代码示例。如果您正苦于以下问题:PHP Notepad类的具体用法?PHP Notepad怎么用?PHP Notepad使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



在下文中一共展示了Notepad类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。

示例1: loadModel

 public function loadModel($id)
 {
     if (($model = Notepad::model()->findByPk($id)) === null) {
         throw new CHttpException(404, 'Страница не найдена');
     }
     return $model;
 }
开发者ID:kuzmina-mariya,项目名称:happy-end,代码行数:7,代码来源:NotepadBackendController.php


示例2: PluginTasklistsTask

     
This file is part of Tasklists.

Tasklists 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.

Tasklists 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 Tasklists. If not, see <http://www.gnu.org/licenses/>.
--------------------------------------------------------------------------
*/
include '../../../inc/includes.php';
if (!isset($_GET["id"])) {
    $_GET["id"] = "";
}
if (!isset($_GET["withtemplate"])) {
    $_GET["withtemplate"] = "";
}
Html::header(PluginTasklistsTask::getTypeName(2), '', "helpdesk", "plugintasklistsmenu");
$task = new PluginTasklistsTask();
$task->checkGlobal(READ);
$task->getFromDB($_GET['id']);
$note = new Notepad();
$note->showForItem($task);
Html::footer();
开发者ID:InfotelGLPI,项目名称:tasklists,代码行数:30,代码来源:comment.form.php


示例3: getSearchOptions


//.........这里部分代码省略.........
     $tab[4]['field'] = 'name';
     $tab[4]['name'] = __('Type');
     $tab[4]['datatype'] = 'dropdown';
     $tab[40]['table'] = 'glpi_phonemodels';
     $tab[40]['field'] = 'name';
     $tab[40]['name'] = __('Model');
     $tab[40]['datatype'] = 'dropdown';
     $tab[31]['table'] = 'glpi_states';
     $tab[31]['field'] = 'completename';
     $tab[31]['name'] = __('Status');
     $tab[31]['datatype'] = 'dropdown';
     $tab[31]['condition'] = "`is_visible_phone`";
     $tab[5]['table'] = $this->getTable();
     $tab[5]['field'] = 'serial';
     $tab[5]['name'] = __('Serial number');
     $tab[5]['datatype'] = 'string';
     $tab[6]['table'] = $this->getTable();
     $tab[6]['field'] = 'otherserial';
     $tab[6]['name'] = __('Inventory number');
     $tab[6]['datatype'] = 'string';
     $tab[7]['table'] = $this->getTable();
     $tab[7]['field'] = 'contact';
     $tab[7]['name'] = __('Alternate username');
     $tab[7]['datatype'] = 'string';
     $tab[8]['table'] = $this->getTable();
     $tab[8]['field'] = 'contact_num';
     $tab[8]['name'] = __('Alternate username number');
     $tab[8]['datatype'] = 'string';
     $tab[9]['table'] = $this->getTable();
     $tab[9]['field'] = 'number_line';
     $tab[9]['name'] = _x('quantity', 'Number of lines');
     $tab[9]['datatype'] = 'string';
     $tab[70]['table'] = 'glpi_users';
     $tab[70]['field'] = 'name';
     $tab[70]['name'] = __('User');
     $tab[70]['datatype'] = 'dropdown';
     $tab[70]['right'] = 'all';
     $tab[71]['table'] = 'glpi_groups';
     $tab[71]['field'] = 'completename';
     $tab[71]['name'] = __('Group');
     $tab[71]['condition'] = '`is_itemgroup`';
     $tab[71]['datatype'] = 'dropdown';
     $tab[19]['table'] = $this->getTable();
     $tab[19]['field'] = 'date_mod';
     $tab[19]['name'] = __('Last update');
     $tab[19]['datatype'] = 'datetime';
     $tab[19]['massiveaction'] = false;
     $tab[16]['table'] = $this->getTable();
     $tab[16]['field'] = 'comment';
     $tab[16]['name'] = __('Comments');
     $tab[16]['datatype'] = 'text';
     $tab[11]['table'] = $this->getTable();
     $tab[11]['field'] = 'brand';
     $tab[11]['name'] = __('Brand');
     $tab[11]['datatype'] = 'string';
     $tab[23]['table'] = 'glpi_manufacturers';
     $tab[23]['field'] = 'name';
     $tab[23]['name'] = __('Manufacturer');
     $tab[23]['datatype'] = 'dropdown';
     $tab[32]['table'] = $this->getTable();
     $tab[32]['field'] = 'firmware';
     $tab[32]['name'] = __('Firmware');
     $tab[32]['datatype'] = 'string';
     $tab[24]['table'] = 'glpi_users';
     $tab[24]['field'] = 'name';
     $tab[24]['linkfield'] = 'users_id_tech';
     $tab[24]['name'] = __('Technician in charge of the hardware');
     $tab[24]['datatype'] = 'dropdown';
     $tab[24]['right'] = 'own_ticket';
     $tab[49]['table'] = 'glpi_groups';
     $tab[49]['field'] = 'completename';
     $tab[49]['linkfield'] = 'groups_id_tech';
     $tab[49]['name'] = __('Group in charge of the hardware');
     $tab[49]['condition'] = '`is_assign`';
     $tab[49]['datatype'] = 'dropdown';
     $tab[42]['table'] = 'glpi_phonepowersupplies';
     $tab[42]['field'] = 'name';
     $tab[42]['name'] = __('Power supply');
     $tab[42]['datatype'] = 'dropdown';
     $tab[43]['table'] = $this->getTable();
     $tab[43]['field'] = 'have_headset';
     $tab[43]['name'] = __('Headset');
     $tab[43]['datatype'] = 'bool';
     $tab[44]['table'] = $this->getTable();
     $tab[44]['field'] = 'have_hp';
     $tab[44]['name'] = __('Speaker');
     $tab[44]['datatype'] = 'bool';
     $tab[80]['table'] = 'glpi_entities';
     $tab[80]['field'] = 'completename';
     $tab[80]['name'] = __('Entity');
     $tab[80]['massiveaction'] = false;
     $tab[80]['datatype'] = 'dropdown';
     $tab[82]['table'] = $this->getTable();
     $tab[82]['field'] = 'is_global';
     $tab[82]['name'] = __('Global management');
     $tab[82]['datatype'] = 'bool';
     $tab[82]['massiveaction'] = false;
     $tab += Notepad::getSearchOptionsToAdd();
     return $tab;
 }
开发者ID:paisdelconocimiento,项目名称:glpi-smartcities,代码行数:101,代码来源:phone.class.php


示例4: getSearchOptions


//.........这里部分代码省略.........
     $tab[19]['name'] = __('Last update');
     $tab[19]['datatype'] = 'datetime';
     $tab[19]['massiveaction'] = false;
     $tab[32]['table'] = 'glpi_networks';
     $tab[32]['field'] = 'name';
     $tab[32]['name'] = __('Network');
     $tab[32]['datatype'] = 'dropdown';
     $tab[33]['table'] = 'glpi_domains';
     $tab[33]['field'] = 'name';
     $tab[33]['name'] = __('Domain');
     $tab[33]['datatype'] = 'dropdown';
     $tab[23]['table'] = 'glpi_manufacturers';
     $tab[23]['field'] = 'name';
     $tab[23]['name'] = __('Manufacturer');
     $tab[23]['datatype'] = 'dropdown';
     $tab[24]['table'] = 'glpi_users';
     $tab[24]['field'] = 'name';
     $tab[24]['linkfield'] = 'users_id_tech';
     $tab[24]['name'] = __('Technician in charge of the hardware');
     $tab[24]['datatype'] = 'dropdown';
     $tab[24]['right'] = 'own_ticket';
     $tab[49]['table'] = 'glpi_groups';
     $tab[49]['field'] = 'completename';
     $tab[49]['linkfield'] = 'groups_id_tech';
     $tab[49]['name'] = __('Group in charge of the hardware');
     $tab[49]['condition'] = '`is_assign`';
     $tab[49]['datatype'] = 'dropdown';
     $tab[80]['table'] = 'glpi_entities';
     $tab[80]['field'] = 'completename';
     $tab[80]['name'] = __('Entity');
     $tab[80]['datatype'] = 'dropdown';
     // add objectlock search options
     $tab += ObjectLock::getSearchOptionsToAdd(get_class($this));
     $tab += Notepad::getSearchOptionsToAdd();
     $tab['periph'] = _n('Component', 'Components', Session::getPluralNumber());
     $items_device_joinparams = array('jointype' => 'itemtype_item', 'specific_itemtype' => 'Computer');
     $tab[17]['table'] = 'glpi_deviceprocessors';
     $tab[17]['field'] = 'designation';
     $tab[17]['name'] = __('Processor');
     $tab[17]['forcegroupby'] = true;
     $tab[17]['usehaving'] = true;
     $tab[17]['massiveaction'] = false;
     $tab[17]['datatype'] = 'string';
     $tab[17]['joinparams'] = array('beforejoin' => array('table' => 'glpi_items_deviceprocessors', 'joinparams' => $items_device_joinparams));
     $tab[36]['table'] = 'glpi_items_deviceprocessors';
     $tab[36]['field'] = 'frequency';
     $tab[36]['name'] = __('Processor frequency');
     $tab[36]['unit'] = __('MHz');
     $tab[36]['forcegroupby'] = true;
     $tab[36]['usehaving'] = true;
     $tab[36]['datatype'] = 'number';
     $tab[36]['width'] = 100;
     $tab[36]['massiveaction'] = false;
     $tab[36]['joinparams'] = $items_device_joinparams;
     $tab[36]['computation'] = "SUM(TABLE.`frequency`) / COUNT(TABLE.`id`)";
     $tab[10]['table'] = 'glpi_devicememories';
     $tab[10]['field'] = 'designation';
     $tab[10]['name'] = __('Memory type');
     $tab[10]['forcegroupby'] = true;
     $tab[10]['usehaving'] = true;
     $tab[10]['massiveaction'] = false;
     $tab[10]['datatype'] = 'string';
     $tab[10]['joinparams'] = array('beforejoin' => array('table' => 'glpi_items_devicememories', 'joinparams' => $items_device_joinparams));
     $tab[35]['table'] = 'glpi_items_devicememories';
     $tab[35]['field'] = 'size';
     $tab[35]['unit'] = __('Mio');
开发者ID:pvasener,项目名称:glpi,代码行数:67,代码来源:computer.class.php


示例5: getSearchOptions


//.........这里部分代码省略.........
     $tab[5]['name'] = __('Serial number');
     $tab[5]['datatype'] = 'string';
     $tab[6]['table'] = $this->getTable();
     $tab[6]['field'] = 'otherserial';
     $tab[6]['name'] = __('Inventory number');
     $tab[6]['datatype'] = 'string';
     $tab[7]['table'] = $this->getTable();
     $tab[7]['field'] = 'contact';
     $tab[7]['name'] = __('Alternate username');
     $tab[7]['datatype'] = 'string';
     $tab[8]['table'] = $this->getTable();
     $tab[8]['field'] = 'contact_num';
     $tab[8]['name'] = __('Alternate username number');
     $tab[8]['datatype'] = 'string';
     $tab[70]['table'] = 'glpi_users';
     $tab[70]['field'] = 'name';
     $tab[70]['name'] = __('User');
     $tab[70]['datatype'] = 'dropdown';
     $tab[70]['right'] = 'all';
     $tab[71]['table'] = 'glpi_groups';
     $tab[71]['field'] = 'completename';
     $tab[71]['name'] = __('Group');
     $tab[71]['condition'] = '`is_itemgroup`';
     $tab[71]['datatype'] = 'dropdown';
     $tab[19]['table'] = $this->getTable();
     $tab[19]['field'] = 'date_mod';
     $tab[19]['name'] = __('Last update');
     $tab[19]['datatype'] = 'datetime';
     $tab[19]['massiveaction'] = false;
     $tab[16]['table'] = $this->getTable();
     $tab[16]['field'] = 'comment';
     $tab[16]['name'] = __('Comments');
     $tab[16]['datatype'] = 'text';
     $tab[11]['table'] = $this->getTable();
     $tab[11]['field'] = 'size';
     $tab[11]['name'] = __('Size');
     $tab[11]['datatype'] = 'number';
     $tab[41]['table'] = $this->getTable();
     $tab[41]['field'] = 'have_micro';
     $tab[41]['name'] = __('Microphone');
     $tab[41]['datatype'] = 'bool';
     $tab[42]['table'] = $this->getTable();
     $tab[42]['field'] = 'have_speaker';
     $tab[42]['name'] = __('Speakers');
     $tab[42]['datatype'] = 'bool';
     $tab[43]['table'] = $this->getTable();
     $tab[43]['field'] = 'have_subd';
     $tab[43]['name'] = __('Sub-D');
     $tab[43]['datatype'] = 'bool';
     $tab[44]['table'] = $this->getTable();
     $tab[44]['field'] = 'have_bnc';
     $tab[44]['name'] = 'BNC';
     $tab[44]['datatype'] = 'bool';
     $tab[45]['table'] = $this->getTable();
     $tab[45]['field'] = 'have_dvi';
     $tab[45]['name'] = __('DVI');
     $tab[45]['datatype'] = 'bool';
     $tab[46]['table'] = $this->getTable();
     $tab[46]['field'] = 'have_pivot';
     $tab[46]['name'] = __('Pivot');
     $tab[46]['datatype'] = 'bool';
     $tab[47]['table'] = $this->getTable();
     $tab[47]['field'] = 'have_hdmi';
     $tab[47]['name'] = __('HDMI');
     $tab[47]['datatype'] = 'bool';
     $tab[48]['table'] = $this->getTable();
     $tab[48]['field'] = 'have_displayport';
     $tab[48]['name'] = __('DisplayPort');
     $tab[48]['datatype'] = 'bool';
     $tab[23]['table'] = 'glpi_manufacturers';
     $tab[23]['field'] = 'name';
     $tab[23]['name'] = __('Manufacturer');
     $tab[23]['datatype'] = 'dropdown';
     $tab[24]['table'] = 'glpi_users';
     $tab[24]['field'] = 'name';
     $tab[24]['linkfield'] = 'users_id_tech';
     $tab[24]['name'] = __('Technician in charge of the hardware');
     $tab[24]['datatype'] = 'dropdown';
     $tab[24]['right'] = 'own_ticket';
     $tab[49]['table'] = 'glpi_groups';
     $tab[49]['field'] = 'completename';
     $tab[49]['linkfield'] = 'groups_id_tech';
     $tab[49]['name'] = __('Group in charge of the hardware');
     $tab[49]['condition'] = '`is_assign`';
     $tab[49]['datatype'] = 'dropdown';
     $tab[80]['table'] = 'glpi_entities';
     $tab[80]['field'] = 'completename';
     $tab[80]['name'] = __('Entity');
     $tab[80]['massiveaction'] = false;
     $tab[80]['datatype'] = 'dropdown';
     $tab[82]['table'] = $this->getTable();
     $tab[82]['field'] = 'is_global';
     $tab[82]['name'] = __('Global management');
     $tab[82]['datatype'] = 'bool';
     $tab[82]['massiveaction'] = false;
     // add objectlock search options
     $tab += ObjectLock::getSearchOptionsToAdd(get_class($this));
     $tab += Notepad::getSearchOptionsToAdd();
     return $tab;
 }
开发者ID:pvasener,项目名称:glpi,代码行数:101,代码来源:monitor.class.php


示例6: getSearchOptions


//.........这里部分代码省略.........
     $tab[42]['field'] = 'have_serial';
     $tab[42]['name'] = __('Serial');
     $tab[42]['datatype'] = 'bool';
     $tab[43]['table'] = $this->getTable();
     $tab[43]['field'] = 'have_parallel';
     $tab[43]['name'] = __('Parallel');
     $tab[43]['datatype'] = 'bool';
     $tab[44]['table'] = $this->getTable();
     $tab[44]['field'] = 'have_usb';
     $tab[44]['name'] = __('USB');
     $tab[44]['datatype'] = 'bool';
     $tab[45]['table'] = $this->getTable();
     $tab[45]['field'] = 'have_ethernet';
     $tab[45]['name'] = __('Ethernet');
     $tab[45]['datatype'] = 'bool';
     $tab[46]['table'] = $this->getTable();
     $tab[46]['field'] = 'have_wifi';
     $tab[46]['name'] = __('Wifi');
     $tab[46]['datatype'] = 'bool';
     $tab[13]['table'] = $this->getTable();
     $tab[13]['field'] = 'memory_size';
     $tab[13]['name'] = __('Memory');
     $tab[13]['datatype'] = 'string';
     $tab[11]['table'] = $this->getTable();
     $tab[11]['field'] = 'init_pages_counter';
     $tab[11]['name'] = __('Initial page counter');
     $tab[11]['datatype'] = 'number';
     $tab[11]['nosearch'] = true;
     // only display and histo, no index
     $tab[12]['table'] = $this->getTable();
     $tab[12]['field'] = 'last_pages_counter';
     $tab[12]['name'] = __('Current counter of pages');
     $tab[12]['datatype'] = 'number';
     $tab[9]['table'] = 'glpi_printers';
     $tab[9]['field'] = '_virtual';
     $tab[9]['linkfield'] = '_virtual';
     $tab[9]['name'] = _n('Cartridge', 'Cartridges', Session::getPluralNumber());
     $tab[9]['datatype'] = 'specific';
     $tab[9]['massiveaction'] = false;
     $tab[9]['nosearch'] = true;
     $tab[9]['nosort'] = true;
     $tab[17]['table'] = 'glpi_cartridges';
     $tab[17]['field'] = 'id';
     $tab[17]['name'] = __('Number of used cartridges');
     $tab[17]['datatype'] = 'count';
     $tab[17]['forcegroupby'] = true;
     $tab[17]['usehaving'] = true;
     $tab[17]['massiveaction'] = false;
     $tab[17]['joinparams'] = array('jointype' => 'child', 'condition' => "AND NEWTABLE.`date_use` IS NOT NULL\n                                                      AND NEWTABLE.`date_out` IS NULL");
     $tab[18]['table'] = 'glpi_cartridges';
     $tab[18]['field'] = 'id';
     $tab[18]['name'] = __('Number of worn cartridges');
     $tab[18]['datatype'] = 'count';
     $tab[18]['forcegroupby'] = true;
     $tab[18]['usehaving'] = true;
     $tab[18]['massiveaction'] = false;
     $tab[18]['joinparams'] = array('jointype' => 'child', 'condition' => "AND NEWTABLE.`date_out` IS NOT NULL");
     $tab[32]['table'] = 'glpi_networks';
     $tab[32]['field'] = 'name';
     $tab[32]['name'] = __('Network');
     $tab[32]['datatype'] = 'dropdown';
     $tab[33]['table'] = 'glpi_domains';
     $tab[33]['field'] = 'name';
     $tab[33]['name'] = __('Domain');
     $tab[33]['datatype'] = 'dropdown';
     $tab[23]['table'] = 'glpi_manufacturers';
     $tab[23]['field'] = 'name';
     $tab[23]['name'] = __('Manufacturer');
     $tab[23]['datatype'] = 'dropdown';
     $tab[24]['table'] = 'glpi_users';
     $tab[24]['field'] = 'name';
     $tab[24]['linkfield'] = 'users_id_tech';
     $tab[24]['name'] = __('Technician in charge of the hardware');
     $tab[24]['datatype'] = 'dropdown';
     $tab[24]['right'] = 'own_ticket';
     $tab[49]['table'] = 'glpi_groups';
     $tab[49]['field'] = 'completename';
     $tab[49]['linkfield'] = 'groups_id_tech';
     $tab[49]['name'] = __('Group in charge of the hardware');
     $tab[49]['condition'] = '`is_assign`';
     $tab[49]['datatype'] = 'dropdown';
     $tab[80]['table'] = 'glpi_entities';
     $tab[80]['field'] = 'completename';
     $tab[80]['name'] = __('Entity');
     $tab[80]['massiveaction'] = false;
     $tab[80]['datatype'] = 'dropdown';
     $tab[82]['table'] = $this->getTable();
     $tab[82]['field'] = 'is_global';
     $tab[82]['name'] = __('Global management');
     $tab[82]['datatype'] = 'bool';
     $tab[82]['massiveaction'] = false;
     $tab[86]['table'] = $this->getTable();
     $tab[86]['field'] = 'is_recursive';
     $tab[86]['name'] = __('Child entities');
     $tab[86]['datatype'] = 'bool';
     // add objectlock search options
     $tab += ObjectLock::getSearchOptionsToAdd(get_class($this));
     $tab += Notepad::getSearchOptionsToAdd();
     return $tab;
 }
开发者ID:pvasener,项目名称:glpi,代码行数:101,代码来源:printer.class.php


示例7: getSearchOptions


//.........这里部分代码省略.........
     $tab[12]['name'] = __('Expiration');
     $tab[12]['datatype'] = 'date_delay';
     $tab[12]['datafields'][1] = 'begin_date';
     $tab[12]['datafields'][2] = 'duration';
     $tab[12]['searchunit'] = 'DAY';
     $tab[12]['delayunit'] = 'MONTH';
     $tab[12]['maybefuture'] = true;
     $tab[12]['massiveaction'] = false;
     $tab[13]['table'] = $this->getTable();
     $tab[13]['field'] = 'expire_notice';
     $tab[13]['name'] = __('Expiration date + notice');
     $tab[13]['datatype'] = 'date_delay';
     $tab[13]['datafields'][1] = 'begin_date';
     $tab[13]['datafields'][2] = 'duration';
     $tab[13]['datafields'][3] = 'notice';
     $tab[13]['searchunit'] = 'DAY';
     $tab[13]['delayunit'] = 'MONTH';
     $tab[13]['maybefuture'] = true;
     $tab[13]['massiveaction'] = false;
     $tab[16]['table'] = $this->getTable();
     $tab[16]['field'] = 'comment';
     $tab[16]['name'] = __('Comments');
     $tab[16]['datatype'] = 'text';
     $tab[80]['table'] = 'glpi_entities';
     $tab[80]['field'] = 'completename';
     $tab[80]['name'] = __('Entity');
     $tab[80]['massiveaction'] = false;
     $tab[80]['datatype'] = 'dropdown';
     $tab[59]['table'] = $this->getTable();
     $tab[59]['field'] = 'alert';
     $tab[59]['name'] = __('Email alarms');
     $tab[59]['datatype'] = 'specific';
     $tab[59]['searchtype'] = array('equals', 'notequals');
     $tab[86]['table'] = $this->getTable();
     $tab[86]['field'] = 'is_recursive';
     $tab[86]['name'] = __('Child entities');
     $tab[86]['datatype'] = 'bool';
     $tab[72]['table'] = 'glpi_contracts_items';
     $tab[72]['field'] = 'id';
     $tab[72]['name'] = _x('quantity', 'Number of items');
     $tab[72]['forcegroupby'] = true;
     $tab[72]['usehaving'] = true;
     $tab[72]['datatype'] = 'count';
     $tab[72]['massiveaction'] = false;
     $tab[72]['joinparams'] = array('jointype' => 'child');
     $tab[29]['table'] = 'glpi_suppliers';
     $tab[29]['field'] = 'name';
     $tab[29]['name'] = _n('Associated supplier', 'Associated suppliers', Session::getPluralNumber());
     $tab[29]['forcegroupby'] = true;
     $tab[29]['datatype'] = 'itemlink';
     $tab[29]['massiveaction'] = false;
     $tab[29]['joinparams'] = array('beforejoin' => array('table' => 'glpi_contracts_suppliers', 'joinparams' => array('jointype' => 'child')));
     $tab += Notepad::getSearchOptionsToAdd();
     $tab['cost'] = __('Cost');
     $tab[11]['table'] = 'glpi_contractcosts';
     $tab[11]['field'] = 'totalcost';
     $tab[11]['name'] = __('Total cost');
     $tab[11]['datatype'] = 'decimal';
     $tab[11]['forcegroupby'] = true;
     $tab[11]['usehaving'] = true;
     $tab[11]['massiveaction'] = false;
     $tab[11]['joinparams'] = array('jointype' => 'child');
     $tab[11]['computation'] = "(SUM(TABLE.`cost`) / COUNT(TABLE.`id`))\n                                       * COUNT(DISTINCT TABLE.`id`)";
     $tab[41]['table'] = 'glpi_contractcosts';
     $tab[41]['field'] = 'cost';
     $tab[41]['name'] = _n('Cost', 'Costs', Session::getPluralNumber());
     $tab[41]['datatype'] = 'decimal';
     $tab[41]['forcegroupby'] = true;
     $tab[41]['massiveaction'] = false;
     $tab[41]['joinparams'] = array('jointype' => 'child');
     $tab[42]['table'] = 'glpi_contractcosts';
     $tab[42]['field'] = 'begin_date';
     $tab[42]['name'] = sprintf(__('%1$s - %2$s'), __('Cost'), __('Begin date'));
     $tab[42]['datatype'] = 'date';
     $tab[42]['forcegroupby'] = true;
     $tab[42]['massiveaction'] = false;
     $tab[42]['joinparams'] = array('jointype' => 'child');
     $tab[43]['table'] = 'glpi_contractcosts';
     $tab[43]['field'] = 'end_date';
     $tab[43]['name'] = sprintf(__('%1$s - %2$s'), __('Cost'), __('End date'));
     $tab[43]['datatype'] = 'date';
     $tab[43]['forcegroupby'] = true;
     $tab[43]['massiveaction'] = false;
     $tab[43]['joinparams'] = array('jointype' => 'child');
     $tab[44]['table'] = 'glpi_contractcosts';
     $tab[44]['field'] = 'name';
     $tab[44]['name'] = sprintf(__('%1$s - %2$s'), __('Cost'), __('Name'));
     $tab[44]['forcegroupby'] = true;
     $tab[44]['massiveaction'] = false;
     $tab[44]['joinparams'] = array('jointype' => 'child');
     $tab[44]['datatype'] = 'dropdown';
     $tab[45]['table'] = 'glpi_budgets';
     $tab[45]['field'] = 'name';
     $tab[45]['name'] = sprintf(__('%1$s - %2$s'), __('Cost'), __('Budget'));
     $tab[45]['datatype'] = 'dropdown';
     $tab[45]['forcegroupby'] = true;
     $tab[45]['massiveaction'] = false;
     $tab[45]['joinparams'] = array('beforejoin' => array('table' => 'glpi_contractcosts', 'joinparams' => array('jointype' => 'child')));
     return $tab;
 }
开发者ID:jose-martins,项目名称:glpi,代码行数:101,代码来源:contract.class.php


示例8: getSearchOptions

 function getSearchOptions()
 {
     $tab = array();
     $tab['common'] = __('Characteristics');
     $tab[1]['table'] = $this->getTable();
     $tab[1]['field'] = 'name';
     $tab[1]['name'] = __('Name');
     $tab[1]['datatype'] = 'itemlink';
     $tab[1]['massiveaction'] = false;
     $tab[2]['table'] = $this->getTable();
     $tab[2]['field'] = 'id';
     $tab[2]['name'] = __('ID');
     $tab[2]['datatype'] = 'number';
     $tab[2]['massiveaction'] = false;
     $tab[34]['table'] = $this->getTable();
     $tab[34]['field'] = 'ref';
     $tab[34]['name'] = __('Reference');
     $tab[34]['datatype'] = 'string';
     $tab[4]['table'] = 'glpi_consumableitemtypes';
     $tab[4]['field'] = 'name';
     $tab[4]['name'] = __('Type');
     $tab[4]['datatype'] = 'dropdown';
     $tab[23]['table'] = 'glpi_manufacturers';
     $tab[23]['field'] = 'name';
     $tab[23]['name'] = __('Manufacturer');
     $tab[23]['datatype'] = 'dropdown';
     $tab[9]['table'] = 'glpi_consumableitems';
     $tab[9]['field'] = '_virtual';
     $tab[9]['linkfield'] = '_virtual';
     $tab[9]['name'] = _n('Consumable', 'Consumables', Session::getPluralNumber());
     $tab[9]['datatype'] = 'specific';
     $tab[9]['massiveaction'] = false;
     $tab[9]['nosearch'] = true;
     $tab[9]['nosort'] = true;
     $tab[9]['additionalfields'] = array('alarm_threshold');
     $tab[17]['table'] = 'glpi_consumables';
     $tab[17]['field'] = 'id';
     $tab[17]['name'] = __('Number of used consumables');
     $tab[17]['datatype'] = 'count';
     $tab[17]['forcegroupby'] = true;
     $tab[17]['usehaving'] = true;
     $tab[17]['massiveaction'] = false;
     $tab[17]['joinparams'] = array('jointype' => 'child', 'condition' => "AND NEWTABLE.`date_out` IS NOT NULL");
     $tab[19]['table'] = 'glpi_consumables';
     $tab[19]['field'] = 'id';
     $tab[19]['name'] = __('Number of new consumables');
     $tab[19]['datatype'] = 'count';
     $tab[19]['forcegroupby'] = true;
     $tab[19]['usehaving'] = true;
     $tab[19]['massiveaction'] = false;
     $tab[19]['joinparams'] = array('jointype' => 'child', 'condition' => "AND NEWTABLE.`date_out` IS NULL");
     $tab += Location::getSearchOptionsToAdd();
     $tab[24]['table'] = 'glpi_users';
     $tab[24]['field'] = 'name';
     $tab[24]['linkfield'] = 'users_id_tech';
     $tab[24]['name'] = __('Technician in charge of the hardware');
     $tab[24]['datatype'] = 'dropdown';
     $tab[24]['right'] = 'own_ticket';
     $tab[49]['table'] = 'glpi_groups';
     $tab[49]['field'] = 'completename';
     $tab[49]['linkfield'] = 'groups_id_tech';
     $tab[49]['name'] = __('Group in charge of the hardware');
     $tab[49]['condition'] = '`is_assign`';
     $tab[49]['datatype'] = 'dropdown';
     $tab[8]['table'] = $this->getTable();
     $tab[8]['field'] = 'alarm_threshold';
     $tab[8]['name'] = __('Alert threshold');
     $tab[8]['datatype'] = 'number';
     $tab[8]['toadd'] = array('-1' => __('Never'));
     $tab[16]['table'] = $this->getTable();
     $tab[16]['field'] = 'comment';
     $tab[16]['name'] = __('Comments');
     $tab[16]['datatype'] = 'text';
     $tab[80]['table'] = 'glpi_entities';
     $tab[80]['field'] = 'completename';
     $tab[80]['name'] = __('Entity');
     $tab[80]['massiveaction'] = false;
     $tab[80]['datatype'] = 'dropdown';
     // add objectlock search options
     $tab += ObjectLock::getSearchOptionsToAdd(get_class($this));
     $tab += Notepad::getSearchOptionsToAdd();
     return $tab;
 }
开发者ID:stweil,项目名称:glpi,代码行数:83,代码来源:consumableitem.class.php


示例9: getSearchOptions

 function getSearchOptions()
 {
     $tab = array();
     $tab += $this->getSearchOptionsMain();
     $tab[63]['table'] = 'glpi_items_problems';
     $tab[63]['field'] = 'id';
     $tab[63]['name'] = _x('quantity', 'Number of items');
     $tab[63]['forcegroupby'] = true;
     $tab[63]['usehaving'] = true;
     $tab[63]['datatype'] = 'count';
     $tab[63]['massiveaction'] = false;
     $tab[63]['joinparams'] = array('jointype' => 'child');
     $tab[13]['table'] = 'glpi_items_problems';
     $tab[13]['field'] = 'items_id';
     $tab[13]['name'] = _n('Associated element', 'Associated elements', Session::getPluralNumber());
     $tab[13]['datatype'] = 'specific';
     $tab[13]['comments'] = true;
     $tab[13]['nosort'] = true;
     $tab[13]['nosearch'] = true;
     $tab[13]['additionalfields'] = array('itemtype');
     $tab[13]['joinparams'] = array('jointype' => 'child');
     $tab[13]['forcegroupby'] = true;
     $tab[13]['massiveaction'] = false;
     $tab[131]['table'] = 'glpi_items_problems';
     $tab[131]['field'] = 'itemtype';
     $tab[131]['name'] = _n('Associated item type', 'Associated item types', Session::getPluralNumber());
     $tab[131]['datatype'] = 'itemtypename';
     $tab[131]['itemtype_list'] = 'ticket_types';
     $tab[131]['nosort'] = true;
     $tab[131]['additionalfields'] = array('itemtype');
     $tab[131]['joinparams'] = array('jointype' => 'child');
     $tab[131]['forcegroupby'] = true;
     $tab[131]['massiveaction'] = false;
     $tab += $this->getSearchOptionsActors();
     $tab['analysis'] = __('Analysis');
     $tab[60]['table'] = $this->getTable();
     $tab[60]['field'] = 'impactcontent';
     $tab[60]['name'] = __('Impacts');
     $tab[60]['massiveaction'] = false;
     $tab[60]['datatype'] = 'text';
     $tab[61]['table'] = $this->getTable();
     $tab[61]['field'] = 'causecontent';
     $tab[61]['name'] = __('Causes');
     $tab[61]['massiveaction'] = false;
     $tab[61]['datatype'] = 'text';
     $tab[62]['table'] = $this->getTable();
     $tab[62]['field'] = 'symptomcontent';
     $tab[62]['name'] = __('Symptoms');
     $tab[62]['massiveaction'] = false;
     $tab[62]['datatype'] = 'text';
     $tab += Notepad::getSearchOptionsToAdd();
     $tab += ProblemTask::getSearchOptionsToAdd();
     $tab += $this->getSearchOptionsSolution();
     $tab += $this->getSearchOptionsStats();
     $tab += ProblemCost::getSearchOptionsToAdd();
     $tab['ticket'] = Ticket::getTypeName(Session::getPluralNumber());
     $tab[141]['table'] = 'glpi_problems_tickets';
     $tab[141]['field'] = 'id';
     $tab[141]['name'] = _x('quantity', 'Number of tickets');
     $tab[141]['forcegroupby'] = true;
     $tab[141]['usehaving'] = true;
     $tab[141]['datatype'] = 'count';
     $tab[141]['massiveaction'] = false;
     $tab[141]['joinparams'] = array('jointype' => 'child');
     return $tab;
 }
开发者ID:jose-martins,项目名称:glpi,代码行数:66,代码来源:problem.class.php


示例10: getSearchOptions


//.........这里部分代码省略.........
     $tab['common'] = __('Characteristics');
     $tab[1]['table'] = $this->getTable();
     $tab[1]['field'] = 'name';
     $tab[1]['name'] = __('Name');
     $tab[1]['datatype'] = 'itemlink';
     $tab[1]['massiveaction'] = false;
     $tab[2]['table'] = $this->getTable();
     $tab[2]['field'] = 'id';
     $tab[2]['name'] = __('ID');
     $tab[2]['massiveaction'] = false;
     $tab[2]['datatype'] = 'number';
     $tab += Location::getSearchOptionsToAdd();
     $tab[4]['table'] = 'glpi_peripheraltypes';
     $tab[4]['field'] = 'name';
     $tab[4]['name'] = __('Type');
     $tab[4]['datatype'] = 'dropdown';
     $tab[40]['table'] = 'glpi_peripheralmodels';
     $tab[40]['field'] = 'name';
     $tab[40]['name'] = __('Model');
     $tab[40]['datatype'] = 'dropdown';
     $tab[31]['table'] = 'glpi_states';
     $tab[31]['field'] = 'completename';
     $tab[31]['name'] = __('Status');
     $tab[31]['datatype'] = 'dropdown';
     $tab[31]['condition'] = "`is_visible_peripheral`";
     $tab[5]['table'] = $this->getTable();
     $tab[5]['field'] = 'serial';
     $tab[5]['name'] = __('Serial number');
     $tab[5]['datatype'] = 'string';
     $tab[6]['table'] = $this->getTable();
     $tab[6]['field'] = 'otherserial';
     $tab[6]['name'] = __('Inventory number');
     $tab[6]['datatype'] = 'string';
     $tab[7]['table'] = $this->getTable();
     $tab[7]['field'] = 'contact';
     $tab[7]['name'] = __('Alternate username');
     $tab[7]['datatype'] = 'string';
     $tab[8]['table'] = $this->getTable();
     $tab[8]['field'] = 'contact_num';
     $tab[8]['name'] = __('Alternate username number');
     $tab[8]['datatype'] = 'string';
     $tab[70]['table'] = 'glpi_users';
     $tab[70]['field'] = 'name';
     $tab[70]['name'] = __('User');
     $tab[70]['datatype'] = 'dropdown';
     $tab[70]['right'] = 'all';
     $tab[71]['table'] = 'glpi_groups';
     $tab[71]['field'] = 'completename';
     $tab[71]['name'] = __('Group');
     $tab[71]['condition'] = '`is_itemgroup`';
     $tab[71]['datatype'] = 'dropdown';
     $tab[19]['table'] = $this->getTable();
     $tab[19]['field'] = 'date_mod';
     $tab[19]['name'] = __('Last update');
     $tab[19]['datatype'] = 'datetime';
     $tab[19]['massiveaction'] = false;
     $tab[121]['table'] = $this->getTable();
     $tab[121]['field'] = 'date_creation';
     $tab[121]['name'] = __('Creation date');
     $tab[121]['datatype'] = 'datetime';
     $tab[121]['massiveaction'] = false;
     $tab[16]['table'] = $this->getTable();
     $tab[16]['field'] = 'comment';
     $tab[16]['name'] = __('Comments');
     $tab[16]['datatype'] = 'text';
     $tab[11]['table'] = $this->getTable();
     $tab[11]['field'] = 'brand';
     $tab[11]['name'] = __('Brand');
     $tab[11]['datatype'] = 'string';
     $tab[23]['table'] = 'glpi_manufacturers';
     $tab[23]['field'] = 'name';
     $tab[23]['name'] = __('Manufacturer');
     $tab[23]['datatype'] = 'dropdown';
     $tab[24]['table'] = 'glpi_users';
     $tab[24]['field'] = 'name';
     $tab[24]['linkfield'] = 'users_id_tech';
     $tab[24]['name'] = __('Technician in charge of the hardware');
     $tab[24]['datatype'] = 'dropdown';
     $tab[24]['right'] = 'own_ticket';
     $tab[49]['table'] = 'glpi_groups';
     $tab[49]['field'] = 'completename';
     $tab[49]['linkfield'] = 'groups_id_tech';
     $tab[49]['name'] = __('Group in charge of the hardware');
     $tab[49]['condition'] = '`is_assign`';
     $tab[49]['datatype'] = 'dropdown';
     $tab[80]['table'] = 'glpi_entities';
     $tab[80]['field'] = 'completename';
     $tab[80]['name'] = __('Entity');
     $tab[80]['massiveaction'] = false;
     $tab[80]['datatype'] = 'dropdown';
     $tab[82]['table'] = $this->getTable();
     $tab[82]['field'] = 'is_global';
     $tab[82]['name'] = __('Global management');
     $tab[82]['datatype'] = 'bool';
     $tab[82]['massiveaction'] = false;
     // add objectlock search options
     $tab += ObjectLock::getSearchOptionsToAdd(get_class($this));
     $tab += Notepad::getSearchOptionsToAdd();
     return $tab;
 }
开发者ID:stweil,项目名称:glpi,代码行数:101,代码来源:peripheral.class.php


示例11: cleanRelationTable

 /**
  * Clean the date in the relation tables for the deleted item
  * Clear N/N Relation
  **/
 function cleanRelationTable()
 {
     global $CFG_GLPI, $DB;
     // If this type have INFOCOM, clean one associated to purged item
     if (Infocom::canApplyOn($this)) {
         $infocom = new Infocom();
         if ($infocom->getFromDBforDevice($this->getType(), $this->fields['id'])) {
             $infocom->delete(array('id' => $infocom->fields['id']));
         }
     }
     // If this type have NETPORT, clean one associated to purged item
     if (in_array($this->getType(), $CFG_GLPI['networkport_types'])) {
         // If we don't use delete, then cleanDBonPurge() is not call and the NetworkPorts are not
         // clean properly
         $networkPortObject = new NetworkPort();
         $networkPortObject->cleanDBonItemDelete($this->getType(), $this->getID());
         // Manage networkportmigration if exists
         if (TableExists('glpi_networkportmigrations')) {
             $networkPortMigObject = new NetworkPortMigration();
             $networkPortMigObject->cleanDBonItemDelete($this->getType(), $this->getID());
         }
     }
     // If this type is RESERVABLE clean one associated to purged item
     if (in_array($this->getType(), $CFG_GLPI['reservation_types'])) {
         $rr = new ReservationItem();
         if ($rr->getFromDBbyItem($this->getType(), $this->fields['id'])) {
             $rr->delete(array('id' => $infocom->fields['id']));
         }
     }
     // If this type have CONTRACT, clean one associated to purged item
     if (in_array($this->getType(), $CFG_GLPI['contract_types'])) {
         $ci = new Contract_Item();
         $ci->cleanDBonItemDelete($this->getType(), $this->fields['id']);
     }
     // If this type have DOCUMENT, clean one associated to purged item
     if (Document::canApplyOn($this)) {
         $di = new Document_Item();
         $di->cleanDBonItemDelete($this->getType(), $this->fields['id']);
     }
     // If this type have NOTEPAD, clean one associated to purged item
     if ($this->usenotepad) {
         $note = new Notepad();
         $note->cleanDBonItemDelete($this->getType(), $this->fields['id']);
     }
 }
开发者ID:JULIO8,项目名称:respaldo_glpi,代码行数:49,代码来源:commondbtm.class.php


示例12: getSearchOptions


//.........这里部分代码省略.........
     $tab += Location::getSearchOptionsToAdd();
     $tab[4]['table'] = 'glpi_networkequipmenttypes';
     $tab[4]['field'] = 'name';
     $tab[4]['name'] = __('Type');
     $tab[4]['datatype'] = 'dropdown';
     $tab[40]['table'] = 'glpi_networkequipmentmodels';
     $tab[40]['field'] = 'name';
     $tab[40]['name'] = __('Model');
     $tab[40]['datatype'] = 'dropdown';
     $tab[31]['table'] = 'glpi_states';
     $tab[31]['field'] = 'completename';
     $tab[31]['name'] = __('Status');
     $tab[31]['datatype'] = 'dropdown';
     $tab[31]['condition'] = "`is_visible_networkequipment`";
     $tab[5]['table'] = $this->getTable();
     $tab[5]['field'] = 'serial';
     $tab[5]['name'] = __('Serial number');
     $tab[5]['datatype'] = 'string';
     $tab[6]['table'] = $this->getTable();
     $tab[6]['field'] = 'otherserial';
     $tab[6]['name'] = __('Inventory number');
     $tab[6]['datatype'] = 'string';
     $tab[7]['table'] = $this->getTable();
     $tab[7]['field'] = 'contact';
     $tab[7]['name'] = __('Alternate username');
     $tab[7]['datatype'] = 'string';
     $tab[8]['table'] = $this->getTable();
     $tab[8]['field'] = 'contact_num';
     $tab[8]['name'] = __('Alternate username number');
     $tab[8]['datatype'] = 'string';
     $tab[70]['table'] = 'glpi_users';
     $tab[70]['field'] = 'name';
     $tab[70]['name'] = __('User');
     $tab[70]['datatype'] = 'dropdown';
     $tab[70]['right'] = 'all';
     $tab[71]['table'] = 'glpi_groups';
     $tab[71]['field'] = 'completename';
     $tab[71]['name'] = __('Group');
     $tab[71]['datatype'] = 'dropdown';
     $tab[71]['condition'] = '`is_itemgroup`';
     $tab[19]['table'] = $this->getTable();
     $tab[19]['field'] = 'date_mod';
     $tab[19]['name'] = __('Last update');
     $tab[19]['datatype'] = 'datetime';
     $tab[19]['massiveaction'] = false;
     $tab[121]['table'] = $this->getTable();
     $tab[121]['field'] = 'date_creation';
     $tab[121]['name'] = __('Creation date');
     $tab[121]['datatype'] = 'datetime';
     $tab[121]['massiveaction'] = false;
     $tab[16]['table'] = $this->getTable();
     $tab[16]['field'] = 'comment';
     $tab[16]['name'] = __('Comments');
     $tab[16]['datatype'] = 'text';
     $tab[11]['table'] = 'glpi_networkequipmentfirmwares';
     $tab[11]['field'] = 'name';
     $tab[11]['name'] = _n('Firmware', 'Firmwares', 1);
     $tab[11]['datatype'] = 'dropdown';
     $tab[14]['table'] = $this->getTable();
     $tab[14]['field'] = 'ram';
     $tab[14]['name'] = sprintf(__('%1$s (%2$s)'), __('Memory'), __('Mio'));
     $tab[14]['datatype'] = 'number';
     $tab[32]['table'] = 'glpi_networks';
     $tab[32]['field'] = 'name';
     $tab[32]['name'] = __('Network');
     $tab[32]['datatype'] = 'dropdown';
     $tab[33]['table'] = 'glpi_domains';
     $tab[33]['field'] = 'name';
     $tab[33]['name'] = __('Domain');
     $tab[33]['datatype'] = 'dropdown';
     $tab[23]['table'] = 'glpi_manufacturers';
     $tab[23]['field'] = 'name';
     $tab[23]['name'] = __('Manufacturer');
     $tab[23]['datatype'] = 'dropdown';
     $tab[24]['table'] = 'glpi_users';
     $tab[24]['field'] = 'name';
     $tab[24]['linkfield'] = 'users_id_tech';
     $tab[24]['name'] = __('Technician in charge of the hardware');
     $tab[24]['datatype'] = 'dropdown';
     $tab[24]['right'] = 'own_ticket';
     $tab[49]['table'] = 'glpi_groups';
     $tab[49]['field'] = 'completename';
     $tab[49]['linkfield'] = 'groups_id_tech';
     $tab[49]['name'] = __('Group in charge of the hardware');
     $tab[49]['condition'] = '`is_assign`';
     $tab[49]['datatype'] = 'dropdown';
     $tab[80]['table'] = 'glpi_entities';
     $tab[80]['field'] = 'completename';
     $tab[80]['name'] = __('Entity');
     $tab[80]['massiveaction'] = false;
     $tab[80]['datatype'] = 'dropdown';
     $tab[86]['table'] = $this->getTable();
     $tab[86]['field'] = 'is_recursive';
     $tab[86]['name'] = __('Child entities');
     $tab[86]['datatype'] = 'bool';
     // add objectlock search options
     $tab += ObjectLock::getSearchOptionsToAdd(get_class($this));
     $tab += Notepad::getSearchOptionsToAdd();
     return $tab;
 }
开发者ID:glpi-project,项目名称:glpi,代码行数:101,代码来源:networkequipment.class.php


示例13: delete

 /**
  * Delete an item in the database.
  *
  * @see CommonDBTM::delete()
  *
  * @param $input     array    the _POST vars returned by the item form when press delete
  * @param $force     boolean  force deletion (default 0)
  * @param $history   boolean  do history log ? (default 1)
  *
  * @return boolean : true on success
  **/
 function delete(array $input, $force = 0, $history = 1)
 {
     $deleteSuccessful = parent::delete($input, $force, $history);
     if ($deleteSuccessful != false) {
         if ($force == 1) {
             $notepad = new Notepad();
             $notepad->deleteByCriteria(array('itemtype' => 'PluginSimcardSimcard', 'items_id' => $input['id']));
         }
     }
     return $deleteSuccessful;
 }
开发者ID:NandyJoshu,项目名称:simcard,代码行数:22,代码来源:simcard.class.php


示例14: run

 public function run()
 {
     $date = date("Y-m-d");
     $models = Notepad::model()->active()->date($date)->findAll();
     $this->render($this->view, array('models' => $models));
 }
开发者ID:kuzmina-mariya,项目名称:happy-end,代码行数:6,代码来源:NotepadWidget.php


示例15: getSearchOptions


//.........这里部分代码省略.........
     $tab[1]['field'] = 'name';
     $tab[1]['name'] = __('Name');
     $tab[1]['datatype'] = 'itemlink';
     $tab[1]['massiveaction'] = false;
     $tab[2]['table'] = $this->getTable();
     $tab[2]['field'] = 'id';
     $tab[2]['name'] = __('ID');
     $tab[2]['massiveaction'] = false;
     $tab[2]['datatype'] = 'number';
     $tab[3]['table'] = $this->getTable();
     $tab[3]['field'] = 'address';
     $tab[3]['name'] = __('Address');
     $tab[3]['datatype'] = 'text';
     $tab[10]['table'] = $this->getTable();
     $tab[10]['field'] = 'fax';
     $tab[10]['name'] = __('Fax');
     $tab[10]['datatype'] = 'string';
     $tab[11]['table'] = $this->getTable();
     $tab[11]['field'] = 'town';
     $tab[11]['name'] = __('City');
     $tab[11]['datatype'] = 'string';
     $tab[14]['table'] = $this->getTable();
     $tab[14]['field'] = 'postcode';
     $tab[14]['name'] = __('Postal code');
     $tab[14]['datatype'] = 'string';
     $tab[12]['table'] = $this->getTable();
     $tab[12]['field'] = 'state';
     $tab[12]['name'] = _x('location', 'State');
     $tab[12]['datatype'] = 'string';
     $tab[13]['table'] = $this->getTable();
     $tab[13]['field'] = 'country';
     $tab[13]['name'] = __('Country');
     $tab[13]['datatype'] = 'string';
     $tab[4]['table'] = $this->getTable();
     $tab[4]['field'] = 'website';
     $tab[4]['name'] = __('Website');
     $tab[4]['datatype'] = 'weblink';
     $tab[5]['table'] = $this->getTable();
     $tab[5]['field'] = 'phonenumber';
     $tab[5]['name'] = __('Phone');
     $tab[5]['datatype'] = 'string';
     $tab[6]['table'] = $this->getTable();
     $tab[6]['field'] = 'email';
     $tab[6]['name'] = _n('Email', 'Emails', 1);
     $tab[6]['datatype'] = 'email';
     $tab[9]['table'] = 'glpi_suppliertypes';
     $tab[9]['field'] = 'name';
     $tab[9]['name'] = __('Third party type');
     $tab[9]['datatype'] = 'dropdown';
     $tab[19]['table'] = $this->getTable();
     $tab[19]['field'] = 'date_mod';
     $tab[19]['name'] = __('Last update');
     $tab[19]['datatype'] = 'datetime';
     $tab[19]['massiveaction'] = false;
     $tab[121]['table'] = $this->getTable();
     $tab[121]['field'] = 'date_creation';
     $tab[121]['name'] = __('Creation date');
     $tab[121]['datatype'] = 'datetime';
     $tab[121]['massiveaction'] = false;
     if ($_SESSION["glpinames_format"] == User::FIRSTNAME_BEFORE) {
         $name1 = 'firstname';
         $name2 = 'name';
     } else {
         $name1 = 'name';
         $name2 = 'firstname';
     }
     $tab[8]['table'] = 'glpi_contacts';
     $tab[8]['field'] = 'completename';
     $tab[8]['name'] = _n('Associated contact', 'Associated contacts', Session::getPluralNumber());
     $tab[8]['forcegroupby'] = true;
     $tab[8]['datatype'] = 'itemlink';
     $tab[8]['massiveaction'] = false;
     $tab[8]['computation'] = "CONCAT(TABLE.`{$name1}`, ' ', TABLE.`{$name2}`)";
     $tab[8]['computationgroupby'] = true;
     $tab[8]['joinparams'] = array('beforejoin' => array('table' => 'glpi_contacts_suppliers', 'joinparams' => array('jointype' => 'child')));
     $tab[16]['table'] = $this->getTable();
     $tab[16]['field'] = 'comment';
     $tab[16]['name'] = __('Comments');
     $tab[16]['dat 

鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP Notice类代码示例发布时间:2022-05-23
下一篇:
PHP Note类代码示例发布时间:2022-05-23
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap