landing page finished
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import { HttpClient } from '@angular/common/http';
|
||||
import { Injectable } from '@angular/core';
|
||||
import { Observable } from 'rxjs';
|
||||
import { CountyResult, GeoResult } from '../../../../bizmatch-server/src/models/main.model';
|
||||
import { CityAndStateResult, CountyResult, GeoResult } from '../../../../bizmatch-server/src/models/main.model';
|
||||
import { environment } from '../../environments/environment';
|
||||
|
||||
@Injectable({
|
||||
@@ -15,6 +15,9 @@ export class GeoService {
|
||||
const stateString = state ? `/${state}` : '';
|
||||
return this.http.get<GeoResult[]>(`${this.apiBaseUrl}/bizmatch/geo/${prefix}${stateString}`);
|
||||
}
|
||||
findCitiesAndStatesStartingWith(prefix: string): Observable<CityAndStateResult[]> {
|
||||
return this.http.get<CityAndStateResult[]>(`${this.apiBaseUrl}/bizmatch/geo/citiesandstates/${prefix}`);
|
||||
}
|
||||
findCountiesStartingWith(prefix: string, states?: string[]): Observable<CountyResult[]> {
|
||||
return this.http.post<CountyResult[]>(`${this.apiBaseUrl}/bizmatch/geo/counties`, { prefix, states });
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user