Ticket #6071 (closed defect: invalid)
QueryReadStore does not work with FilteringSelect
| Reported by: | guest | Owned by: | haysmark |
|---|---|---|---|
| Priority: | normal | Milestone: | |
| Component: | Dijit | Version: | 1.0 |
| Severity: | normal | Keywords: | |
| Cc: | josh@… |
Description
Not sure if this is a defect or enhancement.
I tried using a QueryReadStore? with a FilteringSelect? so I could easily re-fetch the data from the server on demand. I have an "Add New" button next to my Select list which adds a new item to a backend db, which when finished should update the select list with the new value.
The problem with using a QueryReadStore? and FilteringSelect? is that it re-fetches the data on each keypress in the filtering select and also when you select an item with the mouse - this causes the initial value to become re-selected. In other words there is no way to actually change the value in the Select Box.
I would not need to use a QueryReadStore? with a FilteringSelect? if there was an easy way to tell an ItemFileReadStore? that you want to re-fetch the data from the server.
At current the only way (that I know of) to handle this is to create a brand new ItemFileReadStore? object with the same URL as the original store, and assign it to widget.store. This seems like a poor way to solve this problem.
For what it's worth - here is the attempted markeup I used: