diff --git a/src-ui/src/app/components/admin/trash/trash.component.html b/src-ui/src/app/components/admin/trash/trash.component.html index 451f22895..94d20bcd4 100644 --- a/src-ui/src/app/components/admin/trash/trash.component.html +++ b/src-ui/src/app/components/admin/trash/trash.component.html @@ -6,6 +6,9 @@ info="Manage trashed items." + @@ -24,7 +27,7 @@ info="Manage trashed items."
- +
@@ -66,10 +69,10 @@ info="Manage trashed items."
diff --git a/src-ui/src/app/components/admin/trash/trash.component.ts b/src-ui/src/app/components/admin/trash/trash.component.ts index c5e53bfc8..4821a51f9 100644 --- a/src-ui/src/app/components/admin/trash/trash.component.ts +++ b/src-ui/src/app/components/admin/trash/trash.component.ts @@ -14,7 +14,7 @@ import { Subject, takeUntil } from 'rxjs' export class TrashComponent implements OnDestroy { public documentsInTrash: Document[] = [] public selectedDocuments: Set = new Set() - public togggleAll: boolean = false + public allToggled: boolean = false public page: number = 1 public isLoading: boolean = false unsubscribeNotifier: Subject = new Subject() @@ -37,7 +37,7 @@ export class TrashComponent implements OnDestroy { this.trashService.getTrash().subscribe((documentsInTrash) => { this.documentsInTrash = documentsInTrash this.isLoading = false - console.log('Trash:', documentsInTrash) + this.selectedDocuments.clear() }) } @@ -79,6 +79,7 @@ export class TrashComponent implements OnDestroy { .emptyTrash(documents ? Array.from(documents) : []) .subscribe(() => { this.toastService.showInfo($localize`Document(s) deleted`) + this.allToggled = false this.reload() }) }) @@ -86,7 +87,7 @@ export class TrashComponent implements OnDestroy { restore(document: Document) { this.trashService.restoreDocuments([document.id]).subscribe(() => { - this.toastService.showInfo($localize`Object restored`) + this.toastService.showInfo($localize`Document restored`) this.reload() }) } @@ -95,7 +96,8 @@ export class TrashComponent implements OnDestroy { this.trashService .restoreDocuments(objects ? Array.from(this.selectedDocuments) : []) .subscribe(() => { - this.toastService.showInfo($localize`Object(s) restored`) + this.toastService.showInfo($localize`Document(s) restored`) + this.allToggled = false this.reload() }) } @@ -115,7 +117,7 @@ export class TrashComponent implements OnDestroy { } clearSelection() { - this.togggleAll = false + this.allToggled = false this.selectedDocuments.clear() } } diff --git a/src-ui/src/app/components/app-frame/app-frame.component.html b/src-ui/src/app/components/app-frame/app-frame.component.html index 3695a731c..20c90b402 100644 --- a/src-ui/src/app/components/app-frame/app-frame.component.html +++ b/src-ui/src/app/components/app-frame/app-frame.component.html @@ -267,15 +267,13 @@ } - - - +