|
|
|
@ -191,14 +191,76 @@ export default { |
|
|
|
|
sessionStorage.setItem('assessmentId', assessmentId) |
|
|
|
|
sessionStorage.setItem('token', token) |
|
|
|
|
if(process.env.NODE_ENV === "development") { |
|
|
|
|
this.intervalJudge = setInterval(() => { |
|
|
|
|
const data = { |
|
|
|
|
id: parseInt(sessionStorage.getItem('assessmentId')), |
|
|
|
|
token: parseInt(sessionStorage.getItem('token')) |
|
|
|
|
} |
|
|
|
|
// 获取教师端最新项目 |
|
|
|
|
let params = { |
|
|
|
|
"systemId":sessionStorage.getItem('systemId'), |
|
|
|
|
"cId":sessionStorage.getItem('cid'), |
|
|
|
|
"permissions":0, |
|
|
|
|
} |
|
|
|
|
getProjectBySystemId(params).then((data)=>{ |
|
|
|
|
if(data.status == 200){ |
|
|
|
|
//获取当前时间 |
|
|
|
|
if(data.data.projects.length !== this.topicList.length) { |
|
|
|
|
this.topicList = data.data.projects |
|
|
|
|
this.selectProjects({ |
|
|
|
|
projectId: this.topicList[0].projectId |
|
|
|
|
}) |
|
|
|
|
|
|
|
|
|
if(this.topicList.length > 0){ |
|
|
|
|
this.gotuQueryVariable() |
|
|
|
|
} |
|
|
|
|
this.getQueryCaches() |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
}).catch((error)=>{ |
|
|
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
checkTest(data).then(data => { |
|
|
|
|
const { data: { data: { status } } } = data |
|
|
|
|
if(status !== 1) { |
|
|
|
|
this.popContainer = true |
|
|
|
|
clearInterval(this.intervalJudge) |
|
|
|
|
this.$message({ |
|
|
|
|
showClose: true, |
|
|
|
|
message: '考核已结束', |
|
|
|
|
type: 'success' |
|
|
|
|
}); |
|
|
|
|
}else { |
|
|
|
|
} |
|
|
|
|
}) |
|
|
|
|
}, 4000) |
|
|
|
|
}else { |
|
|
|
|
this.intervalJudge = setInterval(() => { |
|
|
|
|
const data = { |
|
|
|
|
id: parseInt(sessionStorage.getItem('assessmentId')), |
|
|
|
|
token: parseInt(sessionStorage.getItem('token')) |
|
|
|
|
} |
|
|
|
|
this.getData() |
|
|
|
|
// 获取教师端最新项目 |
|
|
|
|
let params = { |
|
|
|
|
"systemId":sessionStorage.getItem('systemId'), |
|
|
|
|
"cId":sessionStorage.getItem('cid'), |
|
|
|
|
"permissions":0, |
|
|
|
|
} |
|
|
|
|
getProjectBySystemId(params).then((data)=>{ |
|
|
|
|
if(data.status == 200){ |
|
|
|
|
//获取当前时间 |
|
|
|
|
this.getBeginTime() |
|
|
|
|
if(data.data.projects.length !== this.topicList.length) { |
|
|
|
|
this.topicList = data.data.projects |
|
|
|
|
|
|
|
|
|
this.gotuQueryVariable() |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
}).catch((error)=>{ |
|
|
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
checkTest(data).then(data => { |
|
|
|
|
const { data: { data: { status } } } = data |
|
|
|
|
if(status !== 1) { |
|
|
|
@ -324,20 +386,23 @@ export default { |
|
|
|
|
"permissions":0, |
|
|
|
|
} |
|
|
|
|
getProjectBySystemId(params).then((data)=>{ |
|
|
|
|
console.log('---topicList') |
|
|
|
|
console.log(data) |
|
|
|
|
if(data.status == 200){ |
|
|
|
|
console.log(data.data.projects) |
|
|
|
|
//获取当前时间 |
|
|
|
|
this.getBeginTime() |
|
|
|
|
this.topicList = [] |
|
|
|
|
|
|
|
|
|
for (var i=0;i<data.data.projects.length;i++){ |
|
|
|
|
if (data.data.projects[i].projectId){ |
|
|
|
|
this.topicList.push(data.data.projects[i]) |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
if(this.topicList.length > 0){ |
|
|
|
|
this.selectProjects({ |
|
|
|
|
projectId: this.topicList[0].projectId |
|
|
|
|
}) |
|
|
|
|
this.gotuQueryVariable() |
|
|
|
|
// 加的 |
|
|
|
|
} |
|
|
|
|
this.getQueryCaches() |
|
|
|
|
} |
|
|
|
@ -423,7 +488,7 @@ export default { |
|
|
|
|
if(projectId != null){ |
|
|
|
|
//获取当前时间 |
|
|
|
|
this.getBeginTime() |
|
|
|
|
this.topicList = [data.data.projectManage]; |
|
|
|
|
// this.topicList = [data.data.projectManage]; |
|
|
|
|
this.projectId = +params.projectId |
|
|
|
|
this.projectName = data.data.projectManage.projectName |
|
|
|
|
this.projectManage = data.data.projectManage; |
|
|
|
@ -460,9 +525,9 @@ export default { |
|
|
|
|
//线上 |
|
|
|
|
// location.href = 'http://www.huorantech.cn/banksystem/#/index/list?'+'token='+token+'&cid='+cid+'&systemId='+systemId |
|
|
|
|
//测试服 |
|
|
|
|
location.href = 'http://39.108.250.202/banksystem/#/index/list?'+'token='+token+'&cid='+cid+'&systemId='+systemId |
|
|
|
|
// location.href = 'http://39.108.250.202/banksystem/#/index/list?'+'token='+token+'&cid='+cid+'&systemId='+systemId |
|
|
|
|
//本地 |
|
|
|
|
// location.href = "http://192.168.31.254:8093/#/index/list?"+'token='+token+'&cid='+cid+'&systemId='+systemId |
|
|
|
|
location.href = "http://192.168.31.254:8093/#/index/list?"+'token='+token+'&cid='+cid+'&systemId='+systemId |
|
|
|
|
} |
|
|
|
|
}).catch((error)=>{ |
|
|
|
|
}) |
|
|
|
|