Opened 14 years ago
Closed 14 years ago
#2706 closed defect (invalid)
bug in Store.addData
Reported by: | guest | Owned by: | Tom Trenka |
---|---|---|---|
Priority: | high | Milestone: | |
Component: | Collections | Version: | 0.4.2 |
Keywords: | Cc: | ||
Blocked By: | Blocking: |
Description
Hi,
I think there is a bug in Store.addData when the store is used as a list collection (keys not used), e.g. in charting addData does not work because all the subsequent addition are indexed in items[null]
Suggested fix:
this.addData = function(/* object */obj, /*string?*/key, /* boolean? */bDontFire){
Add an object with optional key to the internal data array.
var k = key obj[this.keyField]; if(k && items[k]!=null){
~here k must be tested first. if it is not null, then check items
Change History (3)
comment:1 Changed 14 years ago by
Owner: | changed from anonymous to Tom Trenka |
---|
comment:2 Changed 14 years ago by
Component: | General → Collections |
---|
comment:3 Changed 14 years ago by
Resolution: | → invalid |
---|---|
Status: | new → closed |
Note: See
TracTickets for help on using
tickets.
The Store was designed primarily as a hashtable-based collection, not as an indexed one; the lack of a key is not an option.
Closing as invalid.