GridColumn Class [PHP]

Summary

Properties Description
Aggregate Get or set the aggregation function.
Align Get or set alignment of column's text
AllowExporting Get or set whether column will be exported.
AllowFiltering Get or set whether filtering section is show and allow user to filter on this column.
AllowGrouping Get or set whether column is able to group by drag and drop.
AllowResizing Get or set whether user can resize the column.
AllowSorting Get or set whether grid allow user to sort this column.
CssClass Get or set the css class for column.
DataField Get or set the database field name that the column associates with.
DataFieldPrefix Set the extra prefix for data field name.
DefaultValue Get or set the default value.
Filter Get or set filtering condition for column.
FilterOptions Get or set default filter options for the column.
FooterStyle Get or set style of column's footer.
FooterText Get or set text of column's footer.
Group Get or set whether grid data will be grouped by this column.
GroupSettings Set the group settings for column.
HeaderStyle Get or set style of header.
HeaderText Get or set the text of header.
ItemStyle Get or set style of data cell in column.
NullDisplayText Get or set the text display when data is null.
ReadOnly Get or set whether the column is readonly.
Sort Get or set the sorting for the column.
TableView Get the tableview instance which contains this column.
Valign Get or set vertical alignment of column's text
Visible Get or set whether the column is visible.
Width Get or set width of the column.
Wrap Get or set whether the column's text is wrap.
Methods Description
InlineEditRender Render cell in inline edit mode.
FormEditRender Render cell in form edit mode.
AddValidator Add validator to column.
GetEditValue Return the updated value.
GetFilterValue Return the filtering value.
RenderHeader Render header of column
RenderFooter Render footer of column
RenderFilter Render filtering section of column.
Render Render data cell.
GetUniqueID Return the column's unique ID which is assigned by KoolGrid.

Properties Detail

AggregateTop

string Aggregate

Get or set the aggregation function. The result of column's aggregation will be added to footer text.

Show/Hide Code

Supported from version: 1.4.0.0

AlignTop

string Align

Get or set alignment of column's text

Default value : "left"

Allowed values :

  • "left" : Colum's text aligns in left side
  • "center" : Colum's text aligns in center
  • "right" : Colum's text aligns in right side

Show/Hide Code

Supported from version: 1.0.0.0

AllowExportingTop

bool AllowExporting

Get or set whether column will be exported.

Show/Hide Code

Supported from version: 2.0.0.0

AllowFilteringTop

bool AllowFiltering

Get or set whether filtering section is show and allow user to filter on this column.

Show/Hide Code

Supported from version: 1.0.0.0

AllowGroupingTop

bool AllowGrouping

Get or set whether column is able to group by drag and drop.

Show/Hide Code

Supported from version: 2.0.0.0

AllowResizingTop

bool AllowResizing

Get or set whether user can resize the column.

Show/Hide Code

Supported from version: 1.0.0.0

AllowSortingTop

bool AllowSorting

Get or set whether grid allow user to sort this column.

Show/Hide Code

Supported from version: 1.0.0.0

CssClassTop

string CssClass

Get or set the css class for column.

Show/Hide Code

Supported from version: 1.0.0.0

DataFieldTop

string DataField

Get or set the database field name that the column associates with.

Show/Hide Code

Supported from version: 1.0.0.0

DataFieldPrefixTop

string DataFieldPrefix

This field is needed when KoolGrid is used with HugeMySQLDataSource and the field name is named with table or alias prefix. This prefix is needed for KoolGrid to function correctly in filtering, grouping and sorting. Please have a look at our example.

Show/Hide Code

Supported from version: 3.6.0.0

DefaultValueTop

object DefaultValue

Get or set the default value. This value will be shown as starting value when users do insert or edit.

Show/Hide Code

Supported from version: 3.0.0.0

FilterTop

array Filter

Get or set filtering condition for column.

Show/Hide Code

Supported from version: 1.0.0.0

FilterOptionsTop

array FilterOptions

Get or set default filter options for the column.

Default value : array("No_Filter","Equal","Not_Equal","Greater_Than","Less_Than","Greater_Than_Or_Equal","Less_Than_Or_Equal","Contain","Not_Contain","Start_With","End_With");

Show/Hide Code

Supported from version: 1.0.0.0

FooterStyleTop

Style FooterStyle

Get or set style of column's footer.

Show/Hide Code

Supported from version: 1.0.0.0

FooterTextTop

string FooterText

Get or set text of column's footer.

Show/Hide Code

Supported from version: 1.0.0.0

GroupTop

bool Group

Get or set whether grid will be grouped by this column.

Default value : 0

Allowed values :

  • true :
  • false :

Show/Hide Code

Supported from version: 1.0.0.0

GroupSettingsTop

GridGroup GroupSettings

Set the group settings for column.

Default value : 0

Show/Hide Code

Supported from version: 1.0.0.0

HeaderStyleTop

Style HeaderStyle

Get or set style of header.

Show/Hide Code

Supported from version: 1.0.0.0

HeaderTextTop

string HeaderText

Get or set the text of header.

Show/Hide Code

Supported from version: 1.0.0.0

ItemStyleTop

Style ItemStyle

Get or set style of data cell in column.

Show/Hide Code

Supported from version: 1.0.0.0

NullDisplayTextTop

string NullDisplayText

Get or set the text display when data is null.

Show/Hide Code

Supported from version: 3.0.0.0

ReadOnlyTop

bool ReadOnly

Get or set whether the column is readonly.

Show/Hide Code

Supported from version: 1.0.0.0

SortTop

int Sort

Get or set the sorting for the column.

Default value : 0

Allowed values :

  • 0 : No sorting
  • -1 : Sort desc
  • 1 : Sort asc

Show/Hide Code

Supported from version: 1.0.0.0

TableViewTop

GridTableView TableView

Get the tableview instance which contains this row. Note: This property is only available after grid has been processed.

Show/Hide Code

Supported from version: 1.6.0.0

ValignTop

string Valign

Get or set vertical alignment of column's text

Default value : "left"

Allowed values :

  • "top" : Top alignment
  • "middle" : Middle alignment
  • "left" : Bottom alignment

Show/Hide Code

Supported from version: 1.0.0.0

VisibleTop

bool Visible

Get or set whether the column is visible.

Show/Hide Code

Supported from version: 1.0.0.0

WidthTop

string Width

Get or set width of the column. The width except both px value and % value.

Show/Hide Code

Supported from version: 1.0.0.0

WrapTop

bool Wrap

Get or set whether the column's text is wrap.

Show/Hide Code

Supported from version: 1.0.0.0

Methods Detail

InlineEditRenderTop

string InlineEditRender(GridRow $row)

Render cell in inline edit mode.

Show/Hide Code

Supported from version: 1.0.0.0

FormEditRenderTop

string FormEditRender(GridRow $row)

Render cell in form edit mode.

Show/Hide Code

Supported from version: 1.0.0.0

AddValidatorTop

string AddValidator(GridValidator $validator)

Add validator to column. The validator will make sure that input from user is valid before performing any data operation. More information of grid validator, please have a look at Validators section.

Show/Hide Code

Supported from version: 1.3.0.0

GetEditValueTop

string GetEditValue()

Return the updated value.

Show/Hide Code

Supported from version: 1.0.0.0

GetFilterValueTop

string GetFilterValue()

Return the filtering value.

Show/Hide Code

Supported from version: 1.0.0.0

RenderHeaderTop

string RenderHeader(GridRow $row)

Render header of column

Show/Hide Code

Supported from version: 1.0.0.0

RenderFooterTop

string RenderFooter(GridRow $row)

Render footer of column

Show/Hide Code

Supported from version: 1.0.0.0

RenderFilterTop

string RenderFilter(GridRow $row)

Render filtering section of column.

Show/Hide Code

Supported from version: 1.0.0.0

RenderTop

string Render(GridRow $row)

Render data cell.

Show/Hide Code

Supported from version: 1.0.0.0

GetUniqueIDTop

string GetUniqueID()

Return the column's unique ID which is assigned by KoolGrid.

Show/Hide Code

Supported from version: 2.3.0.0