mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-05-26 17:24:56 +00:00
Fix selection reset issue (#2414)
This commit is contained in:
parent
757128186c
commit
8afe358f33
@ -198,6 +198,12 @@ describe('DocumentList', () => {
|
|||||||
expect(documentList.resetSelection).toHaveBeenCalled();
|
expect(documentList.resetSelection).toHaveBeenCalled();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
it('should reset selection in the datatable also', () => {
|
||||||
|
spyOn(documentList.dataTable, 'resetSelection').and.callThrough();
|
||||||
|
documentList.loadFolderByNodeId('-trashcan-');
|
||||||
|
expect(documentList.dataTable.resetSelection).toHaveBeenCalled();
|
||||||
|
});
|
||||||
|
|
||||||
it('should empty template be present when no element are present', (done) => {
|
it('should empty template be present when no element are present', (done) => {
|
||||||
documentList.currentFolderId = '1d26e465-dea3-42f3-b415-faa8364b9692';
|
documentList.currentFolderId = '1d26e465-dea3-42f3-b415-faa8364b9692';
|
||||||
documentList.folderNode = new NodeMinimal();
|
documentList.folderNode = new NodeMinimal();
|
||||||
|
@ -484,6 +484,7 @@ export class DocumentListComponent implements OnInit, OnChanges, AfterContentIni
|
|||||||
}
|
}
|
||||||
|
|
||||||
resetSelection() {
|
resetSelection() {
|
||||||
|
this.dataTable.resetSelection();
|
||||||
this.selection = [];
|
this.selection = [];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user