#15145 closed defect (fixed)
[patch][cla] allowNoTrailingSlash & onSet event in JsonRestStore
Reported by: | adros | Owned by: | Kris Zyp |
---|---|---|---|
Priority: | high | Milestone: | 1.9 |
Component: | DojoX Data | Version: | 1.7.2 |
Keywords: | Cc: | ||
Blocked By: | Blocking: |
Description
If I create a JsonRestStore? with allowNoTrailingSlash set to true, the "onSet" event is not called after calling setValue method. I think it is because of _getStoreForItem, which creates new instance of the store.
I have attached a sample and also a json file, which can simulate the service.
Attachments (3)
Change History (7)
Changed 9 years ago by
Attachment: | sample.html added |
---|
Changed 9 years ago by
Attachment: | service.json added |
---|
comment:1 Changed 9 years ago by
Changed 9 years ago by
comment:2 Changed 8 years ago by
Summary: | allowNoTrailingSlash & onSet event in JsonRestStore → [patch][cla] allowNoTrailingSlash & onSet event in JsonRestStore |
---|
comment:4 Changed 8 years ago by
Milestone: | tbd → 1.9 |
---|---|
Priority: | undecided → high |
Note: See
TracTickets for help on using
tickets.
The problem is caused by handling of URLs without trailing slash. At the time of constructing items from raw data (in
dojox/rpc/JsonRest.resolveJson
),allowNoTrailingSlash
setting is disregarded when resolving idPrefix.I think that store with target
"/abc/def"
(andallowNoTrailingSlash == true
) should produce items with__id
attribute"/abc/def/id"
i.e. the same as when using"/abc/def/"
.See proposed patch.