dmaApp.service("dmaPageService", [ "$http", "Constants", function($http, Constants) { var baseUrl = Constants.apiUrl; this.getMatchedCompaniesByIndustry = function(pageNumber){ var promise = $http.get(baseUrl + "/getdmawinners/industry" + "/" + pageNumber + "/dmas.htm"); return promise; } this.getMatchedCompaniesByRegion = function(pageNumber){ var promise = $http.get(baseUrl + "/getdmawinners/region" + "/" + pageNumber + "/dmas.htm"); return promise; } this.getMatchedCompaniesByDivision = function(pageNumber){ var promise = $http.get(baseUrl + "/getdmawinners/division" + "/" + pageNumber + "/dmas.htm"); return promise; } this.getAllCompanies = function(pageNumber) { var promise = $http.get(baseUrl + "/getdmawinners/allIndustry/allRegion/allDivision" + "/" + pageNumber + "/dmas.htm"); return promise; } this.getCompaniesByType = function(companyStatus, pageNumber) { var promise = $http.get(baseUrl + "/getdmawinners/companyStatus/" + companyStatus + "/" + pageNumber + "/dmas.htm"); return promise; } this.getCompanySearchResult = function(query, pageNumber) { var promise = $http.get(baseUrl + "/getdmawinners/search/" + query + "/" + pageNumber+ "/dmas.htm"); return promise; } } ]);