Hi say i have an object as below
{ID:'1',Name:'Some name',Notes:'NOTES'}
and another object as
{junk:'lll'}
I need the output as
{ ID: '1', Name: 'Some name', Notes: 'NOTES', junk: 'lll' }
Below is the code that i tried
var objIssues = [
{ID:'1',Name:'Some name',Notes:'NOTES'}
];
objIssues[objIssues.length] = {junk:'lll'};
console.log(objIssues)
The out put that i got is
[ { ID: '1', Name: 'Some name', Notes: 'NOTES' },
{ junk: 'lll' } ]
I'm stuck here any help regarding this will be much helpful.
$.extend(jsonIssues, {junk:'111'});andjsonIssueswill contain you other object.