PHP Class Chumper\Datatable\Table

Afficher le fichier Open project: chumper/datatable Class Usage Examples

Protected Properties

Свойство Type Description
$className The name of the class the table will have later
$footerMode The footer's display mode
$idName The name of the id the table will have later
$script_view The view used to render the javascript
$table_view The view used to render the table

Méthodes publiques

Méthode Description
__construct ( )
addColumn ( )
countColumns ( ) : integer Count the number of columns in the datatable.
getCallbacks ( ) : array
getClass ( ) : String
getCustomValues ( ) : array
getData ( ) : array
getId ( ) : String
getOptions ( ) : array
noScript ( ) Instructs the table not to echo the javascript
removeOption ( string $key ) Remove an option item from the options array
render ( null $view = null, array $additional_template_variables = null ) : mixed
script ( null $view = null ) : mixed
setAliasMapping ( boolean $value = true ) Advise the Datatable to return the data mapped with the column name.
setCallbacks ( )
setClass ( $class ) Set the name of the class that will be used by the datatable.
setCustomValues ( )
setData ( array $data )
setId ( string $id = '' )
setOptions ( ) Set a single option or an array of options for the jquery call
setOrder ( $order = [] )
setUrl ( $url )
showFooter ( $value = 'columns' ) Set the footer display mode.

Private Methods

Méthode Description
createMapping ( ) : array

Method Details

__construct() public méthode

public __construct ( )

addColumn() public méthode

public addColumn ( )

countColumns() public méthode

Count the number of columns in the datatable.
public countColumns ( ) : integer
Résultat integer

getCallbacks() public méthode

public getCallbacks ( ) : array
Résultat array

getClass() public méthode

public getClass ( ) : String
Résultat String

getCustomValues() public méthode

public getCustomValues ( ) : array
Résultat array

getData() public méthode

public getData ( ) : array
Résultat array

getId() public méthode

public getId ( ) : String
Résultat String

getOptions() public méthode

public getOptions ( ) : array
Résultat array

noScript() public méthode

Instructs the table not to echo the javascript
public noScript ( )

removeOption() public méthode

Remove an option item from the options array
public removeOption ( string $key )
$key string the name of the key to remove from the options.

render() public méthode

public render ( null $view = null, array $additional_template_variables = null ) : mixed
$view null
$additional_template_variables array
Résultat mixed

script() public méthode

public script ( null $view = null ) : mixed
$view null
Résultat mixed

setAliasMapping() public méthode

Advise the Datatable to return the data mapped with the column name.
public setAliasMapping ( boolean $value = true )
$value boolean explicitly set if the table should be aliased or not

setCallbacks() public méthode

public setCallbacks ( )

setClass() public méthode

Set the name of the class that will be used by the datatable.
public setClass ( $class )
$class the name of the class

setCustomValues() public méthode

public setCustomValues ( )

setData() public méthode

public setData ( array $data )
$data array

setId() public méthode

public setId ( string $id = '' )
$id string

setOptions() public méthode

Set a single option or an array of options for the jquery call
public setOptions ( )

setOrder() public méthode

public setOrder ( $order = [] )

setUrl() public méthode

public setUrl ( $url )
$url

showFooter() public méthode

Set the footer display mode.
public showFooter ( $value = 'columns' )
$value the one of next values: 'hidden', 'columns', 'empty'

Property Details

$className protected_oe property

The name of the class the table will have later
protected $className

$footerMode protected_oe property

The footer's display mode
protected $footerMode

$idName protected_oe property

The name of the id the table will have later
protected $idName

$script_view protected_oe property

The view used to render the javascript
protected $script_view

$table_view protected_oe property

The view used to render the table
protected $table_view