3

Writing a function to generate and push some random data inside of the unknown passed data store object. I know I can iterate over records and then iterate over fields, but I need to have the list of fields before starting to push random generated record at top of other records (and then remove the last item to simulate a real-time chart).

Any enlightening idea besides of I am a n00b on ExtJS?

Grant Zhu
  • 2,988
  • 2
  • 23
  • 28
Sadegh
  • 33
  • 2

1 Answers1

3

UPDATE: You are using Extjs 4. Then try this:

var store = new Ext.data.Store({url:'testUrl', fields:[{name:'value'}]});

//The array of fields(Ext.data.Field)
var fields = store.proxy.reader.getFields();  
Grant Zhu
  • 2,988
  • 2
  • 23
  • 28