Agile Toolkit  4.2
Agile Toolkit is a powerful web development framework. Inspired by GUI Applications development
Grid_Basic Class Reference
Inheritance diagram for Grid_Basic:
CompleteLister Lister View AbstractView AbstractObject Grid_Advanced Grid InfoWindow MVCGrid

Public Member Functions

 init ()
 initWidget ()
 defaultTemplate ()
 importFields ($model, $fields=undefined)
 addColumn ($formatters, $name=null, $descr=null)
 precacheTemplate ()
 formatRow ()
 renderRows ()
 format_shorttext ($field)

Data Fields

 $columns = array()
 $default_controller = 'Controller_MVCGrid'
 $sort_icons

Detailed Description

This is a Basic Grid implementation, which produces fully functional HTML grid capable of filtering, sorting, paginating and using multiple column formatters. Basic Grid no longer implements the column formatters, instead they have been moved into Grid_Advanced

Use: $grid=$this->add('Grid'); $grid->setModel('User'); See http://agiletoolkit.org/about/license


Member Function Documentation

addColumn ( formatters,
name = null,
descr = null 
)

Redefine to return default template, when 4th argument of add() is omitted

Reimplemented from CompleteLister.

Reimplemented in Grid_Advanced, and InfoWindow.

format_shorttext ( field)
formatRow ( )

Redefine and change $this->current_row to format data before it appears

Reimplemented from CompleteLister.

importFields ( model,
fields = undefined 
)

Reimplemented in Grid_Advanced.

init ( )

Initialize object. Always call parent

This method is called for initialization

Reimplemented from CompleteLister.

Reimplemented in Grid_Advanced, and InfoWindow.

You might want Grid to be enganced with a widget. Initialize it here or define this as empty function to avoid

Reimplemented from CompleteLister.


Field Documentation

$columns = array()
$default_controller = 'Controller_MVCGrid'

When using setModel() with Views some views will want to populate fields, columns etc corresponding to models meta-data. That is the job of Controller. When you create a custom controller for your view set this property to point at your controller and it will be used automatically

Reimplemented from AbstractView.

Reimplemented in Grid_Advanced.

$sort_icons
Initial value:
array(
        'ui-icon ui-icon-arrowthick-2-n-s',
        'ui-icon ui-icon-arrowthick-1-n',
        'ui-icon ui-icon-arrowthick-1-s',
    )

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