dev_tpm_ui
杨树明 5 years ago
parent 7086d250b9
commit 09aecef7b3

@ -105,13 +105,8 @@ class Challengesjupyter extends Component {
} }
} }
componentDidMount() {
let that=this; gettimeinfo_with_tpm=()=>{
setTimeout(this.ChallengesList(), 1000);
let id = this.props.match.params.shixunId;
let datas={
identifier:id,
}
let timeinfo_with_tpm=`/jupyters/timeinfo_with_tpm.json` let timeinfo_with_tpm=`/jupyters/timeinfo_with_tpm.json`
axios.get(timeinfo_with_tpm, {params: datas}).then((response) => { axios.get(timeinfo_with_tpm, {params: datas}).then((response) => {
if (response.data.status === 403||response.data.status === 401||response.data.status === 500) { if (response.data.status === 403||response.data.status === 401||response.data.status === 500) {
@ -138,6 +133,15 @@ class Challengesjupyter extends Component {
}).catch((error) => { }).catch((error) => {
}); });
}
componentDidMount() {
let that=this;
setTimeout(this.ChallengesList(), 1000);
let id = this.props.match.params.shixunId;
let datas={
identifier:id,
}
let ChallengesURL = `/jupyters/get_info_with_tpm.json`; let ChallengesURL = `/jupyters/get_info_with_tpm.json`;
@ -150,6 +154,7 @@ class Challengesjupyter extends Component {
}, 600) }, 600)
}else{ }else{
if(response.data.status===0){ if(response.data.status===0){
this.gettimeinfo_with_tpm(datas)
setTimeout(() => { setTimeout(() => {
this.setState({ this.setState({
jupyter_url:response.data.url, jupyter_url:response.data.url,

Loading…
Cancel
Save