yee 7 years ago
parent
commit
2306c30611

+ 6 - 2
js/component/manageCenter/achievement/techAchievementDesc.jsx

@@ -839,11 +839,15 @@ const AchievementDetailForm = Form.create()(React.createClass({
     },
     componentWillMount() {
         this.state.therottleSearch = throttle(this.handleSearch, 1000, { leading: false }).bind(this);
-        this.loadData(this.props.data.id, this.props.detailApiUrl);
+        if (this.props.data && this.props.data.id) {
+            this.loadData(this.props.data.id, this.props.detailApiUrl);
+        };
     },
     componentWillReceiveProps(nextProps) {
         if (!this.props.visible && nextProps.visible) {
-            this.loadData(nextProps.data.id.nextProps.detailApiUrl);
+            if (nextProps.data && nextProps.data.id) {
+                this.loadData(nextProps.data.id, nextProps.detailApiUrl);
+            };
             this.state.textFileList = [];
             this.state.techPlanFileList = [];
             this.state.businessPlanFileList = [];

+ 10 - 12
js/component/manageCenter/demand/techDemand.jsx

@@ -455,18 +455,16 @@ const DemandList = React.createClass({
                             <Select.Option value="0" >未发布</Select.Option>
                             <Select.Option value="1" >已发布</Select.Option>
                         </Select>
-                        <p>
-                            <span>有效期限 :</span>
-                            <RangePicker
-                                value={[this.state.validityPeriodDate[0] ? moment(this.state.validityPeriodDate[0]) : null,
-                                this.state.validityPeriodDate[1] ? moment(this.state.validityPeriodDate[1]) : null]}
-                                onChange={(data, dataString) => { this.setState({ validityPeriodDate: dataString }); }} />
-                            <span>发布时间 :</span>
-                            <RangePicker
-                                value={[this.state.releaseDate[0] ? moment(this.state.releaseDate[0]) : null,
-                                this.state.releaseDate[1] ? moment(this.state.releaseDate[1]) : null]}
-                                onChange={(data, dataString) => { this.setState({ releaseDate: dataString }); }} />
-                        </p>
+                        <span style={{marginLeft:'10px'}}>有效期限 : </span>
+                        <RangePicker
+                            value={[this.state.validityPeriodDate[0] ? moment(this.state.validityPeriodDate[0]) : null,
+                            this.state.validityPeriodDate[1] ? moment(this.state.validityPeriodDate[1]) : null]}
+                            onChange={(data, dataString) => { this.setState({ validityPeriodDate: dataString }); }} />
+                        <span style={{marginLeft:'10px'}}>发布时间 : </span>
+                        <RangePicker
+                            value={[this.state.releaseDate[0] ? moment(this.state.releaseDate[0]) : null,
+                            this.state.releaseDate[1] ? moment(this.state.releaseDate[1]) : null]}
+                            onChange={(data, dataString) => { this.setState({ releaseDate: dataString }); }} />
                     </div>
                 </div>
                 <div className="patent-table">

+ 10 - 6
js/component/manageCenter/demand/techDemandDesc.jsx

@@ -648,9 +648,9 @@ const DemandDetailForm = Form.create()(React.createClass({
             };
             //url转化
             let thePictureUrl = [];
-            if (this.props.pictureUrl.length) {
+            if (this.state.pictureUrl.length) {
                 let picArr = [];
-                this.props.pictureUrl.map(function (item) {
+                this.state.pictureUrl.map(function (item) {
                     picArr.push(item.response.data);
                 });
                 thePictureUrl = picArr.join(",");
@@ -711,11 +711,15 @@ const DemandDetailForm = Form.create()(React.createClass({
         });
     },
     componentWillMount() {
-        this.loadData(this.props.id, this.props.detailApiUrl);
+        if (this.props.data && this.props.data.id) {
+            this.loadData(this.props.data.id, this.props.detailApiUrl);
+        };
     },
     componentWillReceiveProps(nextProps) {
         if (!this.props.visible && nextProps.visible) {
-            this.loadData(nextProps.id, nextProps.detailApiUrl);
+            if (nextProps.data && nextProps.data.id) {
+                this.loadData(nextProps.data.id, nextProps.detailApiUrl);
+            };
             this.state.textFileList = [];
             this.state.videoFileList = [];
             this.state.textFileUrl = undefined;
@@ -769,7 +773,7 @@ const DemandDetailForm = Form.create()(React.createClass({
                                     onSelect={(e, n) => {
                                         theData.uid = e;
                                         if (this.props.detailApiUrl.indexOf('org') >= 0) {
-                                            this.props.getContactsList(e);
+                                            this.getContactsList(e);
                                         };
                                     }}>
                                     {this.props.detailApiUrl.indexOf('org') >= 0 ? this.props.companyOption : this.props.userOption}
@@ -787,7 +791,7 @@ const DemandDetailForm = Form.create()(React.createClass({
                                     notFoundContent="未获取到联系人列表"
                                     showSearch
                                     filterOption={companySearch}>
-                                    {this.props.contactsOption}
+                                    {this.state.contactsOption}
                                 </Select>
                                 )}
                         </FormItem> : <div></div>}

+ 14 - 3
js/component/portal/portal.less

@@ -78,6 +78,8 @@
                 line-height: 70px;
                 text-align: center;
                 a {
+                    display: inline-block;
+                    width: 200px;
                     font-size: 18px;
                     color: #333;
                 }
@@ -300,9 +302,9 @@
         padding: 0 20px 20px;
     }
     .interest_list_title {
-        position: relative;
-        line-height: 60px;
+        line-height: 40px;
         padding-left: 60px;
+        position: relative;
         >img {
             width: 30px;
             position: absolute;
@@ -313,10 +315,19 @@
             font-size: 20px;
             color: #58a3ff;
         }
+    }
+    .interest_list_name {
+        position: relative;
+        >p {
+            font-size: 16px;
+            text-align: right;
+            padding-right: 120px;
+            color: #58a3ff;
+        }
         .interest_list_confirm {
             position: absolute;
             right: 10px;
-            top: 0;
+            top: 2px;
             span {
                 margin-right: 10px;
             }

+ 3 - 0
js/component/portal/search/achievement.jsx

@@ -352,6 +352,9 @@ const Content = React.createClass({
                                     style={{ float: 'left', marginLeft: '20px', width: '48%' }}>
                                     <div className="interest_list_title" style={{ paddingLeft: '20px' }}>
                                         <span>{item.name}</span>
+                                    </div>
+                                    <div className="interest_list_name" style={{ paddingLeft: '20px' }}>
+                                        <p>{item.ownerName}</p>
                                         <div className="interest_list_confirm">
                                             <span>{item.level ? '身份已验证' : '身份未验证'}</span>
                                             <img src={item.level ? certify : uncertify} alt="" />

+ 3 - 0
js/component/portal/search/demand.jsx

@@ -281,6 +281,9 @@ const Content = React.createClass({
                                     <div className="interest_list_title">
                                         <img src={demand_sup} alt="" />
                                         <span>{item.name}</span>
+                                    </div>
+                                    <div className="interest_list_name" style={{ paddingLeft: '20px' }}>
+                                        <p>{item.employerName}</p>
                                         <div className="interest_list_confirm">
                                             <span>{item.level ? '身份已验证' : '身份未验证'}</span>
                                             <img src={item.level ? certify : uncertify} alt="" />