Property | Type | Description | |
---|---|---|---|
$auto_message_on_action | |||
$dohistory | |||
$items_id | |||
$itemtype | From CommonDBChild | ||
$logs_for_parent | Link in message can't work' | ||
$rightname |
Method | Description | |
---|---|---|
Amort ( $type_amort, $va, $duree, $coef, $date_achat, $date_use, $date_tax, $view = "n" ) : float | Calculate amortissement for an item | |
addPluginInfos ( CommonDBTM $item ) | ||
autofillDates ( &$infocoms = [], $field = '', $action, $params = [] ) : nothing | Automatically manage copying one date to another is necessary | |
canApplyOn ( $item ) : true | Check if given object can have InfoCom | |
cleanDBonPurge ( ) | ||
cloneItem ( $itemtype, $oldid, $newid, $newitemtype = '' ) | Duplicate infocoms from an item template to its clone | |
countForSupplier ( Supplier $item ) | ||
cronInfo ( $name ) | ||
cronInfocom ( $task = NULL ) | Cron action on infocom : alert on expired warranty | |
displayTabContentForItem ( CommonGLPI $item, $tabnum = 1, $withtemplate ) | ||
dropdownAlert ( $options ) | ||
dropdownAmortType ( $name, $value, $display = true ) | Dropdown of amortissement type for infocoms | |
getAlertName ( $val = NULL ) : array | Get the possible value for infocom alert | |
getAmortTypeName ( $value ) | Get amortissement type name for infocoms | |
getAutoManagemendDatesFields ( ) : an | Return all infocom dates that could be automaticall filled | |
getFromDBforDevice ( $itemtype, $ID ) : true | Retrieve an item from the database for a device | |
getItemtypesThatCanHave ( ) : array | Get all the types that can have an infocom | |
getLogTypeID ( ) | ||
getMassiveActionsForItemtype ( array &$actions, $itemtype, $is_deleted, CommonDBTM $checkitem = NULL ) | ||
getSearchOptions ( ) | ||
getSearchOptionsToAdd ( $itemtype ) | ||
getSpecificValueToDisplay ( $field, $values, array $options = [] ) | ||
getSpecificValueToSelect ( $field, $name = '', $values = '', array $options = [] ) | ||
getTabNameForItem ( CommonGLPI $item, $withtemplate ) | ||
getTypeName ( $nb ) | ||
getWarrantyExpir ( $from, $addwarranty, $deletenotice, $color = false ) : expiration | Get date using a begin date and a period in month | |
manageDateOnStatusChange ( CommonDBTM $item, $action_add = true ) : nothing | Fill, if necessary, automatically some dates when status changes | |
post_getEmpty ( ) | ||
pre_updateInDB ( ) | ||
prepareInputForAdd ( $input ) | ||
prepareInputForUpdate ( $input ) | ||
processMassiveActionsForOneItemtype ( MassiveAction $ma, CommonDBTM $item, array $ids ) | ||
showDebug ( ) | Display debug information for infocom of current object | |
showDisplayLink ( $itemtype, $device_id ) : float | Show infocom link to display modal | |
showForItem ( CommonDBTM $item, $withtemplate = '' ) | Show Infocom form for an item (not a standard showForm) | |
showTco ( $ticket_tco, $value, $date_achat = "" ) : float | Calculate TCO and TCO by month for an item |
static public Amort ( $type_amort, $va, $duree, $coef, $date_achat, $date_use, $date_tax, $view = "n" ) : float | ||
$type_amort | type d'amortisssment "lineaire=2" ou "degressif=1" | |
$va | valeur d'acquisition | |
$duree | duree d'amortissement | |
$coef | coefficient d'amortissement | |
$date_achat | Date d'achat | |
$date_use | Date d'utilisation | |
$date_tax | date du debut de l'annee fiscale | |
$view | "n" pour l'annee en cours ou "all" pour le tableau complet (default 'n') | |
return | float | or array |
static public addPluginInfos ( CommonDBTM $item ) | ||
$item | CommonDBTM |
static public autofillDates ( &$infocoms = [], $field = '', $action, $params = [] ) : nothing | ||
return | nothing |
static public canApplyOn ( $item ) : true | ||
$item | an object or a string | |
return | true | if $object is an object that can have InfoCom |
static public cloneItem ( $itemtype, $oldid, $newid, $newitemtype = '' ) | ||
$itemtype | itemtype of the item | |
$oldid | ID of the item to clone | |
$newid | ID of the item cloned | |
$newitemtype | itemtype of the new item (= $itemtype if empty) (default '') |
static public countForSupplier ( Supplier $item ) | ||
$item | Supplier | Supplier object |
static public cronInfocom ( $task = NULL ) | ||
$task | to log, if NULL use display (default NULL) |
static public displayTabContentForItem ( CommonGLPI $item, $tabnum = 1, $withtemplate ) | ||
$item | CommonGLPI | CommonGLPI object |
$tabnum | (default 1) | |
$withtemplate | (default 0) |
static public dropdownAmortType ( $name, $value, $display = true ) | ||
$name | select name | |
$value | default value (default 0) | |
$display | display or get string (true by default) |
static public getAlertName ( $val = NULL ) : array | ||
$val | if not set, ask for all values, else for 1 value (default NULL) | |
return | array | or string |
static public getAmortTypeName ( $value ) | ||
$value | status ID |
static public getAutoManagemendDatesFields ( ) : an | ||
return | an | array with all dates (configuration field & real field) |
public getFromDBforDevice ( $itemtype, $ID ) : true | ||
$itemtype | type of the device to retrieve infocom | |
$ID | ID of the device to retrieve infocom | |
return | true | if succeed else false |
static public getItemtypesThatCanHave ( ) : array | ||
return | array | of the itemtypes |
static public getMassiveActionsForItemtype ( array &$actions, $itemtype, $is_deleted, CommonDBTM $checkitem = NULL ) | ||
$actions | array | |
$checkitem | CommonDBTM |
static public getSearchOptionsToAdd ( $itemtype ) | ||
$itemtype |
static public getSpecificValueToDisplay ( $field, $values, array $options = [] ) | ||
$options | array |
static public getSpecificValueToSelect ( $field, $name = '', $values = '', array $options = [] ) | ||
$field | ||
$name | (default '') | |
$values | (default '') | |
$options | array | array |
public getTabNameForItem ( CommonGLPI $item, $withtemplate ) | ||
$item | CommonGLPI |
static public getWarrantyExpir ( $from, $addwarranty, $deletenotice, $color = false ) : expiration | ||
$from | date begin date | |
$addwarranty | integer period in months | |
$deletenotice | integer period in months of notice (default 0) | |
$color | boolean if show expire date in red color (false by default) | |
return | expiration | date string |
static public manageDateOnStatusChange ( CommonDBTM $item, $action_add = true ) : nothing | ||
$item | CommonDBTM | |
return | nothing |
static public processMassiveActionsForOneItemtype ( MassiveAction $ma, CommonDBTM $item, array $ids ) | ||
$ma | MassiveAction | |
$item | CommonDBTM | |
$ids | array |
public showDebug ( ) |
static public showDisplayLink ( $itemtype, $device_id ) : float | ||
$itemtype | integer item type | |
$device_id | integer item ID | |
return | float |
static public showForItem ( CommonDBTM $item, $withtemplate = '' ) | ||
$item | CommonDBTM | CommonDBTM object |
$withtemplate | integer template or basic item (default '') |
public static $logs_for_parent |