/* 
*@props perInfo 资格证信息
*/
import React, { Component } from 'react';

import {
  Row,
  Col,
  Form,
  Input
} from 'antd';

import { formItemLayout } from './formLayout';
// @withRouter
export default class Submitted extends Component {
  constructor(props, context) {
    super(props, context);
    this.state = {

    };
  }

  componentDidMount() {

  }

  render() {
    if (!this.props.perInfo.cerNo) {
      return '';
    }
    return (
      <>
        <h3>资格证信息</h3>

        <Row gutter={16}>
          {/* <Col span={6}>
    <Form.Item {...formLayout1} label="证书类型">
      {getFieldDecorator('resident', {
        initialValue: ''
      })(
          <Input style={{width: '100%'}} />
      )}
    </Form.Item>
  </Col> */}
          <Col span={7}>
            <Form.Item {...formItemLayout} label="证书编号">
              {/* {getFieldDecorator('resident', {
        initialValue: this.state.perInfo.cerNo
      })(
          <Input style={{width: '100%'}} />
      )} */}
              <Input disabled value={this.props.perInfo.cerNo} style={{ width: '100%' }} />
            </Form.Item>
          </Col>
          {/* <Col span={6}>
    <Form.Item {...formLayout1} label="培训单位">
      {getFieldDecorator('resident', {
        initialValue: ''
      })(
          <Input style={{width: '100%'}} />
      )}
    </Form.Item>
  </Col> */}
          <Col span={7}>
            <Form.Item {...formItemLayout} label="发证机关">
              <Input disabled value={this.props.perInfo.licenceOrg} style={{ width: '100%' }} />
            </Form.Item>
          </Col>
        </Row>
        <Row gutter={16}>

          <Col span={7}>
            <Form.Item {...formItemLayout} label="发证日期">
              <Input disabled value={this.props.perInfo.licenceDate} style={{ width: '100%' }} />
            </Form.Item>
          </Col>
          <Col span={7}>
            <Form.Item {...formItemLayout} label="电子证">
              {/* <Input value={this.state.perInfo.licenceOrg} style={{width: '100%'}} /> */}
              <a href={this.props.perInfo.electronCerUrl} target="_blank">{this.props.perInfo.name}-电子保安员证</a>
            </Form.Item>
          </Col>
        </Row>
      </>
    );
  }
}

