Kendo-UI description data source properties learning DataSource

kendo.data.DataSource data source
when using the grid of kendo-ui, background data acquired dynamically display the list, in this case, the data source provides KendoUI dispensing method, and each may be configured to operate the data source kinds of attributes.

Usage: var dataSource = new kendo.data.DataSource (option); option for a specific configuration attribute.

DataSource Configuration Properties Description

aggregate: Array whether the polymerization is calculated. The method of calculating the polymerization column can be configured. The default average including average, maximum value max, the minimum value min, the total number of count, the sum value sum.

autoSync: boolean data source is a synchronization request at the time and the background data exchange, defaults to false asynchronous request.

transport: Object remote data source load configuration.

read: Object remote data source pull configuration data.

create: Object data sources to create a remote configuration data.

update: Object remote configuration data source update data.

destroy: Object data source to delete data remotely.

url: request path.

type: request means such as: POST GET.

dataType: data types such as: json.

contentType: Request parameter request header format. Such as: appliaction / json.

cache: whether to cache, default false

parameterMap: time function parameter request remote data format and the information necessary to define the rear end of need.

read: Object remote data source pull configuration data.

             create: Object data sources to create a remote configuration data.

             update: Object remote configuration data source update data.

             destroy: Object data source to delete data remotely.

                     url: request path.

                     type: request means such as: POST GET.

                     dataType: data types such as: json.

                     contentType: Request parameter request header format. Such as: appliaction / JSON.

                     cache: whether to cache, default false

           the parameterMap: function parameter request when data needs to be defined as remote and format information required for the rear end.
--------------------- 
Author: CNOYG 
Source: CSDN 
Original: HTTPS: // blog.csdn.net/qq_35611143/article/details/81485634 
Copyright: This article is a blogger original article, reproduced, please attach Bowen link!

page: Current page Number data source to display.

pageSize: Number paging parameters of the data source.

data: Array | data source initialization String array of json or xml format. The configuration attribute request background when not needed. When the requested data has no effect to the remote data attribute.

schema: Object remote data parsing configuration. This property can be configured property and filter template and all fields of remote data and so on.

data: String | Function remote server is configured to return the data format, so as to acquire a data source, data corresponding to the filter. Array data format is not returned when the remote requires declared here how to remove or filter out the corresponding Array Array.

model: Remote Data Object model configuration.

id: primary key for the model.

fields: Column configuration model. Field Name column includes model, field attributes, default values, verification methods, where the attribute set in the adding, modifying will be reflected.

total: String | Function total number of remote data, where you need to specify the value of the return parameter field name, or use your own function to filter return. This and data properties as if it contains additional information, to tell the filter assembly needs to be returned in the background of how to obtain the data format of the data.

type: String format data sources, the default is json. Other formats include xml.

parse: Function data format, corresponding to filtered data.

Data: String | Function remote server is configured to return the data format, so as to acquire a data source, data corresponding to the filter. Array data format is not returned when the remote requires declared here how to remove or filter out the corresponding Array Array.

           model: Remote Data Object model configuration.

                     id: primary key for the model.

                     fields: Column configuration model. Field Name column includes model, field attributes, default values, verification methods, where the attribute set in the adding, modifying will be reflected.

          total: String | Function total number of remote data, where you need to specify the value of the return parameter field name, or use your own function to filter return. This and data properties as if it contains additional information, to tell the filter assembly needs to be returned in the background of how to obtain the data format of the data.

          type: String format data sources, the default is json. Other formats include xml.

          parse: Function data format, corresponding to filtered data.
--------------------- 
Author: CNOYG 
Source: CSDN 
Original: HTTPS: // blog.csdn.net/qq_35611143/article/details/81485634 
Copyright: This article is a blogger original article, reproduced, please attach Bowen link!

 


filter: Array | Object to filter the data source. You can specify a column data filtering, filed by the column specified properties, filtration properties by operator configuration, the filter configuration values ​​required value. Value operator has, startswith start character, eq equal, neq not equal.

group: Array | Object data display configuration packet. , Packet data may be displayed in a list by specifying the desired grouping on the field name. As shown, when the age is set to grouped objects, of the same age group were divided into a display.

serverSorting: Boolean whether the remote ordering service, the default is false; when set to true, sort will sort the data by requesting the remote server.

serverAggregates: Boolean whether the remote computing polymerization.

serverFiltering: Boolean Whether Remote Filtering data.

serverPaging: Boolean whether the remote formatted data.

serverGrouping: Boolean whether the remote packet data.

inPlaceSort: Boolean default is false. If set to true, then the original array will be executed when the sort operation as data sorting. This setting only supports local data.

offlineStorage: String | Object whether the offline cache to sessionStorage, you can set the cache key, or customize getItem setItem methods and data cache.
---------------------
Author: CNOYG
Source: CSDN
Original: https: //blog.csdn.net/qq_35611143/article/details/81485634
Disclaimer: This article as a blogger original article, reproduced, please attach Bowen link!

Guess you like

Origin www.cnblogs.com/water-1/p/11026606.html