PHP Class ProjectCost, glpi

Inheritance: extends CommonDBChild
Mostrar archivo Open project: glpi-project/glpi Class Usage Examples

Public Properties

Property Type Description
$dohistory
$items_id
$itemtype From CommonDBChild

Public Methods

Method Description
cloneProject ( $oldid, $newid ) Duplicate all costs from a project template to its clone
displayTabContentForItem ( CommonGLPI $item, $tabnum = 1, $withtemplate )
getLastCostForProject ( $projects_id ) Get last datas for a project
getSearchOptions ( )
getTabNameForItem ( CommonGLPI $item, $withtemplate )
getTypeName ( $nb )
initBasedOnPrevious ( ) Init cost for creation based on previous cost
prepareInputForAdd ( $input )
prepareInputForUpdate ( $input )
showForProject ( Project $project, $withtemplate = '' ) : Nothing Print the project costs
showForm ( $ID, $options = [] ) Print the project cost form

Method Details

cloneProject() static public method

Duplicate all costs from a project template to its clone
static public cloneProject ( $oldid, $newid )
$oldid
$newid

displayTabContentForItem() static public method

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

getLastCostForProject() public method

Get last datas for a project
public getLastCostForProject ( $projects_id )
$projects_id integer ID of the project

getSearchOptions() public method

See also: CommonDBTM::getSearchOptions()
public getSearchOptions ( )

getTabNameForItem() public method

See also: CommonGLPI::getTabNameForItem()
public getTabNameForItem ( CommonGLPI $item, $withtemplate )
$item CommonGLPI

getTypeName() static public method

static public getTypeName ( $nb )

initBasedOnPrevious() public method

Init cost for creation based on previous cost
public initBasedOnPrevious ( )

prepareInputForAdd() public method

See also: CommonDBChild::prepareInputForAdd()
public prepareInputForAdd ( $input )

prepareInputForUpdate() public method

See also: CommonDBTM::prepareInputForUpdate()
public prepareInputForUpdate ( $input )

showForProject() static public method

Print the project costs
static public showForProject ( Project $project, $withtemplate = '' ) : Nothing
$project Project Project object
$withtemplate boolean Template or basic item (default '')
return Nothing (call to classes members)

showForm() public method

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

Property Details

$dohistory public_oe property

public $dohistory

$items_id public_oe static_oe property

public static $items_id

$itemtype public_oe static_oe property

From CommonDBChild
public static $itemtype