#17093 closed defect (fixed)
dojox/mobile/EdgeToEdgeStoreList does not update when using itemMap or labelProperty to map a different field to the label.
Reported by: | Ed Chatelain | Owned by: | Eric Durocher |
---|---|---|---|
Priority: | undecided | Milestone: | 1.9.1 |
Component: | DojoX Mobile | Version: | 1.9.0rc2 |
Keywords: | Cc: | cjolif, Adrian Vasiliu | |
Blocked By: | Blocking: |
Description
dojox/mobile/EdgeToEdgeStoreList does not update when using itemMap or labelProperty to map a different field to the label.
When using an observable store and updating an item's label the update is shown in the EdgeToEdgeStoreList? if "label" is used, but if an itemMap or labelProperty is used to map a different field to the label then the update is not shown.
I will attach an updated copy of dojox/mobile/tests/test_EdgeToEdgeStoreList-itemMap.html to show the problem. When the "Update" button is pressed for "set2" the 2nd row is updated immediately, because "set2" uses "label", but when "Update" is pressed for "set1" the update will not be seen unless you swap back to "set2" and then back to "set1".
Attachments (3)
Change History (19)
Changed 8 years ago by
Attachment: | test_EdgeToEdgeStoreList-itemMap.html added |
---|
comment:1 Changed 8 years ago by
Cc: | cjolif added |
---|
comment:2 Changed 8 years ago by
Cc: | Adrian Vasiliu added |
---|---|
Milestone: | tbd → 1.9.1 |
comment:5 Changed 8 years ago by
Tested OK too. Now, I would think we should also include a test case in the product - say a variant of the test currently attached, modified to make it nicer. Unless Ed wants to do it himself, I'll go this way.
Changed 8 years ago by
Attachment: | test_EdgeToEdgeStoreList-itemMap.2.html added |
---|
Manual test for this bug fix. (IBM CCLA).
comment:7 Changed 8 years ago by
@sbrunot, about your variant of Ed's test, I'm not 100% convinced we should add an id attribute to the items, as replacement of the use of idProperty on the Memory store. In my mind we would enrich the existing test with the update feature, as in Ed's original test case, thus we should keep testing/illustrating the idProperty mechanism too, which allows to avoid the overhead of an id attribute as long as there is another field with unique values. That said, we can also add it as yet another new test. Opinions?
comment:8 Changed 8 years ago by
Not really answering Adrian's point, but why not add a DOH test instead of yet another manual test? It seems typically the kind of things that can be tested automatically...
comment:9 Changed 8 years ago by
Fully agree. I would say we can have both, since a manual test also has value - easier for users to pick an usage example in the manual tests than in the DOH. Say:
- I commit sbrunot's lib fix + a manual test case based on Ed's test case that I tend to modify this way: a) the update would hold for all items instead of just updating the second item, and b) instead of appending "Updated" to the label each time the "Update" button is pressed", I would suffix the label with "Update #n" with "n" incremented at each update.
- When a DOH is ready, it will get added.
Changed 8 years ago by
Attachment: | ticket17093.patch added |
---|
dojox/mobile/EdgeToEdgeStoreList now properly update when using itemMap or labelProperty to map a different field to the label. (IBM CCLA).
An updated copy of dojox/mobile/tests/test_EdgeToEdgeStoreList-itemMap.html with an "Update" button to show the problem.