Sla_options Class Reference

Report options for SLA reports. More...

Inheritance diagram for Sla_options:
Report_options

Public Member Functions

 setup_properties ()
 Properties should be completely setup - with translations and all - before loading any options, and options are loaded by the construct, so do initialization here.
 set ($name, $value)
 Set an option, with some validation.

Static Public Member Functions

static discover_options ($input=false)
 Finds properties to inject into.

Static Public Attributes

static $type = 'sla'
 A name for this report type that doesn't rely on splitting class_name() by _ This is used when saving the report.

Protected Member Functions

 calculate_time ($report_period)
 Calculates $this['start_time'] and $this['end_time'] based on an availability report style period such as "today", "last24hours" or "lastmonth".
 load_options ($id)
 Loads options for a saved report by id.

Detailed Description

Report options for SLA reports.


Member Function Documentation

Sla_options::calculate_time ( report_period  )  [protected]

Calculates $this['start_time'] and $this['end_time'] based on an availability report style period such as "today", "last24hours" or "lastmonth".

Parameters:
$report_period The textual period to set our options by
Returns:
false on errors, true on success

Reimplemented from Report_options.

static Sla_options::discover_options ( input = false  )  [static]

Finds properties to inject into.

. myself

You probably want setup_options_obj instead.

Parameters:
$input array = false Autodiscovers options using superglobals: $input > POST > GET
Returns:
array

Reimplemented from Report_options.

Sla_options::load_options ( id  )  [protected]

Loads options for a saved report by id.

Primarily exists so report-type-specific load-mangling can take place.

Parameters:
$id int
Returns:
array (empty if nothing was found)

The months array is indexed from 1 instead of 0 so make a new array with index from 1 to 12 with the SLA values from the db and fill the rest of the array with 0.0.

Reimplemented from Report_options.

Sla_options::set ( name,
value 
)

Set an option, with some validation.

Parameters:
$name Option name
$value Option value
Returns:
false on error, else true

Reimplemented from Report_options.


The documentation for this class was generated from the following file:
 All Data Structures Functions Variables

Generated on 19 Dec 2018 for ninja by  doxygen 1.6.1