import { FormProps, FormSchema } from '/@/components/Form'; import { BasicColumn } from '/@/components/Table'; export const formConfig = { useCustomConfig: false, }; export const searchFormSchema: FormSchema[] = [ { field: 'dateGrade', label: '日期', component: 'RangePicker', componentProps: { format: 'YYYY-MM-DD', style: { width: '100%' }, getPopupContainer: () => document.body, }, }, { field: 'cpName', label: '供应商', component: 'Input', }, { field: 'approCode', label: '审批状态', component: 'XjrSelect', componentProps: { datasourceType: 'dic', params: { itemId: '1990669393069129729' }, labelField: 'name', valueField: 'value', getPopupContainer: () => document.body, }, }, ]; export const columns: BasicColumn[] = [ { dataIndex: 'cpName', title: '供应商', componentType: 'input', align: 'left', sorter: true, }, { dataIndex: 'gsName', title: '评价体系', componentType: 'select', align: 'left', sorter: true, }, { dataIndex: 'score', title: '评价分数', componentType: 'input', align: 'left', sorter: true, }, { dataIndex: 'dateGrade', title: '评价日期', componentType: 'time', align: 'left', sorter: true, }, { dataIndex: 'approCode', title: '审批状态', componentType: 'select', align: 'left', sorter: true, }, { dataIndex: 'note', title: '备注', componentType: 'textarea', 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: '5cea49518df847009ef88a4a7607c327', field: 'cpCode', 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: '9c8f9af1121c40c2802e6479d515ca56', field: 'gsId', label: '评价体系', type: 'select', component: 'XjrSelect', colProps: { span: 24 }, componentProps: { width: '100%', span: '', labelWidthMode: 'fix', labelFixWidth: 120, responsive: false, respNewRow: false, placeholder: '请选择下拉选择', sepTextField: '', showLabel: true, showSearch: false, clearable: false, disabled: false, mode: 'multiple', staticOptions: [ { key: 1, label: 'Option 1', value: 'Option 1' }, { key: 2, label: 'Option 2', value: 'Option 2' }, { key: 3, label: 'Option 3', value: 'Option 3' }, ], defaultSelect: '', datasourceType: 'api', params: null, labelField: 'label', valueField: 'value', apiConfig: { path: 'CodeGeneration/selection', method: 'GET', apiId: '93d735dcb7364a0f8102188ec4d77ac7', }, dicOptions: [], required: false, rules: [], events: {}, isShow: true, style: { width: '100%' }, }, }, { key: '14b57d5a9264471fb752356b5ff174f1', field: 'dateGrade', label: '评价日期', type: 'time', component: 'TimePicker', colProps: { span: 24 }, defaultValue: '', componentProps: { labelWidthMode: 'fix', labelFixWidth: 120, responsive: false, span: '', defaultValue: '', width: '100%', placeholder: '请选择评价日期', format: 'HH:mm:ss', showLabel: true, allowClear: true, disabled: false, required: false, rules: [], events: {}, isShow: true, style: { width: '100%' }, }, }, { key: '6a6f0926b4734fe09d6db0469f13bfc3', field: 'score', 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: '394f55d8b7e14587ac5762a90832fb87', field: 'approCode', label: '审批状态', type: 'select', component: 'XjrSelect', colProps: { span: 24 }, componentProps: { width: '100%', span: '', labelWidthMode: 'fix', labelFixWidth: 120, responsive: false, respNewRow: false, placeholder: '请选择下拉选择审批状态', sepTextField: '', showLabel: true, showSearch: false, clearable: false, disabled: true, mode: '', staticOptions: [ { key: 1, label: 'Option 1', value: 'Option 1' }, { key: 2, label: 'Option 2', value: 'Option 2' }, { key: 3, label: 'Option 3', value: 'Option 3' }, ], defaultSelect: 'WTJ', datasourceType: 'dic', params: { itemId: '1990669393069129729' }, labelField: 'name', valueField: 'value', apiConfig: { path: 'CodeGeneration/selection', method: 'GET', apiId: '93d735dcb7364a0f8102188ec4d77ac7', }, dicOptions: [], required: false, rules: [], events: {}, isShow: true, itemId: '1990669393069129729', style: { width: '100%' }, }, }, { key: '2a53efcd8c154ae8b74ac7e9cb77e5b8', field: 'note', label: '备注', type: 'textarea', component: 'InputTextArea', colProps: { span: 24 }, defaultValue: '', componentProps: { width: '100%', span: '', defaultValue: '', labelWidthMode: 'fix', labelFixWidth: 120, responsive: false, respNewRow: true, placeholder: '请输入备注', maxlength: null, rows: 2, autoSize: false, showCount: false, disabled: false, showLabel: true, allowClear: false, required: false, isShow: true, rules: [], events: {}, style: { width: '100%' }, }, }, { key: '437fbc6627ad493a8dc5546a480e5d45', label: '表格组件', field: 'lngScoreDtlList', type: 'form', component: 'SubForm', required: true, colProps: { span: 24 }, componentProps: { mainKey: 'lngScoreDtlList', columns: [ { key: '6b60e016048a40ada38634af3c8741cd', title: '单行文本', dataIndex: 'itemName', componentType: 'Input', 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, }, }, { title: '操作', key: 'action', fixed: 'right', width: '50px' }, ], span: '24', preloadType: 'api', apiConfig: {}, itemId: '', dicOptions: [], useSelectButton: false, buttonName: '选择数据', showLabel: true, showComponentBorder: true, showFormBorder: true, showIndex: false, isShow: true, multipleHeads: [], }, }, ], showActionButtonGroup: false, buttonLocation: 'center', actionColOptions: { span: 24 }, showResetButton: false, showSubmitButton: false, hiddenComponent: [], };