杨树明 5 years ago
parent 60137fc05a
commit 0cce347143

@ -2,7 +2,7 @@ import React, {Component} from 'react';
import {Link} from "react-router-dom"; import {Link} from "react-router-dom";
import axios from 'axios'; import axios from 'axios';
import { Input ,Icon,Button,Pagination,DatePicker,Breadcrumb} from 'antd'; import { Input ,Icon,Button,Pagination,DatePicker,Breadcrumb} from 'antd';
import { handleDateString,markdownToHTML,bytesToSize} from 'educoder'; import { handleDateString,markdownToHTML,bytesToSize,getImageUrl} from 'educoder';
import NEITaskDetailsModel from './NEITaskDetailsModel'; import NEITaskDetailsModel from './NEITaskDetailsModel';
import moment from 'moment'; import moment from 'moment';
import '../packageconcnet.css'; import '../packageconcnet.css';
@ -281,7 +281,7 @@ class PackageIndexNEITaskDetails extends Component {
<div className="fl edu-back-white "> <div className="fl edu-back-white ">
<a href={`/users/${data&&data.creator.login}`}> <a href={`/users/${data&&data.creator.login}`}>
<img alt="头像" className="radius mt10 ml5" height="70" id="nh_user_logo" name="avatar_image" <img alt="头像" className="radius mt10 ml5" height="70" id="nh_user_logo" name="avatar_image"
src={data&&data.creator.image_url} width="70"/> src={getImageUrl("images/"+data&&data.creator.image_url)} width="70"/>
</a> </a>
<div className=" edu-back-white pagemancenter mt10 "> <div className=" edu-back-white pagemancenter mt10 ">
{data&&data.creator.name} {data&&data.creator.name}
@ -403,7 +403,7 @@ class PackageIndexNEITaskDetails extends Component {
return( return(
<div className="ysldivhomediv1s homehove" key={key}> <div className="ysldivhomediv1s homehove" key={key}>
{item.status==="bidding_won"?<img src={gouxuan} className="yslgouxuanimg"/>:""} {item.status==="bidding_won"?<img src={gouxuan} className="yslgouxuanimg"/>:""}
<a href={`/users/${item.login}`}><img className="div1imgs" src={item.image_url}/></a> <a href={`/users/${item.login}`}><img className="div1imgs" src={getImageUrl("images/"+item.image_url)}/></a>
<div className="textall mt10" title={item.name}> <p className="ptext">{item.name}</p></div> <div className="textall mt10" title={item.name}> <p className="ptext">{item.name}</p></div>
{this.props.current_user&&this.props.current_user.login!=item.login?<a className="ContacttheTAs fl none" target="_blank" href={`/users/${item.login}/message_detail?user_id=${item.id}`}> {this.props.current_user&&this.props.current_user.login!=item.login?<a className="ContacttheTAs fl none" target="_blank" href={`/users/${item.login}/message_detail?user_id=${item.id}`}>
<img alt="头像" className="mr5" src={require('./newstwo.png')}/>联系TA <img alt="头像" className="mr5" src={require('./newstwo.png')}/>联系TA
@ -451,7 +451,7 @@ class PackageIndexNEITaskDetails extends Component {
return( return(
<div className="ysldivhomediv1s" onClick={()=>this.Clickteacher2(item.id)} key={key}> <div className="ysldivhomediv1s" onClick={()=>this.Clickteacher2(item.id)} key={key}>
{item.bool===true?<img src={gouxuan} className="yslgouxuanimg"/>:<img src={weigouxuan} className="yslgouxuanimg"/>} {item.bool===true?<img src={gouxuan} className="yslgouxuanimg"/>:<img src={weigouxuan} className="yslgouxuanimg"/>}
<a href={`/users/${item.login}`} target="_blank"><img className="div1imgs" src={item.image_url}/></a> <a href={`/users/${item.login}`} target="_blank"><img className="div1imgs" src={getImageUrl("images/"+item.image_url)}/></a>
<span className={item.bool===true?"textall mt10 color-blue":"textall mt10"} title={item.name}> <p className="ptext">{item.name}</p></span> <span className={item.bool===true?"textall mt10 color-blue":"textall mt10"} title={item.name}> <p className="ptext">{item.name}</p></span>
</div> </div>
) )

@ -67,7 +67,7 @@ class PackageIndexNEIBannerConcent extends Component {
} }
} }
componentDidUpdate = (prevProps) => { componentDidUpdate = (prevProps) => {
if(prevProps.current_user.username!=this.props.current_user.username){ if(prevProps.current_user.username!=this.props.current_user&&this.props.current_user.username){
this.setState({ this.setState({
contact_name:this.props.current_user&&this.props.current_user.username contact_name:this.props.current_user&&this.props.current_user.username
}) })

Loading…
Cancel
Save