You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The issue is when combining an or with an and in the 2nd clause.
require(['dojo/when','dstore/Memory'],function(when,Memory){varstore=newMemory({data: [],idProperty: 'id'});store.setData([{id:1,name:'a'},{id: 2,name: 'b'}]);varf=store.Filter;varmyFilter=f.prototype.or(newf({id: 1}),newf({id: 2}));console.log("Works: simple or")when(store.filter(myFilter).fetch(),function(allItems){console.log('filtered size: '+allItems.length);});varmyFilter=f.prototype.or(newf({id: 1}),newf({id: 2,name: 'b'}));console.log("Fails: or with and on 2nd arg")when(store.filter(myFilter).fetch(),function(allItems){console.log('filtered size: '+allItems.length);});varmyFilter=f.prototype.or(newf({id: 1,name: 'a'}),newf({id: 2}));console.log("Works: reverse the order of the args")when(store.filter(myFilter).fetch(),function(allItems){console.log('filtered size: '+allItems.length);});});
The text was updated successfully, but these errors were encountered:
The issue is when combining an or with an and in the 2nd clause.
The text was updated successfully, but these errors were encountered: