Check documentation for the latest version of dhtmlxSuite DataStore API DHTMLX Docs

DataStore API

Methods
add Adds a new record to the dataset.
attachEvent adds any user-defined handler to available events
bind binds 2 dataStore objects (just for filtration one of datasets. Changes in the master dataStore [creating, updating, deleting] doesn't reflect in the bound dataStore).
clearAll Removes all data from the component.
dataCount Returns the total count of items in DataStore. In case of dynamic loading the method returns the expected count of items.
detachEvent detaches a handler from an event
exists Returns true if an item with the defined ID already exists.
filter Filters DataStore by provided parameters.
first Returns the ID of the first item ( an item with the index == 0 )
getCursor get position of virtual cursor
idByIndex Returns the ID of an item with the specified index.
indexById Returns the index of an item with the specified ID.
item Returns hash of data related to the specific item.
last Returns the ID of the last item ( an item with the index == dataCount-1).
load loads data to the component via XML or JSON, usually data-values pairs
next Returns the ID of the next item ( an item with the index == current + 1).
parse Parse an object or a string and fill the DataStore by parsed items.
previous Returns the ID of the previous item ( an item with the index == current - 1).
remove Removes item by the ID.
saveBatch Makes simultaneous saving several components (batch saving).
serialize serializes data to a JSON object .
setCursor set virtual cursor
sort Sorts a dataset.
sync binds 2 dataStore objects (changes in the master dataStore [creating, updating, deleting] reflect in the bound dataStore).
unbind unbinds 2 DataStore objects
update updates a specific item
Events
onAfterAdd fires after item adding is finished.
onAfterCursorChange event called after value of cursor was changed
onAfterDelete Occurs after item deleting is finished.
onBeforeAdd fires before item adding is initiated
onBeforeCursorChange event called just before value of cursor will be changed
onBeforeDelete fires before item deleting is initiated
onDataRequest called when component issues dynamic request for a data
onLoadError occurs when server side returns invalid response during data loading
onStoreUpdated fires when data was changed by any means
onXLE fires when the data loading is finished and a component or data is rendered
onXLS fires when XML loading started
Back to top