//订单列表
import React from 'react';
import { Table, Popconfirm, Icon, message, Modal, Form, Divider, Select, Row, Col, Button, Input, DatePicker, Tabs } from 'antd';
import { $http } from '../../containers/config/https';
import moment from 'moment';
import { handleExcel } from 'tools/handleExcel.js';
import store from '../../store';
import './style/style.less'
import CommonPagination from 'components/pagination/index';

const { Option } = Select;
const { TabPane } = Tabs;
const dateFormat = 'YYYY-MM-DD'; //定义全局日期格式
const formItemLayout = {    // label 和input宽度
    labelCol: { span: 10 },
    wrapperCol: { span: 12, offset: 2 },
};
let user;
class MaintainBSTransactionRecord extends React.Component {
    constructor(props) {
        super(props);
        user = window.sessionStorage.userData ? JSON.parse(window.sessionStorage.userData) : {};
        this.state = {
            loading: false, //加载状态标志
            visible: false, //弹窗显示状态标志
            motalTitle: '', //弹窗标题
            total1: 0,  // 表格数据总条数
            page1: 1, //当前页数
            pageSize1: 50, //每页显示条数
            total2: 0,  // 表格数据总条数
            page2: 1, //当前页数
            pageSize2: 50, //每页显示条数
            tableData1: [],
            tableData2: [],
            ifBaddebts: 1,  //1代表正常列表，2代表坏账列表
            outtradeno: '', //订单号
            transactionid: '', //微信支付流水号
            selectStatus: '', //状态选择
            BusinessTypeData: [], //支付方式下拉框
            BusinessType: '', //支付类型
            patID: '', //病人id
            patName: '', //病人姓名
            payDate: moment(), //支付日期
            payEndDate: moment(),
            record: {}      // 行数据记录
        };
        this.columns1 = [
            {
                title: '订单号',
                dataIndex: 'outtradeno',
                key: 'outtradeno',
                width: '250px',
                ellipsis: true,
                align: "center",
            },
            {
                title: '平台订单号',
                dataIndex: 'hipPayTradeNum',
                key: 'hipPayTradeNum',
                width: '250px',
                ellipsis: true,
                align: "center",
            },
            {
                title: '姓名',
                dataIndex: 'patName',
                key: 'patName',
                width: '100px',
                align: "center",
                ellipsis: true,
            },
            {
                title: '身份证号',
                dataIndex: 'IDCardNo',
                key: 'IDCardNo',
                width: '180px',
                align: "center",
                ellipsis: true,
            },
            {
                title: '医保金额',
                dataIndex: 'insuAmt',
                key: 'insuAmt',
                width: '100px',
                align: "center",
                ellipsis: true,
            },
            {
                title: '状态',
                dataIndex: 'statusDesc',
                key: 'statusDesc',
                width: '100px',
                align: "center",
                ellipsis: true,
            },
            {
                title: '医院',
                dataIndex: 'hosp',
                key: 'hosp',
                width: '150px',
                align: "center",
                ellipsis: true,
            },
            {
                title: '电话',
                dataIndex: 'mobile',
                key: 'mobile',
                width: '100px',
                align: "center",
                ellipsis: true,
            },
            {
                title: 'HIS订单号',
                dataIndex: 'hisTradeNum',
                key: 'hisTradeNum',
                width: '280px',
                ellipsis: true,
                align: "center",
            },
            {
                title: '微信支付流水号',
                dataIndex: 'transactionid',
                key: 'transactionid',
                width: '250px',
                ellipsis: true,
                align: "center",
            },
            {
                title: '订单描述',
                dataIndex: 'body',
                key: 'body',
                width: '100px',
                ellipsis: true,
                align: "center",
            },
            {
                title: '金额',
                dataIndex: 'settlementtotalfee',
                key: 'settlementtotalfee',
                width: '100px',
                align: "center",
                ellipsis: true,
            },
            {
                title: '订单状态',
                dataIndex: 'tradestate',
                key: 'tradestate',
                width: '100px',
                ellipsis: true,
                align: "center",
            },
            {
                title: '日期',
                dataIndex: 'payDate',
                key: 'payDate',
                width: '180px',
                ellipsis: true,
                align: "center",
            },
            {
                title: '支付渠道',
                dataIndex: 'businessType',
                key: 'businessType',
                width: '180px',
                ellipsis: true,
                align: "center",
            },
            {
                title: '错误代码',
                dataIndex: 'errcode',
                key: 'errcode',
                width: '200px',
                ellipsis: true,
                align: "center",
            },
            {
                title: '错误描述',
                dataIndex: 'errcodedes',
                key: 'errcodedes',
                width: '250px',
                ellipsis: true,
                align: "center",
            },
            {
                title: '检查',
                key: 'check',
                align: "center",
                fixed: 'right',
                width: '100px',
                render: (text, record) => (
                    <span>
                        <span className='span' onClick={() => this.checkOut(record)} style={{ color: record.status == 'UN' ? '#fa8c16' : '#d9d9d9' }}><Icon type="search" />检查</span>
                    </span>
                ),
            },
            {
                title: '操作',
                key: 'op',
                align: "center",
                fixed: 'right',
                width: '100px',
                render: (text, record) => (
                    <span>
                        <span className='span' onClick={() => this.showModal(record)}><Icon type="edit" />订单详情</span>
                    </span>
                ),
            },
        ];
        this.columns2 = [
            {
                title: '订单号',
                dataIndex: 'outtradenoB',
                key: 'outtradenoB',
                width: '100px',
                align: "center",
            },
            {
                title: '姓名',
                dataIndex: 'patNameB',
                key: 'patNameB',
                width: '100px',
                align: "center",
            },
            {
                title: '身份证号',
                dataIndex: 'IDCardNoB',
                key: 'IDCardNoB',
                width: '100px',
                align: "center",
            },
            {
                title: '电话',
                dataIndex: 'mobileB',
                key: 'mobileB',
                width: '100px',
                align: "center",
            },
            {
                title: '微信支付流水号',
                dataIndex: 'transactionidB',
                key: 'transactionidB',
                width: '100px',
                align: "center",
            },
            {
                title: '订单描述',
                dataIndex: 'body',
                key: 'body',
                width: '100px',
                align: "center",
            },
            {
                title: '金额',
                dataIndex: 'settlementtotalfeeB',
                key: 'settlementtotalfeeB',
                width: '100px',
                align: "center",
            },
            {
                title: '订单类型',
                dataIndex: 'tradetypeB',
                key: 'tradetypeB',
                width: '100px',
                align: "center",
            },
            {
                title: '订单状态',
                dataIndex: 'tradestateB',
                key: 'tradestateB',
                width: '100px',
                align: "center",
            },
            {
                title: '订单错误',
                dataIndex: 'errcodedesB',
                key: 'errcodedesB',
                width: '100px',
                align: "center",
            },
            {
                title: '日期',
                dataIndex: 'payDateB',
                key: 'payDateB',
                width: '100px',
                align: "center",
            },
            {
                title: '操作',
                key: 'opB',
                align: "center",
                width: '100px',
                render: (text, record) => (
                    <span>
                        <span className='span' onClick={() => this.showModal(record, 'bad')} ><Icon type="edit" />坏账详情</span>
                    </span>
                ),
            },
        ];
    }


    componentDidMount() {
        //初始化列表数据
        this.handleQuery();
        //支付类型下拉框
        this.getBusinessTypeData();
    }

    // 导出订单列表
    exportInformation() {
        let columns1 = this.columns1;
        console.log("columns1", columns1)
        if (this.state.tableData1.length > 0) {
            handleExcel.exportExcel(columns1, this.state.tableData1, '订单列表')
        }
    }

    //支付方式下拉框数据
    getBusinessTypeData = () => {
        let data = {
            params: [{

            }],
        }
        let busTypeData = []
        $http.post('urlS', this, {
            code: '130965',
            data: data,
            success: function (res) {
                if (+res.errorCode === 0) {
                    for (var i = 0; i < res.result.data.length; i++) {
                        busTypeData.push(<Option value={String(res.result.data[i].id)} key={i + "P"} >{res.result.data[i].descripts}</Option>)
                    }
                    this.setState({ BusinessTypeData: busTypeData })
                }
            }
        })
    }

    //初始化列表数据
    handleQuery = () => {
        this.setState({loading:true});
        let { page1, pageSize1, page2, pageSize2, ifBaddebts, outtradeno, transactionid, patID, patName, payDate, payEndDate, selectStatus, BusinessType } = this.state;
        let data = {}
        let code = '130966'
        if (ifBaddebts === 1) {
            code = '130966'
            data = {
                params: [{
                    outtradeno: outtradeno,
                    transactionid: transactionid,
                    selectStatus: selectStatus,
                    businessType: BusinessType,
                    patID: patID,
                    patName: patName,
                    payDate: payDate,
                    payEndDate: payEndDate
                }],
                pagination: [{
                    pageSize: pageSize1,
                    currentPage: page1,
                    sortColumn: 'code',
                    sortOrder: 'asc'
                }]
            }
        } else {
            code = '130967'
            data = {
                params: [{
                    outtradeno: outtradeno,
                    transactionid: transactionid,
                    patID: patID,
                    patName: patName,
                    payDate: payDate,
                }],
                pagination: [{
                    pageSize: pageSize2,
                    currentPage: page2,
                    sortColumn: 'code',
                    sortOrder: 'asc'
                }]
            }
        }
        $http.post('urlS', this, {
            code: code,
            data: data,
            success: function (res) {
                if (ifBaddebts == 1) {
                    if (+res.errorCode === 0 && res.result.data) {
                        this.setState({ tableData1: res.result.data, total1: res.result.totalCount, loading: false })
                    } else {
                        this.setState({ tableData1: [], total1: 0, loading: false })
                    }
                } else {
                    if (+res.errorCode === 0 && res.result.data) {
                        console.log(res.result.data)
                        this.setState({ tableData2: res.result.data, total2: res.result.totalCount, loading: false })
                    } else {
                        this.setState({ tableData2: [], total2: 0, loading: false })
                    }
                }
            }
        })
    }

    checkOut(record) {
        if (record.status != 'UN') {
            return;
        }
        let data = {}
        data = {
            params: [{
                UPPPayMentRecordID: record.id,
                hipPayTradeNum: record.hipPayTradeNum,
                hospID: record.hospID,
                hospCode: record.hospCode
            }]
        }
        $http.post('urlS', this, {
            code: '130985',
            data: data,
            success: function (res) {
                if (+res.errorCode == 0) {
                    message.success(res.errorMessage);
                    this.handleQuery();
                } else {
                    message.error(res.errorMessage);
                }
            }
        })
    }

    // 页码改变的回调，参数是改变后的页码及每页条数
    appPageChange = (page, pageSize) => {
        this.setState({
            page1: page,
            pageSize1: pageSize,
        }, () => {
            // 重新调用查询方法
            this.handleQuery();
        });
    }

    // 条数改变的回调
    apponShowSizeChange = (current, size) => {
        this.setState({
            page1: current,
            pageSize1: size,
        }, () => {
            // 重新调用查询方法
            this.handleQuery();
        });
    }

    // 页码改变的回调，参数是改变后的页码及每页条数
    appPageChange2 = (page, pageSize) => {
        this.setState({
            page2: page,
            pageSize2: pageSize,
        }, () => {
            // 重新调用查询方法
            this.handleQuery();
        });
    }

    // 条数改变的回调
    apponShowSizeChange2 = (current, size) => {
        this.setState({
            page2: current,
            pageSize2: size,
        }, () => {
            // 重新调用查询方法
            this.handleQuery();
        });
    }

    //订单号改变
    onChangeOuttradeno = (e) => {
        this.setState({ outtradeno: e.target.value })
    }

    //微信交易流水改变
    onChangeTransactionid = (e) => {
        this.setState({ transactionid: e.target.value })
    }

    //病人ID改变
    onChangePatID = (e) => {
        this.setState({ patID: e.target.value })
    }

    //病人姓名改变
    onChangePatName = (e) => {
        this.setState({ patName: e.target.value })
    }

    //支付日期改变
    onChangePayDate = value => {
        this.setState({ payDate: value })
    }
    //支付日期改变
    onChangeEndPayDate = value => {
        this.setState({ payEndDate: value })
    }
    statusChange = (e) => {
        this.setState({ selectStatus: e });
    }

    onChangeBusinessType = (e) => {
        let arr = ""
        for (var i = 0; i < e.length; i++) {
            if (i != (e.length - 1)) {
                arr = arr + e[i] + ','
            } else {
                arr = arr + e[i]
            }
        }
        this.setState({ BusinessType: arr });
    }

    //标签变化
    changeTabs = key => {
        if (key === "1") {
            this.setState({ ifBaddebts: 1 }, () => { this.handleQuery() })
        } else {
            this.setState({ ifBaddebts: 2 }, () => { this.handleQuery() })
        }
    }

    //弹窗点击取消
    handleCancel = () => {
        this.setState({ visible: false, });
    };
    // 退款
    refound = () => {
        let { record } = this.state
        let data = {
            params: [{
                businessType: 'REFUND',
                reason: '前端订单管理退款',
                transactionid: record.transactionid,
                payTradeNum: record.hipPayTradeNum,
                refundamt: 0 - record.settlementtotalfee,
                hisTradeNo: record.hisTradeNum,
                hospitalCode: record.hospCode,
                userCode: user.userCode,
                userName: user.userName,
                onlineYBFalg: '',
                reFomdFalg: 'C'
            }]
        }
        $http.post('urlS', this, {
            code: '130990',
            data: data,
            success: function (res) {
                if (+res.errorCode == 0) {
                    message.success('退款成功')
                } else {
                    message.error('退款失败')
                }
            }
        })
    };
    //正常订单弹窗显示
    showModal = (record) => {
        this.setState({ record })
        let data = {}
        data = {
            params: [{
                BSUPPPayMentRecordID: record.id
            }]
        }
        $http.post('urlS', this, {
            code: '130974',
            data: data,
            success: function (res) {
                if (+res.errorCode === 0 && res.result.data) {
                    this.props.form.setFieldsValue({
                        hosp: res.result.data[0].hosp,
                        businessType: res.result.data[0].businessType,
                        payReasonDesc: res.result.data[0].payReasonDesc,
                        payDate: res.result.data[0].payDate,
                        PayTime: res.result.data[0].PayTime,
                        totalAmt: res.result.data[0].totalAmt,
                        discountAmt: res.result.data[0].discountAmt,
                        shareFreeAmt: res.result.data[0].shareFreeAmt,
                        patAmt: res.result.data[0].patAmt,
                        insuAmt: res.result.data[0].insuAmt,
                        recordStatus: res.result.data[0].recordStatus,
                        reportFlag: res.result.data[0].reportFlag,
                        reason: res.result.data[0].reason,
                        electronicPictureUrl: res.result.data[0].electronicPictureUrl,
                        payTradeNum: res.result.data[0].payTradeNum,
                        outtradeno: res.result.data[0].outtradeno,
                        hisTradeNum: res.result.data[0].hisTradeNum,
                        resultCode: res.result.data[0].resultCode,
                        errorCode: res.result.data[0].errorCode,
                        tradeState: res.result.data[0].tradeState,
                        body: res.result.data[0].body
                    });
                    if (record.status == 'UN') {
                        this.setState({
                            visible: true,
                            motalTitle: "坏账订单详情",
                        });
                    } else {
                        this.setState({
                            visible: true,
                            motalTitle: "正常订单详情",
                        });
                    }
                }
            }
        })
    };

    render() {
        let { BusinessTypeData } = this.state;
        const { getFieldDecorator } = this.props.form;
        return (
            <div>
                <div style={{ width: '100%', height: '100%', padding: '24px 24px 24px 24px', minHeight: '120px' }}>
                    <Row>
                        <Col span={4}>
                            <span>订单号：</span>
                            <Input allowClear placeholder="请输入订单号" style={{ width: '200px', }} onChange={this.onChangeOuttradeno} />
                        </Col>
                        <Col span={6}>
                            <span>微信交易流水号：</span>
                            <Input allowClear placeholder="请输入交易流水" style={{ width: '200px', }} onChange={this.onChangeTransactionid} />
                        </Col>
                        <Col span={5}>
                            <span>支付起始日期：</span>
                            <DatePicker
                                style={{ width: '180px' }}
                                format='YYYY-MM-DD'
                                onChange={this.onChangePayDate}
                                value={this.state.payDate}
                            />
                        </Col>
                        <Col span={5}>
                            <span>支付结束日期：</span>
                            <DatePicker
                                style={{ width: '180px' }}
                                format='YYYY-MM-DD'
                                onChange={this.onChangeEndPayDate}
                                value={this.state.payEndDate}
                            />
                        </Col>
                        <Col span={3} style={{ textAlign: 'right' }}>
                            <Button type="primary" onClick={() => this.handleQuery()} icon="search" loading={this.state.loading}>查询</Button>
                            <Button type="primary" onClick={() => this.exportInformation()} style={{ marginLeft: "20px" }} >导出订单</Button>
                        </Col>
                    </Row>
                    <Row style={{ marginTop: '10px' }}>
                        <Col span={4}>
                            <span>病人ID：</span>
                            <Input allowClear placeholder="请输入病人ID" style={{ width: '200px', }} onChange={this.onChangePatID} />
                        </Col>
                        <Col span={5}>
                            <span>病人姓名：</span>
                            <Input allowClear placeholder="请输入病人姓名" style={{ width: '180px', }} onChange={this.onChangePatName} />
                        </Col>
                        <Col span={4}>
                            <span>状态：</span>
                            <Select allowClear placeholder="请选择状态" style={{ width: '180px', }} onChange={this.statusChange}>
                                <Option value="N">正常</Option>
                                <Option value="T">退费</Option>
                                <Option value="UN">异常</Option>
                            </Select>
                        </Col>
                        <Col span={8}>
                            <span>支付类型：</span>
                            <Select style={{ width: '400px' }} mode="multiple" allowClear placeholder="请选择支付方式" onChange={this.onChangeBusinessType} >
                                {BusinessTypeData}
                            </Select>
                        </Col>
                    </Row>
                </div>
                <div style={{ widht: '100%', height: '10px', background: '#f0f2f5' }}></div>
                <div style={{ padding: 24 }}>
                    <Table
                        style={{}}
                        dataSource={this.state.tableData1}
                        columns={this.columns1}
                        className='TableA'
                        pagination={false}
                        scroll={{ x: 900, y: store.getState().tableHeight.y - 25 }}
                        bordered
                        loading={this.state.loading}
                        rowClassName={record => { if (record.status == 'UN') return 'table-color-dust'; if (record.status == 'NT') return 'table-color-nt'; }}
                    />
                    {/* <CommonPagination size="large" current={this.state.page1} total={this.state.total1} search='search'
                        onShowSizeChange={this.apponShowSizeChange} complete={true} dataSource={this.state.tableData1}
                        onChange={this.appPageChange} /> */}
                    <Modal
                        visible={this.state.visible}
                        title={this.state.motalTitle}
                        onOk={this.handleCancel}
                        onCancel={this.handleCancel}
                        width='1000px'
                        footer={[
                            <Button key="back" onClick={this.handleCancel}>返回</Button>,
                            this.state.record && this.state.record.status == 'UN' ? <Button key="back" onClick={this.refound}>退款</Button> : null
                        ]}
                    >
                        <Form layout="inline" className='formTable'>
                            <div>
                                <Row>
                                    <Col span={8}>
                                        <Form.Item label='医院：' {...formItemLayout} >
                                            {getFieldDecorator("hosp", {
                                                initialValue: '',
                                            })(
                                                <Input style={{ width: '180px' }} disabled={true} />
                                            )}
                                        </Form.Item>
                                    </Col>
                                    <Col span={8}>
                                        <Form.Item label='交易类型：' {...formItemLayout} >
                                            {getFieldDecorator("businessType", {
                                                initialValue: '',
                                            })(
                                                <Input style={{ width: '180px' }} disabled={true} />
                                            )}
                                        </Form.Item>
                                    </Col>
                                    <Col span={8}>
                                        <Form.Item label='支付费别：' {...formItemLayout} >
                                            {getFieldDecorator("payReasonDesc", {
                                                initialValue: '',
                                            })(
                                                <Input style={{ width: '180px' }} disabled={true} />
                                            )}
                                        </Form.Item>
                                    </Col>
                                    <Col span={8}>
                                        <Form.Item label='收款日期：' {...formItemLayout} >
                                            {getFieldDecorator("payDate", {
                                                initialValue: '',
                                            })(
                                                <Input style={{ width: '180px' }} disabled={true} />
                                            )}
                                        </Form.Item>
                                    </Col>
                                    <Col span={8}>
                                        <Form.Item label='收款时间：' {...formItemLayout} >
                                            {getFieldDecorator("PayTime", {
                                                initialValue: '',
                                            })(
                                                <Input style={{ width: '180px' }} disabled={true} />
                                            )}
                                        </Form.Item>
                                    </Col>
                                    <Col span={8}>
                                        <Form.Item label='总金额：' {...formItemLayout} >
                                            {getFieldDecorator("totalAmt", {
                                                initialValue: '',
                                            })(
                                                <Input style={{ width: '180px' }} disabled={true} />
                                            )}
                                        </Form.Item>
                                    </Col>
                                    <Col span={8}>
                                        <Form.Item label='折扣金额：' {...formItemLayout} >
                                            {getFieldDecorator("discountAmt", {
                                                initialValue: '',
                                            })(
                                                <Input style={{ width: '180px' }} disabled={true} />
                                            )}
                                        </Form.Item>
                                    </Col>
                                    <Col span={8}>
                                        <Form.Item label='记账金额：' {...formItemLayout} >
                                            {getFieldDecorator("shareFreeAmt", {
                                                initialValue: '',
                                            })(
                                                <Input style={{ width: '180px' }} disabled={true} />
                                            )}
                                        </Form.Item>
                                    </Col>
                                    <Col span={8}>
                                        <Form.Item label='实付金额：' {...formItemLayout} >
                                            {getFieldDecorator("patAmt", {
                                                initialValue: '',
                                            })(
                                                <Input style={{ width: '180px' }} disabled={true} />
                                            )}
                                        </Form.Item>
                                    </Col>
                                    <Col span={8}>
                                        <Form.Item label='医保结算金额：' {...formItemLayout} >
                                            {getFieldDecorator("insuAmt", {
                                                initialValue: '',
                                            })(
                                                <Input style={{ width: '180px' }} disabled={true} />
                                            )}
                                        </Form.Item>
                                    </Col>
                                    <Col span={8}>
                                        <Form.Item label='收费状态：' {...formItemLayout} >
                                            {getFieldDecorator("recordStatus", {
                                                initialValue: '',
                                            })(
                                                <Input style={{ width: '180px' }} disabled={true} />
                                            )}
                                        </Form.Item>
                                    </Col>
                                    <Col span={8}>
                                        <Form.Item label='结账状态：' {...formItemLayout} >
                                            {getFieldDecorator("reportFlag", {
                                                initialValue: '',
                                            })(
                                                <Input style={{ width: '180px' }} disabled={true} />
                                            )}
                                        </Form.Item>
                                    </Col>
                                    <Col span={8}>
                                        <Form.Item label='退款原因：' {...formItemLayout} >
                                            {getFieldDecorator("reason", {
                                                initialValue: '',
                                            })(
                                                <Input style={{ width: '180px' }} disabled={true} />
                                            )}
                                        </Form.Item>
                                    </Col>
                                    <Col span={8}>
                                        <Form.Item label='电子发票地址：' {...formItemLayout} >
                                            {getFieldDecorator("electronicPictureUrl", {
                                                initialValue: '',
                                            })(
                                                <Input style={{ width: '180px' }} disabled={true} />
                                            )}
                                        </Form.Item>
                                    </Col>
                                    <Col span={8}>
                                        <Form.Item label='交易类型：' {...formItemLayout} >
                                            {getFieldDecorator("businessType", {
                                                initialValue: '',
                                            })(
                                                <Input style={{ width: '180px' }} disabled={true} />
                                            )}
                                        </Form.Item>
                                    </Col>
                                    <Col span={8}>
                                        <Form.Item label='付款交易流水号：' {...formItemLayout} >
                                            {getFieldDecorator("payTradeNum", {
                                                initialValue: '',
                                            })(
                                                <Input style={{ width: '180px' }} disabled={true} />
                                            )}
                                        </Form.Item>
                                    </Col>
                                    <Col span={8}>
                                        <Form.Item label='商户订单号：' {...formItemLayout} >
                                            {getFieldDecorator("outtradeno", {
                                                initialValue: '',
                                            })(
                                                <Input style={{ width: '180px' }} disabled={true} />
                                            )}
                                        </Form.Item>
                                    </Col>
                                    <Col span={8}>
                                        <Form.Item label='HIS交易流水：' {...formItemLayout} >
                                            {getFieldDecorator("hisTradeNum", {
                                                initialValue: '',
                                            })(
                                                <Input style={{ width: '180px' }} disabled={true} />
                                            )}
                                        </Form.Item>
                                    </Col>
                                    <Col span={8}>
                                        <Form.Item label='业务结果：' {...formItemLayout} >
                                            {getFieldDecorator("resultCode", {
                                                initialValue: '',
                                            })(
                                                <Input style={{ width: '180px' }} disabled={true} />
                                            )}
                                        </Form.Item>
                                    </Col>
                                    <Col span={8}>
                                        <Form.Item label='错误代码：' {...formItemLayout} >
                                            {getFieldDecorator("errorCode", {
                                                initialValue: '',
                                            })(
                                                <Input style={{ width: '180px' }} disabled={true} />
                                            )}
                                        </Form.Item>
                                    </Col>
                                    <Col span={8}>
                                        <Form.Item label='交易状态：' {...formItemLayout} >
                                            {getFieldDecorator("tradeState", {
                                                initialValue: '',
                                            })(
                                                <Input style={{ width: '180px' }} disabled={true} />
                                            )}
                                        </Form.Item>
                                    </Col>
                                    <Col span={8}>
                                        <Form.Item label='商品描述：' {...formItemLayout} >
                                            {getFieldDecorator("body", {
                                                initialValue: '',
                                            })(
                                                <Input style={{ width: '180px' }} disabled={true} />
                                            )}
                                        </Form.Item>
                                    </Col>
                                </Row>
                            </div>
                        </Form>
                    </Modal>
                </div>
            </div >
        )
    }
}

const MaintainBSTransactionRecordForm = Form.create()(MaintainBSTransactionRecord);
export default MaintainBSTransactionRecordForm;
