dev_202412
yujialong 1 year ago
parent 69010141d5
commit c179ffad7b
  1. 2
      public/index.html
  2. 1
      src/api/index.js
  3. 9
      src/layouts/header/index.vue
  4. 71
      src/pages/ass/list/index.vue
  5. 4
      src/pages/index/list/index.vue
  6. 6
      src/pages/match/details/index.vue
  7. 6
      src/pages/match/list/index.vue
  8. 2
      src/setting.js
  9. 18
      src/styles/layout/index.scss

@ -9,7 +9,7 @@
content="职站是一款辅助院校教师开展虚拟仿真实验教学的智能云实践平台。平台采用了大数据,云计算等技术,为学校搭建信息化平台提供了基础,可助力院校实现教学智能化升级。职站平台设计遵循着极简、高效的理念,可帮助老师轻松开展实验教学,并支持自定义发布考核和练习,智能统计和检验学生的日常实训练习效果;老师还可以通过可视化图表报告直观查看学生实训成绩,评估教学成果。"
/>
<meta name="baidu-site-verification" content="code-TRfXe8xIkJ" />
<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
<meta name="viewport" content="width=device-width, user-scalable=yes, shrink-to-fit=no" />
<link rel="stylesheet" href="//at.alicdn.com/t/font_830376_qzecyukz0s.css" />
<title>职站——为院校打造一站式虚拟仿真实训教学数智云平台</title>
<script>

@ -20,6 +20,7 @@ export default {
refreshPageNotification : `nakadai/message/refreshPageNotification`,
getUserInfo : `users/users/userInfo/getUserInfo`,
getCurrentTime : `competition/competition/management/getCurrentTime`,
heartbeatDetection : `nakadai/message/heartbeatDetection`,
// 阿里云文件/视频管理
getPlayAuth: `${uploadURL}oss/manage/getPlayAuth`, // 获取播放凭证

@ -128,6 +128,7 @@ export default {
this.$once('hook:beforeDestroy', function () {
clearInterval(this.noticeTimer)
})
this.heartbeatDetection()
},
methods: {
...mapMutations("user", [
@ -180,7 +181,7 @@ export default {
initSocket ({ id, account }) {
// socket
this.socket = new WebSocket(`${Setting.isTest ? 'ws' : 'wss'}://${Setting.isDev ? '121.37.12.51' : location.host}/nakadai/websocket/${id}/${account}`)
// this.socket = new WebSocket(`ws://121.37.12.51:9100/nakadai/websocket/${id}/${account}`)
// this.socket = new WebSocket(`ws://192.168.31.51:9100/nakadai/websocket/${id}/${account}`)
// socket
this.socket.onopen = this.open;
// socket
@ -188,6 +189,12 @@ export default {
// socket
this.socket.onmessage = this.getMessage;
},
//
heartbeatDetection () {
setInterval(async () => {
await this.$get(this.api.heartbeatDetection)
}, 58 * 1000)
},
//

@ -146,7 +146,7 @@
<el-button v-if="scope.row.status == 2 && scope.row.stuState == 0"
type="text"
disabled>未参加</el-button>
<el-button v-if="(scope.row.status == 2 && scope.row.stuState == 1) || (scope.row.status == 2 && scope.row.stuState == 2 && scope.row.reportId == null)"
<el-button v-if="(scope.row.status == 2 && scope.row.stuState == 1) || (scope.row.status == 2 && scope.row.stuState == 2 && !scope.row.reportId)"
type="text"
disabled>
未提交
@ -270,8 +270,6 @@ export default {
assessmentId: '',
classId: '',
stopTime: '',
sss: 1,
datassdata: 0,
};
},
computed: {
@ -313,7 +311,6 @@ export default {
//
this.$once("hook:beforeDestroy", function () {
this.sss = 0
clearInterval(this.ticker);
this.ticker = null;
});
@ -322,11 +319,11 @@ export default {
this.getClassData();
},
methods: {
timeFilter (countDown) {
if (countDown.countDown > 0) {
let h = Math.floor(countDown.countDown / (60 * 60));
let m = Math.floor(countDown.countDown % (60 * 60) / 60);
let s = Math.floor(countDown.countDown % (60 * 60) % 60);
timeFilter (row) {
if (row.countDown > 0) {
let h = Math.floor(row.countDown / (60 * 60));
let m = Math.floor(row.countDown % (60 * 60) / 60);
let s = Math.floor(row.countDown % (60 * 60) % 60);
return `${h > 9 ? h : `0${h}`}:${m > 9 ? m : `0${m}`}:${s > 9 ? s : `0${s}`}`;
} else {
return "00:00:00";
@ -335,35 +332,24 @@ export default {
beginTimer () {
clearInterval(this.ticker)
this.ticker = setInterval(() => {
if (this.sss == 0) {
this.ticker = null;
clearInterval(this.ticker);
} else {
for (let i = 0; i < this.listData.length; i++) {
const item = this.listData[i];
if (item.countDown > 0) {
item.countDown--;
} else {
if (item.status == 0 && item.type == 2) { // -
item.status = 1;
item.countDown = (new Date(item.stopTime).getTime() - new Date().getTime()) / 1000;
} else if (item.status == 1) {
// item.status = 2;
}
for (let i = 0; i < this.listData.length; i++) {
const item = this.listData[i];
if (item.countDown > 0) {
item.countDown--;
} else {
if (item.status == 0 && item.type == 2) { // -
item.status = 1;
item.countDown = (new Date(item.stopTime).getTime() - new Date().getTime()) / 1000;
} else if (item.status == 1) {
// item.status = 2;
}
this.$set(this.listData, i, item);
}
this.$set(this.listData, i, item);
}
}, 1000);
},
getData () {
this.listLoading = true;
this.sss = 0
this.listData.splice(0);
if (this.ticker) {
clearInterval(this.ticker);
}
let data = {
...this.form,
pageNum: this.page,
@ -371,47 +357,39 @@ export default {
};
this.$post(this.api.pageStuAssessment, data).then(res => {
this.listData = res.list;
for (var i = 0; i < this.listData.length; i++) {
if (this.listData[i].reportId == undefined) {
this.listData[i].reportId = null
}
}
this.totals = res.total;
this.listData.forEach(i => {
let countDown = 0
if (i.status == 2) { //
i.countDown = 0;
countDown = 0;
} else {
if (i.type == 2) { //
if (i.status == 0) {
//
i.countDown = (new Date(i.startTime).getTime() - new Date().getTime()) / 1000; //
countDown = (new Date(i.startTime).getTime() - new Date().getTime()) / 1000; //
} else if (i.status == 1) {
//
i.countDown = (new Date(i.stopTime).getTime() - new Date().getTime()) / 1000;
countDown = (new Date(i.stopTime).getTime() - new Date().getTime()) / 1000;
}
} else if (i.type == 1) { //
if (i.status == 0) {
//
i.countDown = 0;
countDown = 0;
} else if (i.status == 1) {
//
i.countDown = (new Date(i.stopTime).getTime() - new Date().getTime()) / 1000;
countDown = (new Date(i.stopTime).getTime() - new Date().getTime()) / 1000;
}
}
}
this.$set(i, 'countDown', countDown)
});
this.sss = 1;
// if(this.datassdata == 0){
// this.datassdata = this.datassdata+1
this.beginTimer()
// }
this.listLoading = false;
}).catch(err => {
this.listLoading = false;
});
},
initData () {
this.sss = 0
this.page = 1;
this.getData();
},
@ -429,7 +407,6 @@ export default {
},
handleCurrentChange (val) { //
this.page = val;
this.sss = 0
this.getData();
},
entry (row) { //

@ -391,7 +391,9 @@ export default {
}
},
mounted () {
new WOW().init()
new WOW({
mobile: false
}).init()
},
methods: {
toPart (i) {

@ -1704,9 +1704,9 @@ export default {
//
toSub () {
const { form } = this
const { systemId, systemName, projectId, cid, stageId, startTime, endTime, mallId } = this.curStage
const { systemId, systemName, projectId, cid, stageId, startTime, endTime, mallId, resultAnnouncementTime } = this.curStage
const competitionId = form.id
const teamId = form.competitionRegistration.teamId
const teamId = form.competitionRegistration.teamId || ''
let token = Util.local.get(Setting.tokenKey);
if (systemId == 11) {
//
@ -1716,7 +1716,7 @@ export default {
window.open(`http://${Setting.zcPath}?systemId=${systemId}&courseId=${cid}&projectId=${projectId}&token=${token}&userId=${this.userId}&classId=1&competitionId=${competitionId}&stageId=${stageId}&teamId=${teamId}&startTime=${startTime}&endTime=${endTime}&mallId=${mallId}${Setting.isTest ? '&beta=1' : ''}`);
} else if (systemId == 19) {
//
location.href = `${Setting.sandPath}/#/?curriculumName=${systemName}&token=${token}&cid=${cid}&mallId=${mallId}&systemId=${systemId}&projectId=${projectId}&assessmentId=&classId=&startTime=&stopTime=${endTime}&competitionId=${competitionId}&stageId=${stageId}&teamId=${teamId}&userId=${this.userId}&account=${this.account}&referrer=${encodeURIComponent(location.href)}`
location.href = `${Setting.sandPath}/#/?curriculumName=${systemName}&token=${token}&cid=${cid}&mallId=${mallId}&systemId=${systemId}&projectId=${projectId}&assessmentId=&classId=&startTime=&stopTime=${endTime}&competitionId=${competitionId}&stageId=${stageId}&teamId=${teamId}&resultAnnouncementTime=${resultAnnouncementTime || ''}&userId=${this.userId}&account=${this.account}&referrer=${encodeURIComponent(location.href)}`
} else {
// python
this.toPython(this.curProject)

@ -1037,9 +1037,9 @@ export default {
//
toSub () {
const form = this.curItem
const { systemId, systemName, projectId, cid, stageId, startTime, endTime, mallId } = form.curStage
const { systemId, systemName, projectId, cid, stageId, startTime, endTime, mallId, resultAnnouncementTime } = form.curStage
const competitionId = form.id
const teamId = form.teamId
const teamId = form.teamId || ''
let token = Util.local.get(Setting.tokenKey);
if (systemId == 11) {
//
@ -1049,7 +1049,7 @@ export default {
window.open(`http://${Setting.zcPath}?systemId=${systemId}&courseId=${cid}&projectId=${projectId}&token=${token}&userId=${this.userId}&classId=1&competitionId=${competitionId}&stageId=${stageId}&teamId=${teamId}&startTime=${startTime}&endTime=${endTime}&mallId=${mallId}${Setting.isTest ? '&beta=1' : ''}`);
} else if (systemId == 19) {
//
location.href = `${Setting.sandPath}/#/?curriculumName=${systemName}&token=${token}&cid=${cid}&mallId=${mallId}&systemId=${systemId}&projectId=${projectId}&assessmentId=&classId=&startTime=&stopTime=${endTime}&competitionId=${competitionId}&stageId=${stageId}&teamId=${teamId}&userId=${this.userId}&account=${this.account}&referrer=${encodeURIComponent(location.href)}`
location.href = `${Setting.sandPath}/#/?curriculumName=${systemName}&token=${token}&cid=${cid}&mallId=${mallId}&systemId=${systemId}&projectId=${projectId}&assessmentId=&classId=&startTime=&stopTime=${endTime}&competitionId=${competitionId}&stageId=${stageId}&teamId=${teamId}&resultAnnouncementTime=${resultAnnouncementTime || ''}&userId=${this.userId}&account=${this.account}&referrer=${encodeURIComponent(location.href)}`
} else {
// python
this.toPython()

@ -35,7 +35,7 @@ if (isPro) {
uploadURL = `http://121.37.12.51/`
host = "http://121.37.12.51/"; // 测试服
// host = 'https://www.occupationlab.com/' // 正式服
host = "http://192.168.31.217:9000/";
host = "http://192.168.31.51:9000/";
} else if (isSq) {
zcPath = `10.20.100.204:8883`
}

@ -1,17 +1,17 @@
@import "lib/var";
@import "var";
@import 'lib/var';
@import 'var';
html,
body,
#app,
.wrapper {
width: 100%;
height: 100%;
width: 100%;
height: 100%;
}
body {
min-width: 1280px;
font-family: PingFangSC-Regular, PingFang SC;
font-size: 14px;
background: rgba(0, 0, 0, 0.02);
}
min-width: 1280px;
font-family: PingFangSC-Regular, PingFang SC;
font-size: 14px;
background: rgba(0, 0, 0, 0.02);
}

Loading…
Cancel
Save