| | |
| | | import React, {Component} from 'react' |
| | | import PropTypes from 'prop-types' |
| | | import { Form, Row, Col, Button, Input, InputNumber, Radio } from 'antd' |
| | | import './index.scss' |
| | | // import './index.scss' |
| | | |
| | | class ExcelOutColumn extends Component { |
| | | static propTpyes = { |
| | |
| | | // 表单提交时检查输入值是否正确 |
| | | this.props.form.validateFieldsAndScroll((err, values) => { |
| | | if (!err) { |
| | | this.props.columnChange(values) |
| | | this.props.form.setFieldsValue({ |
| | | Column: '', |
| | | Text: '', |
| | | Width: 20 |
| | | this.props.columnChange(values, () => { |
| | | this.props.form.setFieldsValue({ |
| | | Column: '', |
| | | Text: '', |
| | | Width: 20 |
| | | }) |
| | | }) |
| | | } |
| | | }) |
| | |
| | | { |
| | | required: true, |
| | | message: '请输入字段!' |
| | | }, |
| | | { |
| | | pattern: /^[\u4E00-\u9FA50-9a-zA-Z_]*$/ig, |
| | | message: '只允许包含数字、字母、汉字以及_' |
| | | } |
| | | ] |
| | | })(<Input placeholder="" autoComplete="off" onPressEnter={this.handleConfirm}/>)} |