dev_tpm_ui
杨树明 5 years ago
parent cb075d0f17
commit 95871b7b46

@ -188,6 +188,7 @@ function JupyterTPI (props) {
// 重置实训
const handleClickResetTpi = () => {
stopposttpip(1)
updataspinning(true)
Modal.confirm({
title: '重置实训',
content: (
@ -206,6 +207,7 @@ function JupyterTPI (props) {
},
onCancel() {
stopposttpip(2)
updataspinning(false)
},
})
}

@ -26,7 +26,7 @@ function RightPane (props) {
const loadInit = (
<div className="jupyter_loading_init">
<Spin tip="加载中..."></Spin>
{/*<Spin tip="加载中..."></Spin>*/}
</div>
);

@ -119,10 +119,7 @@ class Challengesjupyter extends Component {
}else{
if(response.data.status===0){
if(response.data.useSeconds===null){
Modal.warning({
title: '提示',
content: '因为这个实训pod不在了请联系系统管理人员',
});
this.handleClickResetTpi()
}else{
let useSeconds=response.data.useSeconds;
let summain=3600 * 1000;
@ -503,6 +500,7 @@ class Challengesjupyter extends Component {
}
</style>
<span className={"Countdowntypes"}>
{/*this.state.jupytertime*/}
<Countdown value={this.state.jupytertime} format="HH:mm:ss" onFinish={this.onFinish}/>
</span>

@ -248,10 +248,20 @@ export const timeinfo_with_tpi = (identifier, dispatch) => {
if (res.status === 200) {
if(res.data.status===0){
if(res.data.useSeconds===null){
Modal.warning({
title: '提示',
content: '因为这个实训pod不在了无法获取倒计时请联系系统管理人员',
});
Modal.confirm({
title: '重置环境',
content: (
<p style={{ lineHeight: '24px' }}>
是否确定重置环境
</p>
),
okText: '确定',
cancelText: '取消',
onOk () {
reset_with_tpi(identifier, '重置成功');
},
onCancel() {}
})
}else{
let useSeconds=res.data.useSeconds;
let summain=3600 * 1000;

Loading…
Cancel
Save