Implement 'select/unselect all' actions
[arvados.git] / src / views-components / context-menu / action-sets / collection-files-action-set.ts
index 1e183d53c078a58452762b8f097f3395d1d712fc..dc17e693e38a8cff841689ff29121f4f9bf3fa71 100644 (file)
@@ -3,17 +3,18 @@
 // SPDX-License-Identifier: AGPL-3.0
 
 import { ContextMenuActionSet } from "../context-menu-action-set";
+import { collectionPanelFilesAction } from "../../../store/collection-panel/collection-panel-files/collection-panel-files-actions";
 
 
 export const collectionFilesActionSet: ContextMenuActionSet = [[{
     name: "Select all",
-    execute: (dispatch, resource) => {
-        return;
+    execute: (dispatch) => {
+        dispatch(collectionPanelFilesAction.SELECT_ALL_COLLECTION_FILES());
     }
 },{
     name: "Unselect all",
-    execute: (dispatch, resource) => {
-        return;
+    execute: (dispatch) => {
+        dispatch(collectionPanelFilesAction.UNSELECT_ALL_COLLECTION_FILES());
     }
 },{
     name: "Remove selected",