createDes.jsx 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. import React from 'react';
  2. import { Modal, Spin } from 'antd';
  3. import CreateFrom from '@/account/evaluate/create';
  4. class DemandDesc extends React.Component {
  5. constructor(props) {
  6. super(props);
  7. this.state = {
  8. loading: false,
  9. showState:false
  10. };
  11. }
  12. handleCancel() {
  13. this.setState({
  14. visible: false,
  15. });
  16. this.props.closeDesc(false, true);
  17. }
  18. handOk() {
  19. this.setState({
  20. visible: false,
  21. });
  22. this.props.closeDesc(false, true);
  23. }
  24. componentWillReceiveProps(nextProps) {
  25. this.state.visible = nextProps.showDesc;
  26. }
  27. render() {
  28. let data = this.props.data || {};
  29. return (
  30. <div className="patent-desc">
  31. <Modal
  32. maskClosable={false}
  33. visible={this.state.visible}
  34. onOk={this.handOk.bind(this)}
  35. onCancel={this.handleCancel.bind(this)}
  36. width="1200px"
  37. title={!data.id ? '开始新评估' : '评估结果'}
  38. footer=""
  39. className="admin-desc-content"
  40. >
  41. <div>
  42. <div>
  43. <CreateFrom
  44. closeDesc={this.handleCancel.bind(this)}
  45. data={this.props.data}
  46. visible={this.state.visible}
  47. handOk={this.handOk.bind(this)}
  48. />
  49. </div>
  50. </div>
  51. </Modal>
  52. </div>
  53. );
  54. }
  55. }
  56. export default DemandDesc;