fixed-removing-selected-files
authorPawel Kowalczyk <pawel.kowalczyk@contractors.roche.com>
Tue, 19 Feb 2019 14:26:05 +0000 (15:26 +0100)
committerPawel Kowalczyk <pawel.kowalczyk@contractors.roche.com>
Tue, 19 Feb 2019 14:26:05 +0000 (15:26 +0100)
Feature #14856

Arvados-DCO-1.1-Signed-off-by: Pawel Kowalczyk <pawel.kowalczyk@contractors.roche.com>

src/store/collection-panel/collection-panel-files/collection-panel-files-actions.ts

index 11cdd6226fa264d3ac98770438290e372c211138..b75de94a7e890ac74871b496b565bf270c3d861e 100644 (file)
@@ -39,9 +39,13 @@ export const removeCollectionFiles = (filePaths: string[]) =>
         if (currentCollection) {
             dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Removing...' }));
             try {
-                await services.collectionService.deleteFiles('', filePaths);
+                await services.collectionService.deleteFiles(currentCollection.uuid, filePaths);
                 dispatch<any>(loadCollectionFiles(currentCollection.uuid));
-                dispatch(snackbarActions.OPEN_SNACKBAR({ message: 'Removed.', hideDuration: 2000 }));
+                dispatch(snackbarActions.OPEN_SNACKBAR({
+                    message: 'Removed.',
+                    hideDuration: 2000,
+                    kind: SnackbarKind.SUCCESS
+                }));
             } catch (e) {
                 dispatch(snackbarActions.OPEN_SNACKBAR({
                     message: 'Could not remove file.',