diff --git a/client/src/pages/actions/Show.tsx b/client/src/pages/actions/Show.tsx index f57afa4..60ec72c 100644 --- a/client/src/pages/actions/Show.tsx +++ b/client/src/pages/actions/Show.tsx @@ -12,7 +12,7 @@ import { Show } from '@refinedev/mui' import type { IChangeEvent } from '@rjsf/core' import { withTheme } from '@rjsf/core' import { Theme } from '@rjsf/mui' -import type { RJSFSchema } from '@rjsf/utils' +import type { RJSFSchema, UiSchema } from '@rjsf/utils' import validator from '@rjsf/validator-ajv8' import type { FC } from 'react' import { useState } from 'react' @@ -22,6 +22,7 @@ import { RunningActionsList } from '../../components/RunningActionsList' // @todo move to types interface IActionData extends BaseRecord { jsonschema: RJSFSchema + uischema: UiSchema } interface IFormValues { @@ -52,6 +53,8 @@ export const ActionShow: FC = () => { const jsonschema = queryResult?.data?.data?.jsonschema + const uischema = queryResult?.data?.data?.uischema?.uiSchema || {} + if (jsonschema) { // @todo I actually don't know for the moment how to overcome error // "no schema with key or ref" produced when schema is defined. @@ -117,7 +120,12 @@ export const ActionShow: FC = () => { }} /> {jsonschema && ( -
+