Table
class Table extends UIComponent
Constants
SYSTEM_TEMPLATE_UI_FOLDER |
|
Properties
Link | $xf_link | from UIComponent | |
$link_id | |||
$GPvars | |||
Core | $mod | ||
protected array | $local_template_marker | from UIComponent | |
protected | $_overwrite_param_array | ||
protected bool|array|ModelCollection | $marker_content | from UIComponent | |
string | $mod_object_manager | from UIComponent | |
protected bool | $_orig_marker_content | from UIComponent | |
protected array | $_allowed_params_filter | from UIComponent | |
string | $unique_dom_id | from UIComponent | |
protected string | $uid | from UIComponent | |
string read-only | $_content | When used in template this property will contain the XML/HTML within the XUI Nodes |
from UIComponent |
protected | $process_priority | ||
protected | $process_queue_id | ||
protected | $process_queue | ||
$order_by | |||
$order_field | |||
$start | |||
$limit | |||
string | $order_field_secondary | ||
$order_fields | |||
$pre_ordered | |||
$new_order_field | |||
$new_order_by | |||
$new_start | |||
$sql_order_fields | |||
$field_filter | |||
$show_table_options | |||
$show_optional_fields | |||
$show_record_count | |||
$ajax_table | |||
$hidden_array_sort_field | |||
$hide_head_rows | |||
$order_array | |||
$fields_visible | |||
$field_tooltips | |||
$grouping | |||
$group_type | |||
$no_record_message | |||
array | $rows | ||
int | $rows_total | ||
$extension_extui | |||
protected | $xtag_params | ||
protected | $large_export | ||
string | $export_filename | When exported the file will have the name provided here. |
|
array | $cmd_array |
Methods
No description
Schedule Add Callback to Table Col (Will transform an existing col)
Schedule Add Col to Table
Schedule Add Callback to Table Col (Will transform an existing col)
Simple Replace Function to be used in callbacks
Add Single Row Object to Table
No description
No description
No description
No description
Enable periodical update (JS function)
No description
No description
No description
Export (get_table-Alias)
Schedule Fill table by array
No description
Fill Table with Query
Return the current table command which where given encoded via _GET params for this table instance
Returns the table id.
No description
No description
Return Page Control
Get HTML Table
Generates a unique dom id, dependent on the provided UID, as well as the current context.
Return new template view If using within module xui the tpl file should be named [class_name].tpl e.g. xui_core_table.tpl within the module's template folder
No description
No description
No description
Set cols to be hidden in output
Set cols to be visible in output
Registered a callback that will be called after the rows have been limited, passing the resulting row array as it's only parameter. The return of the callback can be used in any low-prio callback using the field 'field:_additional_data'. You should use this callback to load additional information required in the table that for some reason cannot be loaded in the fillby* Method, for example because you are using models and the data is from a foreign table.
Set Variable / Option for an array
Allow use of Caches (e.g. Query Cache)
No description
No description
Set formatting parameters for each column
Set Responsive COLs (Other cols wil be hidden if given responsive level is reached)
No description
set all fields that shall be exported
No description
No description
sets marker_content to passed data -> restore original content with reset_marker_content()
No description
No description
Used to inject params. Only allowed params will be used (see $allowed_params_filter)
Details
at line 176
__construct(string|bool $table_id = false, array $table_attributes = array())
No description
in
UIComponent at line 324
string
__toString()
No description
at line 1586
void
_add_col_callback_to_q(string $field, mixed $callback, mixed $cb_params, string $type = "body")
Schedule Add Callback to Table Col (Will transform an existing col)
at line 542
void
add_col(string $field, string $value, mixed $attributes = array(), $type = "body")
Schedule Add Col to Table
at line 560
void
add_col_callback(string $field, callable $callback, array $cb_params = array(), string $type = "body", string $priority = 'auto')
Schedule Add Callback to Table Col (Will transform an existing col)
at line 604
add_col_replace(mixed $field, array $replace, bool $regex = false, string $type = "body", string $priority = 'auto')
Simple Replace Function to be used in callbacks
$table->add_col_replace('city',array('*'=>array('field:zip_code',' ','field:city')));
at line 525
TableRow
add_row(array $record, string $type = "body", bool|string $class = false)
Add Single Row Object to Table
at line 1317
cb_property($matches)
No description
at line 2408
deactivateAjax()
No description
at line 299
void
enable_grouping(array|bool $fields = true, bool $hide_group_col = false)
No description
at line 222
enable_optional_fields(array $fields, array|bool $visible_fields = false)
No description
at line 267
enable_periodical_update(int $interval = 10)
Enable periodical update (JS function)
at line 386
enable_select_column(string $select_field, bool $multi_select = true, string|bool $field_name = false, array $condition = [])
No description
at line 256
void
enable_table_options(bool $large_export = false, int $large_export_limit = 100)
No description
at line 278
void
enable_tooltips(array $field_descriptions)
No description
at line 853
string
export(mixed $export_format = 'csv')
Export (get_table-Alias)
at line 511
void
fill_by_array(mixed $row_array, string $array_format = "assoc", string $type = "body")
Schedule Fill table by array
at line 479
fill_by_callback($callback)
No description
at line 491
fill_by_model_find(Model|ModelCollection $model, string $find_function = 'all')
No description
at line 468
void
fill_by_sql(string $pquery, array $params = array(), string $type = "body", bool $language = false)
Fill Table with Query
in
UIComponent at line 185
mixed
get($var)
Get Variable / Option
at line 2376
array
getCMDArray()
Return the current table command which where given encoded via _GET params for this table instance
at line 207
string
getId()
Returns the table id.
at line 2401
mixed
getTableUid()
No description
at line 1082
get_action()
No description
at line 2147
string
get_page_control()
Return Page Control
at line 1012
string
get_table(bool $export_format = false)
Get HTML Table
in
UIComponent at line 202
string
get_unique_dom_id()
Generates a unique dom id, dependent on the provided UID, as well as the current context.
in
UIComponent at line 289
Template|null
get_view(string|bool $section = false)
Return new template view If using within module xui the tpl file should be named [class_name].tpl e.g. xui_core_table.tpl within the module's template folder
at line 287
hide_head_rows(mixed $hide = true)
No description
in
UIComponent at line 72
init()
put your comment there.
..
in
UIComponent at line 221
string
parse_template(string $template_content, array|bool $marker_array = false)
No description
in
UIComponent at line 234
string|null
parse_template_cb_wrapper(mixed $matches)
No description
in
UIComponent at line 260
mixed|string
parse_xtag($xml_source)
No description
in
UIComponent at line 335
process()
Declared in Classes
at line 685
render()
No description
in
UIComponent at line 268
mixed
render_xtag_element()
No description
in
UIComponent at line 173
void
reset_marker_content()
restores original content of marker_content
in
UIComponent at line 106
void
set(mixed $var, mixed $value = false)
Set Variable / Option
at line 337
setHiddenFields(array $fields = [])
Set cols to be hidden in output
at line 329
setVisibleFields(array $fields = [])
Set cols to be visible in output
at line 632
set_additional_data_callback(mixed $callback)
Registered a callback that will be called after the rows have been limited, passing the resulting row array as it's only parameter. The return of the callback can be used in any low-prio callback using the field 'field:_additional_data'. You should use this callback to load additional information required in the table that for some reason cannot be loaded in the fillby* Method, for example because you are using models and the data is from a foreign table.
in
UIComponent at line 122
void
set_array(mixed $member_array, mixed $vars)
Set Variable / Option for an array
at line 363
set_cache(int|bool $ttl = false)
Allow use of Caches (e.g. Query Cache)
at line 411
set_column_attributes($attributes, $type = 'body')
No description
at line 448
void
set_column_class(array $col_class, string $type = 'body')
No description
at line 406
void
set_column_format(array $formatting_options, $type = 'body')
Set formatting parameters for each column
$formatting_options['field1']=array("format"=>"money",
"suffix"=>"EUR");
at line 422
set_column_responsive(array $responsive_cols, string $responsive_level = 'smartphone')
Set Responsive COLs (Other cols wil be hidden if given responsive level is reached)
at line 453
set_column_tooltips($tooltips)
No description
at line 2367
set_export_filter(array $filter)
set all fields that shall be exported
at line 314
void
set_grouping(string $field, bool $hide_group_col = false)
No description
at line 374
void
set_limit(int $limit)
No description
in
UIComponent at line 165
void
set_marker_content(mixed $marker_content = false)
sets marker_content to passed data -> restore original content with reset_marker_content()
in
UIComponent at line 90
set_mod(mixed $mod)
Set link to owning module
at line 351
void
set_order(string $field, string $direction = 'ASC', array $order_fields = null, string|bool $secondary_order_field = false)
No description
at line 189
void
set_params(string|bool $table_id = false, array $table_attributes = array())
No description
in
UIComponent at line 135
void
set_render_params(mixed $input_params = array())
Used to inject params. Only allowed params will be used (see $allowed_params_filter)