|
|
|
@ -55,9 +55,11 @@ class PackageIndexNEITaskDetails extends Component {
|
|
|
|
|
getdatas=()=>{
|
|
|
|
|
let url =`/project_packages/${this.props.match.params.id}.json`;
|
|
|
|
|
axios.get(url).then((response) => {
|
|
|
|
|
this.setState({
|
|
|
|
|
data:response.data
|
|
|
|
|
})
|
|
|
|
|
if(response.data.status!=401&&response.data.status!=403&&response.data.status!=408&&response.data.status!=409)[
|
|
|
|
|
this.setState({
|
|
|
|
|
data:response.data
|
|
|
|
|
})
|
|
|
|
|
]
|
|
|
|
|
}).catch((error) => {
|
|
|
|
|
console.log(error);
|
|
|
|
|
|
|
|
|
@ -236,8 +238,12 @@ class PackageIndexNEITaskDetails extends Component {
|
|
|
|
|
|
|
|
|
|
render() {
|
|
|
|
|
let {overtype,data}=this.state;
|
|
|
|
|
// console.log(data&&data.creator.login)
|
|
|
|
|
console.log(data)
|
|
|
|
|
// console.log(data&&data.creator.id)
|
|
|
|
|
let datalogin=data&&data.creator.id;
|
|
|
|
|
let userlogin=this.props.current_user&&this.props.current_user.user_id;
|
|
|
|
|
|
|
|
|
|
console.log(datalogin===userlogin)
|
|
|
|
|
// console.log(this.props.current_user&&this.props.current_user.user_id)
|
|
|
|
|
return (
|
|
|
|
|
data===undefined?"":<div>
|
|
|
|
|
<div className="clearfix">
|
|
|
|
@ -258,11 +264,9 @@ class PackageIndexNEITaskDetails extends Component {
|
|
|
|
|
<Breadcrumb.Item><span className={"tabelcli"} title={data&&data.title}>{data&&data.title}</span></Breadcrumb.Item>
|
|
|
|
|
|
|
|
|
|
</Breadcrumb>
|
|
|
|
|
<a className="color-grey-6 fr font-15 mr20" onClick={this.goback}>返回</a>
|
|
|
|
|
<a className="color-grey-6 fr font-18 mr20" onClick={this.goback}>返回</a>
|
|
|
|
|
<div className="mb20">
|
|
|
|
|
|
|
|
|
|
<p className="clearfix ">
|
|
|
|
|
|
|
|
|
|
<p className="clearfix">
|
|
|
|
|
<div className={"stud-class-set coursenavbox edu-back-white mt20"}>
|
|
|
|
|
<div className={"ant-row contentbox mdInForm "}>
|
|
|
|
|
|
|
|
|
@ -289,12 +293,12 @@ class PackageIndexNEITaskDetails extends Component {
|
|
|
|
|
{data&&data.creator.name}
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
{data&&data.creator.login===this.props.current_user&&this.props.current_user.login?"":<div className=" edu-back-white ml5 mt10 "
|
|
|
|
|
{datalogin===userlogin===true?"":<div className=" edu-back-white ml5 mt10 "
|
|
|
|
|
onMouseOver={this.setover}
|
|
|
|
|
onMouseOut={this.setout}
|
|
|
|
|
>
|
|
|
|
|
{overtype===false?<a className="ContacttheTA fl" target="_blank" href={`/message/${data&&data.creator.login}/message_detail?target_ids=${data&&data.creator.id}`}> <img alt="头像" class="mr5" src={require('./newsone.png')} />联系TA</a>:
|
|
|
|
|
<a className="ContacttheTAs fl" target="_blank" href={`/message/${data&&data.creator.login}/message_detail?target_ids=${data&&data.creator.id}`}> <img alt="头像" className="mr5"
|
|
|
|
|
{overtype===false?<a className="ContacttheTA fl" target="_blank" href={`/message/${this.props.current_user&&this.props.current_user.user_id}/message_detail?target_ids=${data&&data.creator.id}`}> <img alt="头像" class="mr5" src={require('./newsone.png')} />联系TA</a>:
|
|
|
|
|
<a className="ContacttheTAs fl" target="_blank" href={`/message/${this.props.current_user&&this.props.current_user.user_id}/message_detail?target_ids=${data&&data.creator.id}`}> <img alt="头像" className="mr5"
|
|
|
|
|
src={require('./newstwo.png')}/>联系TA</a>}
|
|
|
|
|
</div>}
|
|
|
|
|
</div>
|
|
|
|
@ -304,7 +308,7 @@ class PackageIndexNEITaskDetails extends Component {
|
|
|
|
|
|
|
|
|
|
<div className=" item-body">
|
|
|
|
|
|
|
|
|
|
<div className=" item-head mbf10">
|
|
|
|
|
<div className=" item-head mbf10 mt15 ">
|
|
|
|
|
|
|
|
|
|
<div className=" item-head-title ">
|
|
|
|
|
<span className={"fl mt3 font-18 font-bd color-dark maxwidth700 "}
|
|
|
|
@ -407,7 +411,7 @@ class PackageIndexNEITaskDetails extends Component {
|
|
|
|
|
{item.status==="bidding_won"?<img src={gouxuan} className="yslgouxuanimg"/>:""}
|
|
|
|
|
<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>
|
|
|
|
|
{this.props.current_user&&this.props.current_user.login!=item.login?<a className="ContacttheTAs fl none" target="_blank" href={`/message/${item.login}/message_detail?target_ids=${item.id}`}>
|
|
|
|
|
{this.props.current_user&&this.props.current_user.login!=item.login?<a className="ContacttheTAs fl none" target="_blank" href={`/message/${this.props.current_user&&this.props.current_user.user_id}/message_detail?target_ids=${item.id}`}>
|
|
|
|
|
<img alt="头像" className="mr5" src={require('./newstwo.png')}/>联系TA
|
|
|
|
|
</a>:""}
|
|
|
|
|
</div>
|
|
|
|
|