Class: iHRIS Module PersonPosition (Development): Difference between revisions

From IHRIS Wiki
(Created page with '{{otherversions|Class: iHRIS_Module_PersonPosition}} This article describes the class ''iHRIS_Module_PersonPosition'' . *Extends the class: [[Class: I2CE_Module (Development) | I…')
 
No edit summary
 
Line 2: Line 2:
This article describes the class ''iHRIS_Module_PersonPosition'' .
This article describes the class ''iHRIS_Module_PersonPosition'' .
*Extends the class: [[Class: I2CE_Module (Development) | I2CE_Module]].
*Extends the class: [[Class: I2CE_Module (Development) | I2CE_Module]].
*Location: Part of the module [[iHRIS Manage Module List (Development)#ihris-manage-PersonPosition|ihris-manage-PersonPosition]] in the package [https://launchpad.net/ihris-manage iHRIS Manage] 4.0-dev
*Location: Part of the module [[iHRIS Manage Module List (Development)#ihris-manage-PersonPosition|ihris-manage-PersonPosition]] in the package [https://launchpad.net/ihris-manage iHRIS Manage] 4.1-dev
*Source: Defined in the file [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.0-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L33 modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 33
*Source: Defined in the file [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.1-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L33 modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 33
*Author: Carl Leitner <litlfred@ibiblio.org>
*Author: Carl Leitner <litlfred@ibiblio.org>
*Since: v3.2.6
*Since: v3.2.6
Line 10: Line 10:
===$do_migrate===
===$do_migrate===
A flag to determine if migrate needs to be called during the upgrade method.
A flag to determine if migrate needs to be called during the upgrade method.
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.0-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L38 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 38
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.1-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L61 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 61
*Type: protected [http://www.php.net/manual/en/language.types.boolean.php boolean ] $do_migrate
*Type: protected [http://www.php.net/manual/en/language.types.boolean.php boolean ] $do_migrate


===$do_migrate3212===
===$do_migrate3212===
A flag to determine if migrate3212 needs to be called during the upgrade method.
A flag to determine if migrate3212 needs to be called during the upgrade method.
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.0-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L42 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 42
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.1-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L65 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 65
*Type: protected [http://www.php.net/manual/en/language.types.boolean.php boolean ] $do_migrate3212
*Type: protected [http://www.php.net/manual/en/language.types.boolean.php boolean ] $do_migrate3212


Line 21: Line 21:
===action_initialize()===
===action_initialize()===
Method called before the module is enabled for the first time. @param boolean -- returns true on success. false on error.
Method called before the module is enabled for the first time. @param boolean -- returns true on success. false on error.
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.0-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L162 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 162
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.1-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L185 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 185
*Signature: public function action_initialize()
*Signature: public function action_initialize()
===action_person_position()===
===action_person_position()===
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.0-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L335 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 335
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.1-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L358 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 358
*Signature: public function action_person_position($page)
*Signature: public function action_person_position($page)
*Parameters:
*Parameters:
**$page  
**$page  
===getHooks()===
Return the array of hooks available in this module.
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.1-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L39 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 39
*Signature: static public function getHooks()
*Returns: [http://www.php.net/manual/en/language.types.array.php array ]
===getLastPosition()===
===getLastPosition()===
Find and return the most recent position held by this person.
Find and return the most recent position held by this person.
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.0-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L313 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 313
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.1-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L336 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 336
*Signature: public function getLastPosition($person)
*Signature: public function getLastPosition($person)
*Parameters:
*Parameters:
Line 36: Line 41:
*Returns: [[Class: I2CE_Form (Development) | I2CE_Form]]<br/>or null
*Returns: [[Class: I2CE_Form (Development) | I2CE_Form]]<br/>or null
===getMethods()===
===getMethods()===
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.0-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L264 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 264
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.1-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L287 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 287
*Signature: static public function getMethods()
*Signature: static public function getMethods()
===isActive_Person()===
===isActive_Person()===
Checks to see if the most recent position for this person is still active and doesn't have an end date for his/her position. @see getLastPosition()
Checks to see if the most recent position for this person is still active and doesn't have an end date for his/her position. @see getLastPosition()
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.0-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L280 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 280
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.1-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L303 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 303
*Signature: public function isActive_Person($person)
*Signature: public function isActive_Person($person)
*Parameters:
*Parameters:
Line 47: Line 52:
===isActive_PersonPosition()===
===isActive_PersonPosition()===
Checks to see if the most recent position for this person is still active and doesn't have an end date for his/her position. @see getLastPosition()
Checks to see if the most recent position for this person is still active and doesn't have an end date for his/her position. @see getLastPosition()
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.0-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L292 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 292
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.1-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L315 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 315
*Signature: public function isActive_PersonPosition($pers_pos)
*Signature: public function isActive_PersonPosition($pers_pos)
*Parameters:
*Parameters:
Line 54: Line 59:
===migrate()===
===migrate()===
Perform the migrate actions for this module This is for going from pre 3.2 versions where benefit data has been saved to the database.
Perform the migrate actions for this module This is for going from pre 3.2 versions where benefit data has been saved to the database.
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.0-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L82 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 82
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.1-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L105 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 105
*Signature: protected function migrate()
*Signature: protected function migrate()
*Returns: [http://www.php.net/manual/en/language.types.boolean.php boolean ]
*Returns: [http://www.php.net/manual/en/language.types.boolean.php boolean ]
===migrate3212()===
===migrate3212()===
Perform the migrate actions for this module from 3.2.10 to 3.2.12 This is for going from pre 3.2 versions where benefit data has been saved to the database.
Perform the migrate actions for this module from 3.2.10 to 3.2.12 This is for going from pre 3.2 versions where benefit data has been saved to the database.
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.0-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L143 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 143
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.1-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L166 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 166
*Signature: protected function migrate3212()
*Signature: protected function migrate3212()
*Returns: [http://www.php.net/manual/en/language.types.boolean.php boolean ]
*Returns: [http://www.php.net/manual/en/language.types.boolean.php boolean ]
===post_update()===
===post_update()===
Upgrade this module if necessary
Upgrade this module if necessary
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.0-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L246 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 246
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.1-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L269 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 269
*Signature: public function post_update($old_vers,$new_vers)
*Signature: public function post_update($old_vers,$new_vers)
*Parameters:
*Parameters:
Line 72: Line 77:
===pre_migrate()===
===pre_migrate()===
Perform any pre migrate actions for this module. This is for going from pre 3.2 versions where benefit data has been saved to the database.
Perform any pre migrate actions for this module. This is for going from pre 3.2 versions where benefit data has been saved to the database.
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.0-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L51 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 51
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.1-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L74 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 74
*Signature: protected function pre_migrate()
*Signature: protected function pre_migrate()
*Returns: [http://www.php.net/manual/en/language.types.boolean.php boolean ]
*Returns: [http://www.php.net/manual/en/language.types.boolean.php boolean ]
===pre_migrate3212()===
===pre_migrate3212()===
Perform any pre migrate actions for this module from 3.2.10 to 3.2.12 This is for going from pre 3.2 versions where benefit data has been saved to the database.
Perform any pre migrate actions for this module from 3.2.10 to 3.2.12 This is for going from pre 3.2 versions where benefit data has been saved to the database.
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.0-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L66 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 66
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.1-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L89 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 89
*Signature: protected function pre_migrate3212()
*Signature: protected function pre_migrate3212()
*Returns: [http://www.php.net/manual/en/language.types.boolean.php boolean ]
*Returns: [http://www.php.net/manual/en/language.types.boolean.php boolean ]
===pre_upgrade()===
===pre_upgrade()===
Run the pre upgrade for this module.  This can use the old config data before it has been changed from the config.
Run the pre upgrade for this module.  This can use the old config data before it has been changed from the config.
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.0-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L193 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 193
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.1-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L216 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 216
*Signature: public function pre_upgrade($old_vers,$new_vers,$new_storage)
*Signature: public function pre_upgrade($old_vers,$new_vers,$new_storage)
*Parameters:
*Parameters:
Line 91: Line 96:
===upgrade()===
===upgrade()===
Run the upgrade function for this module.
Run the upgrade function for this module.
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.0-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L222 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 222
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.1-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L245 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 245
*Signature: public function upgrade($old_vers,$new_vers)
*Signature: public function upgrade($old_vers,$new_vers)
*Parameters:
*Parameters:
Line 97: Line 102:
** [http://www.php.net/manual/en/language.types.string.php string ] $new_vers
** [http://www.php.net/manual/en/language.types.string.php string ] $new_vers
*Returns: [http://www.php.net/manual/en/language.types.boolean.php boolean ]
*Returns: [http://www.php.net/manual/en/language.types.boolean.php boolean ]
===validate_form_person_position()===
Checks to make sure the end date is after the start date for the person position.
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/ihris-manage/4.1-dev/annotate/head:/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php#L49 manage/modules/ManagePersonPosition/lib/iHRIS_Module_PersonPosition.php] on line 49
*Signature: public function validate_form_person_position($form)
*Parameters:
** [[Class: I2CE_Form (Development) | I2CE_Form]] $form
==Inherited Methods==
==Inherited Methods==
===__construct()===
===__construct()===
Line 109: Line 120:
===action_enable()===
===action_enable()===
This public method is inherited from [[Class: I2CE_Module (Development)#action_enable() | I2CE_Module->action_enable()]]
This public method is inherited from [[Class: I2CE_Module (Development)#action_enable() | I2CE_Module->action_enable()]]
===getCLIHooks()===
This public method is inherited from [[Class: I2CE_Module (Development)#getCLIHooks() | I2CE_Module->getCLIHooks()]]


===getCLIMethods()===
===getCLIMethods()===
Line 118: Line 126:
===getConfig()===
===getConfig()===
This public method is inherited from [[Class: I2CE_Module (Development)#getConfig() | I2CE_Module->getConfig()]]
This public method is inherited from [[Class: I2CE_Module (Development)#getConfig() | I2CE_Module->getConfig()]]
===getHooks()===
This public method is inherited from [[Class: I2CE_Module (Development)#getHooks() | I2CE_Module->getHooks()]]


===_hasMethod()===
===_hasMethod()===

Latest revision as of 08:27, 6 May 2015


This article describes the class iHRIS_Module_PersonPosition .

@filesource Class iHRIS_Module_PersonPosition

Variables

$do_migrate

A flag to determine if migrate needs to be called during the upgrade method.

$do_migrate3212

A flag to determine if migrate3212 needs to be called during the upgrade method.

Methods

action_initialize()

Method called before the module is enabled for the first time. @param boolean -- returns true on success. false on error.

action_person_position()

getHooks()

Return the array of hooks available in this module.

getLastPosition()

Find and return the most recent position held by this person.

getMethods()

isActive_Person()

Checks to see if the most recent position for this person is still active and doesn't have an end date for his/her position. @see getLastPosition()

isActive_PersonPosition()

Checks to see if the most recent position for this person is still active and doesn't have an end date for his/her position. @see getLastPosition()

migrate()

Perform the migrate actions for this module This is for going from pre 3.2 versions where benefit data has been saved to the database.

migrate3212()

Perform the migrate actions for this module from 3.2.10 to 3.2.12 This is for going from pre 3.2 versions where benefit data has been saved to the database.

post_update()

Upgrade this module if necessary

pre_migrate()

Perform any pre migrate actions for this module. This is for going from pre 3.2 versions where benefit data has been saved to the database.

pre_migrate3212()

Perform any pre migrate actions for this module from 3.2.10 to 3.2.12 This is for going from pre 3.2 versions where benefit data has been saved to the database.

pre_upgrade()

Run the pre upgrade for this module. This can use the old config data before it has been changed from the config.

upgrade()

Run the upgrade function for this module.

validate_form_person_position()

Checks to make sure the end date is after the start date for the person position.

Inherited Methods

__construct()

This public method is inherited from I2CE_Module->__construct()

action_configure()

This public method is inherited from I2CE_Module->action_configure()

action_disable()

This public method is inherited from I2CE_Module->action_disable()

action_enable()

This public method is inherited from I2CE_Module->action_enable()

getCLIMethods()

This public method is inherited from I2CE_Module->getCLIMethods()

getConfig()

This public method is inherited from I2CE_Module->getConfig()

_hasMethod()

This public method is inherited from I2CE_Fuzzy->_hasMethod()

Inherited Fuzzy Methods

launchBackgroundProcess()

This method is inherited from I2CE_Module->launchBackgroundProcess()

launchBackgroundPHPScript()

This method is inherited from I2CE_Module->launchBackgroundPHPScript()

launchBackgroundPage()

This method is inherited from I2CE_Module->launchBackgroundPage()

userMessage()

This method is inherited from I2CE_Fuzzy->userMessage()