Say I have two arrays, one of objects, one simple:
var objArray = [{id:1,name:'fred'},{id:2,name:'john'},{id:3,name:'jane'},{id:4,name:'pete'}]
var simpleArray = [1,3]
I want to return a new array with just the items from objArray where the id property value (1,2,3 etc) does not match an item in the simpleArray.
I should have returned:
result = [{id:2,name:'john'},{id:4,name:'pete'}]
I've tried various combinations of $.grep, .filter and $.inArray but struggling with this.