PHP 클래스 Computer_Item, glpi

상속: extends CommonDBRelation
파일 보기 프로젝트 열기: glpi-project/glpi 1 사용 예제들

공개 프로퍼티들

프로퍼티 타입 설명
$checkItem_2_Rights
$items_id_1
$items_id_2
$itemtype_1 From CommonDBRelation
$itemtype_2

공개 메소드들

메소드 설명
cleanDBonPurge ( ) : nothing Actions done when item is deleted from the database Overloaded to manage autoupdate feature
cloneComputer ( $oldid, $newid ) Duplicate connected items to computer from an item template to its clone
cloneItem ( $itemtype, $oldid, $newid ) Duplicate connected items to item from an item template to its clone
countForAll ( Computer $comp, CommonDBTM $item ) : integer: Count connection for a Computer and an itemtype
countForComputer ( Computer $comp ) : integer: Count connection for a Computer
countForItem ( CommonDBTM $item ) : integer: Count connection for an item
disconnectForItem ( CommonDBTM $item ) : boolean Disconnect an item to its computer
displayTabContentForItem ( CommonGLPI $item, $tabnum = 1, $withtemplate )
dropdownAllConnect ( $fromtype, $myname, $entity_restrict, $onlyglobal, $used = [] ) : nothing Make a select box for connections
dropdownConnect ( $itemtype, $fromtype, $myname, $entity_restrict, $onlyglobal, $used = [] ) : nothing Make a select box for connections
getForbiddenStandardMassiveAction ( )
getMassiveActionsForItemtype ( array &$actions, $itemtype, $is_deleted, CommonDBTM $checkitem = NULL )
getRelationMassiveActionsSpecificities ( )
getTabNameForItem ( CommonGLPI $item, $withtemplate )
prepareInputForAdd ( $input ) : the Prepare input datas for adding the relation
showForComputer ( Computer $comp, $withtemplate = '' ) : Nothing Print the form for computers or templates connections to printers, screens or peripherals
showForItem ( CommonDBTM $item, $withtemplate = '' ) : nothing Prints a direct connection to a computer
unglobalizeItem ( CommonDBTM $item ) Unglobalize an item : duplicate item and connections

메소드 상세

cleanDBonPurge() 공개 메소드

Actions done when item is deleted from the database Overloaded to manage autoupdate feature
public cleanDBonPurge ( ) : nothing
리턴 nothing

cloneComputer() 정적인 공개 메소드

Duplicate connected items to computer from an item template to its clone
static public cloneComputer ( $oldid, $newid )
$oldid ID of the item to clone
$newid ID of the item cloned

cloneItem() 정적인 공개 메소드

Duplicate connected items to item from an item template to its clone
static public cloneItem ( $itemtype, $oldid, $newid )
$itemtype type of the item to clone
$oldid ID of the item to clone
$newid ID of the item cloned

countForAll() 정적인 공개 메소드

Count connection for a Computer and an itemtype
static public countForAll ( Computer $comp, CommonDBTM $item ) : integer:
$comp Computer Computer object
$item CommonDBTM CommonDBTM object
리턴 integer:

countForComputer() 정적인 공개 메소드

Count connection for a Computer
static public countForComputer ( Computer $comp ) : integer:
$comp Computer Computer object
리턴 integer:

countForItem() 정적인 공개 메소드

Count connection for an item
static public countForItem ( CommonDBTM $item ) : integer:
$item CommonDBTM CommonDBTM object
리턴 integer:

disconnectForItem() 공개 메소드

Disconnect an item to its computer
public disconnectForItem ( CommonDBTM $item ) : boolean
$item CommonDBTM CommonDBTM object: the Monitor/Phone/Peripheral/Printer
리턴 boolean : action succeeded

displayTabContentForItem() 정적인 공개 메소드

static public displayTabContentForItem ( CommonGLPI $item, $tabnum = 1, $withtemplate )
$item CommonGLPI CommonGLPI object
$tabnum (default 1)
$withtemplate (default 0)

dropdownAllConnect() 정적인 공개 메소드

Make a select box for connections
static public dropdownAllConnect ( $fromtype, $myname, $entity_restrict, $onlyglobal, $used = [] ) : nothing
$fromtype from where the connection is
$myname select name
$entity_restrict Restrict to a defined entity (default = -1)
$onlyglobal display only global devices (used for templates) (default 0)
$used array Already used items ID: not to display in dropdown
리턴 nothing (print out an HTML select box)

dropdownConnect() 정적인 공개 메소드

Make a select box for connections
static public dropdownConnect ( $itemtype, $fromtype, $myname, $entity_restrict, $onlyglobal, $used = [] ) : nothing
$itemtype type to connect
$fromtype from where the connection is
$myname select name
$entity_restrict Restrict to a defined entity (default = -1)
$onlyglobal display only global devices (used for templates) (default 0)
$used array Already used items ID: not to display in dropdown
리턴 nothing (print out an HTML select box)

getForbiddenStandardMassiveAction() 공개 메소드

getMassiveActionsForItemtype() 정적인 공개 메소드

또한 보기: CommonDBTM::getMassiveActionsForItemtype()
static public getMassiveActionsForItemtype ( array &$actions, $itemtype, $is_deleted, CommonDBTM $checkitem = NULL )
$actions array
$checkitem CommonDBTM

getRelationMassiveActionsSpecificities() 정적인 공개 메소드

또한 보기: CommonDBRelation::getRelationMassiveActionsSpecificities()

getTabNameForItem() 공개 메소드

또한 보기: CommonGLPI::getTabNameForItem()
public getTabNameForItem ( CommonGLPI $item, $withtemplate )
$item CommonGLPI

prepareInputForAdd() 공개 메소드

Overloaded to check is Disconnect needed (during OCS sync) and to manage autoupdate feature
public prepareInputForAdd ( $input ) : the
$input array of datas used to add the item
리턴 the modified $input array

showForComputer() 정적인 공개 메소드

Print the form for computers or templates connections to printers, screens or peripherals
static public showForComputer ( Computer $comp, $withtemplate = '' ) : Nothing
$comp Computer Computer object
$withtemplate boolean Template or basic item (default '')
리턴 Nothing (call to classes members)

showForItem() 정적인 공개 메소드

Prints a direct connection to a computer
static public showForItem ( CommonDBTM $item, $withtemplate = '' ) : nothing
$item CommonDBTM CommonDBTM object: the Monitor/Phone/Peripheral/Printer
$withtemplate integer withtemplate param (default '')
리턴 nothing (print out a table)

unglobalizeItem() 정적인 공개 메소드

Unglobalize an item : duplicate item and connections
static public unglobalizeItem ( CommonDBTM $item )
$item CommonDBTM CommonDBTM object to unglobalize

프로퍼티 상세

$checkItem_2_Rights 공개적으로 정적으로 프로퍼티

public static $checkItem_2_Rights

$items_id_1 공개적으로 정적으로 프로퍼티

public static $items_id_1

$items_id_2 공개적으로 정적으로 프로퍼티

public static $items_id_2

$itemtype_1 공개적으로 정적으로 프로퍼티

From CommonDBRelation
public static $itemtype_1

$itemtype_2 공개적으로 정적으로 프로퍼티

public static $itemtype_2