Class WhRelationalColumn
- TbDataColumn
- WhRelationalColumn
Copyright: Copyright © 2amigos.us 2013-
License: New BSD License
Author: Antonio Ramirez <amigo.cobos@gmail.com>
Located at widgets/grid/WhRelationalColumn.php
Methods summary
public
|
|
public
|
#
renderDataCell( integer $row )
Overrides CDataColumn renderDataCell in order to wrap up its content with the object that will be used as a trigger. Important: Making use of links as a content for this of column is an error. |
protected
null|string
|
#
getPrimaryKey( CActiveRecord $data )
Helper function to return the primary key of the $data |
public
|
Magic methods summary
Properties summary
public
string
|
$url |
#
$url the route to call via AJAX to get the data from |
public
string
|
$cssClass |
#
$cssClass the class name that will wrap up the cell content. Important Note: this class will be used as the trigger for the AJAX call, so make sure is unique for the column. |
public
boolean
|
$cacheData |
#
$cacheData if set to true, there won't be more than one AJAX request. If set to false, the widget will continuously make AJAX requests. This is useful if the data could vary. If the data doesn't change then is better to set it to true. Defaults to true. |
public
string
|
$afterAjaxUpdate |
#
a javascript function that will be invoked if an AJAX call occurs. The function signature is<span
class="php-keyword1">function</span>(tr, rowid, data)
Example (add in a call to TbRelationalColumn): ... 'afterAjaxUpdate'=>'js:function(tr,rowid, data){ console.log(rowid); }', ... |
public
string
|
$ajaxErrorMessage |
#
$ajaxErrorMessage the message that is displayed on the newly created row in case there is an AJAX error. |