From f3d65152ad14df4c7d6ad51d1f279794c241e76f Mon Sep 17 00:00:00 2001 From: Yuliia Naumenko Date: Tue, 23 Jun 2020 12:12:39 -0700 Subject: [PATCH] Disabled multiple select for preconfigured connectors to avoid requesting bulk delete on them (#69459) --- .../components/actions_connectors_list.tsx | 1 + .../apps/triggers_actions_ui/connectors.ts | 3 +++ 2 files changed, 4 insertions(+) diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/actions_connectors_list/components/actions_connectors_list.tsx b/x-pack/plugins/triggers_actions_ui/public/application/sections/actions_connectors_list/components/actions_connectors_list.tsx index 6379c4e94866af..5d52896cc628f8 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/actions_connectors_list/components/actions_connectors_list.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/actions_connectors_list/components/actions_connectors_list.tsx @@ -277,6 +277,7 @@ export const ActionsConnectorsList: React.FunctionComponent = () => { onSelectionChange(updatedSelectedItemsList: ActionConnectorTableItem[]) { setSelectedItems(updatedSelectedItemsList); }, + selectable: ({ isPreconfigured }: ActionConnectorTableItem) => !isPreconfigured, } : undefined } diff --git a/x-pack/test/functional_with_es_ssl/apps/triggers_actions_ui/connectors.ts b/x-pack/test/functional_with_es_ssl/apps/triggers_actions_ui/connectors.ts index 41be67592cbeb2..810a80c3401ca8 100644 --- a/x-pack/test/functional_with_es_ssl/apps/triggers_actions_ui/connectors.ts +++ b/x-pack/test/functional_with_es_ssl/apps/triggers_actions_ui/connectors.ts @@ -189,6 +189,9 @@ export default ({ getPageObjects, getService }: FtrProviderContext) => { expect(await testSubjects.exists('deleteConnector')).to.be(false); expect(await testSubjects.exists('preConfiguredTitleMessage')).to.be(true); + + const checkboxSelectRow = await testSubjects.find('checkboxSelectRow-my-server-log'); + expect(await checkboxSelectRow.getAttribute('disabled')).to.be('true'); }); it('should not be able to edit a preconfigured connector', async () => {