import React from 'react'; import ajax from 'jquery/src/ajax/xhr.js'; import $ from 'jquery/src/ajax'; import { Form, Spin, message, Modal } from 'antd'; import {getProjectName,getNewOrderStatus,getJsyPaymentType} from '@/tools.js'; const BonusDetail=React.createClass({ getInitialState() { return { loading: false, visible:false, showDesc:false, }; }, onCancel(){ this.setState({ visible:false }) this.props.closeDesc(false,false); }, onShow() { this.setState({ visible: false, }); this.props.closeDesc(false, true); }, componentWillMount() { }, componentWillReceiveProps(nextProps) { if(nextProps.data.orderNo){ this.setState({data:nextProps.data}); } this.state.visible=nextProps.showDesc; }, render() { const theData = this.props.data || {}; const FormItem = Form.Item; const formItemLayout = { labelCol: { span: 10 }, wrapperCol: { span: 12 }, }; return (