Feature/reuse notification service for alert dialogs (#3670)
* Reuse notification service for alert dialogs
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
import { Activity } from '@ghostfolio/api/app/order/interfaces/activities.interface';
|
||||
import { GfAssetProfileIconComponent } from '@ghostfolio/client/components/asset-profile-icon/asset-profile-icon.component';
|
||||
import { NotificationService } from '@ghostfolio/client/core/notification/notification.service';
|
||||
import { GfSymbolModule } from '@ghostfolio/client/pipes/symbol/symbol.module';
|
||||
import { DEFAULT_PAGE_SIZE } from '@ghostfolio/common/config';
|
||||
import { getDateFormatString, getLocale } from '@ghostfolio/common/helper';
|
||||
@@ -120,7 +121,10 @@ export class GfActivitiesTableComponent
|
||||
|
||||
private unsubscribeSubject = new Subject<void>();
|
||||
|
||||
public constructor(private router: Router) {}
|
||||
public constructor(
|
||||
private notificationService: NotificationService,
|
||||
private router: Router
|
||||
) {}
|
||||
|
||||
public ngOnInit() {
|
||||
if (this.showCheckbox) {
|
||||
@@ -260,7 +264,9 @@ export class GfActivitiesTableComponent
|
||||
}
|
||||
|
||||
public onOpenComment(aComment: string) {
|
||||
alert(aComment);
|
||||
this.notificationService.alert({
|
||||
title: aComment
|
||||
});
|
||||
}
|
||||
|
||||
public onOpenPositionDialog({ dataSource, symbol }: AssetProfileIdentifier) {
|
||||
|
Reference in New Issue
Block a user