Opened 11 years ago
Closed 8 years ago
#11410 closed defect (wontfix)
[regression] getValues produces error: args.item is undefined
Reported by: | Simon Speich | Owned by: | Kris Zyp |
---|---|---|---|
Priority: | high | Milestone: | tbd |
Component: | DojoX Data | Version: | 1.5.0rc1 |
Keywords: | regression, JsonRestStore, ServiceStore, Version 1.5.0.rc2 | Cc: | |
Blocked By: | Blocking: |
Description
In dojo 1.4.3 ServiceStore?.getValues(item, property) returned an empty array if item was not loaded yet, e.g.:
var val = this.getValue(item,property); return val instanceof Array ? val : val === undefined ? [] : [val];
but now getValues() fails with the error args.item is undefined since it tries to load the item e.g.:
var val = this.getValue(item,property); if(val instanceof Array){ return val; } if(!this.isItemLoaded(val)){ dojox.rpc._sync = true; val = this.loadItem({item:val}); } return val instanceof Array ? val : val === undefined ? [] : [val];
but {item:val} is undefined since val === undefined and so loadItem(args) fails, e.g.:
var item; if(args.item._loadObject){ ... }); }else if(args.onItem){ ... } return item;
Note: 1.5.0.rc2 was not in list yet
Change History (5)
comment:1 Changed 11 years ago by
comment:2 Changed 11 years ago by
Component: | General → DojoX Data |
---|---|
Owner: | changed from anonymous to kriszyp |
Summary: | getValues produces error: args.item is undefined → [regression] getValues produces error: args.item is undefined |
comment:3 Changed 11 years ago by
Owner: | changed from kriszyp to Kris Zyp |
---|
comment:4 Changed 10 years ago by
Same problem when "val === null".
Trying todo a getvalues on a field which is null (returned by server)
comment:5 Changed 8 years ago by
Resolution: | → wontfix |
---|---|
Status: | new → closed |
dojox/data is abandoned. Some dojox/data stores have been upgraded to use the Dojo Store API and can be found at https://github.com/kfranqueiro/dojo-smore.
Note: See
TracTickets for help on using
tickets.
Change line 220 in ServiceStore?.js to:
would fix the problem.