Agile Toolkit
4.2
Agile Toolkit is a powerful web development framework. Inspired by GUI Applications development
|
Public Member Functions | |
init () | |
addTotals ($fields=null) | |
updateTotals () | |
formatTotalsRow () | |
formatRow () | |
renderRows () | |
render () | |
defaultTemplate () | |
Data Fields | |
$totals = false | |
$totals_t = false | |
Protected Attributes | |
$item_tag = 'row' | |
$container_tag = 'rows' | |
$row_t | |
$odd_even = null |
CompleteLister is very similar to regular Lister, but will use <?rows?><?row?>blah<?/?><?/?> structrue inside template. Also adds support for totals.
Use: $list=$this->add('CompleteLister'); $list->setModel('User'); $list->addTotals(); Template (view/users.html): Users <?rows?> <?row?>
<?$desc?> <?/row?>
Sample template. Will be ignored <?/rows?> <?totals?> <?$row_count?> user<?$plural_s?>. <?/?>
addTotals | ( | $ | fields = null | ) |
Enable total calculation for specified array of fields. If not specified, all field totals are calculated
defaultTemplate | ( | ) |
Redefine to return default template, when 4th argument of add() is omitted
Reimplemented from Lister.
Reimplemented in Paginator_Basic, Grid_Advanced, Menu_Basic, Grid_Basic, and InfoWindow.
formatRow | ( | ) |
Redefine and change $this->current_row to format data before it appears
Reimplemented from Lister.
Reimplemented in Grid_Basic.
formatTotalsRow | ( | ) |
Additional formatting for Totals row
Reimplemented in Grid_Advanced.
init | ( | ) |
Initialize object. Always call parent
This method is called for initialization
Reimplemented from AbstractObject.
Reimplemented in Grid_Advanced, Menu_Basic, Grid_Basic, InfoWindow, and Paginator_Basic.
render | ( | ) |
Default render. Generates HTML presentation of the view based on $this->template and passes it to output() function which then inserts output into parent's template
For visual objects, their default action while rendering is rely on SMlite engine. For sake of simplicity and speed you can redefine this method with a simple call
Reimplemented from Lister.
Reimplemented in Grid_Advanced, Menu_Basic, and InfoWindow.
renderRows | ( | ) |
Reimplemented in Grid_Basic.
updateTotals | ( | ) |
Update totals on rows. Called at the start of formatRow()
Reimplemented in Grid_Advanced.
$container_tag = 'rows' [protected] |
Reimplemented in Menu_Basic.
$item_tag = 'row' [protected] |
Reimplemented in Menu_Basic.
$odd_even = null [protected] |
$row_t [protected] |
$totals = false |
Will contain accumulated totals for all fields
$totals_t = false |
Will be initialized to "totals" template when addTotals() is called
Reimplemented in Grid_Advanced.