PHP Class CommonITILValidation, glpi

Inheritance: extends CommonDBChild
Afficher le fichier Open project: glpi-project/glpi Class Usage Examples

Méthodes publiques

Свойство Type Description
$auto_message_on_action From CommonDBTM
$log_history_add
$log_history_delete
$log_history_update

Méthodes publiques

Méthode Description
alertValidation ( CommonITILObject $item, $type )
alreadyExists ( $items_id, $users_id ) : boolean Check if validation already exists
canCreate ( )
canCreateItem ( ) : boolean Is the current user have right to delete the current validation ?
canDeleteItem ( ) : boolean Is the current user have right to delete the current validation ?
canUpdate ( )
canUpdateItem ( ) : boolean Is the current user have right to update the current validation ?
canValidate ( $items_id )
canView ( )
computeValidationStatus ( CommonITILObject $item ) : validation Compute the validation status
displayTabContentForItem ( CommonGLPI $item, $tabnum = 1, $withtemplate )
dropdownStatus ( $name, $options = [] ) : nothing Dropdown of validation status
dropdownValidator ( array $options = [] ) : nothing Dropdown of validator
getAllStatusArray ( $withmetaforsearch = false, $global = false ) : an get the Ticket validation status list
getAllValidationStatusArray ( ) : an Get the ITIL object all validation status list
getCanValidationStatusArray ( ) : an Get the ITIL object can validation status list
getCreateRights ( )
getForbiddenStandardMassiveAction ( )
getGroupUserHaveRights ( array $options = [] ) : array Get list of users from a group which have validation rights
getHistoryChangeWhenUpdateField ( $field )
getHistoryNameForItem ( CommonDBTM $item, $case )
getItilObjectItemType ( ) rejected
getNumberToValidate ( $users_id ) Get item validation demands count for a user
getNumberValidationForTicket ( $items_id ) Get item validation demands count
getPurgeRights ( )
getRights ( $interface = 'central' )
getSearchOptions ( )
getSearchOptionsToAdd ( )
getSpecificValueToDisplay ( $field, $values, array $options = [] )
getSpecificValueToSelect ( $field, $name = '', $values = '', array $options = [] )
getStatus ( $value ) Get Ticket validation status Name
getStatusColor ( $value ) Get Ticket validation status Color
getTabNameForItem ( CommonGLPI $item, $withtemplate )
getTicketStatusNumber ( $items_id, $status ) Get the number of validations attached to an item having a specified status
getTypeName ( $nb )
getValidateRights ( )
getValidationStats ( $tID ) : statistics Get the validation statistics
isAllValidationsHaveSameStatusForTicket ( $items_id ) All validations requests for an item have the same status ?
post_addItem ( )
post_getEmpty ( )
post_updateItem ( $history = 1 )
prepareInputForAdd ( $input )
prepareInputForUpdate ( $input )
processMassiveActionsForOneItemtype ( MassiveAction $ma, CommonDBTM $item, array $ids )
showForm ( $ID, $options = [] ) Print the validation form
showFormMassiveAction ( ) Form for Followup on Massive action
showMassiveActionsSubForm ( MassiveAction $ma )
showSummary ( $item ) Print the validation list into item

Method Details

alertValidation() static public méthode

static public alertValidation ( CommonITILObject $item, $type )
$item CommonITILObject CommonITILObject
$type

alreadyExists() static public méthode

Check if validation already exists
static public alreadyExists ( $items_id, $users_id ) : boolean
$items_id integer item ID
$users_id integer user ID
Résultat boolean

canCreate() static public méthode

static public canCreate ( )

canCreateItem() public méthode

Is the current user have right to delete the current validation ?
public canCreateItem ( ) : boolean
Résultat boolean

canDeleteItem() public méthode

Is the current user have right to delete the current validation ?
public canDeleteItem ( ) : boolean
Résultat boolean

canUpdate() static public méthode

static public canUpdate ( )

canUpdateItem() public méthode

Is the current user have right to update the current validation ?
public canUpdateItem ( ) : boolean
Résultat boolean

canValidate() static public méthode

static public canValidate ( $items_id )
$items_id ID of the item

canView() static public méthode

static public canView ( )

computeValidationStatus() static public méthode

Compute the validation status
static public computeValidationStatus ( CommonITILObject $item ) : validation
$item CommonITILObject CommonITILObject
Résultat validation status

displayTabContentForItem() static public méthode

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

dropdownStatus() static public méthode

Dropdown of validation status
static public dropdownStatus ( $name, $options = [] ) : nothing
$name select name
$options array of possible options: - value : default value (default waiting) - all : boolean display all (default false) - global : for global validation (default false) - display : boolean display or get string ? (default true)
Résultat nothing (display)

dropdownValidator() static public méthode

Dropdown of validator
static public dropdownValidator ( array $options = [] ) : nothing
$options array array of options - name : select name - id : ID of object > 0 Update, < 0 New - entity : ID of entity - right : validation rights - groups_id : ID of group validator - users_id_validate : ID of user validator - applyto
Résultat nothing (display)

getAllStatusArray() static public méthode

get the Ticket validation status list
static public getAllStatusArray ( $withmetaforsearch = false, $global = false ) : an
$withmetaforsearch boolean (false by default)
$global boolean (true for global status, with "no validation" option) (false by default)
Résultat an array

getAllValidationStatusArray() static public méthode

Get the ITIL object all validation status list
static public getAllValidationStatusArray ( ) : an
Résultat an array

getCanValidationStatusArray() static public méthode

Get the ITIL object can validation status list
static public getCanValidationStatusArray ( ) : an
Résultat an array

getCreateRights() static public méthode

static public getCreateRights ( )

getForbiddenStandardMassiveAction() public méthode

getGroupUserHaveRights() static public méthode

Get list of users from a group which have validation rights
static public getGroupUserHaveRights ( array $options = [] ) : array
$options array array possible: groups_id right entity
Résultat array

getHistoryChangeWhenUpdateField() public méthode

See also: CommonDBConnexity::getHistoryChangeWhenUpdateField

getHistoryNameForItem() public méthode

See also: CommonDBChild::getHistoryNameForItem
public getHistoryNameForItem ( CommonDBTM $item, $case )
$item CommonDBTM

getItilObjectItemType() public méthode

rejected

getNumberToValidate() static public méthode

Get item validation demands count for a user
static public getNumberToValidate ( $users_id )
$users_id integer User ID

getNumberValidationForTicket() static public méthode

Get item validation demands count
static public getNumberValidationForTicket ( $items_id )
$items_id integer item ID

getPurgeRights() static public méthode

static public getPurgeRights ( )

getRights() public méthode

See also: commonDBTM::getRights()
public getRights ( $interface = 'central' )

getSearchOptions() public méthode

public getSearchOptions ( )

getSearchOptionsToAdd() static public méthode

static public getSearchOptionsToAdd ( )

getSpecificValueToDisplay() static public méthode

static public getSpecificValueToDisplay ( $field, $values, array $options = [] )
$field
$values
$options array array

getSpecificValueToSelect() static public méthode

static public getSpecificValueToSelect ( $field, $name = '', $values = '', array $options = [] )
$field
$name (default '')
$values (default '')
$options array array

getStatus() static public méthode

Get Ticket validation status Name
static public getStatus ( $value )
$value status ID

getStatusColor() static public méthode

Get Ticket validation status Color
static public getStatusColor ( $value )
$value status ID

getTabNameForItem() public méthode

public getTabNameForItem ( CommonGLPI $item, $withtemplate )
$item CommonGLPI

getTicketStatusNumber() static public méthode

Get the number of validations attached to an item having a specified status
static public getTicketStatusNumber ( $items_id, $status )
$items_id integer item ID
$status status

getTypeName() static public méthode

static public getTypeName ( $nb )

getValidateRights() static public méthode

static public getValidateRights ( )

getValidationStats() static public méthode

Get the validation statistics
static public getValidationStats ( $tID ) : statistics
$tID tickets id
Résultat statistics array

isAllValidationsHaveSameStatusForTicket() static public méthode

All validations requests for an item have the same status ?
static public isAllValidationsHaveSameStatusForTicket ( $items_id )
$items_id integer item ID

post_addItem() public méthode

public post_addItem ( )

post_getEmpty() public méthode

public post_getEmpty ( )

post_updateItem() public méthode

public post_updateItem ( $history = 1 )

prepareInputForAdd() public méthode

public prepareInputForAdd ( $input )

prepareInputForUpdate() public méthode

public prepareInputForUpdate ( $input )

processMassiveActionsForOneItemtype() static public méthode

See also: CommonDBTM::processMassiveActionsForOneItemtype()
static public processMassiveActionsForOneItemtype ( MassiveAction $ma, CommonDBTM $item, array $ids )
$ma MassiveAction
$item CommonDBTM
$ids array

showForm() public méthode

Print the validation form
public showForm ( $ID, $options = [] )
$ID integer ID of the item
$options array options used

showFormMassiveAction() static public méthode

Form for Followup on Massive action
static public showFormMassiveAction ( )

showMassiveActionsSubForm() static public méthode

See also: CommonDBTM::showMassiveActionsSubForm()
static public showMassiveActionsSubForm ( MassiveAction $ma )
$ma MassiveAction

showSummary() public méthode

Print the validation list into item
public showSummary ( $item )
$item class

Property Details

$auto_message_on_action public_oe property

From CommonDBTM
public $auto_message_on_action

$log_history_add public_oe static_oe property

public static $log_history_add

$log_history_delete public_oe static_oe property

public static $log_history_delete

$log_history_update public_oe static_oe property

public static $log_history_update