View Full Version : Ext.data.Model missing store property
6 Jan 2012, 7:39 AM
The store property is a documented property of Ext.data.Model and as such can be relied upon for customer use. It was not present in the 4.1 alpha release and was reported at that time. It is also not present in the 4.1 beta release. It seams to be replaced with a stores property which appears to be an array containing 1 element.
I have not seen mention of this in any 4.1 release documentation or backward compatability guide. If I missed it my apology and please point me to it.
In the mean time can I rely on stores being an array with the first element pointing back to the store?
6 Jan 2012, 11:08 AM
A model can be used by many stores, this is the reason for this change.
6 Jan 2012, 3:18 PM
Umm, ok. So we have an undocumented breaking change caused by undocumented new features. Can you see where I might be going with this?
If this were an isolated case I wouldn't even blink but this has been an on going issue for quite some time. You guys need to step up to the plate. Wild west software development (seemed to start some time after version 2) needs to be a thing of the past. Think documentation, compatability, customers, unit testing, testing of any kind, etc....
This was an oversight, I've updated the API changes page here: http://www.sencha.com/forum/showthread.php?152929-API-Changes
It isn't obvious to me looking at the source why a model needs to know what stores it is associated with. Is it just to reduce the number of observable listeners between models and stores?
Pretty much, yeah. Records tend to be "throwaway" objects, so binding listeners is rather heavy for them.
Will there be a compat layer for 4.1? Should be easy to set
to solve bw compat. Don't think users will appreciate another release with breaking api changes.
Powered by vBulletin® Version 4.1.5 Copyright © 2014 vBulletin Solutions, Inc. All rights reserved.