From 47fc853d373905dd81c267ecc8ac972e071350f8 Mon Sep 17 00:00:00 2001 From: Michael Small Date: Mon, 26 Aug 2024 22:59:30 -0500 Subject: [PATCH] fix: point service at actual endpoint/service, store at actual service for RXJS `withDataService` --- .../flight-booking-simple.store.ts | 4 ++-- apps/demo/src/app/shared/flight.service.ts | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/apps/demo/src/app/flight-search-data-service-simple/flight-booking-simple.store.ts b/apps/demo/src/app/flight-search-data-service-simple/flight-booking-simple.store.ts index 6b537f6..edcdfe2 100644 --- a/apps/demo/src/app/flight-search-data-service-simple/flight-booking-simple.store.ts +++ b/apps/demo/src/app/flight-search-data-service-simple/flight-booking-simple.store.ts @@ -1,4 +1,4 @@ -import { FlightService } from '../shared/flight.service'; +import { FlightService, FlightServiceRXJS } from '../shared/flight.service'; import { signalStore } from '@ngrx/signals'; @@ -26,7 +26,7 @@ export const SimpleFlightBookingStoreWithObservables = signalStore( withCallState(), withEntities(), withDataService({ - dataServiceType: FlightService, + dataServiceType: FlightServiceRXJS, filter: { from: 'Paris', to: 'New York' }, }), withUndoRedo(), diff --git a/apps/demo/src/app/shared/flight.service.ts b/apps/demo/src/app/shared/flight.service.ts index dfce2b5..7552f30 100644 --- a/apps/demo/src/app/shared/flight.service.ts +++ b/apps/demo/src/app/shared/flight.service.ts @@ -77,7 +77,7 @@ export class FlightService implements DataService { providedIn: 'root' }) export class FlightServiceRXJS implements DataService { - private baseUrl = 'http://localhost:3000/books'; + private baseUrl = `https://demo.angulararchitects.io/api`; private http = inject(HttpClient); loadById(id: EntityId): Observable {