|
|
|
@ -6,133 +6,184 @@ import {
|
|
|
|
|
} from 'react-router-dom';
|
|
|
|
|
import axios from 'axios';
|
|
|
|
|
import moment from 'moment';
|
|
|
|
|
import {SnackbarHOC, WordsBtn} from 'educoder';
|
|
|
|
|
import {TPMIndexHOC} from '../tpm/TPMIndexHOC';
|
|
|
|
|
import competition from './comcss/competition.css';
|
|
|
|
|
import {SnackbarHOC, WordsBtn, getImageUrl} from 'educoder';
|
|
|
|
|
import {TPMIndexHOC} from '../../tpm/TPMIndexHOC';
|
|
|
|
|
import competition from '../comcss/competition.css';
|
|
|
|
|
import {Button} from 'antd';
|
|
|
|
|
|
|
|
|
|
// 团队竞赛报名无报名子组件团队 竞赛报名-已创建战队
|
|
|
|
|
class Registrationitem extends React.Component {
|
|
|
|
|
class PersonalCompetititem extends React.Component {
|
|
|
|
|
constructor(props) {
|
|
|
|
|
super(props)
|
|
|
|
|
this.state = {
|
|
|
|
|
data: ""
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
componentDidMount() {
|
|
|
|
|
// //console.log(this.props.data)
|
|
|
|
|
this.setState({
|
|
|
|
|
data: this.props.data,
|
|
|
|
|
})
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
componentDidUpdate = (prevProps) => {
|
|
|
|
|
//
|
|
|
|
|
// if (prevProps.data != this.props.data) {
|
|
|
|
|
//
|
|
|
|
|
// }
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
render() {
|
|
|
|
|
const {data} = this.state;
|
|
|
|
|
//console.log("PersonalCompetititem");
|
|
|
|
|
//console.log(data);
|
|
|
|
|
//console.log(data[0]);
|
|
|
|
|
//console.log(data&&data[0].creator.image_url);
|
|
|
|
|
// const listItems = mydatas.map((item, index) =>
|
|
|
|
|
//
|
|
|
|
|
// );
|
|
|
|
|
return (
|
|
|
|
|
|
|
|
|
|
<div className="regitem">
|
|
|
|
|
<div className="regitemimg1 borders">
|
|
|
|
|
<div className="regitemimg2">
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div className="borders" style={{
|
|
|
|
|
marginTop: "29px",
|
|
|
|
|
marginLeft: "37px"
|
|
|
|
|
}}>
|
|
|
|
|
<p style={{
|
|
|
|
|
border: "1px solid",
|
|
|
|
|
color: "#05101A",
|
|
|
|
|
fontSize: "16px",
|
|
|
|
|
width: "160px",
|
|
|
|
|
textAlign: "center"
|
|
|
|
|
}}>重庆邮电大学</p>
|
|
|
|
|
</div>
|
|
|
|
|
<div className="borders" style={{
|
|
|
|
|
marginLeft: "37px",
|
|
|
|
|
display: "flex",
|
|
|
|
|
flexDirection: "initial",
|
|
|
|
|
width: "487px"
|
|
|
|
|
}}>
|
|
|
|
|
<div className="regitemimgs">
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
<div className="regitemimgs2">
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
<div className="regitemimgs2">
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
<div className="regitemimgs2">
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
<div className="regitemimgs2">
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
<div className="regitemimgs2">
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
<div className="regitemimgs22">
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div className="borders" style={{
|
|
|
|
|
marginLeft: "37px",
|
|
|
|
|
}}>
|
|
|
|
|
<p style={{
|
|
|
|
|
border: "1px solid",
|
|
|
|
|
marginTop: "30px",
|
|
|
|
|
color: "#05101A",
|
|
|
|
|
fontSize: "16px",
|
|
|
|
|
}}>邀请码:yngh5</p>
|
|
|
|
|
</div>
|
|
|
|
|
<div className="regitemimgs3 "
|
|
|
|
|
style={{
|
|
|
|
|
marginLeft: "18px",
|
|
|
|
|
}}
|
|
|
|
|
>
|
|
|
|
|
</div>
|
|
|
|
|
<div>
|
|
|
|
|
{
|
|
|
|
|
this.props.type === 5 ?
|
|
|
|
|
<div className="regitemimgs4"
|
|
|
|
|
style={{
|
|
|
|
|
marginLeft: "32px",
|
|
|
|
|
}}
|
|
|
|
|
>
|
|
|
|
|
<div className="regitemimgs5">
|
|
|
|
|
<p>删除战队</p>
|
|
|
|
|
data && data[0] ? <div className="regitem">
|
|
|
|
|
<div className="regitemimg1 " style={{
|
|
|
|
|
marginBottom: "16px",
|
|
|
|
|
}}>
|
|
|
|
|
<img className="regitemimg2" src={getImageUrl("images/" + data[0].creator.image_url)}>
|
|
|
|
|
|
|
|
|
|
</img>
|
|
|
|
|
<p className="" style={{
|
|
|
|
|
color: "#999999",
|
|
|
|
|
fontSize: "14px",
|
|
|
|
|
width: "78px",
|
|
|
|
|
textAlign: "center"
|
|
|
|
|
|
|
|
|
|
}}>{data && data[0].name}</p>
|
|
|
|
|
</div>
|
|
|
|
|
<div className="regitemimgs6">
|
|
|
|
|
<p>编辑战队</p>
|
|
|
|
|
<div className=" " style={{
|
|
|
|
|
marginTop: "29px",
|
|
|
|
|
marginLeft: "37px"
|
|
|
|
|
}}>
|
|
|
|
|
<p style={{
|
|
|
|
|
|
|
|
|
|
color: "#05101A",
|
|
|
|
|
fontSize: "16px",
|
|
|
|
|
width: "160px",
|
|
|
|
|
textAlign: "center"
|
|
|
|
|
}}>{data && data[0].school_name}</p>
|
|
|
|
|
</div>
|
|
|
|
|
<div className=" " style={{
|
|
|
|
|
marginLeft: "37px",
|
|
|
|
|
display: "flex",
|
|
|
|
|
flexDirection: "initial",
|
|
|
|
|
width: "487px"
|
|
|
|
|
}}>
|
|
|
|
|
{
|
|
|
|
|
data && data[0].team_members.map((item, index) => {
|
|
|
|
|
return (
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
: this.props.type === 2 ?
|
|
|
|
|
<div className="regitemimgs4"
|
|
|
|
|
style={{
|
|
|
|
|
marginLeft: "32px",
|
|
|
|
|
}}
|
|
|
|
|
>
|
|
|
|
|
<div className="regitemimgs5">
|
|
|
|
|
<p>战队详情</p>
|
|
|
|
|
</div>
|
|
|
|
|
<div className="regitemimgs6">
|
|
|
|
|
<p>退出战队</p>
|
|
|
|
|
</div>
|
|
|
|
|
index === 0 ?
|
|
|
|
|
<img className="regitemimgs" src={getImageUrl("images/" + item.image_url)}>
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
:
|
|
|
|
|
this.props.type === 3 ?
|
|
|
|
|
<div className="regitemimgs4"
|
|
|
|
|
style={{
|
|
|
|
|
marginLeft: "32px",
|
|
|
|
|
}}
|
|
|
|
|
>
|
|
|
|
|
</img>
|
|
|
|
|
: index === 1 ?
|
|
|
|
|
<div className="regitemimgs2" src={getImageUrl("images/" + item.image_url)}>
|
|
|
|
|
|
|
|
|
|
<div className="regitemimgs6">
|
|
|
|
|
<p>退出战队</p>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
: index === 2 ?
|
|
|
|
|
<div className="regitemimgs2" src={getImageUrl("images/" + item.image_url)}>
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
:
|
|
|
|
|
""
|
|
|
|
|
</div>
|
|
|
|
|
: index === 3 ?
|
|
|
|
|
<div className="regitemimgs2" src={getImageUrl("images/" + item.image_url)}>
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
</div>
|
|
|
|
|
: index === 4 ?
|
|
|
|
|
<div className="regitemimgs2" src={getImageUrl("images/" + item.image_url)}>
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
: index === 5 ?
|
|
|
|
|
|
|
|
|
|
<div className="regitemimgs2" src={getImageUrl("images/" + item.image_url)}>
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
:
|
|
|
|
|
<div className="regitemimgs22" src={getImageUrl("images/" + item.image_url)}>
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
)
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
<div className=" " style={{
|
|
|
|
|
marginLeft: "37px",
|
|
|
|
|
}}>
|
|
|
|
|
<p style={{
|
|
|
|
|
|
|
|
|
|
marginTop: "30px",
|
|
|
|
|
color: "#05101A",
|
|
|
|
|
fontSize: "16px",
|
|
|
|
|
}}>邀请码:yngh5</p>
|
|
|
|
|
</div>
|
|
|
|
|
<i className="regitemimgs3 iconfont icon-fuzhi1 font-14 font-n"
|
|
|
|
|
style={{
|
|
|
|
|
marginLeft: "18px",
|
|
|
|
|
}}
|
|
|
|
|
>
|
|
|
|
|
</i>
|
|
|
|
|
{
|
|
|
|
|
this.props.type === 5 ?
|
|
|
|
|
<div className="regitemimgs4"
|
|
|
|
|
style={{
|
|
|
|
|
marginLeft: "32px",
|
|
|
|
|
}}
|
|
|
|
|
>
|
|
|
|
|
<div className="regitemimgs5">
|
|
|
|
|
<p>删除战队</p>
|
|
|
|
|
</div>
|
|
|
|
|
<div className="regitemimgs6">
|
|
|
|
|
<p>编辑战队</p>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
: this.props.type === 2 ?
|
|
|
|
|
<div className="regitemimgs4"
|
|
|
|
|
style={{
|
|
|
|
|
marginLeft: "32px",
|
|
|
|
|
}}
|
|
|
|
|
>
|
|
|
|
|
<div className="regitemimgs5">
|
|
|
|
|
<p>战队详情</p>
|
|
|
|
|
</div>
|
|
|
|
|
<div className="regitemimgs6">
|
|
|
|
|
<p>退出战队</p>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
:
|
|
|
|
|
this.props.type === 3 ?
|
|
|
|
|
<div className="regitemimgs4"
|
|
|
|
|
style={{
|
|
|
|
|
marginLeft: "32px",
|
|
|
|
|
}}
|
|
|
|
|
>
|
|
|
|
|
|
|
|
|
|
<div className="regitemimgs6">
|
|
|
|
|
<p>退出战队</p>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
:
|
|
|
|
|
""
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
</div>
|
|
|
|
|
: ""
|
|
|
|
|
}
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -141,4 +192,4 @@ class Registrationitem extends React.Component {
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export default Registrationitem;
|
|
|
|
|
export default PersonalCompetititem;
|
|
|
|
|