From 2d758817f9cc35a6365b293495f2344b348b5d86 Mon Sep 17 00:00:00 2001 From: Thomas <4159106+dtslvr@users.noreply.github.com> Date: Sat, 7 Oct 2023 09:00:08 +0200 Subject: [PATCH] Remove show condition for markets overview --- .../app/components/home-market/home-market.html | 2 +- .../src/app/pages/home/home-page.component.ts | 14 +------------- 2 files changed, 2 insertions(+), 14 deletions(-) diff --git a/apps/client/src/app/components/home-market/home-market.html b/apps/client/src/app/components/home-market/home-market.html index 43f560d85..7ce07b6e9 100644 --- a/apps/client/src/app/components/home-market/home-market.html +++ b/apps/client/src/app/components/home-market/home-market.html @@ -1,6 +1,6 @@

Markets

-
+
Last {{ numberOfDays }} Days diff --git a/apps/client/src/app/pages/home/home-page.component.ts b/apps/client/src/app/pages/home/home-page.component.ts index a39a371c4..fea8e9ac3 100644 --- a/apps/client/src/app/pages/home/home-page.component.ts +++ b/apps/client/src/app/pages/home/home-page.component.ts @@ -1,8 +1,6 @@ import { ChangeDetectorRef, Component, OnDestroy, OnInit } from '@angular/core'; -import { DataService } from '@ghostfolio/client/services/data.service'; import { UserService } from '@ghostfolio/client/services/user/user.service'; import { TabConfiguration, User } from '@ghostfolio/common/interfaces'; -import { hasPermission, permissions } from '@ghostfolio/common/permissions'; import { DeviceDetectorService } from 'ngx-device-detector'; import { Subject } from 'rxjs'; import { takeUntil } from 'rxjs/operators'; @@ -15,7 +13,6 @@ import { takeUntil } from 'rxjs/operators'; }) export class HomePageComponent implements OnDestroy, OnInit { public deviceType: string; - public hasPermissionToAccessFearAndGreedIndex: boolean; public tabs: TabConfiguration[] = []; public user: User; @@ -23,17 +20,9 @@ export class HomePageComponent implements OnDestroy, OnInit { public constructor( private changeDetectorRef: ChangeDetectorRef, - private dataService: DataService, private deviceService: DeviceDetectorService, private userService: UserService ) { - const { globalPermissions } = this.dataService.fetchInfo(); - - this.hasPermissionToAccessFearAndGreedIndex = hasPermission( - globalPermissions, - permissions.enableFearAndGreedIndex - ); - this.userService.stateChanged .pipe(takeUntil(this.unsubscribeSubject)) .subscribe((state) => { @@ -57,8 +46,7 @@ export class HomePageComponent implements OnDestroy, OnInit { { iconName: 'newspaper-outline', label: $localize`Markets`, - path: ['/home', 'market'], - showCondition: this.hasPermissionToAccessFearAndGreedIndex + path: ['/home', 'market'] } ]; this.user = state.user;