Property | Type | Description | |
---|---|---|---|
$dohistory | From CommonDBTM | ||
$rightname | |||
$tag_prefix |
Property | Type | Description | |
---|---|---|---|
$forward_entity_to | |||
$usenotepad |
Method | Description | |
---|---|---|
canApplyOn ( $item ) : true | Check if given object can have Document | |
canCreate ( ) | ||
canCreateItem ( ) | ||
canViewFile ( $options ) : boolean | Check is the curent user is allowed to see the file | |
cleanDBonPurge ( ) | ||
defineTabs ( $options = [] ) | ||
dropdown ( $options = [] ) : nothing | Make a select box for link document | |
getDownloadLink ( $params = '', $len = 20 ) | Get download link for a document | |
getFromDBbyContent ( $entity, $path ) : boolean | find a document with a file attached | |
getImageTag ( $string ) : string | ||
getItemtypesThatCanHave ( ) : array | Get all the types that can have a document | |
getMassiveActionsForItemtype ( array &$actions, $itemtype, $is_deleted, CommonDBTM $checkitem = NULL ) | ||
getMaxUploadSize ( ) | Get max upload size from php config | |
getMenuShorcut ( ) | ||
getSearchOptions ( ) | ||
getSearchOptionsToAdd ( ) | ||
getSpecificMassiveActions ( $checkitem = NULL ) | ||
getTypeName ( $nb ) | ||
getUploadFileValidLocationName ( $dir, $sha1sum ) : nothing | Find a valid path for the new file | |
isValidDoc ( $filename ) | Is this file a valid file ? check based on file extension | |
moveDocument ( array &$input, $filename ) : boolean | Move a document (files in GLPI_DOC_DIR."/_tmp" dir) | |
moveUploadedDocument ( array &$input, $filename ) : boolean | Move an uploadd document (files in GLPI_DOC_DIR."/_uploads" dir) | |
post_addItem ( ) | ||
prepareInputForAdd ( $input ) | ||
prepareInputForUpdate ( $input ) | ||
renameForce ( $srce, $dest ) : boolean | Move a file to a new location Work even if dest file already exists | |
send ( ) | Send a document to navigator | |
showForm ( $ID, $options = [] ) : Nothing | Print the document form | |
showUploadedFilesDropdown ( $myname ) | Show dropdown of uploaded files | |
uploadDocument ( array &$input, $FILEDESC ) : true | Upload a new file |
static public canApplyOn ( $item ) : true | ||
$item | an object or a string | |
return | true | if $object is an object that can have InfoCom |
public canViewFile ( $options ) : boolean | ||
$options | array of options (only 'tickets_id' used) | |
return | boolean |
static public dropdown ( $options = [] ) : nothing | ||
$options | array of possible options | |
return | nothing | (print out an HTML select box) |
public getDownloadLink ( $params = '', $len = 20 ) | ||
$params | additonal parameters to be added to the link (default '') | |
$len | maximum length of displayed string (default 20) |
public getFromDBbyContent ( $entity, $path ) : boolean | ||
$entity | of the document | |
$path | of the searched file | |
return | boolean |
static public getImageTag ( $string ) : string | ||
$string | ||
return | string |
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 getMaxUploadSize ( ) |
static public getUploadFileValidLocationName ( $dir, $sha1sum ) : nothing | ||
$dir | dir to search a free path for the file | |
$sha1sum | SHA1 of the file | |
return | nothing |
static public isValidDoc ( $filename ) | ||
$filename | filename to clean |
static public moveDocument ( array &$input, $filename ) : boolean | ||
$input | array | array of datas used in adding process (need current_filepath) |
$filename | filename to move | |
return | boolean | for success / $input array is updated |
static public moveUploadedDocument ( array &$input, $filename ) : boolean | ||
$input | array | array of datas used in adding process (need current_filepath) |
$filename | filename to move | |
return | boolean | for success / $input array is updated |
static public renameForce ( $srce, $dest ) : boolean | ||
$srce | source file path | |
$dest | destination file path | |
return | boolean | : success |
public showForm ( $ID, $options = [] ) : Nothing | ||
$ID | integer ID of the item | |
$options | array - target filename : where to go when done. - withtemplate boolean : template or basic item | |
return | Nothing | (display) |
static public showUploadedFilesDropdown ( $myname ) | ||
$myname | dropdown name |
static public uploadDocument ( array &$input, $FILEDESC ) : true | ||
$input | array | |
$FILEDESC | FILE descriptor | |
return | true | on success |