Opened 12 years ago

Closed 12 years ago

#4569 closed defect (invalid)

Cannot add item to dojo.data.ItemFileWriteStore if item with same ID previously existed in store

Reported by: guest Owned by: Jared Jurkiewicz
Priority: high Milestone:
Component: Data Version: 0.9
Keywords: Cc:
Blocked By: Blocking:

Description

If I delete an item from the store (with .deleteItem( item )), then insert an item with the same ID the deleted item has (with .newItem( item )), the insert operation will fail: the store behaves as if the deleted item was still there.

Attachments (2)

_ItemFileWriteStore_Bug.html (2.1 KB) - added by guest 12 years ago.
Test page demonstrating the bug. Place in dojo/tests. Requires myData.json (separate attachment).
myData.json (540 bytes) - added by guest 12 years ago.
Sample data for test page demonstrating bug.

Download all attachments as: .zip

Change History (4)

Changed 12 years ago by guest

Test page demonstrating the bug. Place in dojo/tests. Requires myData.json (separate attachment).

Changed 12 years ago by guest

Attachment: myData.json added

Sample data for test page demonstrating bug.

comment:1 Changed 12 years ago by guest

Never mind, I figured it out (didn't realize you had to use .save(), silly me.)

comment:2 Changed 12 years ago by Jared Jurkiewicz

Resolution: invalid
Status: newclosed

Yes, you have to save to commit the changes.

Note: See TracTickets for help on using tickets.