mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
Revert "ACS-3640 a 11 y aca 881740 snackbar messages disappear without option to adjust timing (#7916)" (#7977)
This reverts commit 4d76ebe1ab
.
This commit is contained in:
@@ -49,7 +49,8 @@ export class CommunityStartProcessCloudDemoComponent implements OnInit {
|
||||
|
||||
openSnackMessage(event: any) {
|
||||
this.notificationService.openSnackMessage(
|
||||
event.response.body.message
|
||||
event.response.body.message,
|
||||
4000
|
||||
);
|
||||
}
|
||||
}
|
||||
|
@@ -42,7 +42,8 @@ export class CommunityStartTaskCloudDemoComponent {
|
||||
|
||||
openSnackMessage(event: any) {
|
||||
this.notificationService.openSnackMessage(
|
||||
event.response.body.message
|
||||
event.response.body.message,
|
||||
4000
|
||||
);
|
||||
}
|
||||
}
|
||||
|
@@ -17,14 +17,8 @@
|
||||
|
||||
import { Component, OnInit, ViewEncapsulation } from '@angular/core';
|
||||
import { ActivatedRoute, Router, PRIMARY_OUTLET } from '@angular/router';
|
||||
import {
|
||||
ContentService,
|
||||
AllowableOperationsEnum,
|
||||
PermissionsEnum,
|
||||
NodesApiService,
|
||||
FileUploadErrorEvent,
|
||||
NotificationService
|
||||
} from '@alfresco/adf-core';
|
||||
import { ContentService, AllowableOperationsEnum, PermissionsEnum, NodesApiService, FileUploadErrorEvent } from '@alfresco/adf-core';
|
||||
import { MatSnackBar } from '@angular/material/snack-bar';
|
||||
import { PreviewService } from '../../services/preview.service';
|
||||
|
||||
@Component({
|
||||
@@ -70,10 +64,10 @@ export class FileViewComponent implements OnInit {
|
||||
|
||||
constructor(private router: Router,
|
||||
private route: ActivatedRoute,
|
||||
private snackBar: MatSnackBar,
|
||||
private nodeApiService: NodesApiService,
|
||||
private contentServices: ContentService,
|
||||
private preview: PreviewService,
|
||||
private notificationService: NotificationService) {
|
||||
private preview: PreviewService) {
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
@@ -111,7 +105,7 @@ export class FileViewComponent implements OnInit {
|
||||
|
||||
onUploadError(event: FileUploadErrorEvent) {
|
||||
const errorMessage = event.error;
|
||||
this.notificationService.showError(errorMessage);
|
||||
this.snackBar.open(errorMessage, '', { duration: 4000 });
|
||||
}
|
||||
|
||||
toggleEmptyMetadata() {
|
||||
|
@@ -18,8 +18,9 @@
|
||||
import { Component, Inject, ViewEncapsulation } from '@angular/core';
|
||||
import { MAT_DIALOG_DATA, MatDialogRef } from '@angular/material/dialog';
|
||||
import { MinimalNodeEntryEntity } from '@alfresco/js-api';
|
||||
import { MatSnackBar } from '@angular/material/snack-bar';
|
||||
import { PreviewService } from '../../services/preview.service';
|
||||
import {FileUploadErrorEvent, NotificationService} from '@alfresco/adf-core';
|
||||
import { FileUploadErrorEvent } from '@alfresco/adf-core';
|
||||
|
||||
@Component({
|
||||
templateUrl: './version-manager-dialog-adapter.component.html',
|
||||
@@ -36,8 +37,8 @@ export class VersionManagerDialogAdapterComponent {
|
||||
showVersionComparison = false;
|
||||
|
||||
constructor(private previewService: PreviewService,
|
||||
private notificationService: NotificationService,
|
||||
@Inject(MAT_DIALOG_DATA) data: any,
|
||||
private snackBar: MatSnackBar,
|
||||
private containingDialog?: MatDialogRef<VersionManagerDialogAdapterComponent>) {
|
||||
this.contentEntry = data.contentEntry;
|
||||
this.newFileVersion = data.hasOwnProperty('newFileVersion') ? data.newFileVersion : this.newFileVersion;
|
||||
@@ -47,7 +48,7 @@ export class VersionManagerDialogAdapterComponent {
|
||||
|
||||
uploadError(event: FileUploadErrorEvent) {
|
||||
const errorMessage = event.error;
|
||||
this.notificationService.showError(errorMessage);
|
||||
this.snackBar.open(errorMessage, '', { duration: 4000 });
|
||||
}
|
||||
|
||||
close() {
|
||||
|
Reference in New Issue
Block a user