/* This file is part of Ext JS 3.4 Copyright (c) 2011-2013 Sencha Inc Contact: http://www.sencha.com/contact GNU General Public License Usage This file may be used under the terms of the GNU General Public License version 3.0 as published by the Free Software Foundation and appearing in the file LICENSE included in the packaging of this file. Please review the following information to ensure the GNU General Public License version 3.0 requirements will be met: http://www.gnu.org/copyleft/gpl.html. If you are unsure which license is appropriate for your use, please contact the sales department at http://www.sencha.com/contact. Build date: 2013-04-03 15:07:25 */ Ext.data.JsonP.Ext_data_DirectStore({"alternateClassNames":[],"aliases":{"widget":["directstore"]},"enum":null,"parentMixins":[],"tagname":"class","subclasses":[],"extends":"Ext.data.Store","uses":[],"html":"
Hierarchy
Ext.util.ObservableExt.data.StoreExt.data.DirectStoreFiles
Small helper class to create an Ext.data.Store configured with an\nExt.data.DirectProxy and Ext.data.JsonReader to make interacting\nwith an Ext.Direct Server-side Provider easier.\nTo create a different proxy/reader combination create a basic Ext.data.Store\nconfigured as needed.
\n\n\n\n\n*Note: Although they are not listed, this class inherits all of the config options of:
\n\n\ntrue to destroy the store when the component the store is bound\nto is destroyed (defaults to false).
\n\nNote: this should be set to true when using stores that are bound to only 1 component.
\n\nDefaults to: false
An object containing properties which are to be sent as parameters\nfor every HTTP request.
\n\n\nParameters are encoded as standard HTTP parameters using Ext.urlEncode.
\n\n\nNote: baseParams
may be superseded by any params
\nspecified in a load
request, see load
\nfor more details.
This property may be modified after creation using the setBaseParam
\nmethod.
Defaults to true (unless restful:true
). Multiple\nrequests for each CRUD action (CREATE, READ, UPDATE and DESTROY) will be combined\nand sent as one transaction. Only applies when autoSave
is set\nto false.
If Store is RESTful, the DataProxy is also RESTful, and a unique transaction is\n\n\n
generated for each record.
\nDefaults to: true
Provides the default values for the paramNames property. To globally modify the parameters\nfor all stores, this object should be changed on the store prototype.
\nDefaults to: {start: 'start', limit: 'limit', sort: 'sort', dir: 'dir'}
(optional)
A config object containing one or more event handlers to be added to this\nobject during initialization. This should be a valid listeners config object as specified in the\naddListener example for attaching multiple handlers at once.
\n\nDOM events from ExtJs Components
\n\n\nWhile some ExtJs Component classes export selected DOM events (e.g. \"click\", \"mouseover\" etc), this\n\n\n
is usually only done when extra value can be added. For example the DataView's\nclick
event passing the node clicked on. To access DOM\nevents directly from a Component's HTMLElement, listeners must be added to the Element after the Component\nhas been rendered. A plugin can simplify this step:
// Plugin is configured with a listeners config object.\n// The Component is appended to the argument list of all handler functions.\nExt.DomObserver = Ext.extend(Object, {\n constructor: function(config) {\n this.listeners = config.listeners ? config.listeners : config;\n },\n\n // Component passes itself into plugin's init method\n init: function(c) {\n var p, l = this.listeners;\n for (p in l) {\n if (Ext.isFunction(l[p])) {\n l[p] = this.createHandler(l[p], c);\n } else {\n l[p].fn = this.createHandler(l[p].fn, c);\n }\n }\n\n // Add the listeners to the Element immediately following the render call\n c.render = c.render.createSequence(function() {\n var e = c.getEl();\n if (e) {\n e.on(l);\n }\n });\n },\n\n createHandler: function(fn, c) {\n return function(e) {\n fn.call(this, e, c);\n };\n }\n});\n\nvar combo = new Ext.form.ComboBox({\n\n // Collapse combo when its element is clicked on\n plugins: [ new Ext.DomObserver({\n click: function(evt, comp) {\n comp.collapse();\n }\n })],\n store: myStore,\n typeAhead: true,\n mode: 'local',\n triggerAction: 'all'\n});\n
\n\n\n\nAn object containing properties which specify the names of the paging and\nsorting parameters passed to remote servers when loading blocks of data. By default, this\nobject takes the following form:
\n\n\n{\n start : 'start', // The parameter name which specifies the start row\n limit : 'limit', // The parameter name which specifies number of rows to return\n sort : 'sort', // The parameter name which specifies the column to sort on\n dir : 'dir' // The parameter name which specifies the sort direction\n}\n
\n\n\nThe server must produce the requested data block upon receipt of these parameter names.\nIf different parameter names are required, this property can be overriden using a configuration\nproperty.
\n\n\nA PagingToolbar bound to this Store uses this property to determine\nthe parameter names to use in its requests.\n\n
true to clear all modified record information each time\nthe store is loaded or when a record is removed (defaults to false). See getModifiedRecords\nfor the accessor method to retrieve the modified records.
\nDefaults to: false
The Reader object which processes the\ndata object and returns an Array of Ext.data.Record objects which are cached keyed by their\nid property.
\ntrue if sorting is to be handled by requesting the Proxy\nto provide a refreshed version of the data object in sorted order, as opposed to sorting the Record cache\nin place (defaults to false).
\n\nIf remoteSort is true, then clicking on a Grid Column's\nheader causes the current page to be requested from the server appending\nthe following two parameters to the params:
The name (as specified in the Record's\nField definition) of the field to sort on.
The direction of the sort, 'ASC' or 'DESC' (case-sensitive).
Defaults to: false
Defaults to false. Set to true to have the Store and the set\nProxy operate in a RESTful manner. The store will automatically generate GET, POST,\nPUT and DELETE requests to the server. The HTTP method used for any given CRUD\naction is described in Ext.data.Api.restActions. For additional information\nsee Ext.data.DataProxy.restful.
\n\nNote: if restful:true
batch
will\ninternally be set to false.
Defaults to: false
A config object to specify the sort order in the request of a Store's\nload operation. Note that for local sorting, the direction property is\ncase-sensitive. See also remoteSort and paramNames.\nFor example:
\n\nsortInfo: {\n field: 'fieldName',\n direction: 'ASC' // or 'DESC' (case sensitive for local sorting)\n}\n
\n\nIf passed, the id to use to register with the StoreMgr.
\n\nNote: if a (deprecated) id is specified it will supersede the storeId\nassignment.
\n\nThe Writer object which processes a record object for being written\nto the server-side database.
\n\n\nWhen a writer is installed into a Store the add, remove, and update\n\n\n
events on the store are monitored in order to remotely create records,\ndestroy records, or update records.
\n\nThe proxy for this store will relay any writexception events to this store.
\n\n\nSample implementation:\n\n\n
var writer = new Ext.data.JsonWriter({\n encode: true,\n writeAllFields: true // write all fields, not just those that changed\n});\n\n// Typical Store collecting the Proxy, Reader and Writer together.\nvar store = new Ext.data.Store({\n storeId: 'user',\n root: 'records',\n proxy: proxy,\n reader: reader,\n writer: writer, // <-- plug a DataWriter into the store just as you would a Reader\n paramsAsHash: true,\n autoSave: false // <-- false to delay executing create, update, destroy requests\n // until specifically told to do so.\n});\n
\n\n\n\nSee the corresponding configuration option
\nfor a description of this property.\nTo modify this property see setBaseParam
.
A MixedCollection containing the defined Fields\nfor the Records stored in this Store. Read-only.
\nTrue if this store is currently sorted by more than one field/direction combination.
\nTrue if this store is currently sorted by more than one field/direction combination.
\nTrue if the store has been destroyed already. Read only
\nObject containing overall sort direction and an ordered array of sorter configs used when sorting on multiple fields
\nObject containing overall sort direction and an ordered array of sorter configs used when sorting on multiple fields
\nThe Record constructor as supplied to (or created by) the\nReader. Read-only.
\n\nIf the Reader was constructed by passing in an Array of Ext.data.Field definition objects,\ninstead of a Record constructor, it will implicitly create a Record constructor from that Array (see\nExt.data.Record.create for additional details).
\n\n\nThis property may be used to create new Records of the type held in this Store, for example:
\n\n\n // create the data store\n var store = new Ext.data.ArrayStore({\n autoDestroy: true,\n fields: [\n {name: 'company'},\n {name: 'price', type: 'float'},\n {name: 'change', type: 'float'},\n {name: 'pctChange', type: 'float'},\n {name: 'lastChange', type: 'date', dateFormat: 'n/j h:ia'}\n ]\n });\n store.loadData(myData);\n\n // create the Grid\n var grid = new Ext.grid.EditorGridPanel({\n store: store,\n colModel: new Ext.grid.ColumnModel({\n columns: [\n {id:'company', header: 'Company', width: 160, dataIndex: 'company'},\n {header: 'Price', renderer: 'usMoney', dataIndex: 'price'},\n {header: 'Change', renderer: change, dataIndex: 'change'},\n {header: '% Change', renderer: pctChange, dataIndex: 'pctChange'},\n {header: 'Last Updated', width: 85,\n renderer: Ext.util.Format.dateRenderer('m/d/Y'),\n dataIndex: 'lastChange'}\n ],\n defaults: {\n sortable: true,\n width: 75\n }\n }),\n autoExpandColumn: 'company', // match the id specified in the column model\n height:350,\n width:600,\n title:'Array Grid',\n tbar: [{\n text: 'Add Record',\n handler : function(){\n var defaultData = {\n change: 0,\n company: 'New Company',\n lastChange: (new Date()).clearTime(),\n pctChange: 0,\n price: 10\n };\n var recId = 3; // provide unique id\n var p = new store.recordType(defaultData, recId); // create new record\n grid.stopEditing();\n store.insert(0, p); // insert a new record into the store (also see add)\n grid.startEditing(0, 0);\n }\n }]\n });\n
\n\nAdd Records to the Store and fires the add event. To add Records\nto the store from a remote source use load({add:true})
.\nSee also recordType
and insert
.
An Array of Ext.data.Record objects\nto add to the cache. See recordType.
\nAdds the specified events to the list of events which this Observable may fire.
\nEither an object with event names as properties with a value of true
\nor the first event name string if multiple event names are being passed as separate parameters.
. Event name if multiple event names are being passed as separate parameters.\nUsage:
\n\nthis.addEvents('storeloaded', 'storecleared');\n
\n\nAppends an event handler to this object.
\nThe name of the event to listen for.
\nThe method the event invokes.
\nThe scope (this
reference) in which the handler function is executed.\nIf omitted, defaults to the object which fired the event.
An object containing handler configuration.\nproperties. This may contain any of the following properties:
this
reference) in which the handler function is executed.\nIf omitted, defaults to the object which fired the event.\nCombining Options
\nUsing the options argument, it is possible to combine different types of listeners:
\n
\nA delayed, one-time listener.\n
myDataView.on('click', this.onClick, this, {\nsingle: true,\ndelay: 100\n});
\n\nAttaching multiple handlers in 1 call
\nThe method also allows for a single argument to be passed which is a config object containing properties\nwhich specify multiple handlers.\n
\n
myGridPanel.on({\n'click' : {\n fn: this.onClick,\n scope: this,\n delay: 100\n},\n'mouseover' : {\n fn: this.onMouseOver,\n scope: this\n},\n'mouseout' : {\n fn: this.onMouseOut,\n scope: this\n}\n});
\n\nOr a shorthand syntax:
\n
myGridPanel.on({\n'click' : this.onClick,\n'mouseover' : this.onMouseOver,\n'mouseout' : this.onMouseOut,\n scope: this\n});
\n\n(Local sort only) Inserts the passed Record into the Store at the index where it\nshould go based on the current sort information.
\nInvokes sortData if we have sortInfo to sort on and are not sorting remotely
\nbuilds a DataWriter instance when Store constructor is provided with a writer config-object instead of an instace.
\nWriter configuration
\nRevert to a view of the Record cache with no filtering applied.
\nIf true the filter is cleared silently without firing the\ndatachanged event.
\nClears records from modified array after an exception event.\nNOTE: records are left marked dirty. Do we want to commit them even though they were not updated/realized?\nTODO remove this method?
\nCollects unique values for a particular dataIndex from this store.
\nThe property to collect
\nPass true to allow null, undefined or empty string values
\nPass true to collect from all records, even ones which are filtered
\nAn array of the unique values
\nCommit all Records with outstanding changes. To handle updates for changes,\nsubscribe to the Store's update event, and perform updating when the third parameter is\nExt.data.Record.COMMIT.
\ncallback-handler for remote CRUD actions\nDo not override -- override loadRecords, onCreateRecords, onDestroyRecords and onUpdateRecords instead.
\nReturns a filter function used to test a the given property's value. Defers most of the work to\nExt.util.MixedCollection's createValueMatcher function
\nThe property to create the filter function for
\nThe string/regex to compare the property value to
\nTrue if we don't care if the filter value is not the full value (defaults to false)
\nTrue to create a case-sensitive regex (defaults to false)
\nTrue to force exact match (^ and $ characters added to the regex). Defaults to false. Ignored if anyMatch is true.
\nGiven an array of filter functions (each with optional scope), constructs and returns a single function that returns\nthe result of all of the filters ANDed together
\nThe array of filter objects (each object should contain an 'fn' and optional scope)
\nThe multiple filter function
\nShould not be used directly. Store#add will call this automatically if a Writer is set
\nDestroys a Record. Should not be used directly. It's called by Store#remove if a Writer is set.
\nthis
\nprivate. Simply wraps call to Store#execute in try/catch. Defers to Store#handleException on error. Loops if batch: false
\nUpdate a record within the store with a new reference
\nCalls the specified function for each of the Records in the cache.
\nEnables events fired by this Observable to bubble up an owner hierarchy by calling\nthis.getBubbleTarget()
if present. There is no implementation in the Observable base class.
This is commonly used by Ext.Components to bubble events to owner Containers. See Ext.Component.getBubbleTarget. The default\nimplementation in Ext.Component returns the Component's immediate owner. But if a known target is required, this can be overridden to\naccess the required target more quickly.
\n\n\nExample:
\n\n\nExt.override(Ext.form.Field, {\n // Add functionality to Field's initComponent to enable the change event to bubble\n initComponent : Ext.form.Field.prototype.initComponent.createSequence(function() {\n this.enableBubble('change');\n }),\n\n // We know that we want Field's events to bubble directly to the FormPanel.\n getBubbleTarget : function() {\n if (!this.formPanel) {\n this.formPanel = this.findParentByType('form');\n }\n return this.formPanel;\n }\n});\n\nvar myForm = new Ext.formPanel({\n title: 'User Details',\n items: [{\n ...\n }],\n listeners: {\n change: function() {\n // Title goes red if form has been modified.\n myForm.header.setStyle('color', 'red');\n }\n }\n});\n
\n\nThis method should generally not be used directly. This method is called internally\nby load, or if a Writer is set will be called automatically when add,\nremove, or update events fire.
\nAction name ('read', 'create', 'update', or 'destroy')
\nError
\nFilter the records by a specified property. Alternatively, pass an array of filter\noptions to filter by more than one property.\nSingle filter example:\nstore.filter('name', 'Ed', true, true); //finds all records containing the substring 'Ed'\nMultiple filter example:
\n\nstore.filter([\n {\n property : 'name',\n value : 'Ed',\n anyMatch : true, //optional, defaults to true\n caseSensitive: true //optional, defaults to true\n },\n\n //filter functions can also be passed\n {\n fn : function(record) {\n return record.get('age') == 24\n },\n scope: this\n }\n]);\n
\n\nA field on your records, or an array containing multiple filter options
\nEither a string that the field should begin with, or a RegExp to test\nagainst the field.
\ntrue to match any part not just the beginning
\ntrue for case sensitive comparison
\nTrue to force exact match (^ and $ characters added to the regex). Defaults to false. Ignored if anyMatch is true.
\nFilter by a function. The specified function will be called for each\nRecord in this Store. If the function returns true the Record is included,\notherwise it is filtered out.
\nThe function to be called. It will be passed the following parameters:
The record\nto test for filtering. Access field values using Ext.data.Record.get.
The ID of the Record passed.
The scope (this
reference) in which the function is executed. Defaults to this Store.
Finds the index of the first matching Record in this store by a specific field value.
\nThe name of the Record field to test.
\nEither a string that the field value\nshould begin with, or a RegExp to test against the field.
\nThe index to start searching at
\nTrue to match any part of the string, not just the beginning
\nTrue for case sensitive comparison
\nThe matched index or -1
\nFind the index of the first matching Record in this Store by a function.\nIf the function returns true it is considered a match.
\nThe function to be called. It will be passed the following parameters:
The record\nto test for filtering. Access field values using Ext.data.Record.get.
The ID of the Record passed.
The scope (this
reference) in which the function is executed. Defaults to this Store.
The index to start searching at
\nThe matched index or -1
\nFinds the index of the first matching Record in this store by a specific field value.
\nThe name of the Record field to test.
\nThe value to match the field against.
\nThe index to start searching at
\nThe matched index or -1
\nFires the specified event with the passed parameters (minus the event name).
\n\n\nAn event may be set to bubble up an Observable parent hierarchy (See Ext.Component.getBubbleTarget)\nby calling enableBubble.
\n\nThe name of the event to fire.
\nVariable number of parameters are passed to handlers.
\nreturns false if any of the handlers return false otherwise it returns true.
\nGet the Record at the specified index.
\nThe index of the Record to find.
\nThe Record at the passed index. Returns undefined if not found.
\nGet the Record with the specified id.
\nThe id of the Record to find.
\nThe Record with the passed id. Returns undefined if not found.
\nGets the number of cached records.
\n\nIf using paging, this may not be the total size of the dataset. If the data object\nused by the Reader contains the dataset size, then the getTotalCount function returns\nthe dataset size. Note: see the Important note in load.
\n\nThe number of Records in the Store's cache.
\nGets all records modified since the last commit. Modified records are\npersisted across load operations (e.g., during paging). Note: deleted records are not\nincluded. See also pruneModifiedRecords and\nExt.data.RecordmarkDirty..
\nAn array of Records containing outstanding\nmodifications. To obtain modified fields within a modified record see\nExt.data.Recordmodified..
\nReturns a range of Records between specified indices.
\nThe starting index (defaults to 0)
\nThe ending index (defaults to the last Record in the Store)
\nAn array of Records
\nReturns an object describing the current sort state of this Store.
\nThe sort state of the Store. An object with two properties:
The name of the field by which the Records are sorted.
The sort order, 'ASC' or 'DESC' (case-sensitive).
Gets the total number of records in the dataset as returned by the server.
\n\nIf using paging, for this to be accurate, the data object used by the Reader\nmust contain the dataset size. For remote data sources, the value for this property\n(totalProperty for JsonReader,\ntotalRecords for XmlReader) shall be returned by a query on the server.\nNote: see the Important note in load.
\n\nThe number of Records as specified in the data object passed to the Reader\nby the Proxy.
\n\nNote: this value is not updated when changing the contents of the Store locally.
\n\nprotected handleException. Possibly temporary until Ext framework has an exception-handler.
\nChecks to see if this object has any listeners for a specified event
\nThe name of the event to check for
\nTrue if the event is being listened for, else false
\nGet the index within the cache of the passed Record.
\nThe Ext.data.Record object to find.
\nThe index of the passed Record. Returns -1 if not found.
\nInserts Records into the Store at the given index and fires the add event.\nSee also add
and addSorted
.
The start index at which to insert the passed Records.
\nAn Array of Ext.data.Record objects to add to the cache.
\nReturns true if this store is currently filtered
\nLoads the Record cache from the configured proxy using the configured reader.
\n\n\nNotes:
options.params
property to establish the initial position within the\ndataset, and the number of Records to cache on each read from the Proxy.sortInfo
\nwill be automatically included with the posted parameters according to the specified\nparamNames
.An object containing properties which control loading options:
An object containing properties to pass as HTTP\nparameters to a remote data source. Note: params
will override any\nbaseParams
of the same name.
Parameters are encoded as standard HTTP parameters using Ext.urlEncode.
\n\n\nA function to be called after the Records\nhave been loaded. The callback is called after the load event is fired, and is passed the following arguments:
Scope with which to call the callback (defaults\nto the Store object)
Indicator to append loaded records rather than\nreplace the current cache. Note: see note for loadData
If the developer provided beforeload event handler returns\nfalse, the load call will abort and will return false; otherwise will return true.
\nLoads data from a passed data block and fires the load event. A Reader\nwhich understands the format of the data must have been configured in the constructor.
\nThe data block from which to read the Records. The format of the data expected\nis dependent on the type of Reader that is configured and should correspond to\nthat Reader's Ext.data.Reader.readRecords parameter.
\ntrue to append the new Records rather the default to replace\nthe existing cache.\nNote: that Records in a Store are keyed by their id, so added Records\nwith ids which are already present in the Store will replace existing Records. Only Records with\nnew, unique ids will be added.
\nprivate\nCalled as a callback by the Reader during a load operation.
\nSorts the contents of this store by multiple field/direction sorters. This is called internally by sort\nand would not usually be called manually.\nMulti sorting only currently applies to local datasets - multiple sort data is not currently sent to a proxy\nif remoteSort is used.
\nAppends an event handler to this object (shorthand for addListener.)
\nThe type of event to listen for
\nThe method the event invokes
\nThe scope (this
reference) in which the handler function is executed.\nIf omitted, defaults to the object which fired the event.
An object containing handler configuration.
\nonCreateRecord proxy callback for create action
\nonDestroyRecords proxy callback for destroy action
\n, onUpdateRecords proxy callback for update action
\nQuery the records by a specified property.
\nA field on your records
\nEither a string that the field\nshould begin with, or a RegExp to test against the field.
\nTrue to match any part not just the beginning
\nTrue for case sensitive comparison
\nReturns an Ext.util.MixedCollection of the matched records
\nQuery the cached records in this Store using a filtering function. The specified function\nwill be called with each record in this Store. If the function returns true the record is\nincluded in the results.
\nThe function to be called. It will be passed the following parameters:
The record\nto test for filtering. Access field values using Ext.data.Record.get.
The ID of the Record passed.
The scope (this
reference) in which the function is executed. Defaults to this Store.
Returns an Ext.util.MixedCollection of the matched records
\nremap record ids in MixedCollection after records have been realized. @see Store#onCreateRecords, @see DataReader#realize
\nReject outstanding changes on all modified records.
\nRelays selected events from the specified Observable as if the events were fired by this.
\nThe Observable whose events this object is to relay.
\nArray of event names to relay.
\nReloads the Record cache from the configured Proxy using the configured\nReader and the options from the last load operation\nperformed.
\n\n\nNote: see the Important note in load.
\n\n(optional) An Object containing\nloading options which may override the options\nused in the last load operation. See load for details\n(defaults to null, in which case the lastOptions are\nused).
\n\n\nTo add new params to the existing params:
\n\n\nlastOptions = myStore.lastOptions;\nExt.apply(lastOptions.params, {\n myNewParam: true\n});\nmyStore.reload(lastOptions);\n
\n\nRemove Records from the Store and fires the remove event.
\nThe record object or array of records to remove from the cache.
\nRemove all Records from the Store and fires the clear event.
\n[false] Defaults to false. Set true to not fire clear event.
\nRemoves an event handler.
\nThe type of event the handler was associated with.
\nThe handler to remove. This must be a reference to the function passed into the addListener call.
\nThe scope originally specified for the handler.
\nResume firing events. (see suspendEvents)\nIf events were suspended using the queueSuspended parameter, then all\nevents fired during event suspension will be sent to any listeners now.
\nSaves all pending changes to the store. If the commensurate Ext.data.Api.actions action is not configured, then\nthe configured url
will be used.
change url\n--------------- --------------------\nremoved records Ext.data.Api.actions.destroy\nphantom records Ext.data.Api.actions.create\nmodified records Ext.data.Api.actions.update\n\n\n\n
@TODO: Create extensions of Error class and send associated Record with thrown exceptions.\ne.g.: Ext.data.DataReader.Error or Ext.data.Error or Ext.data.DataProxy.Error, etc.
\nbatch Returns a number to uniquely identify the \"batch\" of saves occurring. -1 will be returned\nif there are no items to save or the save was cancelled.
\nSet the value for a property name in this store's baseParams. Usage:
\n\nmyStore.setBaseParam('foo', {bar:3});\n
\n\nName of the property to assign
\nValue to assign the named property
\nSort the Records.\nIf remote sorting is used, the sort is performed on the server, and the cache is reloaded. If local\nsorting is used, the cache is sorted internally. See also remoteSort and paramNames.\nThis function accepts two call signatures - pass in a field name as the first argument to sort on a single\nfield, or pass in an array of sort configuration objects to sort by multiple fields.\nSingle sort example:\nstore.sort('name', 'ASC');\nMulti sort example:\nstore.sort([\n {
\n\nfield : 'name',\ndirection: 'ASC'\n
\n\n},\n {
\n\nfield : 'salary',\ndirection: 'DESC'\n
\n\n}\n], 'ASC');\nIn this second form, the sort configs are applied in order, with later sorters sorting within earlier sorters' results.\nFor example, if two records with the same name are present they will also be sorted by salary if given the sort configs\nabove. Any number of sort configs can be added.
\nPerforms the actual sorting of data. This checks to see if we currently have a multi sort or not. It applies\neach sorter field/direction pair in turn by building an OR'ed master sorting function and running it against\nthe full dataset
\nSums the value of property for each record between start\nand end and returns the result.
\nA field in each record
\nThe record index to start at (defaults to 0)
\nThe last record index to include (defaults to length - 1)
\nThe sum
\nSuspend the firing of all events. (see resumeEvents)
\nPass as true to queue up suspended events to be fired\nafter the resumeEvents call instead of discarding all suspended events;
\nRemoves an event handler (shorthand for removeListener.)
\nThe type of event the handler was associated with.
\nThe handler to remove. This must be a reference to the function passed into the addListener call.
\nThe scope originally specified for the handler.
\nupdateRecord Should not be used directly. This method will be called automatically if a Writer is set.\nListens to 'update' event.
\nFires when Records have been added to the Store
\nThe array of Records added
\nThe index at which the record(s) were added
\nFires before a save action is called. A save encompasses destroying records, updating records and creating records.
\nAn object containing the data that is to be saved. The object will contain a key for each appropriate action,\nwith an array of records for each action.
\n[Ext.data.Api.actions.create|update|destroy]
\nThe Record(s) being written.
\nThe loading options that were specified. Edit options.params
to add Http parameters to the request. (see save for details)
The callback's arg object passed to the request function
\nFires when the data cache has been cleared.
\nThe records that were cleared.
\nFires when the data cache has changed in a bulk manner (e.g., it has been sorted, filtered, etc.) and a\nwidget that is using this Store as a Record cache should refresh its view.
\nFires if an exception occurs in the Proxy during a remote request.\nThis event is relayed through the corresponding Ext.data.DataProxy.\nSee Ext.data.DataProxy.exception\nfor additional details.\n\n
See Ext.data.DataProxy.exception\nfor description.
\nFires after a new set of Records has been loaded.
\nThe Records that were loaded
\nThe loading options that were specified (see load for details)
\nThis event is deprecated in favor of the catch-all exception
\nevent instead.
This event is relayed through the corresponding Ext.data.DataProxy.\nSee Ext.data.DataProxy.loadexception\nfor additional details.\n\n
See Ext.data.DataProxy.loadexception\nfor description.
\nFires when this store's reader provides new metadata (fields). This is currently only supported for JsonReaders.
\nThe JSON metadata
\nFires when a Record has been removed from the Store
\nThe Record that was removed
\nThe index at which the record was removed
\nFires after a save is completed. A save encompasses destroying records, updating records and creating records.
\nThe identifier for the batch that was saved.
\nAn object containing the data that is to be saved. The object will contain a key for each appropriate action,\nwith an array of records for each action.
\nFires when a Record has been updated
\nThe Record that was updated
\nThe update operation being performed. Value may be one of:
\n\n Ext.data.Record.EDIT\n Ext.data.Record.REJECT\n Ext.data.Record.COMMIT\n
\n\nFires if the server returns 200 after an Ext.data.Api.actions CRUD action.\nSuccess of the action is determined in the result['successProperty']
property (NOTE for RESTful stores,\na simple 20x response is sufficient for the actions \"destroy\" and \"update\". The \"create\" action should should return 200 along with a database pk).
[Ext.data.Api.actions.create|update|destroy]
\nThe 'data' picked-out out of the response for convenience.
\nStore's records, the subject(s) of the write-action
\n