123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960 |
- import React from 'react';
- import { Modal, Spin } from 'antd';
- import BannerForm from '@/administration/banner/bannerForm';
- class DemandDesc extends React.Component {
- constructor(props) {
- super(props);
- this.state = {
- loading: false,
- pictureUrl: [],
- showState:false
- };
- }
- handleCancel() {
- this.setState({
- visible: false,
- });
- this.props.closeDesc(false, false);
- }
- handOk() {
- this.setState({
- visible: false,
- });
- this.props.closeDesc(false, true);
- }
- componentWillReceiveProps(nextProps) {
- this.state.visible = nextProps.showDesc;
- }
- render() {
- let data = this.props.data || {releaseStatus:0};
- return (
- <div className="patent-desc">
- <Modal
- maskClosable={false}
- visible={this.state.visible}
- onOk={this.handOk.bind(this)}
- onCancel={this.handleCancel.bind(this)}
- width="600px"
- title={data.id?'修改轮播图':'新建轮播图'}
- footer=""
- className="admin-desc-content"
- >
- <div>
- <div>
- <BannerForm
- closeDesc={this.handleCancel.bind(this)}
- data={this.props.data}
- visible={this.state.visible}
- handOk={this.handOk.bind(this)}
- />
- </div>
- </div>
- </Modal>
- </div>
- );
- }
- }
- export default DemandDesc;
|