X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/6d1c41d6fd83824669cd1a6d714ea6da1ae7ab4c..0a274c87a1412df329469504b3581cc8c7084255:/services/workbench2/src/views-components/context-menu/action-sets/keep-service-action-set.ts diff --git a/services/workbench2/src/views-components/context-menu/action-sets/keep-service-action-set.ts b/services/workbench2/src/views-components/context-menu/action-sets/keep-service-action-set.ts index 820d1978fd..2957f008cd 100644 --- a/services/workbench2/src/views-components/context-menu/action-sets/keep-service-action-set.ts +++ b/services/workbench2/src/views-components/context-menu/action-sets/keep-service-action-set.ts @@ -4,25 +4,31 @@ import { openKeepServiceAttributesDialog, openKeepServiceRemoveDialog } from 'store/keep-services/keep-services-actions'; import { openAdvancedTabDialog } from 'store/advanced-tab/advanced-tab'; -import { ContextMenuActionSet } from "views-components/context-menu/context-menu-action-set"; -import { AdvancedIcon, RemoveIcon, AttributesIcon } from "components/icon/icon"; +import { ContextMenuActionSet } from 'views-components/context-menu/context-menu-action-set'; +import { AdvancedIcon, RemoveIcon, AttributesIcon } from 'components/icon/icon'; -export const keepServiceActionSet: ContextMenuActionSet = [[{ - name: "Attributes", - icon: AttributesIcon, - execute: (dispatch, { uuid }) => { - dispatch(openKeepServiceAttributesDialog(uuid)); - } -}, { - name: "API Details", - icon: AdvancedIcon, - execute: (dispatch, { uuid }) => { - dispatch(openAdvancedTabDialog(uuid)); - } -}, { - name: "Remove", - icon: RemoveIcon, - execute: (dispatch, { uuid }) => { - dispatch(openKeepServiceRemoveDialog(uuid)); - } -}]]; +export const keepServiceActionSet: ContextMenuActionSet = [ + [ + { + name: 'Attributes', + icon: AttributesIcon, + execute: (dispatch, resources) => { + dispatch(openKeepServiceAttributesDialog(resources[0].uuid)); + }, + }, + { + name: 'API Details', + icon: AdvancedIcon, + execute: (dispatch, resources) => { + dispatch(openAdvancedTabDialog(resources[0].uuid)); + }, + }, + { + name: 'Remove', + icon: RemoveIcon, + execute: (dispatch, resources) => { + dispatch(openKeepServiceRemoveDialog(resources[0].uuid)); + }, + }, + ], +];