diff --git a/src/app/shared/components/home/client-table/client-table.component.html b/src/app/shared/components/home/client-table/client-table.component.html index 64cbdcf..9c34981 100644 --- a/src/app/shared/components/home/client-table/client-table.component.html +++ b/src/app/shared/components/home/client-table/client-table.component.html @@ -45,16 +45,14 @@ -

- {{ client.name }} -

+ {{ client.name }} - {{ client.billed_users_count === 0 ? '-' : client.billed_users_count }} + {{ client.billed_users_count }} - {{ client.enabled_users_count === 0 ? '-' : client.enabled_users_count }} - + {{ client.enabled_users_count }} + View

@@ -62,8 +60,8 @@
- {{ client.pending_users_count === 0 ? '-' : client.pending_users_count }} - + {{ client.pending_users_count }} + View

@@ -71,8 +69,8 @@
- {{ client.incomplete_expenses_count === 0 ? '-' : client.incomplete_expenses_count }} - + {{ client.incomplete_expenses_count }} + View

@@ -80,8 +78,8 @@
- {{ client.approval_pending_reports_count === 0 ? '-' : client.approval_pending_reports_count }} - + {{ client.approval_pending_reports_count }} + View

diff --git a/src/app/shared/components/home/client-table/client-table.component.spec.ts b/src/app/shared/components/home/client-table/client-table.component.spec.ts index bac686e..66ae8ef 100644 --- a/src/app/shared/components/home/client-table/client-table.component.spec.ts +++ b/src/app/shared/components/home/client-table/client-table.component.spec.ts @@ -43,10 +43,6 @@ describe('ClientTableComponent', () => { expect(component).toBeTruthy(); }); - it('should open org in Fyle', () => { - expect(component.openOrg('dummy_org_id')).toBeUndefined(); - }); - it('should show/hide View button for table rows', () => { const client = clientOrgResponse.data[0]; expect(component.showOrHideViewInFyle(client, true)); diff --git a/src/app/shared/components/home/client-table/client-table.component.ts b/src/app/shared/components/home/client-table/client-table.component.ts index c366d3a..e63f6a3 100644 --- a/src/app/shared/components/home/client-table/client-table.component.ts +++ b/src/app/shared/components/home/client-table/client-table.component.ts @@ -1,11 +1,9 @@ import { Component, EventEmitter, HostListener, Input, OnInit, Output } from '@angular/core'; import { FormGroup } from '@angular/forms'; -import { ClientRedirectionType, RedirectLink } from 'src/app/core/models/enum/enum.model'; +import { ClientRedirectionType } from 'src/app/core/models/enum/enum.model'; import { Client, PageScroll, TableColumn } from 'src/app/core/models/home/client.model'; import { HomeService } from 'src/app/core/services/home/home.service'; import { TrackingService } from 'src/app/core/services/integration/tracking.service'; -import { environment } from 'src/environments/environment'; -import { WindowService } from 'src/app/core/services/core/window.service'; @Component({ selector: 'app-client-table', @@ -70,8 +68,7 @@ export class ClientTableComponent implements OnInit { constructor( private homeService: HomeService, - private trackingService: TrackingService, - private windowService: WindowService + private trackingService: TrackingService ) { } onWindowScroll(event: any) { @@ -93,12 +90,6 @@ export class ClientTableComponent implements OnInit { client.showViewinFyle = isRowHovered; } - openOrg(org_id: string): void { - const url = `${environment.fyle_app_url}${RedirectLink.FYLE_ADMIN}?org_id=${org_id}`; - this.trackingService.onClickViewEvent(ClientRedirectionType.FYLE_ADMIN); - this.windowService.openInNewTab(url); - } - redirect(clientRedirectionType: ClientRedirectionType, org_id: string): void { this.trackingService.onClickViewEvent(clientRedirectionType); this.homeService.redirect(clientRedirectionType, org_id);