| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788 | 
							- import React from 'react';
 
- import { Icon, Modal, message, Spin, Button } from 'antd';
 
- import './comprehensive.less';
 
- import ajax from 'jquery/src/ajax/xhr.js';
 
- import $ from 'jquery/src/ajax';
 
- const CorrectionDesc = React.createClass({
 
-     getInitialState() {
 
-         return {
 
-             visible: false,
 
-             loading: false,
 
-         };
 
-     },
 
-     showModal() {
 
-         this.setState({
 
-             visible: true,
 
-         });
 
-     },
 
-     handleOk() {
 
-         this.setState({
 
-             loading: true
 
-         });
 
-         $.ajax({
 
-             method: "post",
 
-             dataType: "json",
 
-             crossDomain: false,
 
-             url: globalConfig.context + "/api/admin/patent/replyConfirm",
 
-             data: {
 
-                 pid: this.props.data.pid,
 
-                 uid: this.props.data.uid,
 
-                 patentState: this.props.data.patentState
 
-             },
 
-             success: function (data) {
 
-                 if (data.error && data.error.length) {
 
-                     message.warning(data.error[0].message);
 
-                 } else {
 
-                     message.success('保存成功!');
 
-                     this.props.closeDesc(false, true);
 
-                 };
 
-             }.bind(this),
 
-         }).always(function () {
 
-             this.setState({
 
-                 loading: false,
 
-                 visible: false,
 
-             });
 
-         }.bind(this));
 
-     },
 
-     handleCancel(e) {
 
-         this.setState({
 
-             visible: false,
 
-         });
 
-         this.props.closeDesc(false);
 
-     },
 
-     componentWillReceiveProps(nextProps) {
 
-         this.state.visible = nextProps.showDesc
 
-     },
 
-     render() {
 
-         if (this.props.data) {
 
-             return (
 
-                 <div className="payment-desc">
 
-                     <Spin spinning={this.state.loading} className='spin-box'>
 
-                         <Modal maskClosable={false} title="通知答复确认" visible={this.state.visible}
 
-                             onOk={this.handleOk} onCancel={this.handleCancel}
 
-                             width='500px'
 
-                             footer={[
 
-                                 <Button key="submit" type="primary" size="large" onClick={this.handleOk}>确认</Button>,
 
-                                 <Button key="back" type="ghost" size="large" onClick={this.handleCancel}>取消</Button>,
 
-                             ]}
 
-                             className="patent-desc-content">
 
-                             <div style={{ fontSize: '16px' }}>
 
-                                 <p><span>公司:</span>{this.props.data.unitName}</p>
 
-                                 <p><span>专利:</span>{this.props.data.patentName}</p>
 
-                                 <p>{(() => {
 
-                                     if (this.props.data.patentState == 6) { return <span>审查意见</span> }
 
-                                     else if (this.props.data.patentState == 8) { return <span>补正通知</span> }
 
-                                 })()}
 
-                                     <span>确认已经答复?</span></p>
 
-                             </div>
 
-                         </Modal>
 
-                     </Spin>
 
-                 </div>
 
-             );
 
-         } else {
 
-             return <div></div>
 
-         }
 
-     },
 
- });
 
- export default CorrectionDesc;
 
 
  |