X-Git-Url: http://git.ithinksw.org/extjs.git/blobdiff_plain/25ef3491bd9ae007ff1fc2b0d7943e6eaaccf775..10a866c12701c0a0afd0ac85dcdcf32a421514ac:/docs/output/Ext.data.XmlStore.html?ds=inline diff --git a/docs/output/Ext.data.XmlStore.html b/docs/output/Ext.data.XmlStore.html index e329184c..51787894 100644 --- a/docs/output/Ext.data.XmlStore.html +++ b/docs/output/Ext.data.XmlStore.html @@ -1,4 +1,4 @@ -
Properties Methods Events Config Options Direct Link
Observable
  Store
    XmlStore

Class Ext.data.XmlStore

Package:Ext.data
Defined In:XmlStore.js
Class:XmlStore
Extends:Store
xtype:xmlstore

Small helper class to make creating Ext.data.Stores from XML data easier. +

Observable
  Store
    XmlStore

Class Ext.data.XmlStore

Package:Ext.data
Defined In:XmlStore.js
Class:XmlStore
Extends:Store

Small helper class to make creating Ext.data.Stores from XML data easier. A XmlStore will be automatically configured with a Ext.data.XmlReader.

A store configuration would be something like:

var store = new Ext.data.XmlStore({
     // store configs

@@ -218,59 +218,59 @@ If the Reader was constructed by passing...
The Ext.data.Record.create for additional details).

This property may be used to create new Records of the type held in this Store, for example:

// create the data store
-var store = new Ext.data.ArrayStore({
-    autoDestroy: true,
-    fields: [
-       {name: 'company'},
-       {name: 'price', type: 'float'},
-       {name: 'change', type: 'float'},
-       {name: 'pctChange', type: 'float'},
-       {name: 'lastChange', type: 'date', dateFormat: 'n/j h:ia'}
-    ]
-});
-store.loadData(myData);
+    var store = new Ext.data.ArrayStore({
+        autoDestroy: true,
+        fields: [
+           {name: 'company'},
+           {name: 'price', type: 'float'},
+           {name: 'change', type: 'float'},
+           {name: 'pctChange', type: 'float'},
+           {name: 'lastChange', type: 'date', dateFormat: 'n/j h:ia'}
+        ]
+    });
+    store.loadData(myData);
 
-// create the Grid
-var grid = new Ext.grid.EditorGridPanel({
-    store: store,
-    colModel: new Ext.grid.ColumnModel({
-        columns: [
-            {id:'company', header: 'Company', width: 160, dataIndex: 'company'},
-            {header: 'Price', renderer: 'usMoney', dataIndex: 'price'},
-            {header: 'Change', renderer: change, dataIndex: 'change'},
-            {header: '% Change', renderer: pctChange, dataIndex: 'pctChange'},
-            {header: 'Last Updated', width: 85,
-                renderer: Ext.util.Format.dateRenderer('m/d/Y'),
-                dataIndex: 'lastChange'}
-        ],
-        defaults: {
-            sortable: true,
-            width: 75
-        }
-    }),
-    autoExpandColumn: 'company', // match the id specified in the column model
-    height:350,
-    width:600,
-    title:'Array Grid',
-    tbar: [{
-        text: 'Add Record',
-        handler : function(){
-            var defaultData = {
-                change: 0,
-                company: 'New Company',
-                lastChange: (new Date()).clearTime(),
-                pctChange: 0,
-                price: 10
-            };
-            var recId = 3; // provide unique id
-            var p = new store.recordType(defaultData, recId); // create new record
-            grid.stopEditing();
-            store.insert(0, p); // insert a new record into the store (also see add)
-            grid.startEditing(0, 0);
-        }
-    }]
-});
Store

Public Methods

MethodDefined By

Public Methods

MethodDefined By