Class: I2CE CustomReport: Difference between revisions
No edit summary |
No edit summary |
||
Line 1: | Line 1: | ||
This article desrcibes the class ''I2CE_CustomReport''. | This article desrcibes the class ''I2CE_CustomReport''. | ||
*Extends the class: [[Class: I2CE_Fuzzy | I2CE_Fuzzy]]. | *Extends the class: [[Class: I2CE_Fuzzy | I2CE_Fuzzy]]. | ||
*Parent Classses: [[Class: I2CE_Fuzzy | I2CE_Fuzzy]] | |||
*Location: Part of the module [[iHRIS Module List#CustomReports|CustomReports]] in the package [https://launchpad.net/i2ce I2CE] | *Location: Part of the module [[iHRIS Module List#CustomReports|CustomReports]] in the package [https://launchpad.net/i2ce I2CE] | ||
*Source: Defined in the file [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.0-release/annotate/head:/modules/CustomReports/lib/I2CE_CustomReport.php modules/CustomReports/lib/I2CE_CustomReport.php] | *Source: Defined in the file [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.0-release/annotate/head:/modules/CustomReports/lib/I2CE_CustomReport.php modules/CustomReports/lib/I2CE_CustomReport.php] |
Revision as of 14:01, 17 October 2009
This article desrcibes the class I2CE_CustomReport.
- Extends the class: I2CE_Fuzzy.
- Parent Classses: I2CE_Fuzzy
- Location: Part of the module CustomReports in the package I2CE
- Source: Defined in the file modules/CustomReports/lib/I2CE_CustomReport.php
- Author: Carl Leitner <litlfred@ibiblio.org>
I2CE_CustomReport
Variables
$config
The magic data node holding the configuration information for this report $var protected I2CE_MagicDataNode $config
- Type: protected $config
$table
$var protected string $table the name of the cached table of the report
- Type: protected $table
$tmp_table
$var protected string $tmp_table the temporary name of the cached table of the report
- Type: protected $tmp_table
$db
The instance of the database to perform queries on.
- Type: protected MDB2 $db
$populate_queries
an array of queries used to populate the cached reports table(s)
- Type: protected array $populate_queries
$init_queries
an array of queries used to inialize the cached reports table(s)
- Type: protected array $init_queries
$get_field_def
- Type: protected MDB2_PreparedStatement $get_field_def
$report_table_cols
- Type: static protected $report_table_cols
$hooman
- Type: static protected $hooman
$reportedFunctions
- Type: protected $reportedFunctions
Methods
__construct()
The constructor
- Signature: public function __construct($report)
- Parameters:
- string $report
The report name
- string $report
_generateCache()
- Signature: protected function _generateCache()
generateCache()
Below is the code to actually handle generation of reports Generate the cached report
- Signature: public function generateCache($force,$cache_forms)
- Parameters:
getCachedTableName()
Below is the static code to actually handle checking/setting the status of a cached report
- Signature: static public function getCachedTableName($report,$withDB,$table_prefix)
- Parameters:
- $report
- $withDB
- Default Value: true
- $table_prefix
- Default Value:
getColumnsInReportTable()
Get the actual columns in the cached report table
- Signature: static public function getColumnsInReportTable($report)
- Parameters:
- $report
getCreateField()
- Signature: protected function getCreateField($form,$field,$name)
- Parameters:
- $form
- $field
- $name
getFormRelationship()
- Signature: public function getFormRelationship()
getFormsRequiredByReport()
Gets the forms required by the report @param string $report
- Signature: public function getFormsRequiredByReport()
- Returns: array
of string
getLastGenerationTime()
- Signature: static public function getLastGenerationTime($report)
- Parameters:
- string $report
The shortname for the report
- string $report
- Returns: mixed.
False on failure, int the time the last report generation on sucess
getReportedFunctions()
- Signature: protected function getReportedFunctions()
getStatus()
Get the status of the requested report
- Signature: static public function getStatus($report,$hooman_readable)
- Parameters:
- string $report @param boolean hooman_readable defaults to false.
- $hooman_readable
- Default Value: false
- Returns: string
'does_not_exist','not_generated','generated','failed','in_progress', 'stale' if it is not hooman readable *
hasFailed()
Checks to see if a report has failed in its generation
- Signature: static public function hasFailed($report)
- Parameters:
- string $report
- Returns: mixed.
True if it has failed, false if it has not failed, null if the report does not exist.
isStale()
Check to see if a report is stale.
- Signature: static public function isStale($report)
- Parameters:
- string $report
- Returns: boolean
true/false
processReportingFunctions()
- Signature: protected function processReportingFunctions()
reportExists()
Checks to see if a report exists
setStatus()
Set the status us a report.
- Signature: static public function setStatus($report,$status)
- Parameters:
setupQueries()
- Signature: protected function setupQueries()
Inherited Methods
_hasMethod()
This public method is inherited from I2CE_Fuzzy->_hasMethod()
Inherited Fuzzy Methods
userMessage()
This method is inherited from I2CE_Fuzzy->userMessage()