From 881428a8d4525f919c057b7f9c324301b2669c6a Mon Sep 17 00:00:00 2001 From: Paulo Martins Date: Tue, 27 Jun 2023 18:54:50 -0300 Subject: [PATCH] KOGITO-9481: [SWF Dev UI] Workflows containing hyphens in their id are not listed in the workflow definitions tab - Part 2 --- .../runtime-tools-dev-ui-webapp/src/channel/apis/apis.tsx | 2 +- .../src/channel/apis/tests/apis.test.tsx | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/ui-packages/packages/runtime-tools-dev-ui-webapp/src/channel/apis/apis.tsx b/ui-packages/packages/runtime-tools-dev-ui-webapp/src/channel/apis/apis.tsx index 387cf01cd2..0a1616a425 100755 --- a/ui-packages/packages/runtime-tools-dev-ui-webapp/src/channel/apis/apis.tsx +++ b/ui-packages/packages/runtime-tools-dev-ui-webapp/src/channel/apis/apis.tsx @@ -353,7 +353,7 @@ export const getProcessDefinitionList = ( .then((response) => { const processDefinitionObjs = []; const paths = response.paths; - const regexPattern = /^\/[^\n]+\/schema/; + const regexPattern = /^\/[^\n/]+\/schema/; Object.getOwnPropertyNames(paths) .filter((path) => regexPattern.test(path.toString())) .forEach((url) => { diff --git a/ui-packages/packages/runtime-tools-dev-ui-webapp/src/channel/apis/tests/apis.test.tsx b/ui-packages/packages/runtime-tools-dev-ui-webapp/src/channel/apis/tests/apis.test.tsx index 087ee9ad40..a71abf697a 100755 --- a/ui-packages/packages/runtime-tools-dev-ui-webapp/src/channel/apis/tests/apis.test.tsx +++ b/ui-packages/packages/runtime-tools-dev-ui-webapp/src/channel/apis/tests/apis.test.tsx @@ -897,6 +897,10 @@ describe('process definitions section', () => { SwaggerParser.parse['mockImplementation'](() => Promise.resolve({ paths: { + '/hiring-process/some-task/schema': { + get: {}, + post: {} + }, '/hiring-process/schema': { get: {}, post: {}