Fetch historical data based on timestamp and currency
This commit is contained in:
@@ -335,7 +335,7 @@
|
||||
</div>
|
||||
<div class="clearfix"></div>
|
||||
|
||||
<app-transactions-list [transactions]="transactions" [paginated]="true"></app-transactions-list>
|
||||
<app-transactions-list [transactions]="transactions" [paginated]="true" [blockTime]="block.timestamp"></app-transactions-list>
|
||||
|
||||
<ng-template [ngIf]="transactionsError">
|
||||
<div class="text-center">
|
||||
|
||||
@@ -526,9 +526,9 @@ export class BlockComponent implements OnInit, OnDestroy {
|
||||
if (this.priceSubscription) {
|
||||
this.priceSubscription.unsubscribe();
|
||||
}
|
||||
this.priceSubscription = block$.pipe(
|
||||
switchMap((block) => {
|
||||
return this.priceService.getBlockPrice$(block.timestamp).pipe(
|
||||
this.priceSubscription = combineLatest([this.stateService.fiatCurrency$, block$]).pipe(
|
||||
switchMap(([currency, block]) => {
|
||||
return this.priceService.getBlockPrice$(block.timestamp, true, currency).pipe(
|
||||
tap((price) => {
|
||||
this.blockConversion = price;
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user