So, I'm upgrading from EXT 4.1.1a to 4.2.2 and have come across a problem with buffered stores. In 4.1.1a I could use store.each
to iterate through the currently displayed store records, but in 4.2.2 I simply get the error:
TypeError: Cannot read property 'length' of undefined
Basically inside the store object the data
property does not have an items
property anymore, and the each
method uses the length
property of the items
, hence the error. Instead the items in the store seem to reside in data.map
. I could loop through data.map
but it seems there should be a better way. The docs only mention store.each as the way to do this even though this seems to fail for buffered stores.
I'm iterating through the store on the refresh
listener attached to the grids view.
Any help with this would be much appreciated