import React, {Component} from 'react'; import { BrowserRouter as Router, Route, Switch } from 'react-router-dom'; import axios from 'axios'; import moment from 'moment'; import {SnackbarHOC, WordsBtn, getImageUrl} from 'educoder'; import {TPMIndexHOC} from '../../tpm/TPMIndexHOC'; import competition from '../comcss/competition.css'; import {Button, message, Tooltip} from 'antd'; // 点击按钮复制功能 function jsCopy(s) { var e = document.getElementById(s); e.select(); document.execCommand("Copy"); codesuccess() // const range=document.createRange(); // window.getSelection().removeAllRanges(); // range.selectNode(e.target); // window.getSelection().addRange(range); // const successful =document.execCommand('copy'); // if(successful){ // codesuccess() // } } function codesuccess() { message.success('复制成功'); }; // 团队竞赛报名无报名子组件团队 竞赛报名-已创建战队 class PersonalCompetititem extends React.Component { constructor(props) { super(props) } componentDidMount() { // // ////console.log(this.props.data) } componentDidUpdate = (prevProps) => { // // if (prevProps.data != this.props.data) { // // } } render() { const {key, item, type, mode} = this.props; // ////console.log("PersonalCompetititem"); // ////console.log(data); // ////console.log(data[0]); // ////console.log(data&&data[0].creator.image_url); // const listItems = mydatas.map((item, index) => // // ); // console.log("PersonalCompetititem"); // console.log(data); // console.log("PersonalCompetititem"); // console.log(type); // console.log("sdasjdhahsdas"); // console.log(this.props); return (
{ item !== undefined || item !== null ?
{item.creator.name}

{item.name}

{this.props.type === 5 || this.props.type === 2 ? (this.props.mode === 3 ?
{ item && item.team_members.map((item, index) => { return ( index === 0 ? : index === 1 ? : index === 2 ? : index === 3 ?
: "" ) }) }
:
{ item && item.team_members.map((item, index) => { return ( index === 0 ? : index === 1 ? : index === 2 ? : index === 3 ? : index === 4 ? : index === 5 ?
: "" ) }) }
) :
{ item && item.team_members.map((item, index) => { return ( index === 0 ? : index === 1 ? : index === 2 ? : index === 3 ? : index === 4 ? : index === 5 ?
: "" ) }) }
}
邀请码: {item.invite_code === null || item.invite_code === undefined ? "" : item.invite_code}
{item.invite_code === null || item.invite_code === undefined ? : { jsCopy("copy_invite_code" + this.props.index) }} > } { this.props.type === 5 ? (this.props.mode === 3 ?
战队详情
this.props.Exittheteamshow(item.id, true)}>

this.props.Exittheteamshow(item.id, true)}>删除战队

this.props.Createateamedit(item)}>

this.props.Createateamedit(item)}>编辑战队

this.props.Exittheteamshow(item.id, false)}>

this.props.Exittheteamshow(item.id, false)}>退出战队

:
this.props.Exittheteamshow(item.id, true)}>

this.props.Exittheteamshow(item.id, true)}>删除战队

this.props.Createateamedit(item)}>

this.props.Createateamedit(item)}>编辑战队

this.props.Exittheteamshow(item.id, false)}>

this.props.Exittheteamshow(item.id, false)}>退出战队

) : this.props.type === 2 ? (this.props.mode === 3 ?
战队详情
this.props.Exittheteamshow(item.id, true)}>

this.props.Exittheteamshow(item.id, true)}>删除战队

this.props.Createateamedit(item)}>

this.props.Createateamedit(item)}>编辑战队

this.props.Exittheteamshow(item.id, false)}>

this.props.Exittheteamshow(item.id, false)}>退出战队

:
this.props.Exittheteamshow(item.id, true)}>

this.props.Exittheteamshow(item.id, true)}>删除战队

this.props.Createateamedit(item)}>

this.props.Createateamedit(item)}>编辑战队

this.props.Exittheteamshow(item.id, false)}>

this.props.Exittheteamshow(item.id, false)}>退出战队

) : this.props.type === 3 ?
this.props.Exittheteamshow(item.id, false)}>

this.props.Exittheteamshow(item.id, false)}>退出战队

: "" }
: "" }
) } } export default PersonalCompetititem;