You can't use push to set property. push can use to add array element.
If you want to use
$scope.object.array1.push(value);
then value should be an object like
var value = {content1: 'xyz',id:'4'};
To add property you can follow bellow process.
Say your object like:
$scope.object={
array1: [{content1: 'abc', id1:'100'},
{content2: 'xyz', id2:'200'}],
array2: [{content1: 'abc', id1:'100'},
{content2: 'xyz', id2:'200'}]
};
and if you want to add property name for each object of array1. you can use forEach to add new property and value. say called a function addProperty to add property and value.
$scope.addProperty = function(){
var i =0;
angular.forEach($scope.object.array1, function(eachObj) {
i+=1;
eachObj.name ='foo'+i;
});
};
then out put of array1 will be
[{"content1":"abc","id1":"100","name":"foo1"},{"content2":"xyz","id2":"200","name":"foo2"}]
PLUNKER DEMO
nameproperty on each element? In Javascript, it's ok if the element doesn't have anameproperty to begin with, it will happily let you add one.