\SS_ReportWrapper
SS_ReportWrapper is a base class for creating report wappers.
Wrappers encapsulate an existing report to alter their behaviour - they are implementations of
the standard GoF decorator pattern.
This base class ensure that, by default, wrappers behave in the same way as the report that is
being wrapped. You should override any methods that need to behave differently in your subclass
of SS_ReportWrapper.
It also makes calls to 2 empty methods that you can override and
Synopsis
class SS_ReportWrapper
extends SS_Report
{
- // members
- protected $baseReport;
- // Inherited members from SS_Report
- protected string $title;
- protected string $description;
- protected string $dataClass;
- // methods
- public void __construct()
- public void ID()
- public void parameterFields()
- public void columns()
- public void beforeQuery()
- public void afterQuery()
- public void sourceQuery()
- public void sourceRecords()
- public void title()
- public void group()
- public void sort()
- public void description()
- public void canView()
- // Inherited methods from SS_Report
- public void title()
- public void description()
- public void parameterFields()
- public void sourceQuery()
- public void records()
- public void columns()
- public void sortColumns()
- public void count()
- public void dataClass()
- public FieldSet getCMSFields()
- public void getCMSActions()
- public FormField getReportField()
- public boolean canView()
- public string TreeTitle()
- public string ID()
- public static void register()
- public static void unregister()
- public static An get_reports()
Hierarchy
Extends
Members
protected
- $baseReport
-
$dataClass
The class of object being managed by this report. - $description
—
string
This is a description about what this report does. Used by the ReportAdmin templates. - $title
—
string
This is the title of the report, used by the ReportAdmin templates.
Methods
public
- __construct()
- ID()
- afterQuery() — Override this method to perform some actions after querying.
- beforeQuery() — Override this method to perform some actions prior to querying.
- canView()
- columns()
- description()
- group()
- parameterFields()
- sort()
- sourceQuery()
- sourceRecords()
- title()
Inherited from SS_Report
public
- ID() — Return the ID of this Report class.
- TreeTitle() — Return the name of this report, which is used by the templates to render the name of the report in the report tree, the left hand pane inside ReportAdmin.
- canView()
- columns() — Return an map of columns for your report.
- count() — Return the number of records in this report with no filters applied.
- dataClass() — Return the data class for this report
- description() — Return the description of this report.
- getCMSActions()
- getCMSFields() — Returns a FieldSet with which to create the CMS editing form.
- getReportField() — Return a field, such as a {@link ComplexTableField} that is used to show and manipulate data relating to this report.
- get_reports() — Return the SS_Report objects making up the given list.
- parameterFields() — Return a FieldSet specifying the search criteria for this report.
- records() — Return a DataObjectSet records for this report.
- register() — Register a report.
- sortColumns()
- sourceQuery() — Return the {@link SQLQuery} that provides your report data.
- title() — Return the title of this report.
- unregister() — Unregister a report, removing it from the list