feat(plugin-workflow-request): allow to use variable in url (#3304)

This commit is contained in:
Junyi 2024-01-02 21:35:09 +08:00 committed by GitHub
parent fda30fd519
commit 64e0659f7b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -4,6 +4,7 @@ import {
Instruction,
WorkflowVariableInput,
WorkflowVariableJSON,
WorkflowVariableTextArea,
defaultFieldNames,
} from '@nocobase/plugin-workflow/client';
@ -41,7 +42,7 @@ export default class extends Instruction {
title: `{{t("URL", { ns: "${NAMESPACE}" })}}`,
'x-decorator': 'FormItem',
'x-decorator-props': {},
'x-component': 'Input',
'x-component': 'WorkflowVariableTextArea',
'x-component-props': {
placeholder: 'https://www.nocobase.com',
},
@ -175,6 +176,7 @@ export default class extends Instruction {
components = {
ArrayItems,
WorkflowVariableInput,
WorkflowVariableTextArea,
WorkflowVariableJSON,
};
useVariables({ key, title }, { types, fieldNames = defaultFieldNames }) {