Skip to content

Custom Control Properties

michaelgsmith edited this page Nov 30, 2019 · 6 revisions

datatables-xpages

Required Properties

Property

Type

Description

thisView

Text

Unique identifier for this view

viewKey

Text

Tells the control which view definition to use

dataTableClass

Text

A CSS class name that gets applied to the DataTable and is used to refer to the table programmatically

Data Properties

Property

Type

Description

keys

Text

Values that will be added to the REST service query string in the format of &keys=<keys>

keysIsCategory

Boolean

Default is ‘false’. If true, the keys value will be added to the query string as &category=<keys>

search

Text

Should be a Domino full text search query

queryString

Text

Additional parameters that will be added to the REST service call

scroller

Boolean

Default is ‘false’. When set to true the DataTable scroller functional will be enabled. This is useful for larger data sets as it only creates the table rows as they are needed. See the DataTables documentation for more info.

scrollerCount

Number

Default is 0. If greater than 0 then the REST Service will only call for x amount of documents. The DataTable will keep calling the REST service until all records have been received.

Properties that affect the DataTable appearance

Property

Type

Description

dataTableClassDefault

Text

Can be used to override the default DataTable appearance.

showFixedHeader

Boolean

Defaults to ‘true’. Creates a fixed header that allows the table to be scrolled so that the header is always visible

fixedHeaderClass

Text

CSS class name that gets applied to the div that wraps the table header. Only applies if showFixedHeader=true

showFooter

Boolean

Defaults to ‘true’. Creates a footer at the bottom of the table that remains visible when the table is scrolled

fixedFooterClass

Text

CSS class name that gets applied to the fixed footer

showInfo

Boolean

Defaults to ‘true’. Show or hide the datatables_info div

infoClass

Text

CSS class name that gets applied to the datatables_info div

infoAttachTo

Text

A jQuery selector (class or id). During the initComplete event the datatables_info div will be moved to this element

Ordering

Boolean

Default is ‘true’. Turns column sorting on/off

showFilter

Boolean

Default is ‘true’. Shows/hides the DataTable filter

showFilterText

Boolean

Default is ‘true’. Shows/hides the text next to the DataTables filter field

filterPlaceholder

Text

Text that will placed in a placeholder attr for the filter field

filterText

Text

Text that can be used to replace the default DataTables filter label of ‘filter’

filterAttachTo

Text

A jQuery selector (class or id). During the initComplete event the datatables_filter element will be prepended to this element

showPaging

Boolean

Default is ‘false’. Turns paging on/off

PAGING CONTROLLED FROM VIEW DEF

attachPagerTo

Text

A jQuery selector (class or id). During the initComplete event the datatables_info div will be moved to this element

showCellBorders

Boolean

Default is ‘false’.

Events

Property

Type

Description

createdRow

Text

drawCallback

Text

initComplete

Text

loadOnInit

Boolean

Overrides the loadOnInit value in the Vew Definition. When loadOnInit is true the DataTable is initialized when the page loads. When false the DataTable needs to be initialized by calling .build()

refreshInterval

Number

Default is 0. The DataTable will be reloaded every x milliseconds

multiValue

Boolean

Default is ‘false’. If true then multi selection can be handled in the rowCallback

onError

Text