PHP Class Prado\Web\UI\ActiveControls\TActiveDataGrid
TActiveDataGrid represents a data bound and updatable grid control which is the
active counterpart to the original {@link TDataGrid} control.
This component can be used in the same way as the regular datagrid, the only
difference is that the active datagrid uses callbacks instead of postbacks
for interaction.
There are also active datagrid columns to work with the TActiveDataGrid, which are
- {@link TActiveBoundColumn}, the active counterpart to {@link TBoundColumn}.
- {@link TActiveLiteralColumn}, the active counterpart to {@link TLiteralColumn}.
- {@link TActiveCheckBoxColumn}, the active counterpart to {@link TCheckBoxColumn}.
- {@link TActiveDropDownListColumn}, the active counterpart to {@link TDropDownListColumn}.
- {@link TActiveHyperLinkColumn}, the active counterpart to {@link THyperLinkColumn}.
- {@link TActiveEditCommandColumn}, the active counterpart to {@link TEditCommandColumn}.
- {@link TActiveButtonColumn}, the active counterpart to {@link TButtonColumn}.
- {@link TActiveTemplateColumn}, the active counterpart to {@link TTemplateColumn}.
Please refer to the original documentation of the regular counterparts for usage.
Mostra file
Open project: pradosoft/prado
Protected Properties
Property |
Type |
Description |
|
$_surroundingTag |
|
the tag used to render the surrounding container |
|
Public Methods
Protected Methods
Private Methods
Method |
Description |
|
renderDataGrid ( $writer ) |
Renders the datagrid by writing a {@link getSurroundingTag()} with the container id obtained
from {@link getSurroundingTagId()} which will be called by the replacement method of the client
script to update it's content. |
|
renderPager ( ) |
Loops through all {@link TActivePager} on the page and registers the ones which are set to paginate
the datagrid for rendering. This is to ensure that the connected pagers are also rendered if the
data source changed. |
|
Method Details
__construct()
public method
Creates a new callback control, sets the adapter to
TActiveControlAdapter.
getActiveControl()
public method
public getActiveControl ( ) : TBaseActiveControl |
return |
TBaseActiveControl |
standard active control options. |
getAutoGenerateColumnName()
protected method
getSurroundingTag()
public method
Gets the tag used to render the surrounding container. Defaults to 'div'.
getSurroundingTagID()
public method
Returns the id of the surrounding container.
If the datagrid did not pass the prerender phase yet, it will register itself for rendering later.
Else it will call the {@link renderDataGrid()} method which will do the rendering of the datagrid.
setDataSource()
public method
In addition, the render method of all connected pagers is called so they
get updated when the data source is changed. Also the datagrid registers
itself for rendering in order to get it's content replaced on client side.
setSurroundingTag()
public method
Sets the tag used to render the surrounding container.
Property Details
$_surroundingTag protected_oe property
the tag used to render the surrounding container
protected $_surroundingTag |