Skip to content

Instantly share code, notes, and snippets.

@joncodo
Created September 30, 2014 03:07
Show Gist options
  • Select an option

  • Save joncodo/b8afbaff493a482707ca to your computer and use it in GitHub Desktop.

Select an option

Save joncodo/b8afbaff493a482707ca to your computer and use it in GitHub Desktop.
myApp.service('DealRetrievalService', ['$http', function($http) {
return {
getAllDeals: function() {
return $http.get('/dealRecord')
.success(function(deals) {
var temp = DealRetrievalService.removeExpiredDeals(deals.data);
console.log('deals were:', temp);
return DealRetrievalService.removeExpiredDeals(deals.data);
})
.error(function(err) {
});
},
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment