231 lines
4.9 KiB
TypeScript
231 lines
4.9 KiB
TypeScript
|
|
import { FormProps, FormSchema } from '/@/components/Form';
|
||
|
|
import { BasicColumn } from '/@/components/Table';
|
||
|
|
|
||
|
|
export const formConfig = {
|
||
|
|
useCustomConfig: false,
|
||
|
|
};
|
||
|
|
|
||
|
|
export const searchFormSchema: FormSchema[] = [
|
||
|
|
{
|
||
|
|
field: 'danXingWenBen5518',
|
||
|
|
label: '单行文本',
|
||
|
|
component: 'Input',
|
||
|
|
},
|
||
|
|
{
|
||
|
|
field: 'danXingWenBen5841',
|
||
|
|
label: '单行文本',
|
||
|
|
component: 'Input',
|
||
|
|
},
|
||
|
|
{
|
||
|
|
field: 'jiShuZuJian6835',
|
||
|
|
label: '计数组件',
|
||
|
|
component: 'InputNumber',
|
||
|
|
componentProps: {
|
||
|
|
style: { width: '100%' },
|
||
|
|
},
|
||
|
|
},
|
||
|
|
];
|
||
|
|
|
||
|
|
export const columns: BasicColumn[] = [
|
||
|
|
{
|
||
|
|
dataIndex: 'danXingWenBen5518',
|
||
|
|
title: '单行文本',
|
||
|
|
componentType: 'input',
|
||
|
|
align: 'left',
|
||
|
|
|
||
|
|
sorter: true,
|
||
|
|
},
|
||
|
|
|
||
|
|
{
|
||
|
|
dataIndex: 'danXingWenBen5841',
|
||
|
|
title: '单行文本',
|
||
|
|
componentType: 'input',
|
||
|
|
align: 'left',
|
||
|
|
|
||
|
|
sorter: true,
|
||
|
|
},
|
||
|
|
|
||
|
|
{
|
||
|
|
dataIndex: 'jiShuZuJian6835',
|
||
|
|
title: '计数组件',
|
||
|
|
componentType: 'number',
|
||
|
|
align: 'left',
|
||
|
|
|
||
|
|
sorter: true,
|
||
|
|
},
|
||
|
|
];
|
||
|
|
//表单事件
|
||
|
|
export const formEventConfigs = {
|
||
|
|
0: [
|
||
|
|
{
|
||
|
|
type: 'circle',
|
||
|
|
color: '#2774ff',
|
||
|
|
text: '开始节点',
|
||
|
|
icon: '#icon-kaishi',
|
||
|
|
bgcColor: '#D8E5FF',
|
||
|
|
isUserDefined: false,
|
||
|
|
},
|
||
|
|
{
|
||
|
|
color: '#F6AB01',
|
||
|
|
icon: '#icon-chushihua',
|
||
|
|
text: '初始化表单',
|
||
|
|
bgcColor: '#f9f5ea',
|
||
|
|
isUserDefined: false,
|
||
|
|
nodeInfo: { processEvent: [] },
|
||
|
|
},
|
||
|
|
],
|
||
|
|
1: [
|
||
|
|
{
|
||
|
|
color: '#B36EDB',
|
||
|
|
icon: '#icon-shujufenxi',
|
||
|
|
text: '获取表单数据',
|
||
|
|
detail: '(新增无此操作)',
|
||
|
|
bgcColor: '#F8F2FC',
|
||
|
|
isUserDefined: false,
|
||
|
|
nodeInfo: { processEvent: [] },
|
||
|
|
},
|
||
|
|
],
|
||
|
|
2: [
|
||
|
|
{
|
||
|
|
color: '#F8625C',
|
||
|
|
icon: '#icon-jiazai',
|
||
|
|
text: '加载表单',
|
||
|
|
bgcColor: '#FFF1F1',
|
||
|
|
isUserDefined: false,
|
||
|
|
nodeInfo: { processEvent: [] },
|
||
|
|
},
|
||
|
|
],
|
||
|
|
3: [
|
||
|
|
{
|
||
|
|
color: '#6C6AE0',
|
||
|
|
icon: '#icon-jsontijiao',
|
||
|
|
text: '提交表单',
|
||
|
|
bgcColor: '#F5F4FF',
|
||
|
|
isUserDefined: false,
|
||
|
|
nodeInfo: { processEvent: [] },
|
||
|
|
},
|
||
|
|
],
|
||
|
|
4: [
|
||
|
|
{
|
||
|
|
type: 'circle',
|
||
|
|
color: '#F8625C',
|
||
|
|
text: '结束节点',
|
||
|
|
icon: '#icon-jieshuzhiliao',
|
||
|
|
bgcColor: '#FFD6D6',
|
||
|
|
isLast: true,
|
||
|
|
isUserDefined: false,
|
||
|
|
},
|
||
|
|
],
|
||
|
|
};
|
||
|
|
export const formProps: FormProps = {
|
||
|
|
labelCol: { span: 3, offset: 0 },
|
||
|
|
labelAlign: 'right',
|
||
|
|
layout: 'horizontal',
|
||
|
|
size: 'default',
|
||
|
|
schemas: [
|
||
|
|
{
|
||
|
|
key: '4251bdeb18574f2cb014ca33d650be52',
|
||
|
|
field: 'danXingWenBen5518',
|
||
|
|
label: '单行文本',
|
||
|
|
type: 'input',
|
||
|
|
component: 'Input',
|
||
|
|
colProps: { span: 24 },
|
||
|
|
defaultValue: '',
|
||
|
|
componentProps: {
|
||
|
|
width: '100%',
|
||
|
|
span: '',
|
||
|
|
defaultValue: '',
|
||
|
|
labelWidthMode: 'fix',
|
||
|
|
labelFixWidth: 120,
|
||
|
|
responsive: false,
|
||
|
|
respNewRow: false,
|
||
|
|
placeholder: '请输入单行文本',
|
||
|
|
maxlength: null,
|
||
|
|
prefix: '',
|
||
|
|
suffix: '',
|
||
|
|
addonBefore: '',
|
||
|
|
addonAfter: '',
|
||
|
|
disabled: false,
|
||
|
|
allowClear: false,
|
||
|
|
showLabel: true,
|
||
|
|
required: false,
|
||
|
|
rules: [],
|
||
|
|
events: {},
|
||
|
|
isSave: false,
|
||
|
|
isShow: true,
|
||
|
|
scan: false,
|
||
|
|
style: { width: '100%' },
|
||
|
|
},
|
||
|
|
},
|
||
|
|
{
|
||
|
|
key: '3cea59512d464fa3b5a81814999718f3',
|
||
|
|
field: 'danXingWenBen5841',
|
||
|
|
label: '单行文本',
|
||
|
|
type: 'input',
|
||
|
|
component: 'Input',
|
||
|
|
colProps: { span: 24 },
|
||
|
|
defaultValue: '',
|
||
|
|
componentProps: {
|
||
|
|
width: '100%',
|
||
|
|
span: '',
|
||
|
|
defaultValue: '',
|
||
|
|
labelWidthMode: 'fix',
|
||
|
|
labelFixWidth: 120,
|
||
|
|
responsive: false,
|
||
|
|
respNewRow: false,
|
||
|
|
placeholder: '请输入单行文本',
|
||
|
|
maxlength: null,
|
||
|
|
prefix: '',
|
||
|
|
suffix: '',
|
||
|
|
addonBefore: '',
|
||
|
|
addonAfter: '',
|
||
|
|
disabled: false,
|
||
|
|
allowClear: false,
|
||
|
|
showLabel: true,
|
||
|
|
required: false,
|
||
|
|
rules: [],
|
||
|
|
events: {},
|
||
|
|
isSave: false,
|
||
|
|
isShow: true,
|
||
|
|
scan: false,
|
||
|
|
style: { width: '100%' },
|
||
|
|
},
|
||
|
|
},
|
||
|
|
{
|
||
|
|
key: 'c4aaaf58ffbc468bb3f6c4f013b0350b',
|
||
|
|
field: 'jiShuZuJian6835',
|
||
|
|
label: '计数组件',
|
||
|
|
type: 'number',
|
||
|
|
component: 'InputNumber',
|
||
|
|
colProps: { span: 24 },
|
||
|
|
defaultValue: 0,
|
||
|
|
componentProps: {
|
||
|
|
labelWidthMode: 'fix',
|
||
|
|
labelFixWidth: 120,
|
||
|
|
responsive: false,
|
||
|
|
width: '100%',
|
||
|
|
span: '',
|
||
|
|
defaultValue: 0,
|
||
|
|
min: 0,
|
||
|
|
max: 100,
|
||
|
|
step: 1,
|
||
|
|
maxlength: null,
|
||
|
|
disabled: false,
|
||
|
|
showLabel: true,
|
||
|
|
controls: true,
|
||
|
|
required: false,
|
||
|
|
subTotal: false,
|
||
|
|
isShow: true,
|
||
|
|
rules: [],
|
||
|
|
events: {},
|
||
|
|
style: { width: '100%' },
|
||
|
|
},
|
||
|
|
},
|
||
|
|
],
|
||
|
|
showActionButtonGroup: false,
|
||
|
|
buttonLocation: 'center',
|
||
|
|
actionColOptions: { span: 24 },
|
||
|
|
showResetButton: false,
|
||
|
|
showSubmitButton: false,
|
||
|
|
hiddenComponent: [],
|
||
|
|
};
|