feat(web): 正式提取流程设计能力到AI目录下,做代码拆分
This commit is contained in:
50
service-web/client/src/pages/ai/flow/node/StartNode.tsx
Normal file
50
service-web/client/src/pages/ai/flow/node/StartNode.tsx
Normal file
@@ -0,0 +1,50 @@
|
||||
import type {NodeProps} from '@xyflow/react'
|
||||
import AmisNode from './AmisNode.tsx'
|
||||
|
||||
const StartNode = (props: NodeProps) => AmisNode(
|
||||
props,
|
||||
'start',
|
||||
'开始节点',
|
||||
'定义输入变量',
|
||||
[
|
||||
{
|
||||
type: 'input-kvs',
|
||||
name: 'fields',
|
||||
addButtonText: '新增入参',
|
||||
draggable: false,
|
||||
keyItem: {
|
||||
label: '参数名称',
|
||||
},
|
||||
valueItems: [
|
||||
{
|
||||
type: 'input-text',
|
||||
name: 'description',
|
||||
label: '参数描述',
|
||||
},
|
||||
{
|
||||
type: 'select',
|
||||
name: 'type',
|
||||
label: '参数类型',
|
||||
required: true,
|
||||
selectFirst: true,
|
||||
options: [
|
||||
{
|
||||
label: '文本',
|
||||
value: 'text',
|
||||
},
|
||||
{
|
||||
label: '数字',
|
||||
value: 'number',
|
||||
},
|
||||
{
|
||||
label: '文件',
|
||||
value: 'files',
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
)
|
||||
|
||||
export default StartNode
|
||||
Reference in New Issue
Block a user