new TableConfiguration()
Configuration of a table
Extends
Methods
(static) forDomain(domain, contextopt) → {$k.TableConfiguration}
Returns the table confguration for the domain and the optional context)
Name | Type | Attributes | Description |
---|---|---|---|
domain | $k.Domain | Domain or internal name of a type of the table | |
context | $k.SemanticElement | <optional> | Context of the configuration |
- Since
- 4.1.0
- Type:
- $k.TableConfiguration
(static) from(configurationElement) → {$k.TableConfiguration}
Returns the confguration defined by the element
Name | Type | Description |
---|---|---|
configurationElement | $k.SemanticElement | The configuration element |
- Since
- 4.1.0
- Type:
- $k.TableConfiguration
columns(domain, contextObjectopt) → {object}
Returns the columns of the table
Name | Type | Attributes | Description |
---|---|---|---|
domain | $k.Domain | Domain or internal name of a type of the table | |
contextObject | object | <optional> | JSON render context object |
- Since
- 4.1.0
- Deprecated
- This function is deprecated and might be removed in future releases
- Type:
- object
configElement() → {$k.SemanticElement}
- Since
- 4.1.0
- Type:
- $k.SemanticElement
createFilterProperties(element)
Create properties for each column with a filter value to the element
Name | Type | Description |
---|---|---|
element | $k.SemanticElement |
- Version
- Experimental feature, might be removed at any time
- Since
- 4.1.0
elements(elementsOrQueryopt) → {Array.<$k.SemanticElement>}
Returns the filtered, sorted and paged elements of this table
Name | Type | Attributes | Description |
---|---|---|---|
elementsOrQuery | <optional> | Filter, sort and page elements. Input value can be: elements (no search, only filter, sort and page), a search (search the elements to used) or undefined (Internally, a search with the context object built) |
- Since
- 4.2.0
The filtered, sorted and paged elements
- Type:
- Array.<$k.SemanticElement>
filter(elements, filterDescriptions, disableInheritanceopt) → {Array.<$k.SemanticElement>}
Filters the elements by the given column values
Name | Type | Attributes | Description |
---|---|---|---|
elements | Array.<$k.SemanticElement> | ||
filterDescriptions | Array.<object> | Column index/name and value: {column: indexOrName, value: " Operator is one of: "containsPhrase", "covers", "distance", "equal" (or "=="), "equalBy", "equalCardinality", "equalGeo", "equalMaxCardinality", "equalMinCardinality", "equalPresentTime", "equalsTopicOneWay", "fulltext", "greater" (or ">"), "greaterOrEqual" (or ">="), "greaterOverlaps", "greaterPresentTime", "isCoveredBy", "less" (or "<"), "lessOrEqual" (or "<="), "lessOverlaps", "lessPresentTime", "notEqual" (or "!="), "overlaps", "range", "regexEqual", "regexFulltext", "unmodifiedEqual", "words" | |
disableInheritance | boolean | <optional> | True if the query should only match direct instances/subtypes |
- Since
- 4.1.0
If the filter values are invalid
If the filter value for a column is missing
If filtering was not possible
The filtered elements
- Type:
- Array.<$k.SemanticElement>
configuration.filter(elements, [ {column: "familyName", value: "Doe" }])
render(elementsopt, keyFilteropt, detailFilteropt) → {Array.<object>}
Renders the elements as literal objects
Name | Type | Attributes | Description |
---|---|---|---|
elements | <optional> | Elements, query or undefined | |
keyFilter | object | <optional> | Alternative 1 (preferred): a $k.JSONRenderContext Alternative 2 (compatibility only): A filter. See $k.JSONRenderContext.prototype.setFilters(). |
detailFilter | object | <optional> | Only used if the key filter is not a $k.JSONRenderContext. See $k.JSONRenderContext.prototype.setLevelsOfDetail() |
- Since
- 4.1.0
- Deprecated
- This function is deprecated and might be removed in future releases
The rendered objects
- Type:
- Array.<object>
renderExcel(elements, entity, templateopt, conversionopt, variablesopt)
Renders the elements as an Excel file
Name | Type | Attributes | Description |
---|---|---|---|
elements | Array.<$k.SemanticElement> | The elements to render | |
entity | $k.NetEntity | The render target | |
template | $k.Instance | <optional> | List template |
conversion | $k.SemanticElement | <optional> | The semantic element representing the document conversion |
variables | object | <optional> | Additional variables to pass to the template |
- Version
- Experimental feature, might be removed at any time
- Since
- 4.1.0
When the elements could not be rendered
search(domain, filterDescriptions, disableInheritanceopt) → {Array.<$k.SemanticElement>}
Find the elements by the given column values
Name | Type | Attributes | Description |
---|---|---|---|
domain | $k.Domain | Domain or internal name of a type of the table | |
filterDescriptions | Array.<object> | Column index/name and value: {column: indexOrName, value: " Operator is one of: "containsPhrase", "covers", "distance", "equal" (or "=="), "equalBy", "equalCardinality", "equalGeo", "equalMaxCardinality", "equalMinCardinality", "equalPresentTime", "equalsTopicOneWay", "fulltext", "greater" (or ">"), "greaterOrEqual" (or ">="), "greaterOverlaps", "greaterPresentTime", "isCoveredBy", "less" (or "<"), "lessOrEqual" (or "<="), "lessOverlaps", "lessPresentTime", "notEqual" (or "!="), "overlaps", "range", "regexEqual", "regexFulltext", "unmodifiedEqual", "words" | |
disableInheritance | boolean | <optional> | True if the query should only match direct instances/subtypes |
- Since
- 4.1.0
If the filter values are invalid
If the filter value for a column is missing
If filtering was not possible
- Type:
- Array.<$k.SemanticElement>
configuration.search([ {column: "dateOfBirth", value: "1970", operator: "less" }])
setContext(contextObject) → {$k.TableConfiguration}
Set the context object
Name | Type | Description |
---|---|---|
contextObject | object | Context object |
- Since
- 4.1.0
- Deprecated
- This function is deprecated and might be removed in future releases
- Type:
- $k.TableConfiguration
setQuery(query)
Set the query that returns the table elements. Note that the query is part of the context and will be overwritten if the context is set with setContext()
Name | Type | Description |
---|---|---|
query | $k.Query |
- Since
- 4.1.0
setRenderContext(renderContextObject)
Set render context
Name | Type | Description |
---|---|---|
renderContextObject | RenderContext |
- Since
- 5.3.0
- Inherited From
- Deprecated
- This function is deprecated and might be removed in future releases
sort(semanticElements, sortDescriptionsopt) → {Array.<$k.SemanticElement>}
Returns the elements sorted by the given columns and sort orders
Name | Type | Attributes | Description |
---|---|---|---|
semanticElements | Array.<$k.SemanticElement> | ||
sortDescriptions | Array.<object> | <optional> | Column index/name and optional sort order (ascending). The configured sort order is used if this parameter is undefined. |
- Since
- 4.1.0
The sorted elements
- Type:
- Array.<$k.SemanticElement>
configuration.sort(elements, [ {column: "familyName", ascending: false }, {column: "givenName" }])
sortDescriptions() → {Array.<object>}
Returns the configured sort descriptions of the table
- Since
- 4.1.0
- Deprecated
- This function is deprecated and might be removed in future releases
- Type:
- Array.<object>
toJSON()
- Deprecated
- This function is deprecated and might be removed in future releases