Closed leonibr closed 8 years ago
For now I am replacing the constructor:
function GridRow(number, description) { return { id : uuid(), number : number, description : description }; }
Yes you are correct, it has to be a JSON object not a function. I developed it with only using JSON objects in mind.
It is nice. I love it. Thanks for sharing Em 11/03/2016 09:43, "fordth" notifications@github.com escreveu:
Closed #11 https://github.com/fordth/jinqJs/issues/11.
— Reply to this email directly or view it on GitHub https://github.com/fordth/jinqJs/issues/11#event-586342386.
Great to hear, thank you!
Hi, context:
` function GridRow(number, description) { this.id = uuid(); this.number = number; this.description = description; ///other properties not shown }
var grid = []; grid.push(new GridRow(12345, 'test desc'));
//This works var result = new jinqJs() .from(grid) .select(); //This fails var failedResult = new jinqJs() .from(grid) .select('id'); // or any combination of fields ` It seems that it only accepts typeof 'object', not GridRow Object