diff --git a/app/LocationComponent/location.component.ts b/app/LocationComponent/location.component.ts index b6875f3..0a9f8ee 100644 --- a/app/LocationComponent/location.component.ts +++ b/app/LocationComponent/location.component.ts @@ -9,7 +9,7 @@ import {LocationService} from '../services/location.service'; export class LocationComponent { - locations:Locations; + locations; constructor(private _router:Router, private _routeParams:RouteParams, private locationService:LocationService) { @@ -24,6 +24,7 @@ export class LocationComponent { }, err => console.error(err) ); + } } \ No newline at end of file diff --git a/app/services/location.service.ts b/app/services/location.service.ts index 976c468..9976fc1 100644 --- a/app/services/location.service.ts +++ b/app/services/location.service.ts @@ -5,12 +5,14 @@ import 'rxjs/Rx'; @Injectable() export class LocationService { + http; + constructor(http:Http) { this.http = http; } getLocations() { - return this.http.get('mock.json') + return this.http.get('https://locator-app.com/api/v2/locations/nearby?long=9.169753789901733&lat=47.66868204997508&maxDistance=10000&limit=100000') .map(res => res.json()) } }