king
2020-02-21 063b983daaf51a7f1e8677bde1e9c0e618866c91
src/templates/tableshare/verifycardexcelin/index.jsx
@@ -32,17 +32,17 @@
        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: '最小值',
@@ -134,6 +134,14 @@
      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
    })