I want to push all array of objects into a single array.
For example below is a transaction array which has two different arrays:
transaction:
0:(3) [{…}, {…}, {…}]
1:(2) [{…}, {…}]
I want something like this:
transaction:
0:(5) [{…}, {…}, {…},{…}, {…}]
I am pushing arrays inside transaction array by using a for loop, and i don't how to use concat operation inside for loop.
This below is my for loop i am push objects into transaction array:
for (var j = 0; j < $scope.allRecent.length; j++)
{
if (uniqueDates[i].dates == $scope.formatDate($scope.allRecent[j].date))
{
tempObj.transaction.push($scope.allRecent[j].transaction)
}
}