From 77e3f5b46ac5997f9480e21bce2c76a0dc9fff52 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=9E=97?= <904079904@qq.com>
Date: Thu, 12 Dec 2019 09:53:45 +0800
Subject: [PATCH 1/4] =?UTF-8?q?=E8=B0=83=E6=95=B4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../Challenges/Challengesjupyter.js | 44 ++++++++++++-------
1 file changed, 29 insertions(+), 15 deletions(-)
diff --git a/public/react/src/modules/tpm/shixunchild/Challenges/Challengesjupyter.js b/public/react/src/modules/tpm/shixunchild/Challenges/Challengesjupyter.js
index 86e7f2c04..2eb692f58 100644
--- a/public/react/src/modules/tpm/shixunchild/Challenges/Challengesjupyter.js
+++ b/public/react/src/modules/tpm/shixunchild/Challenges/Challengesjupyter.js
@@ -75,6 +75,16 @@ class Challengesjupyter extends Component {
}else{
console.log("componentDidMountChallengesjupyter");
console.log(response.data);
+ if(response.data.status===0){
+ this.setState({
+ jupyter_url:response.data.url,
+ jupyter_port:response.data.port,
+ })
+
+
+ }else{
+
+ }
}
}
}).catch((error) => {
@@ -142,9 +152,9 @@ class Challengesjupyter extends Component {
let id=this.props.match.params.shixunId;
var jupyter_port="";
try{
- jupyter_port= parseInt(propsysl.shixunsDetails.jupyter_port);
+ jupyter_port= parseInt(this.state.jupyter_port);
}catch (e) {
- jupyter_port=propsysl.shixunsDetails.jupyter_port;
+ jupyter_port=this.state.jupyter_port;
}
const url=`/shixuns/${id}/update_jupyter.json`;
@@ -242,13 +252,22 @@ class Challengesjupyter extends Component {
`
}
+ {
+ this.props.jupyter_url === null || this.props.jupyter_url === undefined ?
+ ""
+ :
+
+
+
+
this.modifyjupyter(this.props)}>
应用到实训
+
+
+ }
-
-
-
this.modifyjupyter(this.props)}>
应用到实训
-
*/}
-
- -
- 学习人数
- {shixunsDetails.stu_num}
-
- {/*- */}
- {/*经验值*/}
- {/*{shixunsDetails.experience}*/}
- {/*
*/}
- -
- 难度级别
- {shixunsDetails.diffcult}
-
-
+
+
+ {/**/}
+
+ -
+ 学习人数
+ {shixunsDetails.stu_num}
+
+ {/*- */}
+ {/*经验值*/}
+ {/*{shixunsDetails.experience}*/}
+ {/*
*/}
+ -
+ 难度级别
+ {shixunsDetails.diffcult}
+
+
-
+
正在等待管理员的审核。在审核通过前,可以随时撤销发布
+
-
- 正在等待管理员的审核。在审核通过前,可以随时撤销发布
-
-
- );
- }
+ );
+ }
}
export default TPMBanner;
diff --git a/public/react/src/modules/tpm/TPMsettings/Shixuninformation.js b/public/react/src/modules/tpm/TPMsettings/Shixuninformation.js
index 1e6980216..b72a4e43f 100644
--- a/public/react/src/modules/tpm/TPMsettings/Shixuninformation.js
+++ b/public/react/src/modules/tpm/TPMsettings/Shixuninformation.js
@@ -64,6 +64,7 @@ class Shixuninformation extends Component {
choice_main_type:this.props.data.shixun.choice_main_type,
choice_small_type:this.props.data.shixun.choice_small_type,
choice_standard_scripts:this.props.data.shixun.choice_standard_scripts,
+ shixunmemoMDvalue:this.props.data.shixun.evaluate_script,
})
this.props.form.setFieldsValue({
@@ -316,7 +317,10 @@ class Shixuninformation extends Component {
let operateauthority=this.props.identity===1?true:this.props.identity<5&&this.props.data.shixun.status==0?true:false;
console.log(operateauthority)
const {getFieldDecorator} = this.props.form;
- const {newshixunlist, languagewrite, systemenvironment, testcoderunmode, fileList, choice_standard_scripts, postapplyvisible, shixunmemoMDvalue} = this.state;
+ const {languagewrite, systemenvironment, testcoderunmode, fileList, choice_standard_scripts, postapplyvisible, shixunmemoMDvalue} = this.state;
+
+ console.log("1222")
+ console.log(choice_standard_scripts)
const {shixun_service_configs}=this.props;
const uploadProps = {
width: 600,
@@ -478,6 +482,7 @@ class Shixuninformation extends Component {
})(
目前该实训项目尚在内测中,将于{shixunsmessage}之后开放,谢谢!
-*/} - {/*知道了*/} - {/*
*/} +目前该实训项目尚在内测中,将于{shixunsmessage}之后开放,谢谢!
+*/} + {/*知道了*/} + {/*
*/}实训已经更新了,正在为您重置!
+实训已经更新了,正在为您重置!
- 发布申请已提交,请等待管理员的审核
--
- 发布申请已提交,请等待管理员的审核
-- • 我们将在1-2个工作日内完成审核 -
- 第 - { - evaluation_set_position.map((item, key) => { - return ( - {item}, - ) - }) - } - 关评测设置尚未完成,无法申请发布 -
-- 每一个关卡至少需要一个技能标签
-- 第 - { - tag_position.map((item, key) => { - return ( - {item}, - ) - }) - } - 关尚未设置技能标签,请补充 -
- 尚未创建任务的实训,不能申请发布 -
-+ 发布申请已提交,请等待管理员的审核
++
+ 发布申请已提交,请等待管理员的审核
++ • 我们将在1-2个工作日内完成审核 +
+ 第 + { + evaluation_set_position.map((item, key) => { + return ( + {item}, + ) + }) + } + 关评测设置尚未完成,无法申请发布 +
++ 每一个关卡至少需要一个技能标签
++ 第 + { + tag_position.map((item, key) => { + return ( + {item}, + ) + }) + } + 关尚未设置技能标签,请补充 +
+ 尚未创建任务的实训,不能申请发布 +
+-
- {
- course_list === undefined ? "" : course_list.map((item, key) => {
- return (
- {item.name}
- )
- })
- }
-
-
-+
+ {
+ course_list === undefined ? "" : course_list.map((item, key) => {
+ return (
+ {item.name}
+ )
+ })
+ }
+
+
+复制将在后台执行,平台将为你创建
-一个新的同名实训和内容,请问是否继续?
复制将在后台执行,平台将为你创建
+一个新的同名实训和内容,请问是否继续?
{can_fork}
-请问是否前往进行认证?
{can_fork}
+请问是否前往进行认证?