Advertisement
Guest User

Untitled

a guest
Jan 21st, 2015
312
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.49 KB | None | 0 0
  1. app.controller('AdsController', function ($scope, $http) {
  2. $scope.items = [];
  3. $scope.getItems = function () {
  4.  
  5. $http({
  6. method: 'GET',
  7. url: 'https://api.parse.com/1/classes/Products',
  8. headers: {'X-Parse-Application-Id': 'P9hWHgBCW4rmJpnEuyB9gjlUPReIWIZsrwRHS1sZ', 'X-Parse-REST-API-Key': 'YJHRqu6JrX1JDmHZ2Cs00ydQYjVvWdAJiBWnHpkC'}
  9. })
  10. .success(function (data, status) {
  11. $scope.items = data;
  12. })
  13. .error(function (data, status) {
  14. alert("Error");
  15. });
  16. };
  17. })
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement