[ACA-4503] Fix closing dialogs behind when closing the content selector dialog (#7138)

* [ACA-4503] Fix closing dialogs behind when closing the content selector dialog

* [ACA-4503] Close the dialogs from the content node selector component
This commit is contained in:
Pablo Martinez Garcia
2021-07-01 15:16:26 +02:00
committed by GitHub
parent 05c3ed01d7
commit d93980d1a3
4 changed files with 31 additions and 21 deletions

View File

@@ -143,9 +143,6 @@ export class ContentNodeDialogService {
if (this.contentService.hasAllowableOperations(contentEntry, permission)) {
const select = new Subject<Node[]>();
select.subscribe({
complete: this.close.bind(this)
});
const data: ContentNodeSelectorComponentData = {
title: this.getTitleTranslation(action, contentEntry.name),
@@ -186,9 +183,6 @@ export class ContentNodeDialogService {
*/
openUploadFolderDialog(action: NodeAction, contentEntry: Node): Observable<Node[]> {
const select = new Subject<Node[]>();
select.subscribe({
complete: this.close.bind(this)
});
const data: ContentNodeSelectorComponentData = {
title: this.getTitleTranslation(action, this.translation.instant('DROPDOWN.MY_FILES_OPTION')),
@@ -214,9 +208,6 @@ export class ContentNodeDialogService {
*/
openUploadFileDialog(action: NodeAction, contentEntry: Node, showFilesInResult = false): Observable<Node[]> {
const select = new Subject<Node[]>();
select.subscribe({
complete: this.close.bind(this)
});
const data: ContentNodeSelectorComponentData = {
title: this.getTitleTranslation(action, this.translation.instant('DROPDOWN.MY_FILES_OPTION')),
@@ -273,9 +264,4 @@ export class ContentNodeDialogService {
return !!entry.guid || entry.nodeType === 'st:site' || entry.nodeType === 'st:sites';
}
/** Closes the currently open dialog. */
close() {
this.dialog.closeAll();
}
}