Posts

Showing posts from March 6, 2019

How to add a $scope object value to another $scope object? (AngularJS)

Image
0 I'm taking the data from different sharepoint pages lists. I'm calling these lists with a Factory . My code is counting how many items with a " Completed " status each list has. I need to take the values of each one into an array, but the result is always null . Here's my example: <script> var myApp = angular.module("myApp", ); myApp.factory("myFactory", ["$http", function($http) { return { siteOne: function() { return $http({ method: "GET", url: "siteURL/_api/web/lists/getByTitle('List 1')/items", headers: {"Accept": "application/json; odata=verbose"}