Opened 8 years ago
Closed 8 years ago
#17171 closed defect (worksforme)
dijit/form/Select not keeping item order from store
Reported by: | Frederic Canteloup | Owned by: | Douglas Hays |
---|---|---|---|
Priority: | undecided | Milestone: | 1.9.1 |
Component: | Dijit - Form | Version: | 1.9.0 |
Keywords: | Cc: | ||
Blocked By: | Blocking: |
Description (last modified by )
Hello,
I have migrated my code to dojo 1.9.0 and have observed the following : Upon creating a dijit/form/Select (either declaratively or programmatically) linked to a store, the original order of store items is not kept in the select. I have tried with a Memory and a JsonRest?.
In the test case below, 'June' ends up in first position followed by the 2 'May' entries :
var store = new dojo.store.Memory({ data: [ { id: "201305", label: "May 2013" }, { id: "201306", label: "June 2013" }, { id: "201405", label: "May 2014" } ] }); new dijit.form.Select({ store : new ObjectStore({objectStore:watchedDateComboStore}), }, "myDivId");
Thanks in advance for your help
Attachments (1)
Change History (4)
comment:1 Changed 8 years ago by
Description: | modified (diff) |
---|---|
Milestone: | tbd → 1.9.1 |
Summary: | dijit/form/Select not keeping item order from store → [regression] dijit/form/Select not keeping item order from store |
Changed 8 years ago by
Attachment: | testcase.html added |
---|
comment:2 Changed 8 years ago by
Thanks for your quick reply. Please find in attachment a testcase.html file with all css and js paths relative, assuming the dojo folder is in the same folder as the testcase. Hope it helps.
Frederic.
comment:3 Changed 8 years ago by
Resolution: | → worksforme |
---|---|
Status: | new → closed |
Summary: | [regression] dijit/form/Select not keeping item order from store → dijit/form/Select not keeping item order from store |
Specify sortByLabel:false
That's odd. It would be better if you could attach a full test case using the "attach file" button but anyway if this is a regression we should take a look.