Use historical price for older blocks and transactions

This commit is contained in:
nymkappa
2023-02-21 12:36:43 +09:00
parent cfa5734f19
commit 72779c8244
16 changed files with 284 additions and 19 deletions

View File

@@ -6,6 +6,7 @@ import { Observable } from 'rxjs';
import { StateService } from './state.service';
import { WebsocketResponse } from '../interfaces/websocket.interface';
import { Outspend, Transaction } from '../interfaces/electrs.interface';
import { Conversion } from './price.service';
@Injectable({
providedIn: 'root'
@@ -303,4 +304,8 @@ export class ApiService {
(style !== undefined ? `?style=${style}` : '')
);
}
getHistoricalPrice$(): Observable<Conversion> {
return this.httpClient.get<Conversion>( this.apiBaseUrl + this.apiBasePath + '/api/v1/historical-price');
}
}