dev_202412
yujialong 11 months ago
parent 44368d96b1
commit 79411cfb07
  1. 2
      public/index.html
  2. 1
      src/api/index.js
  3. 46
      src/pages/match/details/index.vue
  4. 2
      src/pages/screen/index.vue
  5. 3
      src/pages/station/preview/index.vue
  6. 6
      src/plugins/requests/index.js

@ -3,7 +3,7 @@
<head> <head>
<meta charset="utf-8" /> <meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" /> <meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="keywords" content="职站,教学,教育,在线编程" /> <meta name="keywords" content="职站,线上教育,教学,教育,在线编程,数字经济,金融科技" />
<meta <meta
name="description" name="description"
content="职站是一款辅助院校教师开展虚拟仿真实验教学的智能云实践平台。平台采用了大数据,云计算等技术,为学校搭建信息化平台提供了基础,可助力院校实现教学智能化升级。职站平台设计遵循着极简、高效的理念,可帮助老师轻松开展实验教学,并支持自定义发布考核和练习,智能统计和检验学生的日常实训练习效果;老师还可以通过可视化图表报告直观查看学生实训成绩,评估教学成果。" content="职站是一款辅助院校教师开展虚拟仿真实验教学的智能云实践平台。平台采用了大数据,云计算等技术,为学校搭建信息化平台提供了基础,可助力院校实现教学智能化升级。职站平台设计遵循着极简、高效的理念,可帮助老师轻松开展实验教学,并支持自定义发布考核和练习,智能统计和检验学生的日常实训练习效果;老师还可以通过可视化图表报告直观查看学生实训成绩,评估教学成果。"

@ -154,6 +154,7 @@ export default {
getCompetitionStageRankingTime: `competition/competitionReleaseTime/getCompetitionStageRankingTime`, getCompetitionStageRankingTime: `competition/competitionReleaseTime/getCompetitionStageRankingTime`,
cCompetitionStageFileSave: `competition/cCompetitionStageFile/save`, cCompetitionStageFileSave: `competition/cCompetitionStageFile/save`,
cCompetitionStageFileDel: `competition/cCompetitionStageFile/batchDeletion`, cCompetitionStageFileDel: `competition/cCompetitionStageFile/batchDeletion`,
viewEventAllocationInformation: `competition/competitionAutomaticAllocationRecord/viewEventAllocationInformation`,
// 创业活动 // 创业活动
activityList: `occupationlab/occupationlab/activity/activityList`, activityList: `occupationlab/occupationlab/activity/activityList`,

@ -94,7 +94,7 @@
</template> </template>
<template v-if="form.completeCompetitionSetup.competitionType"> <template v-if="form.completeCompetitionSetup.competitionType">
<p>每个团队参赛人数限制{{ rule.teamNumLimit || '不限制' }}</p> <p>每个团队参赛人数限制{{ rule.customNumber || '不限制' }}</p>
<p>团队成绩计算方式{{ teamCalculationMethods.find(e => e.id == rule.teamCalculationMethod) && teamCalculationMethods.find(e => e.id == rule.teamCalculationMethod).name }}</p> <p>团队成绩计算方式{{ teamCalculationMethods.find(e => e.id == rule.teamCalculationMethod) && teamCalculationMethods.find(e => e.id == rule.teamCalculationMethod).name }}</p>
</template> </template>
<!-- <p v-if="rule.resultAnnouncementTime != 0">阶段比赛结束后{{ rule.resultAnnouncementTime }}小时公布阶段比赛成绩</p> --> <!-- <p v-if="rule.resultAnnouncementTime != 0">阶段比赛结束后{{ rule.resultAnnouncementTime }}小时公布阶段比赛成绩</p> -->
@ -336,6 +336,10 @@
<tr> <tr>
<th>竞赛阶段</th> <th>竞赛阶段</th>
<td> <td>
<div class="m-b-10 text-right">
<el-button type="primary"
@click="automaticAllocation">自动分配阶段成员</el-button>
</div>
<table class="table tc"> <table class="table tc">
<tr> <tr>
<th width="70">序号</th> <th width="70">序号</th>
@ -354,7 +358,7 @@
<td>{{ i + 1 }}</td> <td>{{ i + 1 }}</td>
<td>{{ item.stageName || form.name }}</td> <td>{{ item.stageName || form.name }}</td>
<template v-if="form.completeCompetitionSetup.competitionType"> <template v-if="form.completeCompetitionSetup.competitionType">
<td>{{ item.teamNumLimit || '不限制' }}</td> <td>{{ item.customNumber || '不限制' }}</td>
<td> <td>
<template v-if="item.participants"> <template v-if="item.participants">
<el-tag v-for="tag in item.participants" <el-tag v-for="tag in item.participants"
@ -573,8 +577,8 @@
:key="i" :key="i"
:label="item.accountId">{{ item.userName }}</el-checkbox> :label="item.accountId">{{ item.userName }}</el-checkbox>
</el-checkbox-group> </el-checkbox-group>
<p v-if="info.teamLimit && curRow.teamNumLimit" <p v-if="info.teamLimit && curRow.customNumber"
style="margin-top: 15px;font-size: 12px;">当前阶段限制{{ curRow.teamNumLimit }}人参赛且此竞赛每个成员只能参加一个阶段赛项</p> style="margin-top: 15px;font-size: 12px;">当前阶段限制{{ curRow.customNumber }}人参赛且此竞赛每个成员只能参加一个阶段赛项</p>
<span slot="footer" <span slot="footer"
class="dialog-footer"> class="dialog-footer">
<el-button size="small" <el-button size="small"
@ -758,7 +762,6 @@ export default {
], ],
progress: [], progress: [],
timer: null, timer: null,
rankTimer: null,
notices: [], notices: [],
noticeDetail: {}, noticeDetail: {},
curArch: '0', curArch: '0',
@ -832,7 +835,8 @@ export default {
client: null, client: null,
uploading: false, uploading: false,
uploadProgress: 0, uploadProgress: 0,
now: '' now: '',
allocated: 0,
}; };
}, },
computed: { computed: {
@ -846,7 +850,6 @@ export default {
mounted () { mounted () {
this.$once('hook:beforeDestroy', function () { this.$once('hook:beforeDestroy', function () {
clearInterval(this.timer) clearInterval(this.timer)
clearInterval(this.rankTimer)
this.timerList.forEach(n => { this.timerList.forEach(n => {
clearTimeout(n) clearTimeout(n)
}) })
@ -856,6 +859,7 @@ export default {
this.getProgress() this.getProgress()
this.getNotice() this.getNotice()
this.getTeam() this.getTeam()
this.getAutomaticAllocation()
this.initOss() this.initOss()
}, },
@ -1189,7 +1193,6 @@ export default {
// //
intervalRank () { intervalRank () {
this.getRank() this.getRank()
// this.rankTimer = setInterval(this.getRank, 1000)
}, },
// //
@ -1299,6 +1302,11 @@ export default {
}).catch(() => { }) }).catch(() => { })
} }
}, },
//
async getAutomaticAllocation () {
const res = await this.$post(`${this.api.viewEventAllocationInformation}?competitionId=${this.id}`)
this.allocated = true
},
// //
async removePar (e, stage) { async removePar (e, stage) {
const item = this.form.competitionStage.find(e => e.stageId == stage.stageId) const item = this.form.competitionStage.find(e => e.stageId == stage.stageId)
@ -1362,7 +1370,7 @@ export default {
const accountIds = this.checkedMembers const accountIds = this.checkedMembers
if (!accountIds.length) return Util.errorMsg('请选择参赛成员!') if (!accountIds.length) return Util.errorMsg('请选择参赛成员!')
const limit = this.curRow.teamNumLimit // const limit = this.curRow.teamNumLimit //
if (limit && accountIds.length > limit) return Util.errorMsg(`请选择${limit}个以下参赛成员!`) // if (limit && accountIds.length > limit) return Util.errorMsg(`请选择${this.curRow.customNumber}个以下参赛成员!`) //
this.$post(this.api.stageSelectParticipants, { this.$post(this.api.stageSelectParticipants, {
accountIds, accountIds,
competitionId: this.id, competitionId: this.id,
@ -1467,8 +1475,28 @@ export default {
this.enterVisible = false this.enterVisible = false
this.getData() this.getData()
Util.successMsg('报名成功!') Util.successMsg('报名成功!')
this.afterCreateTeam()
}).catch(res => { }) }).catch(res => { })
}, },
//
afterCreateTeam () {
//
if (this.allocated) {
Util.successMsg('团队创建成功,系统将自动帮您分配阶段参赛成员,您也可以到参数信息进行指定')
} else {
//
this.$confirm('是否要启用自动分配成员参加阶段赛项', '提示', {
cancelButtonText: '否',
confirmButtonText: '是',
type: 'success',
closeOnClickModal: false,
}).then(() => {
// this.automaticAllocation(1, next)
}).catch(() => {
// this.automaticAllocation(0, next)
});
}
},
// //
teamClose () { teamClose () {
this.teamForm = { this.teamForm = {

@ -1137,7 +1137,7 @@ export default {
const dom = this.$refs.popularCourses const dom = this.$refs.popularCourses
const dom1 = this.$refs.ach const dom1 = this.$refs.ach
const dom2 = this.$refs.active const dom2 = this.$refs.active
const unit = window.innerWidth >= 1920 ? 2 : 1 const unit = window.innerWidth > 1920 ? 2 : 1
setInterval(() => { setInterval(() => {
dom.scrollTop += unit dom.scrollTop += unit
if (dom.clientHeight + dom.scrollTop >= dom.scrollHeight) dom.scrollTop = 0 if (dom.clientHeight + dom.scrollTop >= dom.scrollHeight) dom.scrollTop = 0

@ -925,7 +925,6 @@ export default {
}, },
// //
showProjectDia () { showProjectDia () {
console.log(123)
this.projectVisible = true this.projectVisible = true
}, },
// //
@ -1008,7 +1007,7 @@ export default {
`${location.origin}/pyTrials` `${location.origin}/pyTrials`
}, },
// //
toSub () { async toSub () {
let curProject = this.projects.find(e => e.projectId == this.curProject) let curProject = this.projects.find(e => e.projectId == this.curProject)
if (!curProject && this.projects.length) { if (!curProject && this.projects.length) {
curProject = this.projects[0] curProject = this.projects[0]

@ -28,6 +28,7 @@ service.interceptors.request.use(config => {
return Promise.reject(err); return Promise.reject(err);
}); });
let logouted = 0;
// 响应拦截器 // 响应拦截器
service.interceptors.response.use( service.interceptors.response.use(
response => { response => {
@ -56,6 +57,7 @@ service.interceptors.response.use(
// 未登录则跳转登录页面,并携带当前页面的路径 // 未登录则跳转登录页面,并携带当前页面的路径
// 在登录成功后返回当前页面,这一步需要在登录页操作。 // 在登录成功后返回当前页面,这一步需要在登录页操作。
case 401: case 401:
if (!logouted) {
util.local.remove(Setting.storeKey); util.local.remove(Setting.storeKey);
util.local.remove(Setting.tokenKey); util.local.remove(Setting.tokenKey);
util.errorMsg("登录过期,请重新登录"); util.errorMsg("登录过期,请重新登录");
@ -64,7 +66,9 @@ service.interceptors.response.use(
path: "/login" path: "/login"
}); });
}, 1000); }, 1000);
break; logouted = 1
}
break;
case 500: case 500:
util.errorMsg("网络错误"); util.errorMsg("网络错误");
break; break;

Loading…
Cancel
Save