X-Git-Url: https://git.arvados.org/arvados-workbench2.git/blobdiff_plain/c3b3bdb39e8e0a8ec7368f06a95450a0ef5e572e..65d436f7c4bd643c7b6cccf97001ff6aef2c896b:/src/views-components/context-menu/action-sets/collection-files-action-set.ts diff --git a/src/views-components/context-menu/action-sets/collection-files-action-set.ts b/src/views-components/context-menu/action-sets/collection-files-action-set.ts index 1e183d53..91fa2b00 100644 --- a/src/views-components/context-menu/action-sets/collection-files-action-set.ts +++ b/src/views-components/context-menu/action-sets/collection-files-action-set.ts @@ -3,31 +3,34 @@ // 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"; +import { openMultipleFilesRemoveDialog } from "../../file-remove-dialog/multiple-files-remove-dialog"; +import { createCollectionWithSelected } from "../../create-collection-dialog-with-selected/create-collection-dialog-with-selected"; 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", execute: (dispatch, resource) => { - return; + dispatch(openMultipleFilesRemoveDialog()); } -},{ +}, { name: "Download selected", execute: (dispatch, resource) => { return; } -},{ +}, { name: "Create a new collection with selected", - execute: (dispatch, resource) => { - return; + execute: (dispatch) => { + dispatch(createCollectionWithSelected()); } }]];