| | |
| | | editable: true |
| | | }, |
| | | { |
| | | title: '类型', |
| | | dataIndex: 'type', |
| | | width: '12%', |
| | | editable: true |
| | | }, |
| | | { |
| | | title: '是否必填', |
| | | dataIndex: 'required', |
| | | width: '12%', |
| | | editable: true, |
| | | render: (text, record) => record.required === 'true' ? '是' : '否' |
| | | }, |
| | | { |
| | | title: '类型', |
| | | dataIndex: 'type', |
| | | width: '12%', |
| | | editable: true |
| | | }, |
| | | { |
| | | title: '最小值', |
| | |
| | | col.required = col.required || 'true' |
| | | col.type = col.type || 'Nvarchar(50)' |
| | | |
| | | if (/^Nvarchar/ig.test(col.type)) { |
| | | col.limit = col.type.match(/\d+/)[0] |
| | | } else if (/^Decimal/ig.test(col.type)) { |
| | | col.limit = col.type.match(/\d+/ig)[1] |
| | | } else { |
| | | col.limit = '' |
| | | } |
| | | |
| | | return col |
| | | }) |
| | | |